Results 1 to 1 of 1
I'm trying to create a shell script which turns my TV on/off via serial / RS232. I'm using OSX.
I think I'm close...
The RS232 commands:
Code:
STXPONETX -- Power ...
- 09-30-2008 #1Just Joined!
- Join Date
- Sep 2008
- Posts
- 1
Need help sending RS232 commands from the shell. printf not working...
I'm trying to create a shell script which turns my TV on/off via serial / RS232. I'm using OSX.
I think I'm close...
The RS232 commands:
If I runCode:STXPONETX -- Power On STXPOFETX -- Power Off
Then type ctrl-B, P, O, N, ctrl-C the TV turns on, proving that the serial port is configured properly, cable is good, etc.Code:screen /dev/tty.PL2303-0000101D
Now how do I make a shell script do the same thing?
I tried:
No dice. Both commands just hang, I have to ctrl-C them.Code:printf "\x02POF\x03" > /dev/tty.PL2303-0000101D echo "\x02POF\x03" > /dev/tty.PL2303-0000101D
Any ideas??


Reply With Quote