Question

In the document ,the serivce's uuid is something like [A-F0-9]{4} while Android BLE sevice's uuid is something like '[A-F0-9]{8}-[A-F0-9]{4}-[A-F0-9]{4}-[A-F0-9]{4}-[A-F0-9]{12}'. And Schema docs say :

<?xml version="1.0" encoding="utf-16"?>
  <xs:simpleType name="uuid">
    <xs:restriction base="xs:string">
      <xs:pattern value="[A-F0-9]{4}" />
      <xs:pattern value="[A-F0-9]{8}-[A-F0-9]{4}-[A-F0-9]{4}-[A-F0-9]{4}-[A-F0-9]{12}" />
   </xs:restriction>
</xs:simpleType>

Are they the same uuid OR just the same thing with different face?
And Why there are two patterns?I think ONE is OK!
Any one can explain why are they not the same? OR can have some java code to convert one to the other ?

Was it helpful?

Solution

After asking someone on Hardware Work, I got a role mapping UUID32 to UUID128 example is:

FF12-->0000FF12-0000-1000-8000-00805f9b34fb

And via Google I got : enter image description here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top