Hey,
i have an account at wia.io to use for IoT. It’s possible to send messages by UDP. They have an instruction on https://developers.wia.io/docs/quectel-bc95-g that workes fine - but only one time. if i repeat the “C:\Python27>python nb-iot.py -aknt” command, i get an “Failed to send message” error.
… some days later i updated the firmware. But again, i got the error.
After some more experiments by manually sending AT commands over terminal software i found out that it works very simple.
First preset your BG95-G for AUTOCONNECT by the following commands, that work with Vodafone Germany
AT+NCONFIG=AUTOCONNECT,TRUE
AT+NCONFIG=CR_0354_0338_SCRAMBLING,TRUE (depends on your carrier?)
AT+NCONFIG=CR_0859_SI_AVOID,FALSE (depends on your carrier?)
AT+NBAND=20 (depends on your country and carrier!)
AT+CGDCONT=0,“IP”,“nb.inetd.gdsp” (Vodafone, “0” is belonging to AUTOCONNECT)
AT+COPS=0
After the “AT+NRB” reset command these preferences are stored in the NV-RAM of the BC95-G and used for AUTOCONNECT at startup.
To send UDP data you only have to open a socket by
AT+NSOCR=DGRAM,17,1234,1 (open socket no. 1)
AT+NSOST=1,192.158.5.1,1024,2,AB30,1 (send data over socket no. 1)