It’s been a struggle but I have an S130 simultaneously listening for broadcasts, while advertising, and able to listen for UI connections.
Receiving a broadcast advertising packet from another node called “Z1”. The example packet contains a maximally-sized 20-byte block of “proprietary data”, i.e. it doesn’t conform to the BLE standard and will only make sense to TS devices.
TS (7) [c7.60.61.56.c1.bf] – BLE_GAP_EVT_ADV_REPORT
T9(2)NAME Z1 Field type and length
T1(1)FLAGS 04
T255(22)TS_PROPRIETARY_DATA [(20), 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 ]
It requests second block of data from the broadcaster – the so-called scan response data. (For some reason this appears to come from a different MAC address – 0xbe instead of 0xbf?? ) This block contains the state of the sender’s battery, and the temp – just random bits of data it was easy to provide.
TS (8) [c7.60.61.56.c1.be] – BLE_GAP_EVT_ADV_REPORT
T22(3)BLE_UUID_BATTERY_SERVICE 100%
T22(6)BLE_UUID_HEALTH_THERMOMETER_SERVICE 34C
Now I use my Android phone and an off-the-shelf applciation to make a “TS_UART” connection to the S130. TS_UART is a connection that simply sends and receives strings of characters (up to 20).
———————-
UI connected.
———————-
While waiting for some activity on the connection it continues to report broadcast packets…
TS (9) [c7.60.61.56.c1.c6] – BLE_GAP_EVT_ADV_REPORT
T9(2)NAME Z1
T1(1)FLAGS 04
T255(22)TS_PROPRIETARY_DATA [(20), 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 ]
TS (10) [c7.60.61.56.c1.c6] – BLE_GAP_EVT_ADV_REPORT
T22(3)BLE_UUID_BATTERY_SERVICE 100%
T22(6)BLE_UUID_HEALTH_THERMOMETER_SERVICE 34C
TS (11) [c7.60.61.56.c1.c6] – BLE_GAP_EVT_ADV_REPORT
T9(2)NAME Z1
T1(1)FLAGS 04
T255(22)TS_PROPRIETARY_DATA [(20), 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 ]
I type a string “buddy” into my phone UI and press “send”. This is the interim mechanism I intend to use to configure each node, and to query it for statistics and so forth.
———————-
UI received string “buddy”
———————-