Add packet example

This commit is contained in:
Nonoo 2020-10-17 11:05:07 +02:00
parent 0f6b5c95d8
commit c6b96265f8

View file

@ -193,6 +193,7 @@ func main() {
for {
// Expecting a Pkt4 answer.
// Example answer from radio: 0x10, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x8c, 0x7d, 0x45, 0x7a, 0x1d, 0xf6, 0xe9, 0x0b
r, _ := read()
if bytes.Equal(r[:8], []byte{0x10, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00}) {
remoteSID = binary.BigEndian.Uint32(r[8:12])