• It's really simple... If you're feeling lucky, simply copy & paste the emoji and upload from the right-hand side of the IDE:

      NRF.setAdvertising({},{ name: "⚡" });
    

    And this should work as long as your IDE is up to date.

    If you're feeling more restrained, you just need the UTF-8 bytes for the emoji you're using - which you can get easily from:

    https://apps.timwhitlock.info/emoji/tabl­es/unicode

    For instance the high voltage sign is U+26A1, but the UTF-8 encoding as bytes is \xE2\x9A\xA1

    So then just do:

      NRF.setAdvertising({},{ name: "\xE2\x9A\xA1" });
    

    Note: While it looks like you're only using 1 character, you are actually sending 3 or 4 bytes - you'll only be able to send a few unicode characters in the relatively small amount of space there is for an advertising name.


    1 Attachment

    • Screenshot_20190408-163723.png
About

Avatar for Gordon @Gordon started