Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Sending Ctrl+Z to a serial port

I'm sending AT-Command to gsm modem through serial port.

At the end of the AT-Command I have to terminate the command with Ctrl+z

How would I do that in serial port?

like image 283
Stacker Avatar asked Jan 18 '23 21:01

Stacker


2 Answers

try this

(char)26

detail on ascii of char-z

like image 82
Arjun Shetty Avatar answered Jan 21 '23 11:01

Arjun Shetty


Send the ASCII character 0x1A.

Have a look at the ASCII code table

like image 37
John Oxley Avatar answered Jan 21 '23 09:01

John Oxley