raw payload recieved
This commit is contained in:
parent
4f09fc7873
commit
1957bfdbf1
@ -36,12 +36,11 @@ func Scanners() {
|
||||
payload := result.AdvertisementPayload
|
||||
lname := result.LocalName()
|
||||
adbytes := payload.Bytes()
|
||||
uuids := payload.ServiceUUIDOut()
|
||||
//uuids := payload.ServiceUUIDOut()
|
||||
rssi := result.RSSI
|
||||
|
||||
//Trying to extract the service UUIDs from advertisment packet
|
||||
|
||||
println(uuids)
|
||||
//srvcPld := device.AdvertisementPayload.HasServiceUUID(projVars.SonosScanTest)
|
||||
// ** List of common Service UUIDS to search for **
|
||||
//bluetooth.ServiceUUIDDeviceInformation
|
||||
@ -52,13 +51,14 @@ func Scanners() {
|
||||
return
|
||||
}
|
||||
|
||||
//println(result.AdvertisementPayload.Bytes())
|
||||
println(result.AdvertisementPayload.ServiceUUIDOut())
|
||||
|
||||
//println(uuids)
|
||||
log.Info().Str("address", result.Address.String()).
|
||||
Str("LocalName", lname).
|
||||
Int16("RSSI", rssi).
|
||||
//Ints32("Service UUID", uuids).
|
||||
//Str("Device: ", ).
|
||||
//Bytes("Service UUID", uuids).
|
||||
Str("Device: ", string(payload.Bytes())).
|
||||
Msg("new_device")
|
||||
|
||||
var nilcheck bool
|
||||
@ -69,7 +69,7 @@ func Scanners() {
|
||||
nilcheck = false
|
||||
}
|
||||
|
||||
log.Debug().Bytes("AdvertisementPayload_Bytes", adbytes).
|
||||
log.Debug().Str("AdvertisementPayload_Bytes", string(payload.Bytes())).
|
||||
Int("AdvertisementPayload_Length", len(adbytes)).
|
||||
Bool("AdvertisementPayload_nil_check", nilcheck).
|
||||
Msg("AD_PAYLOAD")
|
||||
|
Loading…
Reference in New Issue
Block a user