Added ManufacturerData
This commit is contained in:
parent
2c9add9c8e
commit
c7e4bfa581
19
messages.go
19
messages.go
|
@ -966,10 +966,23 @@ type StatusMessage struct {
|
||||||
States map[string]bool `json:"states,omitempty"`
|
States map[string]bool `json:"states,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type ManufacturerDataElement struct {
|
||||||
|
// The company ID, which must be one of the assigned company IDs.
|
||||||
|
// The full list is in here:
|
||||||
|
// https://www.bluetooth.com/specifications/assigned-numbers/
|
||||||
|
// The list can also be viewed here:
|
||||||
|
// https://bitbucket.org/bluetooth-SIG/public/src/main/assigned_numbers/company_identifiers/company_identifiers.yaml
|
||||||
|
// The value 0xffff can also be used for testing.
|
||||||
|
CompanyID uint16 `json:"company-id,omitempty"`
|
||||||
|
|
||||||
|
// The value, which can be any value but can't be very large.
|
||||||
|
Data []byte `json:"data,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
type BleAdvertisementPayload struct {
|
type BleAdvertisementPayload struct {
|
||||||
LocalName string `json:"localName,omitempty"`
|
LocalName string `json:"localName,omitempty"`
|
||||||
Bytes []byte `json:"bytes,omitempty"`
|
Bytes []byte `json:"bytes,omitempty"`
|
||||||
ManufacturerData map[uint16][]byte `json:"manufacturerData,omitempty"`
|
ManufacturerData []ManufacturerDataElement `json:"manufacturerData,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type BleDevice struct {
|
type BleDevice struct {
|
||||||
|
|
Loading…
Reference in New Issue