May 30th, 2006, 03:41 PM
Serial plugin and an LG TV w/rs232
Just hoping for whatever I am missing here. I am trying to communicate to an LG tv using the serial plug in with no sucess. I have made it work with other devices so my system works. Can anyone suggest what the appropriat call would be from Girder. The command the tv is looking for is
[Command1][Command2][ ][Set ID][ ][Data][Cr]
* [Command 1]: First command to control the set. (j,k,m or x)
* [Command 2]: Second command to control the set.
* [Set ID]: You can adjust the set ID to choose desired TV ID
number in Setup menu. Adjustment range is 1 ~
99. When selecting Set ID ‘0’, every connected the
TV is controlled. Set ID is indicated as decimal
(1~99) on menu and as Hexa decimal (0x0~0x63)
on transmission/receiving protocol.
* [DATA]: To transmit command data.
Transmit ‘FF’ data to read status of command.
* [Cr]: Carriage Return
ASCII code ‘0x0D’
* [ ]: ASCII code ‘space (0x20)’
should there be space or something between the commands?
Thanks for any help. I MISS MARK F!!!
May 30th, 2006, 03:51 PM
Here's my serial device for an LG LCD TV - model 32LX2R.
Note that you need to use the included init.lua which replaces the normal init.lua
May 30th, 2006, 04:20 PM
Raj, thanks but a little more direction please
where do the the files go? Do I open in notepad and cut and paste them in the device settings and in the command to be sent? If so, which goes where?
May 30th, 2006, 04:24 PM
Raj, and I am using Girder 3
Have not had the time to migrate yet to 4. If I must to make your solution work, I will. The TV control is very important to me although, Mark F over a year ago assisted in getting my alarm and marantz receiver to work flawlessly. I would rather not change if not necessary
May 30th, 2006, 04:37 PM
Oops, sorry, I hadn't spotted that you were using G3.3
It may still be worth reading the source though.
It's been a long time since I used G3.3 and longer since I used its serial plugin I'm afraid.
An example of a command is -
power on =
ka 0 1<cr>
where <cr> is a carriage return
May 31st, 2006, 07:09 AM
Which parts need to be translated to binary and which don't? Can you post a link to the RS-232 protocol manual?
EDIT: Try these.
The attached .zip file contains a .ini and a .lua file. The .ini should be imported into the serial plugin. Be sure to assign the correct COM port to the new device. The .lua file should be placed in the ...../girder/lua directory.
Once you have done the above, restart Girder and you should be able to use the commands on the LGTV device object. For example:
It must be noted that I stole the commands from the files Rob posted.
Last edited by Mark F; May 31st, 2006 at 08:07 AM.
May 31st, 2006, 08:01 AM
OK, The above is broken but I'll fix it.
EDIT: A fixed version is attached.
Last edited by Mark F; May 31st, 2006 at 08:08 AM.
May 31st, 2006, 09:05 AM
In case you hadn't worked it out already Mark, the LG TVs only use ASCII
May 31st, 2006, 12:17 PM
Thanks Rob. I peeked into the G4 stuff you provided and saw that. The linked G3 .zip file has bin->hex->bin turned off.
I hope it works.
June 5th, 2006, 07:19 PM
Mark, A Blast from the Past!!
Great to hear from you. First off, I hope you and your family are all well!
Thanks so much for your reply. I did try the files but with no luck. My Girder directory does not have a lua folder so I created one. Is that correct?