LEGO power functions
Moderator: Moderators
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
LEGO power functions
I'm contemplating using IRscope to learn the signals of a LEGO remote. It'll be in couple of weeks.
It's a really neat remote. Controls several trains beautifully.
http://shop.lego.com/en-US/LEGO-Power-F ... ntrol-8879
There is a description of IR signals here:
www.philohome.com/pf/LEGO_Power_Functions_RC_v110.pdf (cached version)
I only understand, a little bit, of pages 13-14.
There are rotary buttons, which probably preclude any upgrade working in my remotes, but I thought I ask anyway.
It's a really neat remote. Controls several trains beautifully.
http://shop.lego.com/en-US/LEGO-Power-F ... ntrol-8879
There is a description of IR signals here:
www.philohome.com/pf/LEGO_Power_Functions_RC_v110.pdf (cached version)
I only understand, a little bit, of pages 13-14.
There are rotary buttons, which probably preclude any upgrade working in my remotes, but I thought I ask anyway.
Liz
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
It looks like a custom protocol, so once you get some learns to confirm the structure, we can build an executor for it and the PDF that you found will make it easier to make sense of the learns and create an upgrade.
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
Thanks, Rob. Stick around please.
Pages 13 and 15 of the pdf describe encoding and decoding.
The earlier pages I think give command codes. Also about Toggle.
I looked in PB, for starters, but I don't think I will do it right.
It'll be after Christmas they'll let me play.
Pages 13 and 15 of the pdf describe encoding and decoding.
The earlier pages I think give command codes. Also about Toggle.
I looked in PB, for starters, but I don't think I will do it right.
It'll be after Christmas they'll let me play.
Liz
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
I'd rather base the build on learns than what someone wrote in a doc because the main problem with remote signals is terminology, as there really isn't a standard notation. And, I know how to read learned signals very well. But the doc will help explain everything that we see in the learns, so that will eliminate all the usual guesswork.
What you need to do is, as soon as the Legos arrive, before you wrap them up, grab the remote and capture the signals. Or, if you don't want to break the sealed packaging, as soon as it's out of the box grab the remote. I'll only need 1 or 2 signals that capture properly and work as I can base the rest of it on the doc.
What you need to do is, as soon as the Legos arrive, before you wrap them up, grab the remote and capture the signals. Or, if you don't want to break the sealed packaging, as soon as it's out of the box grab the remote. I'll only need 1 or 2 signals that capture properly and work as I can base the rest of it on the doc.
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Liz,
The link you have is to version 1.10. Here's a link to 1.20, which apparently has changes to the commands. Also, some LIRC files have been generated, so IrScrutinizer could probably provide you with some decodes.
I suspect that using a remote of the type we're used to will restrict you to transmitting on a single channel.
The link you have is to version 1.10. Here's a link to 1.20, which apparently has changes to the commands. Also, some LIRC files have been generated, so IrScrutinizer could probably provide you with some decodes.
I suspect that using a remote of the type we're used to will restrict you to transmitting on a single channel.
I managed to understand the document, and write an IRP description. Here is the main protocol in a for that IrScrutinizer will accept
This can just be appended to IrpProtocol.ini in IrScrutinizer, and it will generate the signals.
There are then four (in version 1.10 even more) "special cases". I have implemented those as inherited protocols. These are
Also these should be appended to IrpProtocols.ini.
Anyone up to writing an IRP -> PB translator?
The notation the author is using is in general not too hard to understand.
Edit: This is all untested, since I do not have the hardware. Please test and report.
Code: Select all
[protocol]
name=lego
irp={38k,1p,msb}<6,-10|6,-21>(6,-39,nibble_1:4,nibble_2:4,F:4,LRC:4,6,-39) \
{ nibble_1 = 8*T:1 | 4*E:1 | D:2, \
nibble_2 = 8*a:1 | mode:3, \
LRC = nibble_1 ^ nibble_2 ^ F:4, \
T = 1-T } \
[T@:0..1=0,a:0..1=0,E:0..1,D:0..3,mode:0..7,F:0..15]
[documentation]
Protocol for Lego remote control, see
http://storage.technicbricks.com/Media/2010/TBs_20100304_1/LEGO%20Power%20Functions%20RC%20v120.pdf. Also see https://www.hifi-remote.com/forums/viewtopic.php?t=16630.
For compatibility with other protocols, the data payload (nibble 3) is here called F, and the channel (CC) D.
There are then four (in version 1.10 even more) "special cases". I have implemented those as inherited protocols. These are
Code: Select all
[protocol]
name=lego-extended
irp=lego{E=0,mode=0}[a:0..1=0,T@:0..1=0,D:0..3,F:0..15]
[documentation]
See page 7 of http://storage.technicbricks.com/Media/2010/TBs_20100304_1/LEGO%20Power%20Functions%20RC%20v120.pdf
[protocol]
name=lego-combo-direct
irp=lego{E=0,mode=1}[a:0..1=0,T@:0..1=0,D:0..3,F:0..15]
[documentation]
See page 8 of http://storage.technicbricks.com/Media/2010/TBs_20100304_1/LEGO%20Power%20Functions%20RC%20v120.pdf
[protocol]
name=lego-single-output
irp=lego{E=0,mode=4*1:1 | 2*M:1}[a:0..1=0,T@:0..1=0,M:0..1=0,D:0..3,F:0..15]
[documentation]
See page 9 of http://storage.technicbricks.com/Media/2010/TBs_20100304_1/LEGO%20Power%20Functions%20RC%20v120.pdf
[protocol]
name=lego-combo-pwm
irp=lego{E=1,nibble_2=output_B}[a:0..1=0,T@:0..1=0,output_B:0..15=0,D:0..3,F:0..15]
[documentation]
See page 10 of http://storage.technicbricks.com/Media/2010/TBs_20100304_1/LEGO%20Power%20Functions%20RC%20v120.pdf. Note that there, a takes the place previously occupied by T. This appears to be a mistake.
Anyone up to writing an IRP -> PB translator?
Funny, for me it is exactly the other way aound...I'd rather base the build on learns than what someone wrote in a doc because the main problem with remote signals is terminology, as there really isn't a standard notation.
Edit: This is all untested, since I do not have the hardware. Please test and report.
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
I can't tell whether the signal is meant to repeat, but I have started the PB file:
https://www.hifi-remote.com/forums/dload ... e_id=13772
https://www.hifi-remote.com/forums/dload ... e_id=13772
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
Barf's .pdf link and amazing work made me look harder.
Remote has a hardly visible 2008 imprint, so I found this earlier .pdf
www.philohome.com/pf/LEGO_Power_Functions_RC.pdf
doesn't look much different than the other two, other than that single pin stuff.
Remote has a hardly visible 2008 imprint, so I found this earlier .pdf
www.philohome.com/pf/LEGO_Power_Functions_RC.pdf
doesn't look much different than the other two, other than that single pin stuff.
Liz
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
Ideally, I'd like an IR.exe file.ElizabethD wrote:Rob, do you want a .ict or .rtf files?
The learning is difficult, clear as mud to me at this point.
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
See picture in the zip file.
Remote controls 4 receivers - that's what the channel slider is for. Channel slider doesn't sent IR signal.
Each receiver controls 2 devices. That's what the wheels and brakes are for.
I recorded the signals for the brake functions on the outermost shell - channels 1-4. Will skip learning all channels later.
Short press seems to send few signals and stops transmitting after 5 blips independent if I hold the button or not.
So I recorded on 3 channels doing both tap then press and hold after stops transmitting, and holding also stops transmitting.
Let me know if it makes sense or if to learn another way.
zip file contains 8 short files and an annotated picture.
https://www.hifi-remote.com/forums/dload ... e_id=13773
I haven't yet figured out how best to learn the wheels. If I do step by step, each is identical to another (starts at zero always), so I probably need to do a quick sweep of a wheel.
So more to come. Comments welcome.
Edit:Rob, the .rtf files include Raw timing similar or identical to what I remember from IR. So maybe, just maybe, you'll be ok.
The reason for separate files is that since everything is GAP, I can't tell where one signal ends and another begins.
Remote controls 4 receivers - that's what the channel slider is for. Channel slider doesn't sent IR signal.
Each receiver controls 2 devices. That's what the wheels and brakes are for.
I recorded the signals for the brake functions on the outermost shell - channels 1-4. Will skip learning all channels later.
Short press seems to send few signals and stops transmitting after 5 blips independent if I hold the button or not.
So I recorded on 3 channels doing both tap then press and hold after stops transmitting, and holding also stops transmitting.
Let me know if it makes sense or if to learn another way.
zip file contains 8 short files and an annotated picture.
https://www.hifi-remote.com/forums/dload ... e_id=13773
I haven't yet figured out how best to learn the wheels. If I do step by step, each is identical to another (starts at zero always), so I probably need to do a quick sweep of a wheel.
So more to come. Comments welcome.
Edit:Rob, the .rtf files include Raw timing similar or identical to what I remember from IR. So maybe, just maybe, you'll be ok.
The reason for separate files is that since everything is GAP, I can't tell where one signal ends and another begins.
Liz
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
Tweeking 8910, HTPro/9811, C7-7800, 6131o, 6131n, AtlasOCAP-1056B01, RCA-RCRP05B and enjoying the ride
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
How did you create the rtf files? They look like they're just cut & pasted from IR or RMIR
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
-
ElizabethD
- Advanced Member
- Posts: 2348
- Joined: Mon Feb 09, 2004 12:07 pm
-
The Robman
- Site Owner
- Posts: 21985
- Joined: Fri Aug 01, 2003 9:37 am
- Location: Chicago, IL
- Contact:
I'm guessing you don't have a learning remote, right? IR.exe is the only one of the tools that has some good tools for messing with learned signals. But I can use these too, it's just gonna take a bit longer.
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!