[Hilo] How to insert non printable characters for <AT+KPATTERN >? Can I use hex “0x0D” in the pattern string?
Answer: If you want you use the non-printable pattern string, for example (0x01 0x02 0x03 0x0A)
You can send the AT command in hex mode, for example:
41 54 2B 4B 50 41 54 54 45 52 4E 3D 22 01 02 03 0A 22 0D 0A (AT+KPATTERN=" ")
Then module will switch to command mode after you send non printable characters “01 02 03 0A”
AT+KTCPSND=1, 10000
CONNECT
<01 02 03 0A >
OK
For your application source code, you can also use “\” for the escape. For example:
‘\0x3F’ is for ‘?’
Please note that, only “0x0D” is forbidden in the pattern string, it is because it’s the same character for checking the end of an AT command.