Handling escaped chars (using \ char) from a user
- From: Johnny Cybermyth <johnny.cybermyth@xxxxxxxxx>
- Date: Fri, 14 Jul 2006 21:16:04 GMT
I'm writing a plugin for a serial port program and need to support sending non ASCII chars. I would like to allow the user to express non-ASCII chars in a simple hex escape format: \01 \0D etc
So a sample string would be input as:
\01A01TEST\02
which would be interpreted as a string of these hex chars:
01 41 30 31 54 45 53 54 02
I'm new to TCL so any ideas on better ways to get this done is appreciated.
--Johnny
.
- Follow-Ups:
- Re: Handling escaped chars (using \ char) from a user
- From: Michael Schlenker
- Re: Handling escaped chars (using \ char) from a user
- Prev by Date: Re: Is AKAv1-MD5 package available in TCL as open source?
- Next by Date: Re: Handling escaped chars (using \ char) from a user
- Previous by thread: Open a file from remote Windows and use the content in the file locally
- Next by thread: Re: Handling escaped chars (using \ char) from a user
- Index(es):
Relevant Pages
|