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

Sending Ctrl+z over uart

I am interfacing the nrf2832 with the sim 808 module.

In order to be able to send a message I need to use Ctrl+z.

This should be entered as an escape sequence.

I have tried printf("\x1A"); but it doesn't work. How do I send Ctrl+z as an escape sequence?

Parents Reply
  • Thank you for the response.

    AT+CMGS=<number><CR><message><CTRL-Z>  (This the format of the AT commands that has to be sent).

    printf("\r\nAT+CMGF=1\n");
    		nrf_delay_ms(5000);
    		printf("AT+CMGS=\"+919xxxxx22\"\r");
    		nrf_delay_ms(2000);
    		printf("Hello,Elecrow!");
    		nrf_delay_ms(1000);
            printf("%c", 0x1A);	// i tried this but its not working , i have put ctrl+z here 
    		nrf_delay_ms(1000);
    		printf("\r\nAT\r\n");
    		nrf_delay_ms(5000);

    the rest of the AT commands are giving proper return values 

Children
Related