I’m using TCP/IP by serial. I sent the small packet to server every minutes.
Now I have a problem.
When failed to communicated various reason, the session is can’t re-use anymore.
Example,
After send the AT+KTCPCNX=session_id, sometimes rejected from server. - receive the ack +KTCP_NOTIF: session_id,5.
Yes, it can be happend. But after this status, I tried to close the sesson or delete the session. Then it goes to fail.
AT+KTCPCLOSE=1,1
NO ack
AT+KTCPDEL=1
ERROR
How can I re-use that session number? Because I reached last session_id at one day. No more usable session_id.
Please provide the output of the below commands:
ATI3
AT+CREG?
AT+CGDCONT?
AT+CGACT?
AT+CGPADDR
AT+CMEE=1
AT+KCNXCFG?
AT+KTCPCFG?
AT+KTCPCLOSE=1,1
AT+KTCPDEL=1
I didn’t check the Software version. I am going to check it.
I usually using below sequence, It’s working well. But sometimes crashed.
AT&K3
AT+KTCNXCFG=1, “GPRS”,“APN”
AT+KTCPCFG=1,0,“ServerIP”,ServerPort - get a session_id
AT+KTCPCNX=session_id
AT+KTCPSND=session_id,length - receive CONNECT and send buffer
+KTCP_DATA: session_id,receive_buffer_size
AT+KTCPRCV=session_id,length - receive CONNECT and read buffer
AT+KTCPCLOSE=session_id,1
AT+KTCPDEL=session_id
Sometimes crashed and can’t re-use session_id. Then got a next session_id and retry.
But HL8548 can get a session_id maximum 32. After using all session_id, can’t communicate anymore.
After crashed I tried AT+KTCPSTAT, but no ACK.
That is my problem. Please advice to me.
Thank you.