STM32 MQTT
Hi,
I'm using a STM32F407VGTx, trying to use MQTT on this microcontroller.
I first made a test program on a NUCLEO dev kit (also a F4 controller) and it worked.
Now I get an error and it doesn't want to connect to my PC which is the broker. I have tried the following things:
- I have made sure my firewall doesn't block port 1883 en 8883.
- I can ping the controller.
- I made an extra init flag to make sure that the init code runs first before trying to subscribe or connect to anything.
I got the following error first: ERR_RTE = -4 which is a routing problem.
But his has changed and now I get:
Assertion "mqtt_sub_unsub: client != NULL" failed at line 1183 in ../Middlewares/Third_Party/LwIP/src/apps/mqtt/mqtt.c
(so I'm not sure if the previous error is fixed)
I'm not immediately sure what the problem can be. For more context i'm using freertos and have given the task a stack size of 256 words. I have included the code from the task. Anyone have any ideas?
Kind regards,
William
