Zephyr mqtt_publisher sample on nrf52840 dongle

Greetings,

Struggling to test the mqtt_publisher sample. I would like to modify this sample as the basis for my application. I successfully compiled and flashed this sample with the Bluetooth overlay to enable IPV6 over BLE.

west build -p auto -b nrf52840dongle_nrf52840 . -- -DOVERLAY_CONFIG=overlay-bt.conf

Using Linux - the Zephyr MQTT device pops up in the list of BT devices. From there I'm not making any progress with testing and don't know if I'm missing something in the zephyr build configuration or on Linux?

$ mosquitto
1647805534: mosquitto version 1.4.15 (build date Tue, 18 Jun 2019 11:42:22 -0300) starting
1647805534: Using default config.
1647805534: Opening ipv4 listen socket on port 1883.
1647805534: Error: Address already in use

I've tried similar steps as indicated in the bluetooth/ipsp sample.

1# modprobe bluetooth_6lowpan
2# echo 1 > /sys/kernel/debug/bluetooth/6lowpan_enable
3# echo "connect <bdaddr> <type>" > /sys/kernel/debug/bluetooth/6lowpan_control

This worked as expected with the ipsp sample flashed and running ifconfig, the bt0 interface was listed. I was able to ping and do an echo test with telnet.

Repeating these commands using the mqtt_publisher sample, does not work - step 3 does not result in a connection and ifconfig never lists the interface.

Any help would be appreciated!

Related