<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/112645/utf8-encoding-in-ncs</link><description>I want to convert raw hex bytes to utf8 format. The nRF5 SDK supported this with help of ble_srv_ascii_to_utf8() api. Is there something similar api available with nRF Connect SDK?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 03 Jul 2024 07:49:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/112645/utf8-encoding-in-ncs" /><item><title>RE: UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/thread/491986?ContentTypeID=1</link><pubDate>Wed, 03 Jul 2024 07:49:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d8767b41-2d93-42f8-b687-f705b274e95f</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;I&amp;#39;m happy to hear that you have things working as you wanted. Please feel free to close this ticket at your convenience.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/thread/491966?ContentTypeID=1</link><pubDate>Wed, 03 Jul 2024 06:45:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6766e213-d5e8-466e-85d9-6a2cf5c8863a</guid><dc:creator>Aniket95</dc:creator><description>&lt;p&gt;Hi Hieu,&lt;/p&gt;
&lt;p&gt;I am handling it as an uint8_t array. Anyways I believe the problem was just about representation of data on nRFConnect app. I just named the characteristic, changed the format and it gave me the expected result.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks for your help though&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/thread/491926?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2024 18:33:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c3004eb9-0cfb-414e-8b54-833cd6b80082</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;Hi Aniket,&lt;/p&gt;
&lt;p&gt;If it&amp;#39;s ASCII, can&amp;#39;t you just treat your string into a uint8_t array?&lt;/p&gt;
&lt;p&gt;What is the type of your string in the first place? How are you handling it? I always handle&amp;nbsp;simple ASCII text string as uint8_t array from the beginning, so I&amp;nbsp;cannot really imagine what you want.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/thread/491896?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2024 15:15:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f1ef268f-ce39-47cf-b1dc-96187b4a894d</guid><dc:creator>Aniket95</dc:creator><description>&lt;p&gt;Hello Hieu,&lt;/p&gt;
&lt;p&gt;Basically I need to convert hex bytes to ASCII and send it over BLE. So if I have 0x45 it should be represented as E. So I am wondering if there is any API exist for this in NCS.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: UTF8 encoding in NCS</title><link>https://devzone.nordicsemi.com/thread/491885?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2024 14:37:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1245f767-db6b-41e6-af0f-97eba8eac23e</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;Hi Aniket,&lt;/p&gt;
&lt;p&gt;Do you need to convert raw UTF-8 encoded hex bytes to UTF-8, or do you need to convert ASCII-encoded bytes to UTF-8?&lt;/p&gt;
&lt;p&gt;If your input is in ASCII, then it is already UTF-8 encoded, because ASCII is a subset of&amp;nbsp;UTF-8.&lt;/p&gt;
&lt;p&gt;Hieu&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>