update uuid generation
This commit is contained in:
parent
be99863ef5
commit
34cb58db57
8 changed files with 2158 additions and 1059 deletions
3
.gitmodules
vendored
Normal file
3
.gitmodules
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
[submodule "bluetooth-numbers-database"]
|
||||
path = bluetooth-numbers-database
|
||||
url = https://github.com/NordicSemiconductor/bluetooth-numbers-database.git
|
1
bluetooth-numbers-database
Submodule
1
bluetooth-numbers-database
Submodule
|
@ -0,0 +1 @@
|
|||
Subproject commit 3d0f452460237f76d7e11d8cd0de8c1cba46b62a
|
File diff suppressed because it is too large
Load diff
1
go.mod
1
go.mod
|
@ -11,6 +11,7 @@ require (
|
|||
github.com/tinygo-org/cbgo v0.0.4
|
||||
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519
|
||||
golang.org/x/sys v0.0.0-20220829200755-d48e67d00261 // indirect
|
||||
golang.org/x/text v0.5.0
|
||||
tinygo.org/x/drivers v0.23.0
|
||||
tinygo.org/x/tinyterm v0.1.0
|
||||
)
|
||||
|
|
10
go.sum
10
go.sum
|
@ -55,6 +55,7 @@ github.com/tinygo-org/cbgo v0.0.4/go.mod h1:7+HgWIHd4nbAz0ESjGlJ1/v9LDU1Ox8MGzP9
|
|||
github.com/valyala/fastjson v1.6.3/go.mod h1:CLCAqky6SMuOcxStkYQvblddUtoRxhYMGLrsQns1aXY=
|
||||
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
|
||||
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
|
@ -69,9 +70,11 @@ golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81R
|
|||
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
|
||||
golang.org/x/net v0.0.0-20210614182718-04defd469f4e/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
|
@ -82,20 +85,27 @@ golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7w
|
|||
golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220829200755-d48e67d00261 h1:v6hYoSR9T5oet+pMXwUWkbiVqx/63mlHjefrHmxwfeY=
|
||||
golang.org/x/sys v0.0.0-20220829200755-d48e67d00261/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 h1:v+OssWQX+hTHEmOBgwxdZxK4zHq3yOs8F9J7mk0PY8E=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY=
|
||||
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
|
||||
golang.org/x/text v0.5.0 h1:OLmvp0KP+FVG99Ct/qFiL/Fhk4zp4QQnZ7b2U+5piUM=
|
||||
golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20200925191224-5d1fdd8fa346/go.mod h1:z6u4i615ZeAfBE4XtMziQW1fSVJXACjjbWkB/mvPzlU=
|
||||
golang.org/x/tools v0.1.11/go.mod h1:SgwaegtQh8clINPpECJMqnxLv9I09HLqnW3RMqW0CA4=
|
||||
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
|
|
461
service_uuids.go
461
service_uuids.go
|
@ -1,40 +1,262 @@
|
|||
// Code generated by bin/gen-service-uuids; DO NOT EDIT.
|
||||
// This file was generated on 2021-02-01 14:19:12.31511038 +0100 CET m=+0.005731522 using the list of standard service UUIDs from
|
||||
// This file was generated on 2022-12-21 19:21:51.011665984 +0100 CET m=+0.000615122 using the list of standard service UUIDs from
|
||||
// https://github.com/NordicSemiconductor/bluetooth-numbers-database/blob/master/v1/service_uuids.json
|
||||
//
|
||||
package bluetooth
|
||||
|
||||
var (
|
||||
|
||||
// ServiceUUIDGenericAccess - Generic Access
|
||||
ServiceUUIDGenericAccess = New16BitUUID(0x1800)
|
||||
// ServiceUUIDExperimentalButtonlessDFU - Experimental Buttonless DFU Service
|
||||
ServiceUUIDExperimentalButtonlessDFU = NewUUID([16]byte{0x8e,0x40,0x00,0x01,0xf3,0x15,0x4f,0x60,0x9f,0xb8,0x83,0x88,0x30,0xda,0xea,0x50,})
|
||||
|
||||
// ServiceUUIDAdafruitTemperature - Adafruit Temperature Service
|
||||
ServiceUUIDAdafruitTemperature = NewUUID([16]byte{0xad,0xaf,0x01,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDAdafruitHumidity - Adafruit Humidity Service
|
||||
ServiceUUIDAdafruitHumidity = NewUUID([16]byte{0xad,0xaf,0x07,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDUserData - User Data
|
||||
ServiceUUIDUserData = New16BitUUID(0x181C)
|
||||
|
||||
// ServiceUUIDAudioStreamControl - Audio Stream Control
|
||||
ServiceUUIDAudioStreamControl = New16BitUUID(0x184E)
|
||||
|
||||
// ServiceUUIDSMP - SMP Service
|
||||
ServiceUUIDSMP = NewUUID([16]byte{0x8d,0x53,0xdc,0x1d,0x1d,0xb7,0x4c,0xd3,0x86,0x8b,0x8a,0x52,0x74,0x60,0xaa,0x84,})
|
||||
|
||||
// ServiceUUIDAdafruitSound - Adafruit Sound Service
|
||||
ServiceUUIDAdafruitSound = NewUUID([16]byte{0xad,0xaf,0x0b,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDPulseOximeter - Pulse Oximeter Service
|
||||
ServiceUUIDPulseOximeter = New16BitUUID(0x1822)
|
||||
|
||||
// ServiceUUIDEddystoneConfiguration - Eddystone Configuration Service
|
||||
ServiceUUIDEddystoneConfiguration = NewUUID([16]byte{0xa3,0xc8,0x75,0x00,0x8e,0xd3,0x4b,0xdf,0x8a,0x39,0xa0,0x1b,0xeb,0xed,0xe2,0x95,})
|
||||
|
||||
// ServiceUUIDLocationAndNavigation - Location and Navigation
|
||||
ServiceUUIDLocationAndNavigation = New16BitUUID(0x1819)
|
||||
|
||||
// ServiceUUIDMediaControl - Media Control
|
||||
ServiceUUIDMediaControl = New16BitUUID(0x1848)
|
||||
|
||||
// ServiceUUIDGenericMediaControl - Generic Media Control
|
||||
ServiceUUIDGenericMediaControl = New16BitUUID(0x1849)
|
||||
|
||||
// ServiceUUIDSignifyNetherlandsBVFormerlyPhilipsLighting - Signify Netherlands B.V. (formerly Philips Lighting) Service
|
||||
ServiceUUIDSignifyNetherlandsBVFormerlyPhilipsLighting = New16BitUUID(0xFE0F)
|
||||
|
||||
// ServiceUUIDPhilipsHueLightControl - Philips Hue Light Control Service
|
||||
ServiceUUIDPhilipsHueLightControl = NewUUID([16]byte{0x93,0x2c,0x32,0xbd,0x00,0x00,0x47,0xa2,0x83,0x5a,0xa8,0xd4,0x55,0xb8,0x59,0xdd,})
|
||||
|
||||
// ServiceUUIDThingyUI - Thingy UI Service
|
||||
ServiceUUIDThingyUI = NewUUID([16]byte{0xef,0x68,0x03,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDAlertNotification - Alert Notification Service
|
||||
ServiceUUIDAlertNotification = New16BitUUID(0x1811)
|
||||
|
||||
// ServiceUUIDAutomationIO - Automation IO
|
||||
ServiceUUIDAutomationIO = New16BitUUID(0x1815)
|
||||
// ServiceUUIDEnvironmentalSensing - Environmental Sensing
|
||||
ServiceUUIDEnvironmentalSensing = New16BitUUID(0x181A)
|
||||
|
||||
// ServiceUUIDBattery - Battery Service
|
||||
ServiceUUIDBattery = New16BitUUID(0x180F)
|
||||
// ServiceUUIDGenericTelephoneBearer - Generic Telephone Bearer
|
||||
ServiceUUIDGenericTelephoneBearer = New16BitUUID(0x184C)
|
||||
|
||||
// ServiceUUIDBloodPressure - Blood Pressure
|
||||
ServiceUUIDBloodPressure = New16BitUUID(0x1810)
|
||||
// ServiceUUIDGenericAttribute - Generic Attribute
|
||||
ServiceUUIDGenericAttribute = New16BitUUID(0x1801)
|
||||
|
||||
// ServiceUUIDAdafruitMagnetometer - Adafruit Magnetometer Service
|
||||
ServiceUUIDAdafruitMagnetometer = NewUUID([16]byte{0xad,0xaf,0x05,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDMicrophoneControl - Microphone Control
|
||||
ServiceUUIDMicrophoneControl = New16BitUUID(0x184D)
|
||||
|
||||
// ServiceUUIDLEGOWirelessProtocolV3Bootloader - LEGO® Wireless Protocol v3 Bootloader Service
|
||||
ServiceUUIDLEGOWirelessProtocolV3Bootloader = NewUUID([16]byte{0x00,0x00,0x16,0x25,0x12,0x12,0xef,0xde,0x16,0x23,0x78,0x5f,0xea,0xbc,0xd1,0x23,})
|
||||
|
||||
// ServiceUUIDAdafruitColor - Adafruit Color Service
|
||||
ServiceUUIDAdafruitColor = NewUUID([16]byte{0xad,0xaf,0x0a,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDMeshProvisioning - Mesh Provisioning Service
|
||||
ServiceUUIDMeshProvisioning = New16BitUUID(0x1827)
|
||||
|
||||
// ServiceUUIDTransportDiscovery - Transport Discovery
|
||||
ServiceUUIDTransportDiscovery = New16BitUUID(0x1824)
|
||||
|
||||
// ServiceUUIDAppleReserved1 - Apple Reserved Service 1
|
||||
ServiceUUIDAppleReserved1 = NewUUID([16]byte{0x7d,0xfc,0x60,0x00,0x7d,0x1c,0x49,0x51,0x86,0xaa,0x8d,0x97,0x28,0xf8,0xd6,0x6c,})
|
||||
|
||||
// ServiceUUIDAppleReserved2 - Apple Reserved Service 2
|
||||
ServiceUUIDAppleReserved2 = NewUUID([16]byte{0x7d,0xfc,0x70,0x00,0x7d,0x1c,0x49,0x51,0x86,0xaa,0x8d,0x97,0x28,0xf8,0xd6,0x6c,})
|
||||
|
||||
// ServiceUUIDAppleReserved3 - Apple Reserved Service 3
|
||||
ServiceUUIDAppleReserved3 = NewUUID([16]byte{0x7d,0xfc,0x80,0x00,0x7d,0x1c,0x49,0x51,0x86,0xaa,0x8d,0x97,0x28,0xf8,0xd6,0x6c,})
|
||||
|
||||
// ServiceUUIDAppleReserved4 - Apple Reserved Service 4
|
||||
ServiceUUIDAppleReserved4 = NewUUID([16]byte{0x7d,0xfc,0x90,0x00,0x7d,0x1c,0x49,0x51,0x86,0xaa,0x8d,0x97,0x28,0xf8,0xd6,0x6c,})
|
||||
|
||||
// ServiceUUIDAdafruitButton - Adafruit Button Service
|
||||
ServiceUUIDAdafruitButton = NewUUID([16]byte{0xad,0xaf,0x06,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDMemfaultDiagnostic - Memfault Diagnostic Service
|
||||
ServiceUUIDMemfaultDiagnostic = NewUUID([16]byte{0x54,0x22,0x00,0x00,0xf6,0xa5,0x40,0x07,0xa3,0x71,0x72,0x2f,0x4e,0xbd,0x84,0x36,})
|
||||
|
||||
// ServiceUUIDScanParameters - Scan Parameters
|
||||
ServiceUUIDScanParameters = New16BitUUID(0x1813)
|
||||
|
||||
// ServiceUUIDCoordinatedSetIdentification - Coordinated Set Identification
|
||||
ServiceUUIDCoordinatedSetIdentification = New16BitUUID(0x1846)
|
||||
|
||||
// ServiceUUIDMicrobitAccelerometer - micro:bit Accelerometer Service
|
||||
ServiceUUIDMicrobitAccelerometer = NewUUID([16]byte{0xe9,0x5d,0x07,0x53,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDMicrobitEvent - micro:bit Event Service
|
||||
ServiceUUIDMicrobitEvent = NewUUID([16]byte{0xe9,0x5d,0x93,0xaf,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDThingySound - Thingy Sound Service
|
||||
ServiceUUIDThingySound = NewUUID([16]byte{0xef,0x68,0x05,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDImmediateAlert - Immediate Alert
|
||||
ServiceUUIDImmediateAlert = New16BitUUID(0x1802)
|
||||
|
||||
// ServiceUUIDBroadcastAudioScan - Broadcast Audio Scan
|
||||
ServiceUUIDBroadcastAudioScan = New16BitUUID(0x184F)
|
||||
|
||||
// ServiceUUIDInsulinDelivery - Insulin Delivery
|
||||
ServiceUUIDInsulinDelivery = New16BitUUID(0x183A)
|
||||
|
||||
// ServiceUUIDVolumeControl - Volume Control
|
||||
ServiceUUIDVolumeControl = New16BitUUID(0x1844)
|
||||
|
||||
// ServiceUUIDMicrobitMagnetometer - micro:bit Magnetometer Service
|
||||
ServiceUUIDMicrobitMagnetometer = NewUUID([16]byte{0xe9,0x5d,0xf2,0xd8,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDMicrobitLED - micro:bit LED Service
|
||||
ServiceUUIDMicrobitLED = NewUUID([16]byte{0xe9,0x5d,0xd9,0x1d,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDFileTransferByAdafruit - File Transfer Service by Adafruit
|
||||
ServiceUUIDFileTransferByAdafruit = New16BitUUID(0xFEBB)
|
||||
|
||||
// ServiceUUIDCommonAudio - Common Audio
|
||||
ServiceUUIDCommonAudio = New16BitUUID(0x1853)
|
||||
|
||||
// ServiceUUIDHearingAccess - Hearing Access
|
||||
ServiceUUIDHearingAccess = New16BitUUID(0x1854)
|
||||
|
||||
// ServiceUUIDBodyComposition - Body Composition
|
||||
ServiceUUIDBodyComposition = New16BitUUID(0x181B)
|
||||
|
||||
// ServiceUUIDBondManagement - Bond Management Service
|
||||
ServiceUUIDBondManagement = New16BitUUID(0x181E)
|
||||
// ServiceUUIDPhysicalActivityMonitor - Physical Activity Monitor
|
||||
ServiceUUIDPhysicalActivityMonitor = New16BitUUID(0x183E)
|
||||
|
||||
// ServiceUUIDContinuousGlucoseMonitoring - Continuous Glucose Monitoring
|
||||
ServiceUUIDContinuousGlucoseMonitoring = New16BitUUID(0x181F)
|
||||
// ServiceUUIDFastPair - Fast Pair Service
|
||||
ServiceUUIDFastPair = New16BitUUID(0xFE2C)
|
||||
|
||||
// ServiceUUIDAdafruitGyroscope - Adafruit Gyroscope Service
|
||||
ServiceUUIDAdafruitGyroscope = NewUUID([16]byte{0xad,0xaf,0x04,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDAdafruitProximity - Adafruit Proximity Service
|
||||
ServiceUUIDAdafruitProximity = NewUUID([16]byte{0xad,0xaf,0x0e,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDTelephoneBearer - Telephone Bearer
|
||||
ServiceUUIDTelephoneBearer = New16BitUUID(0x184B)
|
||||
|
||||
// ServiceUUIDNordicLEDAndButton - Nordic LED and Button Service
|
||||
ServiceUUIDNordicLEDAndButton = NewUUID([16]byte{0x00,0x00,0x15,0x23,0x12,0x12,0xef,0xde,0x15,0x23,0x78,0x5f,0xea,0xbc,0xd1,0x23,})
|
||||
|
||||
// ServiceUUIDInternetProtocolSupport - Internet Protocol Support Service
|
||||
ServiceUUIDInternetProtocolSupport = New16BitUUID(0x1820)
|
||||
|
||||
// ServiceUUIDPublishedAudioCapabilities - Published Audio Capabilities
|
||||
ServiceUUIDPublishedAudioCapabilities = New16BitUUID(0x1850)
|
||||
|
||||
// ServiceUUIDNordicUART - Nordic UART Service
|
||||
ServiceUUIDNordicUART = NewUUID([16]byte{0x6e,0x40,0x00,0x01,0xb5,0xa3,0xf3,0x93,0xe0,0xa9,0xe5,0x0e,0x24,0xdc,0xca,0x9e,})
|
||||
|
||||
// ServiceUUIDExposureNotification - Exposure Notification Service
|
||||
ServiceUUIDExposureNotification = New16BitUUID(0xFD6F)
|
||||
|
||||
// ServiceUUIDEddystone - Eddystone
|
||||
ServiceUUIDEddystone = New16BitUUID(0xFEAA)
|
||||
|
||||
// ServiceUUIDNextDSTChange - Next DST Change Service
|
||||
ServiceUUIDNextDSTChange = New16BitUUID(0x1807)
|
||||
|
||||
// ServiceUUIDRunningSpeedAndCadence - Running Speed and Cadence
|
||||
ServiceUUIDRunningSpeedAndCadence = New16BitUUID(0x1814)
|
||||
|
||||
// ServiceUUIDConstantToneExtension - Constant Tone Extension
|
||||
ServiceUUIDConstantToneExtension = New16BitUUID(0x184A)
|
||||
|
||||
// ServiceUUIDThingyWeatherStation - Thingy Weather Station Service
|
||||
ServiceUUIDThingyWeatherStation = NewUUID([16]byte{0xef,0x68,0x02,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDHealthThermometer - Health Thermometer
|
||||
ServiceUUIDHealthThermometer = New16BitUUID(0x1809)
|
||||
|
||||
// ServiceUUIDHumanInterfaceDevice - Human Interface Device
|
||||
ServiceUUIDHumanInterfaceDevice = New16BitUUID(0x1812)
|
||||
|
||||
// ServiceUUIDCyclingPower - Cycling Power
|
||||
ServiceUUIDCyclingPower = New16BitUUID(0x1818)
|
||||
|
||||
// ServiceUUIDReconnectionConfiguration - Reconnection Configuration
|
||||
ServiceUUIDReconnectionConfiguration = New16BitUUID(0x1829)
|
||||
|
||||
// ServiceUUIDAdafruitQuaternion - Adafruit Quaternion Service
|
||||
ServiceUUIDAdafruitQuaternion = NewUUID([16]byte{0xad,0xaf,0x0d,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDMeshProxy - Mesh Proxy Service
|
||||
ServiceUUIDMeshProxy = New16BitUUID(0x1828)
|
||||
|
||||
// ServiceUUIDThingyMotion - Thingy Motion Service
|
||||
ServiceUUIDThingyMotion = NewUUID([16]byte{0xef,0x68,0x04,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDIndoorPositioning - Indoor Positioning
|
||||
ServiceUUIDIndoorPositioning = New16BitUUID(0x1821)
|
||||
|
||||
// ServiceUUIDAdafruitAddressable - Adafruit Addressable Service
|
||||
ServiceUUIDAdafruitAddressable = NewUUID([16]byte{0xad,0xaf,0x09,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDBloodPressure - Blood Pressure
|
||||
ServiceUUIDBloodPressure = New16BitUUID(0x1810)
|
||||
|
||||
// ServiceUUIDCurrentTime - Current Time Service
|
||||
ServiceUUIDCurrentTime = New16BitUUID(0x1805)
|
||||
|
||||
// ServiceUUIDCyclingPower - Cycling Power
|
||||
ServiceUUIDCyclingPower = New16BitUUID(0x1818)
|
||||
// ServiceUUIDPhoneAlertStatus - Phone Alert Status Service
|
||||
ServiceUUIDPhoneAlertStatus = New16BitUUID(0x180E)
|
||||
|
||||
// ServiceUUIDWeightScale - Weight Scale
|
||||
ServiceUUIDWeightScale = New16BitUUID(0x181D)
|
||||
|
||||
// ServiceUUIDBinarySensor - Binary Sensor
|
||||
ServiceUUIDBinarySensor = New16BitUUID(0x183B)
|
||||
|
||||
// ServiceUUIDDeviceTime - Device Time
|
||||
ServiceUUIDDeviceTime = New16BitUUID(0x1847)
|
||||
|
||||
// ServiceUUIDBroadcastAudioAnnouncement - Broadcast Audio Announcement
|
||||
ServiceUUIDBroadcastAudioAnnouncement = New16BitUUID(0x1852)
|
||||
|
||||
// ServiceUUIDMicrobitDFUControl - micro:bit DFU Control Service
|
||||
ServiceUUIDMicrobitDFUControl = NewUUID([16]byte{0xe9,0x5d,0x93,0xb0,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDBondManagement - Bond Management Service
|
||||
ServiceUUIDBondManagement = New16BitUUID(0x181E)
|
||||
|
||||
// ServiceUUIDLinkLoss - Link Loss
|
||||
ServiceUUIDLinkLoss = New16BitUUID(0x1803)
|
||||
|
||||
// ServiceUUIDAdafruitAccelerometer - Adafruit Accelerometer Service
|
||||
ServiceUUIDAdafruitAccelerometer = NewUUID([16]byte{0xad,0xaf,0x02,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDReferenceTimeUpdate - Reference Time Update Service
|
||||
ServiceUUIDReferenceTimeUpdate = New16BitUUID(0x1806)
|
||||
|
||||
// ServiceUUIDTxPower - Tx Power
|
||||
ServiceUUIDTxPower = New16BitUUID(0x1804)
|
||||
|
||||
// ServiceUUIDMicrobitTemperature - micro:bit Temperature Service
|
||||
ServiceUUIDMicrobitTemperature = NewUUID([16]byte{0xe9,0x5d,0x61,0x00,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDCyclingSpeedAndCadence - Cycling Speed and Cadence
|
||||
ServiceUUIDCyclingSpeedAndCadence = New16BitUUID(0x1816)
|
||||
|
@ -42,104 +264,8 @@ var (
|
|||
// ServiceUUIDDeviceInformation - Device Information
|
||||
ServiceUUIDDeviceInformation = New16BitUUID(0x180A)
|
||||
|
||||
// ServiceUUIDEnvironmentalSensing - Environmental Sensing
|
||||
ServiceUUIDEnvironmentalSensing = New16BitUUID(0x181A)
|
||||
|
||||
// ServiceUUIDFitnessMachine - Fitness Machine
|
||||
ServiceUUIDFitnessMachine = New16BitUUID(0x1826)
|
||||
|
||||
// ServiceUUIDGenericAttribute - Generic Attribute
|
||||
ServiceUUIDGenericAttribute = New16BitUUID(0x1801)
|
||||
|
||||
// ServiceUUIDGlucose - Glucose
|
||||
ServiceUUIDGlucose = New16BitUUID(0x1808)
|
||||
|
||||
// ServiceUUIDHealthThermometer - Health Thermometer
|
||||
ServiceUUIDHealthThermometer = New16BitUUID(0x1809)
|
||||
|
||||
// ServiceUUIDHeartRate - Heart Rate
|
||||
ServiceUUIDHeartRate = New16BitUUID(0x180D)
|
||||
|
||||
// ServiceUUIDHTTPProxy - HTTP Proxy
|
||||
ServiceUUIDHTTPProxy = New16BitUUID(0x1823)
|
||||
|
||||
// ServiceUUIDHumanInterfaceDevice - Human Interface Device
|
||||
ServiceUUIDHumanInterfaceDevice = New16BitUUID(0x1812)
|
||||
|
||||
// ServiceUUIDImmediateAlert - Immediate Alert
|
||||
ServiceUUIDImmediateAlert = New16BitUUID(0x1802)
|
||||
|
||||
// ServiceUUIDIndoorPositioning - Indoor Positioning
|
||||
ServiceUUIDIndoorPositioning = New16BitUUID(0x1821)
|
||||
|
||||
// ServiceUUIDInsulinDelivery - Insulin Delivery
|
||||
ServiceUUIDInsulinDelivery = New16BitUUID(0x183A)
|
||||
|
||||
// ServiceUUIDInternetProtocolSupport - Internet Protocol Support Service
|
||||
ServiceUUIDInternetProtocolSupport = New16BitUUID(0x1820)
|
||||
|
||||
// ServiceUUIDLinkLoss - Link Loss
|
||||
ServiceUUIDLinkLoss = New16BitUUID(0x1803)
|
||||
|
||||
// ServiceUUIDLocationAndNavigation - Location and Navigation
|
||||
ServiceUUIDLocationAndNavigation = New16BitUUID(0x1819)
|
||||
|
||||
// ServiceUUIDMeshProvisioning - Mesh Provisioning Service
|
||||
ServiceUUIDMeshProvisioning = New16BitUUID(0x1827)
|
||||
|
||||
// ServiceUUIDMeshProxy - Mesh Proxy Service
|
||||
ServiceUUIDMeshProxy = New16BitUUID(0x1828)
|
||||
|
||||
// ServiceUUIDNextDSTChange - Next DST Change Service
|
||||
ServiceUUIDNextDSTChange = New16BitUUID(0x1807)
|
||||
|
||||
// ServiceUUIDObjectTransfer - Object Transfer Service
|
||||
ServiceUUIDObjectTransfer = New16BitUUID(0x1825)
|
||||
|
||||
// ServiceUUIDPhoneAlertStatus - Phone Alert Status Service
|
||||
ServiceUUIDPhoneAlertStatus = New16BitUUID(0x180E)
|
||||
|
||||
// ServiceUUIDPulseOximeter - Pulse Oximeter Service
|
||||
ServiceUUIDPulseOximeter = New16BitUUID(0x1822)
|
||||
|
||||
// ServiceUUIDReconnectionConfiguration - Reconnection Configuration
|
||||
ServiceUUIDReconnectionConfiguration = New16BitUUID(0x1829)
|
||||
|
||||
// ServiceUUIDReferenceTimeUpdate - Reference Time Update Service
|
||||
ServiceUUIDReferenceTimeUpdate = New16BitUUID(0x1806)
|
||||
|
||||
// ServiceUUIDRunningSpeedAndCadence - Running Speed and Cadence
|
||||
ServiceUUIDRunningSpeedAndCadence = New16BitUUID(0x1814)
|
||||
|
||||
// ServiceUUIDScanParameters - Scan Parameters
|
||||
ServiceUUIDScanParameters = New16BitUUID(0x1813)
|
||||
|
||||
// ServiceUUIDTransportDiscovery - Transport Discovery
|
||||
ServiceUUIDTransportDiscovery = New16BitUUID(0x1824)
|
||||
|
||||
// ServiceUUIDTxPower - Tx Power
|
||||
ServiceUUIDTxPower = New16BitUUID(0x1804)
|
||||
|
||||
// ServiceUUIDUserData - User Data
|
||||
ServiceUUIDUserData = New16BitUUID(0x181C)
|
||||
|
||||
// ServiceUUIDWeightScale - Weight Scale
|
||||
ServiceUUIDWeightScale = New16BitUUID(0x181D)
|
||||
|
||||
// ServiceUUIDFirmwareRevision - Firmware Revision
|
||||
ServiceUUIDFirmwareRevision = New16BitUUID(0x2A26)
|
||||
|
||||
// ServiceUUIDAppleNotificationCenter - Apple Notification Center Service
|
||||
ServiceUUIDAppleNotificationCenter = NewUUID([16]byte{0x79,0x05,0xf4,0x31,0xb5,0xce,0x4e,0x99,0xa4,0x0f,0x4b,0x1e,0x12,0x2d,0x00,0xd0,})
|
||||
|
||||
// ServiceUUIDAppleMedia - Apple Media Service
|
||||
ServiceUUIDAppleMedia = NewUUID([16]byte{0x89,0xd3,0x50,0x2b,0x0f,0x36,0x43,0x3a,0x8e,0xf4,0xc5,0x02,0xad,0x55,0xf8,0xdc,})
|
||||
|
||||
// ServiceUUIDMicrobitAccelerometer - micro:bit Accelerometer Service
|
||||
ServiceUUIDMicrobitAccelerometer = NewUUID([16]byte{0xe9,0x5d,0x07,0x53,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDMicrobitMagnetometer - micro:bit Magnetometer Service
|
||||
ServiceUUIDMicrobitMagnetometer = NewUUID([16]byte{0xe9,0x5d,0xf2,0xd8,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
// ServiceUUIDTMAS - TMAS
|
||||
ServiceUUIDTMAS = New16BitUUID(0x1855)
|
||||
|
||||
// ServiceUUIDMicrobitButton - micro:bit Button Service
|
||||
ServiceUUIDMicrobitButton = NewUUID([16]byte{0xe9,0x5d,0x98,0x82,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
@ -147,61 +273,82 @@ var (
|
|||
// ServiceUUIDMicrobitIOPin - micro:bit IO Pin Service
|
||||
ServiceUUIDMicrobitIOPin = NewUUID([16]byte{0xe9,0x5d,0x12,0x7b,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
|
||||
// ServiceUUIDMicrobitLED - micro:bit LED Service
|
||||
ServiceUUIDMicrobitLED = NewUUID([16]byte{0xe9,0x5d,0xd9,0x1d,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
// ServiceUUIDAutomationIO - Automation IO
|
||||
ServiceUUIDAutomationIO = New16BitUUID(0x1815)
|
||||
|
||||
// ServiceUUIDMicrobitEvent - micro:bit Event Service
|
||||
ServiceUUIDMicrobitEvent = NewUUID([16]byte{0xe9,0x5d,0x93,0xaf,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
// ServiceUUIDGlucose - Glucose
|
||||
ServiceUUIDGlucose = New16BitUUID(0x1808)
|
||||
|
||||
// ServiceUUIDMicrobitDFUControl - micro:bit DFU Control Service
|
||||
ServiceUUIDMicrobitDFUControl = NewUUID([16]byte{0xe9,0x5d,0x93,0xb0,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
// ServiceUUIDAppleMedia - Apple Media Service
|
||||
ServiceUUIDAppleMedia = NewUUID([16]byte{0x89,0xd3,0x50,0x2b,0x0f,0x36,0x43,0x3a,0x8e,0xf4,0xc5,0x02,0xad,0x55,0xf8,0xdc,})
|
||||
|
||||
// ServiceUUIDMicrobitTemperature - micro:bit Temperature Service
|
||||
ServiceUUIDMicrobitTemperature = NewUUID([16]byte{0xe9,0x5d,0x61,0x00,0x25,0x1d,0x47,0x0a,0xa0,0x62,0xfa,0x19,0x22,0xdf,0xa9,0xa8,})
|
||||
// ServiceUUIDEdgeImpulseRemoteManagement - Edge Impulse Remote Management Service
|
||||
ServiceUUIDEdgeImpulseRemoteManagement = NewUUID([16]byte{0xe2,0xa0,0x00,0x01,0xec,0x31,0x4e,0xc3,0xa9,0x7a,0x1c,0x34,0xd8,0x7e,0x98,0x78,})
|
||||
|
||||
// ServiceUUIDThingyConfiguration - Thingy Configuration Service
|
||||
ServiceUUIDThingyConfiguration = NewUUID([16]byte{0xef,0x68,0x01,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
// ServiceUUIDHeartRate - Heart Rate
|
||||
ServiceUUIDHeartRate = New16BitUUID(0x180D)
|
||||
|
||||
// ServiceUUIDThingyWeatherStation - Thingy Weather Station Service
|
||||
ServiceUUIDThingyWeatherStation = NewUUID([16]byte{0xef,0x68,0x02,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDThingyUI - Thingy UI Service
|
||||
ServiceUUIDThingyUI = NewUUID([16]byte{0xef,0x68,0x03,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDThingyMotion - Thingy Motion Service
|
||||
ServiceUUIDThingyMotion = NewUUID([16]byte{0xef,0x68,0x04,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDThingySound - Thingy Sound Service
|
||||
ServiceUUIDThingySound = NewUUID([16]byte{0xef,0x68,0x05,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDNordicLEDAndButton - Nordic LED and Button Service
|
||||
ServiceUUIDNordicLEDAndButton = NewUUID([16]byte{0x00,0x00,0x15,0x23,0x12,0x12,0xef,0xde,0x15,0x23,0x78,0x5f,0xea,0xbc,0xd1,0x23,})
|
||||
|
||||
// ServiceUUIDNordicUART - Nordic UART Service
|
||||
ServiceUUIDNordicUART = NewUUID([16]byte{0x6e,0x40,0x00,0x01,0xb5,0xa3,0xf3,0x93,0xe0,0xa9,0xe5,0x0e,0x24,0xdc,0xca,0x9e,})
|
||||
|
||||
// ServiceUUIDEddystone - Eddystone
|
||||
ServiceUUIDEddystone = New16BitUUID(0xFEAA)
|
||||
|
||||
// ServiceUUIDEddystoneConfiguration - Eddystone Configuration Service
|
||||
ServiceUUIDEddystoneConfiguration = NewUUID([16]byte{0xa3,0xc8,0x75,0x00,0x8e,0xd3,0x4b,0xdf,0x8a,0x39,0xa0,0x1b,0xeb,0xed,0xe2,0x95,})
|
||||
|
||||
// ServiceUUIDFastPair - Fast Pair Service
|
||||
ServiceUUIDFastPair = New16BitUUID(0xFE2C)
|
||||
// ServiceUUIDPhilipsHueLightUpdate - Philips Hue Light Update Service
|
||||
ServiceUUIDPhilipsHueLightUpdate = NewUUID([16]byte{0xb8,0x84,0x3a,0xdd,0x00,0x00,0x4a,0xa1,0x87,0x94,0xc3,0xf4,0x62,0x03,0x0b,0xda,})
|
||||
|
||||
// ServiceUUIDLegacyDFU - Legacy DFU Service
|
||||
ServiceUUIDLegacyDFU = NewUUID([16]byte{0x00,0x00,0x15,0x30,0x12,0x12,0xef,0xde,0x15,0x23,0x78,0x5f,0xea,0xbc,0xd1,0x23,})
|
||||
|
||||
// ServiceUUIDLEGOWirelessProtocolV3Hub - LEGO® Wireless Protocol v3 Hub Service
|
||||
ServiceUUIDLEGOWirelessProtocolV3Hub = NewUUID([16]byte{0x00,0x00,0x16,0x23,0x12,0x12,0xef,0xde,0x16,0x23,0x78,0x5f,0xea,0xbc,0xd1,0x23,})
|
||||
|
||||
// ServiceUUIDTexasInstrumentsOvertheAirDownloadOAD - Texas Instruments Over-the-Air Download (OAD) Service
|
||||
ServiceUUIDTexasInstrumentsOvertheAirDownloadOAD = NewUUID([16]byte{0xf0,0x00,0xff,0xc0,0x04,0x51,0x40,0x00,0xb0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,})
|
||||
|
||||
// ServiceUUIDHeliumHotspotCustom - Helium Hotspot Custom Service
|
||||
ServiceUUIDHeliumHotspotCustom = NewUUID([16]byte{0x0f,0xda,0x92,0xb2,0x44,0xa2,0x4a,0xf2,0x84,0xf5,0xfa,0x68,0x2b,0xaa,0x2b,0x8d,})
|
||||
|
||||
// ServiceUUIDObjectTransfer - Object Transfer Service
|
||||
ServiceUUIDObjectTransfer = New16BitUUID(0x1825)
|
||||
|
||||
// ServiceUUIDBasicAudioAnnouncement - Basic Audio Announcement
|
||||
ServiceUUIDBasicAudioAnnouncement = New16BitUUID(0x1851)
|
||||
|
||||
// ServiceUUIDEmergencyConfiguration - Emergency Configuration
|
||||
ServiceUUIDEmergencyConfiguration = New16BitUUID(0x183C)
|
||||
|
||||
// ServiceUUIDVolumeOffsetControl - Volume Offset Control
|
||||
ServiceUUIDVolumeOffsetControl = New16BitUUID(0x1845)
|
||||
|
||||
// ServiceUUIDThingyConfiguration - Thingy Configuration Service
|
||||
ServiceUUIDThingyConfiguration = NewUUID([16]byte{0xef,0x68,0x01,0x00,0x9b,0x35,0x49,0x33,0x9b,0x10,0x52,0xff,0xa9,0x74,0x00,0x42,})
|
||||
|
||||
// ServiceUUIDAdafruitLight - Adafruit Light Service
|
||||
ServiceUUIDAdafruitLight = NewUUID([16]byte{0xad,0xaf,0x03,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDAdafruitBarometric - Adafruit Barometric Service
|
||||
ServiceUUIDAdafruitBarometric = NewUUID([16]byte{0xad,0xaf,0x08,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDAdafruitTone - Adafruit Tone Service
|
||||
ServiceUUIDAdafruitTone = NewUUID([16]byte{0xad,0xaf,0x0c,0x00,0xc3,0x32,0x42,0xa8,0x93,0xbd,0x25,0xe9,0x05,0x75,0x6c,0xb8,})
|
||||
|
||||
// ServiceUUIDBattery - Battery Service
|
||||
ServiceUUIDBattery = New16BitUUID(0x180F)
|
||||
|
||||
// ServiceUUIDContinuousGlucoseMonitoring - Continuous Glucose Monitoring
|
||||
ServiceUUIDContinuousGlucoseMonitoring = New16BitUUID(0x181F)
|
||||
|
||||
// ServiceUUIDAudioInputControl - Audio Input Control
|
||||
ServiceUUIDAudioInputControl = New16BitUUID(0x1843)
|
||||
|
||||
// ServiceUUIDAppleNotificationCenter - Apple Notification Center Service
|
||||
ServiceUUIDAppleNotificationCenter = NewUUID([16]byte{0x79,0x05,0xf4,0x31,0xb5,0xce,0x4e,0x99,0xa4,0x0f,0x4b,0x1e,0x12,0x2d,0x00,0xd0,})
|
||||
|
||||
// ServiceUUIDGenericAccess - Generic Access
|
||||
ServiceUUIDGenericAccess = New16BitUUID(0x1800)
|
||||
|
||||
// ServiceUUIDFitnessMachine - Fitness Machine
|
||||
ServiceUUIDFitnessMachine = New16BitUUID(0x1826)
|
||||
|
||||
// ServiceUUIDSecureDFU - Secure DFU Service
|
||||
ServiceUUIDSecureDFU = New16BitUUID(0xFE59)
|
||||
|
||||
// ServiceUUIDExperimentalButtonlessDFU - Experimental Buttonless DFU Service
|
||||
ServiceUUIDExperimentalButtonlessDFU = NewUUID([16]byte{0x8e,0x40,0x00,0x01,0xf3,0x15,0x4f,0x60,0x9f,0xb8,0x83,0x88,0x30,0xda,0xea,0x50,})
|
||||
|
||||
// ServiceUUIDExposureNotification - Exposure Notification Service
|
||||
ServiceUUIDExposureNotification = New16BitUUID(0xFD6F)
|
||||
|
||||
// ServiceUUIDSMP - SMP Service
|
||||
ServiceUUIDSMP = NewUUID([16]byte{0x8d,0x53,0xdc,0x1d,0x1d,0xb7,0x4c,0xd3,0x86,0x8b,0x8a,0x52,0x74,0x60,0xaa,0x84,})
|
||||
// ServiceUUIDHTTPProxy - HTTP Proxy
|
||||
ServiceUUIDHTTPProxy = New16BitUUID(0x1823)
|
||||
|
||||
)
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
//go:build ignore
|
||||
// +build ignore
|
||||
|
||||
package main
|
||||
|
@ -8,10 +9,14 @@ import (
|
|||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"regexp"
|
||||
"strings"
|
||||
"text/template"
|
||||
"time"
|
||||
|
||||
"golang.org/x/text/cases"
|
||||
"golang.org/x/text/language"
|
||||
|
||||
"tinygo.org/x/bluetooth"
|
||||
)
|
||||
|
||||
|
@ -24,12 +29,12 @@ type Characteristic struct {
|
|||
|
||||
func (c Characteristic) VarName() string {
|
||||
str := strings.ReplaceAll(c.Name, "Characteristic", "")
|
||||
str = strings.ReplaceAll(str, ":", "")
|
||||
str = strings.ReplaceAll(str, "-", "")
|
||||
str = strings.ReplaceAll(str, "(", "")
|
||||
str = strings.ReplaceAll(str, ")", "")
|
||||
str = strings.ReplaceAll(str, "/", "")
|
||||
str = strings.Title(str)
|
||||
|
||||
// Remove non-alphanumeric characters.
|
||||
var nonAlphanumericRegex = regexp.MustCompile(`[^a-zA-Z0-9 ]+`)
|
||||
str = nonAlphanumericRegex.ReplaceAllString(str, "")
|
||||
|
||||
str = cases.Title(language.Und, cases.NoLower).String(str)
|
||||
return strings.ReplaceAll(str, " ", "")
|
||||
}
|
||||
|
||||
|
@ -50,8 +55,30 @@ func (c Characteristic) UUIDFunc() string {
|
|||
return "NewUUID([16]byte{" + bss + "})"
|
||||
}
|
||||
|
||||
func dedupCharacteristics(characteristics []Characteristic) []Characteristic {
|
||||
// Group characteristics by name.
|
||||
byName := make(map[string][]Characteristic)
|
||||
for _, c := range characteristics {
|
||||
byName[c.Name] = append(byName[c.Name], c)
|
||||
}
|
||||
|
||||
var newCharacteristics []Characteristic
|
||||
|
||||
// Find duplicate characteristics and rename them.
|
||||
for name, cs := range byName {
|
||||
for i, c := range cs {
|
||||
if len(cs) > 1 {
|
||||
c.Name = fmt.Sprintf("%s %d", name, i+1)
|
||||
}
|
||||
newCharacteristics = append(newCharacteristics, c)
|
||||
}
|
||||
}
|
||||
|
||||
return newCharacteristics
|
||||
}
|
||||
|
||||
func main() {
|
||||
jsonFile, err := os.Open("data/characteristic_uuids.json")
|
||||
jsonFile, err := os.Open("bluetooth-numbers-database/v1/characteristic_uuids.json")
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
|
@ -63,6 +90,8 @@ func main() {
|
|||
var characteristics []Characteristic
|
||||
json.Unmarshal(data, &characteristics)
|
||||
|
||||
characteristics = dedupCharacteristics(characteristics)
|
||||
|
||||
f, err := os.Create("characteristic_uuids.go")
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
//go:build ignore
|
||||
// +build ignore
|
||||
|
||||
package main
|
||||
|
@ -8,10 +9,14 @@ import (
|
|||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"regexp"
|
||||
"strings"
|
||||
"text/template"
|
||||
"time"
|
||||
|
||||
"golang.org/x/text/cases"
|
||||
"golang.org/x/text/language"
|
||||
|
||||
"tinygo.org/x/bluetooth"
|
||||
)
|
||||
|
||||
|
@ -24,9 +29,12 @@ type Service struct {
|
|||
|
||||
func (s Service) VarName() string {
|
||||
str := strings.ReplaceAll(s.Name, "Service", "")
|
||||
str = strings.ReplaceAll(str, ":", "")
|
||||
str = strings.ReplaceAll(str, "-", "")
|
||||
str = strings.Title(str)
|
||||
|
||||
// Remove non-alphanumeric characters.
|
||||
var nonAlphanumericRegex = regexp.MustCompile(`[^a-zA-Z0-9 ]+`)
|
||||
str = nonAlphanumericRegex.ReplaceAllString(str, "")
|
||||
|
||||
str = cases.Title(language.Und, cases.NoLower).String(str)
|
||||
return strings.ReplaceAll(str, " ", "")
|
||||
}
|
||||
|
||||
|
@ -47,8 +55,30 @@ func (s Service) UUIDFunc() string {
|
|||
return "NewUUID([16]byte{" + bss + "})"
|
||||
}
|
||||
|
||||
func dedupServices(services []Service) []Service {
|
||||
// Group services by name.
|
||||
byName := make(map[string][]Service)
|
||||
for _, svc := range services {
|
||||
byName[svc.Name] = append(byName[svc.Name], svc)
|
||||
}
|
||||
|
||||
var newServices []Service
|
||||
|
||||
// Find duplicate services and rename them.
|
||||
for name, svcs := range byName {
|
||||
for i, svc := range svcs {
|
||||
if len(svcs) > 1 {
|
||||
svc.Name = fmt.Sprintf("%s %d", name, i+1)
|
||||
}
|
||||
newServices = append(newServices, svc)
|
||||
}
|
||||
}
|
||||
|
||||
return newServices
|
||||
}
|
||||
|
||||
func main() {
|
||||
jsonFile, err := os.Open("data/service_uuids.json")
|
||||
jsonFile, err := os.Open("bluetooth-numbers-database/v1/service_uuids.json")
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
|
@ -60,6 +90,8 @@ func main() {
|
|||
var services []Service
|
||||
json.Unmarshal(data, &services)
|
||||
|
||||
services = dedupServices(services)
|
||||
|
||||
f, err := os.Create("service_uuids.go")
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
|
|
Loading…
Reference in a new issue