Home AMX User Forum NetLinx Studio

RS232 - Controling TV with PC command

I am trying create a file that I can leave on my desktop so when I open the file it will send the RS232 command out of the PC port "X" into my TV to shut it off.

Comments

  • ericmedleyericmedley Posts: 4,177
    davidv wrote: »
    I am trying create a file that I can leave on my desktop so when I open the file it will send the RS232 command out of the PC port "X" into my TV to shut it off.

    Sounds like something you can cobble together in visual basic. a simple script will do the trick.
  • davidvdavidv Posts: 90
    Bat file

    cant I just write a bat file in notepad?



    mode COM1:9600,n,8,1

    copy autoexec.bat com1
  • DHawthorneDHawthorne Posts: 4,584
    A bat file would probably work, but what you want is more like this:

    echo [insert command here] > com1:

    That redirects the output to the com port ... I don't quite remember if you need the colon after com1 or not, so you may have to play with that. The big if here though is if the protocol is pure ASCII. If you need it to be hex, you are going to have to do a script like Eric suggests. There are some escape sequences ou can enter into a batch file, but for a full blown protocol, it may not be enough.
Sign In or Register to comment.