I am using the Nova (SARA-R410M) on a Raspberry Pi 3 B+ running the latest raspian os (Buster). This hardware is intended to function as a gateway. It receives IoT data from remote sensors via RF (XBee S2C), formats it and then sends it to a cloud server via MQTT. Everything works. Sometimes.
I am using Ruby SerialPort for USB serial communications to the Nova. I have a hologram sim card which connects to “hologram” via a local carrier (Rogers, in Canada, I believe). I am able to send SMS messages via a serial terminal (minicom, in this case).
I am able to identify the correct USB port, open it, send various commands to the Nova. These include basic config commands such as AT, ATE0, AT+CCID, AT+CGSN (which returns 15,99), basic MQTT commands such as port setup (AT+UMQTT=1,<port>) and server setup (AT+UMQTT=2,<domain>), both of which return success. However, when I attempt to login into the MQTT agent - AT+UMQTTC=1 - I get an error return code (1,0). Subsequently issuing AT+UMQTTER returns 350,-20043, which is listed as “MQTT TCP connection error (QAPI MQTT)”.
- The odd time, the login is successful and I can follow up with MQTT publish to a topic commands, which then work and are the whole point of all this.
- It doesn’t seem to matter where the MQTT agent is (eg test.mosquitto.org, or AWS, etc) - they all fail
- It also fails when I send to the Nova from the serial terminal
- If I issue a mosquitto_pub -h… from the command line in the RPi, it works fine. This command logs into the MQTT agent and sends the topic and message.
- I didn’t have to do anything further with Rogers - the Hologram sim card worked ‘out of the box’. Apparently Rogers has rolled out their CAT-M support and Hologram is on board.
- The issue appears to be in the transport layer. I suppose there are a lot of moving parts that integrate a number of newer technologies and I suspect there are lots of bugs in the system.
- My next step might have been to bypass the hologram MQTT api and implement a basic MQTT library myself. But this would rely on the SARA R4 IP transport layer, where I believe the current issues are lurking. Writing such an MQTT library would probably run into the same issues. Hence my posting here…