LinuxMCE Forums
May 20, 2013, 09:47:07 am GMT-1 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Rule #1 - Be Patient - Rule #2 - Don't ask when, if you don't contribute - Rule #3 - You have coding skills - LinuxMCE's small brother is available: http://www.agocontrol.com
 
   Home   Help Search Chat Login Register  
Pages: 1 [2] 3
  Print  
Author Topic: Need help with rs232 tv  (Read 4609 times)
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #15 on: December 03, 2008, 06:51:27 am »

Ok, I'm getting close, but am stuck on the ruby code syntax.  On the A/V page, I have my television listed.  COM Port on PC is /dev/ttyS0, but I cannot get the ruby code correct.

The information I got from Olevia says that the power off Hex Command is BE 05 27 00 EA   

I click A/V properties and assume that here is where I should enter my magic ruby codes.  But I actually don't know any ruby programming, so I got stuck.  I tried to use some syntax I found in other templates, but no dice.  Any help? 
Logged
darrenmason
Addicted
*
Posts: 529


View Profile
« Reply #16 on: December 04, 2008, 12:18:34 am »

If you are just trying to send serial commands then you might be better with the short form.
This allows you to simply enter the serial commands to send without all the ruby syntax.

Described here....
http://wiki.linuxmce.com/index.php/Generic_Serial_Device
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #17 on: December 05, 2008, 05:43:44 am »

Ok, well then how exactly do I do that?  I've tried putting the code straight in.  I've also tried

<$"BE 05 27 00 EA"$>
Logged
hari
Administrator
LinuxMCE God
*****
Posts: 2413



View Profile WWW
« Reply #18 on: December 05, 2008, 10:19:48 am »

you better not send the hex values as ascii strings :-)
Logged

rock your home - http://www.agocontrol.com home automation
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #19 on: December 05, 2008, 10:06:32 pm »

Arg!  Can someone just tell me what to type in there?  I have no idea what I'm doing with that hex code!
Logged
tschak909
LinuxMCE God
****
Posts: 5101

DOES work for LinuxMCE.


View Profile
« Reply #20 on: December 05, 2008, 10:12:22 pm »

http://www.rubycentral.com/pickaxe/language.html

Start at the "Strings" section.

The needed info is in there.

-Thom
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #21 on: December 06, 2008, 06:04:33 am »

Ok, here are the things that I've tried.  I read you link Thom, but I don't know which criteria I should use.

I tried these entries.
<$"BE 05 27 00 EA"$>  <$"BE052700EA"$>
"BE 05 27 00 EA"     "BE052700EA"
"\xBE \x05 \x27 \x00 \xEA"   <$"\xBE \x05 \x27 \x00 \xEA"$>


Does anyone have a straight answer for me?  Thom's link is great, but I still didn't know what I was looking for under "strings".
Logged
tschak909
LinuxMCE God
****
Posts: 5101

DOES work for LinuxMCE.


View Profile
« Reply #22 on: December 06, 2008, 06:44:10 am »

try, <$"\xBE\x05\x27\x00\xEA"$> .. keep in mind that spaces are literal bytes as well, so they will be parsed by the tv..so you need to remove them. The spaces in the protocol specification are simply for visual purposes.

-Thom
Logged
PeteK
Guru
****
Posts: 408


View Profile
« Reply #23 on: December 06, 2008, 07:15:43 pm »

Ok, here are the things that I've tried.  I read you link Thom, but I don't know which criteria I should use.

I tried these entries.
<$"BE 05 27 00 EA"$>  <$"BE052700EA"$>
"BE 05 27 00 EA"     "BE052700EA"
"\xBE \x05 \x27 \x00 \xEA"   <$"\xBE \x05 \x27 \x00 \xEA"$>


Does anyone have a straight answer for me?  Thom's link is great, but I still didn't know what I was looking for under "strings".

I sent you my Olevia 232T template screen shots which work in 0710.  Can you please add the information to a wiki page, like this one?

http://wiki.linuxmce.org/index.php/LG_42LB5D

Thanks,
-Pete
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #24 on: December 06, 2008, 08:27:32 pm »

Hmm.  I'm not sure that anything is even being sent to the TV.  Anyone know of a utility outside of LMCE (like a kubuntu app) that I could use to test my serial port?  <$"\xBE\x05\x27\x00\xEA"$> does not work.


And PeteK, I can add it to the wiki, but I don't have it working, so I don't have all the information you have.  Do you have the on/off functions working?  If so, what exactly do you use for those ruby codes?
Logged
tschak909
LinuxMCE God
****
Posts: 5101

DOES work for LinuxMCE.


View Profile
« Reply #25 on: December 06, 2008, 08:30:40 pm »

We provide a utility called TestSerialPort for this very purpose. You can see it being used in the scripts in the /usr/pluto/pnp directory.

-Thom
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #26 on: December 07, 2008, 04:43:56 am »

PeteK, sorry, I was having email prgram difficulties and didn't notice that you sent more than 1 picture, so I will put that information into the wiki.  You should talk with Thom about getting your script/template implemented in the next release.
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #27 on: December 07, 2008, 07:49:40 am »

PeteK, I've made a preliminary page on the wiki with your information.  However, I'm still having trouble getting any response from my tv.  I mimicked every single setting in those pictures you sent and still cannot get anything.  I'm starting to wonder if I have a bad cable or a bad jack on the TV. 

I tried using your script via the terminal and it claimed that I didn't have an olevia TV.  I got the message "unknown N81".  When I looked at the code of the script, I noticed that port is set to "$3".  I don't know much about how the pnp scripts work, but is this correct?  shouldn't this be something like /dev/ttyS0? 
Logged
Afkpuz
Guru
****
Posts: 211



View Profile
« Reply #28 on: December 12, 2008, 03:42:59 am »

bump
Logged
PeteK
Guru
****
Posts: 408


View Profile
« Reply #29 on: February 27, 2009, 05:45:23 am »

I checked in my Olevia template a few days ago.  Try doing a sqlCVS update and let me know if that template works for you.

Logged
Pages: 1 [2] 3
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!