This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

at_client routine, the test at instruction does not return any information.

Hi Didrik Rokhaug,

sdk:ncs v1.2

Routine path:D:\ncs\v1.2.0\nrf\samples\nrf9160\at_client

The routine is attached:

at_client.rar
The test results are shown in the figure below:

After sending multiple 0A0D instructions, the program does not return a value after sending other normal instructions again.

This error will cause the program to become stuck in the event of a serial communication program exception.

This phenomenon can cause the customer to misdiagnose that there is a bug in the AT instruction.

Please further increase the module AT instruction fault tolerance mechanism.

Kind regards, Peter.Min

Parents
  • Thanks.

    The at_host library does not handle empty AT commands very well. You can terminate an AT command with as many newlines and carriage returns as you want, but you cannot mix them.

    E.g. AT\n\n\n\n\n\r\r\r\r\r\r is OK, but "AT\n\r\n" is not OK because there is an '\r' "inside" the '\n's.

    The same situation happens when you enter "empty" commands.

    What is actually happening is that the at_host library sees the "terminating character", and sends the "AT command" (in this case, nothing) to the modem, then waits for the modem to reply. However, the modem does not receive any command, and therefore does not reply. This causes the at_host library to wait forever.

    You should therefore only send valid AT commands to the at_host library and the at_client sample.

    Best regards,

    Didrik

Reply
  • Thanks.

    The at_host library does not handle empty AT commands very well. You can terminate an AT command with as many newlines and carriage returns as you want, but you cannot mix them.

    E.g. AT\n\n\n\n\n\r\r\r\r\r\r is OK, but "AT\n\r\n" is not OK because there is an '\r' "inside" the '\n's.

    The same situation happens when you enter "empty" commands.

    What is actually happening is that the at_host library sees the "terminating character", and sends the "AT command" (in this case, nothing) to the modem, then waits for the modem to reply. However, the modem does not receive any command, and therefore does not reply. This causes the at_host library to wait forever.

    You should therefore only send valid AT commands to the at_host library and the at_client sample.

    Best regards,

    Didrik

Children
No Data
Related