I would like to rest assured about correct command sequence in case of BC660K incorporated into outdoor sensor regularly, e.g. once per hour, sending uplink message (telemetric data) to the cloud with occasional downlink messages (configuration) from time-to-time, e.g. once per day, using UDP:
- after network registration (+CEREG: 5) open UDP socket and keep opened (AT+QIOPEN=0,0,UDP,server.address,port)
- after specified measurement interval check socket open state AT+QISTATE=1,0,
- if socket open, proceed sending with release assistance after downlink AT+QISEND=0,4,DEADBEEF,2
- if downlink available, process +QIURC
- go to sleep, repeat from 2
Thank you for your suggestion.
Do you need AT Commands to start with registering the network?
Have you enabled PSM?
Initial Commands fo registering, psm etc. was omitted for brevity. My question was toward keeping connection open and data transfer commands.
I think you can work it out by referring to the documentation
Quectel_BC660K-GL_TCP(IP)_Application_Note_V1.0.pdf (361.0 KB)
can you confirm that keeping the UDP socket open between sending (and sleeping) intervals is okay? I.e. that essentially means keeping the socket open indefinitely for the sensor lifetime.
I checked out the document that you shared but I didn’t find an answer to that question. If there is any other documentation that gives info about this question then that would be very much appreciated
This problem depends on the characteristics of your local network. To solve this problem, it is recommended to periodically send heartbeat packets