Commit graph

11 commits

Author SHA1 Message Date
dnlwgnd
e0d5fd4c3a
add ServiceData advertising element (#243)
* gap: fix comment

* gap: expose ServiceData() in AdvertisementFields

* macos: include ServiceData in AdvertisementFields

* gap/linux: include ServiceData in AdvertisementFields

* gap: add unimplemented ServiceData() to raw advertisement

* added ServiceData advertising element also to the sending pieces

* more explicitly use the ad element type ids

* added a test case for ServiceData

* linux: added ServiceData advertising element

* sd: fix: handle no servicedata present

* linux: bluez uses string uuids for service data

* linux: fix: correct datatype for advertise with ServiceData

* uuid: add 32-Bit functions

* ServiceData now also uses a slice instead of a map as in #244

* Revert unnessesary changes

* formatting

* remove extra check

---------

Co-authored-by: William Johansson <radar@radhuset.org>
2024-03-18 22:15:09 +01:00
deadprogram
79285321af all: unify UUID16 creation for all platforms
Signed-off-by: deadprogram <ron@hybridgroup.com>
2022-09-05 15:58:01 +02:00
Bart Meuris
948ea8c7ee
Improve UUID (#107)
Improvements to UUID:
* uuid now works with upper and lowercase
* sped up UUID.String() using stringbuilder, added benchmark
* UUID.String(): grow builder to prevent allocs
* make test in cicd happy
2022-08-25 14:22:52 +02:00
Ron Evans
b4b125480a darwin: properly handle 16-bit UUIDs for service and characteristics in the unique format used by macOS
Signed-off-by: Ron Evans <ron@hybridgroup.com>
2021-02-02 00:17:14 +01:00
Olaf Flebbe
5bedd1dccc fix ParseUUID. Return error for invalid UUID strings 2020-09-14 23:19:52 +02:00
Ayke van Laethem
e0314251c9
all: support HasServiceUUID on advertisement payloads
I have intentionally chosen to implement HasServiceUUID() and not
ServiceUUIDs() because returning a slice of UUIDs will likely cause a
heap allocation. And perhaps the most common use may be checking whether
a packet has a particular UUID, so no list is necessary. Getting the
full list can of course be implemented in the future, if needed.
2020-06-04 19:23:25 +02:00
Ayke van Laethem
21100ebc19
all: add service UUIDs to advertisement packets
Support both 16-bit and 128-bit UUIDs on both Linux and Nordic chips.
2020-06-02 14:00:32 +02:00
Ayke van Laethem
5ed4112930
go fmt 2020-05-27 16:50:21 +02:00
Ayke van Laethem
00e2592aff linux: add support for services
Unfortunately, I couldn't get characteristics to work.
2019-11-16 19:11:59 +00:00
Ayke van Laethem
23c2fa38e4
softdevice: fix some comments 2019-11-16 19:01:22 +01:00
Ayke van Laethem
0cabe28570
Initial commit 2019-11-08 10:58:02 +01:00