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

Please help me with this issue. : Send this instruction using the at_cmd_write function: AT-CGDCONT? Returns an error value

I sent the AT instruction back correctly with the serial tool sscom5.13.1

I sent the AT instruction error with the secondary function:
at_cmd_write ("AT-CGDCONT?," buf, sizeof (buf), s.at_state);

Attachments are serial tools and code

15_hello_world_at_lte.rar

sscom5.13.1.rar

See figure below for testing

Parents
  • I looked at your images, and I'm a little confused. You said at_cmd_write ("AT-CGDCONT?," buf, sizeof (buf), s.at_state) returns an error. However then the line printk("AT command error:...") should return. However, it does not, in the SSCOM terminal. Instead ".... step 11 =" is printed

    Could you elaborate on what goes wrong?

  • 1. Execute this function:
    at_cmd_write ("AT-CGDCONT?,""buf," sizeof (buf), s.at_state)

    2. Normally:
    Step11 should return an IP address similar to the following: .CGDCONT: 0, "IP", "cmnbiot", "100.113.74.90", 0,0,0

    3. Error case, as you can see in the test: "Step 11"
    The return value at this point should be 0

    4. How to do it to return an IP address similar to the following image:
    CGDCONT: 0, "IP", "cmnbiot", "100.113.74.90",0,0

Reply
  • 1. Execute this function:
    at_cmd_write ("AT-CGDCONT?,""buf," sizeof (buf), s.at_state)

    2. Normally:
    Step11 should return an IP address similar to the following: .CGDCONT: 0, "IP", "cmnbiot", "100.113.74.90", 0,0,0

    3. Error case, as you can see in the test: "Step 11"
    The return value at this point should be 0

    4. How to do it to return an IP address similar to the following image:
    CGDCONT: 0, "IP", "cmnbiot", "100.113.74.90",0,0

Children
Related