HL7812 with timeout ('NO CARRIER') problem

Hi all,

Fix or workaround for a timeout problem concerning HL7812 communication with http protocol.

I have a running application which works fine with HL7692.
No timeout appears and no ‘NO CARRIER’ will be thrown, also if the webserver response is > 10 seconds.
If I use the HL7812 with the identical application, every time when the webserver response
needs more than 5 seconds a ‘NO CARRIER’ message appears with the reason ‘timeout’.

I do not know, if timeout is initiated by the HL7812 or the webserver.

If problem comes from HL7812:
I have tried to increase the connection timer idle time to 60

  • “AT+KCNXTIMER=1,60,4,120,60”
    but timeout happens again every time after 5 seconds, while waiting for the webserver response.

If problem comes from webserver:
I have tried to increase the timeout by setting the keep-alive parameter in the http header.

  • Connection: Keep-Alive
  • Keep-Alive: timeout=10
    but timeout happens again every time after 5 seconds, while waiting for the webserver response.

Below shows the relevant part of HL7812 communication with http protocol.

  • index 116-117: time between send data and receive response is 0.5 seconds => no timeout
  • index 140-141: time between send data and ‘no response’ is 5 seconds => timeout and ‘NO CARRIER’

If I use HL7692 instead of HL7812, the HL7692 will wait without any problem
until the webserver response appears (about 10 seconds) and no error appears.
So it looks like the timeout problem comes from HL7812 (instead of webserver).

Index - Time - Data

105, 74.63053501, SERIAL, Usart3-TxD, AT+KHTTPHEADER=1\r\n
106, 74.75691297, SERIAL, Usart3-RxD, CONNECT
107, 74.77185192, SERIAL, Usart3-TxD, Accept: text/plain\r\n
108, 74.90077203, SERIAL, Usart3-TxD, Connection: Keep-Alive\r\n
109, 75.03347042, SERIAL, Usart3-TxD, Keep-Alive: timeout=10\r\n
110, 75.16639926, SERIAL, Usart3-TxD, Content-Type: application/x-www-form-urlencoded\r\n
111, 75.32771136, SERIAL, Usart3-TxD, Content-Length: 25\r\n
112, 75.45592928, SERIAL, Usart3-TxD, --EOF–Pattern–
113, 75.57938351, SERIAL, Usart3-RxD, OK
114, 75.58936068, SERIAL, Usart3-TxD, AT+KHTTPPOST=1 “/xxx/register.php” 0\r\n
115, 75.75301306, SERIAL, Usart3-RxD, CONNECT
116, 75.76830983, SERIAL, Usart3-TxD, ident=0123&customerid=708
117, 76.27380396, SERIAL, Usart3-RxD, XMITRESULT=1000–EOF–Pattern–\r\nOK
118, 76.31832300, SERIAL, Usart3-RxD, XMITRESULT=1000–EOF–Pattern–\r\nOK\r\n\r\n+KHTTP_IND: 1 3 78 200 “OK”
119, 76.49126540, SERIAL, Usart3-TxD, AT+KHTTPCLOSE=1 1\r\n

129, 85.52241419, SERIAL, Usart3-TxD, AT+KHTTPHEADER=1\r\n
130, 85.64871306, SERIAL, Usart3-RxD, CONNECT
131, 85.66362146, SERIAL, Usart3-TxD, Accept: text/plain\r\n
132, 85.79247028, SERIAL, Usart3-TxD, Connection: Keep-Alive\r\n
133, 85.92527051, SERIAL, Usart3-TxD, Keep-Alive: timeout=10\r\n
134, 86.05819893, SERIAL, Usart3-TxD, Content-Type: application/x-www-form-urlencoded\r\n
135, 86.21951097, SERIAL, Usart3-TxD, Content-Length: 25\r\n
136, 86.34772794, SERIAL, Usart3-TxD, --EOF–Pattern–
137, 86.47108325, SERIAL, Usart3-RxD, OK
138, 86.48101976, SERIAL, Usart3-TxD, AT+KHTTPPOST=1 “/xxx/data.php” 0\r\n
139, 86.64361276, SERIAL, Usart3-RxD, CONNECT
140, 86.65882189, SERIAL, Usart3-TxD, ident=0123&customerid=708
141, 91.74650397, SERIAL, Usart3-RxD, NO CARRIER\r\n\r\n+KCNX_IND: 1 5 60\r\n\r\n+KHTTP_ERROR: 1
142, 91.80771835, SERIAL, Usart3-RxD, NO CARRIER\r\n\r\n+KCNX_IND: 1 5 60\r\n\r\n+KHTTP_ERROR: 1 6\r\n\r\n+KHTTP_IND: 1 0
143, 91.91886949, SERIAL, Usart3-TxD, AT+KHTTPCLOSE=1 1\r\n

  1. Is there any AT command where I can change this timeout behaviour on HL7812?
    AT+KCNXTIMER did not have the desired effect.

  2. Is there a possibillity for a workaround, so the timeout will be avoided?

Best regards

As a workaround, you can use +ktcp command instead


  1. did you mean using a sequenz of TCP commands like:
    (is this a workaround for the timeout problem?)

wait for receive data

  1. Is the timeout problem (using AT+KHTTPPOST=) a known bug for the HL7812?
    (AT+KHTTPPOST= works fine, no timeout, with HL7692 )

yes, it is a workaround for the server timeout
BTW, you can use +KTCPSTART

I believe there is a default timeout value of 5 second for +kHTTP command which is hardcoded in the code

If so, why such a strong (5 seconds) restriction? Maybe a nice option for next HL7812 firmware: Let this timeout be configureable with AT command.

did you contact distributor for the feature request?

Our distributor is informed and had send the detailed problem description and fully communication logs to sierra Wireless. I have also send him a link to this thread.