<?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>Identifying beacons with 128 bit UUID</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/20880/identifying-beacons-with-128-bit-uuid</link><description>Hi, 
 I am working on a project where I have 4 advertising beacons which will have to trigger some functions in the central side when it gets the advertising data.
Now I am currently working on the central(ble_app_uart) side which will have to check</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 29 Mar 2017 12:57:23 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/20880/identifying-beacons-with-128-bit-uuid" /><item><title>RE: Identifying beacons with 128 bit UUID</title><link>https://devzone.nordicsemi.com/thread/81539?ContentTypeID=1</link><pubDate>Wed, 29 Mar 2017 12:57:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:35d1b0be-1dcf-4a42-bca5-1917acdbf4a2</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;@Erblin : The function is_uuid_present() is the function you want to use for identifying a 128-bit UUID.&lt;/p&gt;
&lt;p&gt;For custom/vendor specific UUIDs, the UUID should be added to the softdevice using sd_ble_uuid_vs_add(). When using that function, the 128-bit UUID is added to a table internally in the softdevice. The out parameter from sd_ble_uuid_vs_add() is the index in the table where the UUID is located.  As stated in the documentation for sd_ble_uuid_vs_add(), the function will disregard byte 12 and 13 of the UUID (they are set to &amp;#39;0&amp;#39; in the internal table).&lt;/p&gt;
&lt;p&gt;The struct ble_uuid_t has two members:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;type: The index in the table where the UUID can be found.&lt;/li&gt;
&lt;li&gt;uuid: A 16-bit UUID (2 bytes),  corresponding to byte 12 and 13 that were disregarded when the 128-bit UUID was added to the softdevice.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The example ble_app_uart_c uses is_uuid_present() to identify ble_app_uart peripheral devices.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Identifying beacons with 128 bit UUID</title><link>https://devzone.nordicsemi.com/thread/81540?ContentTypeID=1</link><pubDate>Tue, 28 Mar 2017 14:06:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:af8b2fac-0fba-4c50-af47-9cb3a174ba2a</guid><dc:creator>endnode</dc:creator><description>&lt;p&gt;Hi Erblin,&lt;/p&gt;
&lt;p&gt;UUID is name of Service (literally) or in other words name of application (this is not 100% accurate but as GATT Services are used as atomic block by every Application which is using GATT/GAP we can imagine it like that). If your application don&amp;#39;t use BLE Connection or is able to workaround uncertainty of name on GATT layer (because you would be assigning different UUID to each device) then you could go that way. However normally device identification is either GAP device name (also possible to include into ADV_IND packet) or even more commonly Adv. address (6-byte MAC visible in every packet on LL layer).&lt;/p&gt;
&lt;p&gt;When it comes to UUID usage and management in BLE and Nordic stack (Soft Device) specifically is another wider topic. In short there are always &amp;quot;long&amp;quot; 16-byte (128-bit) UUIDs but BT SIG defines so called &amp;quot;base&amp;quot; UUID (and one specific value is assigned to all BT SIG UUIDs) and then 2-byte (16-bit) range which can be called &amp;quot;short&amp;quot; UUID. So if you see 2-byte UUIDs in actual BLE packet then it means some standard object (Service/Characteristic/Descriptor) UUID defined by BT SIG spec. All other UUIDs should be exposed in &amp;quot;long&amp;quot; form but they can be again imagined as 128-bit &amp;quot;base&amp;quot; UUID (no with custom value) and &amp;quot;short&amp;quot; 2-byte range on top of it. This is how Nordic stack represents (in some APIs like GATT Server) UUIDs and that&amp;#39;s what is explained in the code snapshots above. If you want to define your UUID then you cannot use BT SIG hence you define your own &amp;quot;base&amp;quot; UUID and 2-byte &amp;quot;short&amp;quot; UUIDs on top of it and work with these structures on top of Nordic SD GATT API calls/structures.&lt;/p&gt;
&lt;p&gt;Cheers&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>