RAK5860 BG77 mqtt client challenge

I have been attempting to code a mqtt client on the combination of the 4631 core and the rak 5860 (BG77). I am using the native mqtt at commands of the bg 77. With little luck, however. I am unable to receive all of the data the bg 77 modem sends back, i.e. I cannot reliably capture the OK needed to confirm successful sending of some AT commands. Also, there is important ERROR data, network connection and mqtt client connection information within URCs that need to be acted upon by the client to successfully start and maintain the connection. If there is someone on this forum that is interested in this topic I can post my code and likewise I am very interested in your insights and code. The goal is to get an mqtt client going that has high reliability and communications up time.

Hi @jvdstoel1024 ,

I have RAK5860 but no NB-IoT/LTE-M service in my location. But whenever I do cellular IoT related stuff (usually GPRS connection), I do the following:

  1. Test the backend if all is working well using WiFi board first instead of Cellular. This way, we can be sure that the MQTT broker connection is reliable and not an issue.
  2. Ensure that the antenna are properly connected and ensure that there is good coverage in my location.
  3. Doublecheck if the power source is enough. It would be best to check the voltage supply line if stable (not noisy and don’t have significant dip during transmission).

Hello Carl,
Ok, I have been working on this mqtt client for a while. I am confident that your 3 points are not at issue here. The mosquitto service has been working well for several years; I have other cell devices working well at the same location and I have batteries to supply the current needs.
The challenge is dealing with the half duplex (2 wire TX, RX) connection to the modem, without RTS or CTS lines to manage data flow to/from the modem.
I discovered I could not catch the OK transmitted by the modem in response to the AT+QMTOPEN command, and thus had to follow up with a AT+QMTOPEN? command to detect whether the OPEN had succeeded. Similarly with the AT+QMTCONN command.