Your Universal Remote Control Center
RemoteCentral.com
Discrete Code Hunter Forum - View Post
Previous section Next section Up level
Up level
The following page was printed from RemoteCentral.com:

Login:
Pass:
 
 

Topic:
Pronto to Lirc
This thread has 2 replies. Displaying all posts.
Post 1 made on Wednesday July 25, 2007 at 16:46
doucga
Lurking Member
Joined:
Posts:
February 2006
2
Hello Group

I've futzed with this on my own for a couple days and now I'm admitting defeat and hoping someone here can put me out of my misery.

I have a Fisher stereo that I'm controlling with a serial IR Blaster using Lirc. I've managed to get this working nicely.

My problem is the lircd.conf file that I found for the remote has only one button to change the AV input (AV2). The stereo has two buttons, another for a second input (AV1). What I'm trying to do is add another button for the AV1.

I wasn't able to get IRW in Lirc to recognize the codes from the remote using PVR150 receiver I have. So I gave up on that. I have a TSU3000 and was able to get the Pronto codes using the ProntoEdit NG software.

Sooo...

lircd.conf (clipped)

begin remote
# Radio- Stereo set - Fisher Remote Contrl REM S3
name stereo
bits 15
flags SPACE_ENC
eps 25
aeps 100

header 9117 4338
one 665 446
zero 665 1574
ptrail 665
repeat 9068 2124
pre_data_bits 16
pre_data 0xC33C
post_data_bits 1
post_data 0x0
gap 39682
toggle_bit 0

AV2 0x0000000000002ED1


And, Pronto Codes learned from using TSU3000 and ProntoEdit

AV2 - 900A 006D 0000 0001 3CC3 45BA

Can someone give me some guidance on how I can convert the AV1 Pronto code into an equivalent Lirc code.

AV1 - 900A 006D 0000 0001 3CC3 46B9

I would be forever in your debt...

Garry
Post 2 made on Wednesday July 25, 2007 at 17:33
johnsfine
IR Expert
Joined:
Posts:
September 2002
5,159
The line you want is

AV1 0x0000000000004EB1

Explanation:

LIRC and the Pronto are representing the same information but with two important differences:

1) All the bits are inverted (0 becomes 1 and 1 becomes 0)

2) Within each byte the sequence of bits is reversed (left to right).

On July 25, 2007 at 16:46, doucga said...
pre_data 0xC33C

You don't need to change that, but if you want to understand it:

C3 hex is 1100 0011 binary
invert that and you get 0011 1100
reverse the sequence turns out to make no difference
0011 1100 binary is 3C hex.

So the predata C33C that you see in the LIRC file becomes the predata 3CC3 you see in the Pronto signals.

post_data_bits 1
post_data 0x0

That's an annoying extra twist. It means only half of the possible commands can be supported by this LIRC file and it makes translating harder. But it doesn't seem to be a problem for AV1. So it probably isn't worth editing the whole LIRC file to clean that up.

It requires that at a certain moment (see below) in translation, we need to throw away the last bit and that bit must be a '0' (right before we throw it away).

AV2 0x0000000000002ED1

AV2 - 900A 006D 0000 0001 3CC3 45BA

1) Take the command 45BA and translate hex to binary getting 01000101 10111010
2) Invert all the bits: 10111010 01000101
3) Reverse sequence within each 8-bits: 01011101 10100010
4) Throw away the last bit, which must be '0': 01011101 1010001
5) Regroup to translate to hex 010 1110 1101 0001
6) Translate to hex: 2ED1

AV1 - 900A 006D 0000 0001 3CC3 46B9

Do the same with 46B9 instead of 45BA

1) Translate hex to binary getting 01000110 10111001
2) Invert all the bits: 10111001 01000110
3) Reverse sequence within each 8-bits: 10011101 01100010
4) Throw away the last bit, which must be '0': 10011101 0110001
5) Regroup to translate to hex 100 1110 1011 0001
6) Translate to hex: 4EB1
OP | Post 3 made on Wednesday July 25, 2007 at 17:50
doucga
Lurking Member
Joined:
Posts:
February 2006
2
Thank you so much for the clear an concise explanation and for your help!

I'll study this very closely and hopefully it will help someone else too.

Regards,

Garry


Jump to


Protected Feature Before you can reply to a message...
You must first register for a Remote Central user account - it's fast and free! Or, if you already have an account, please login now.

Please read the following: Unsolicited commercial advertisements are absolutely not permitted on this forum. Other private buy & sell messages should be posted to our Marketplace. For information on how to advertise your service or product click here. Remote Central reserves the right to remove or modify any post that is deemed inappropriate.

Hosting Services by ipHouse