6 UDP script
An example of UDP communication over NB-IoT is reported below; in this scenario, APN is
not required and it set automatically by the network. The module enables NB IoT only. A UDP
socket is opened in command mode on xxx.telit.com echo server. “echo_test_UDP” string is
sent to the server and echoed back to the module. Incoming data is signalled through SRING
unsolicited. AT#SI (Socket Info) command is used to check the data buffered and not yet read.
AT#SRECV command is used to read the data. AT#SS command is used to check remote
server IP address and socket status.
AT+WS46?
+WS46: 28
OK
AT#WS46?
#WS46: 1
OK
AT+CGDCONT?
+CGDCONT: 1,"IPV4V6","","0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0",0,0,0,0
+CGDCONT: 2,"IPV4V6","","0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0",0,0,0,0
…
+CGDCONT: 6,"IPV4V6","","0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0",0,0,0,0
OK
AT+CEREG?
+CEREG: 0,1
OK
AT+COPS?
+COPS: 0,1,"I TIM",9
OK
AT#MONI
#MONI: I TIM RSRP:-72 RSRQ:-3 TAC:9091 Id:AAFC4A1 EARFCN:6290 PWR:-67dbm
DRX:1024 pci:0 QRxLevMin:0
OK
AT+CGCONTRDP
+CGCONTRDP: 1,5,"nbiot.tids.tim.it","10.18.13.162",,"192.168.200.43","192.168.200.42"
OK
AT#SGACT?
#SGACT: 1,0
#SGACT: 2,0
…
#SGACT: 6,0
OK