To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.nqcOpen lugnet.robotics.rcx.nqc in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / NQC / 149
148  |  150
Subject: 
[OT] Decoding the LEGO remote control
Newsgroups: 
lugnet.robotics.rcx.nqc
Date: 
Sat, 18 Sep 1999 20:23:40 GMT
Viewed: 
2386 times
  
Hi All - -

A couple of weeks ago I received my LEGO MindStorms #9738 remote
control.  It's really cool to be able to select, start, and stop
programs ... override the motor controls ... send messages, etc.
If fact, it's SO COOL that I want to be able to use the same LEGO
controller to control my other 'bots ... but they are somewhat
retarded (they don't have RCX brains) and don't understand the
IR remote's commands.

I thought that it would be fairly easy to use a GP1U581Y, IS1U60,
or LTM-97DS-38 IR receiver to demodulate the IR signal and a PIC
to decode the commands.  In my naivete I assumed that the remote
used a straight forward modulation/encoding scheme of 7 or 8 bit
ASCII characters turning the 38kHz IR light on & off just like a
standard RS-232 serial connection ... and all I would have to do
would be to find out what codes represented what commands.  Little
did I know that there are at least a zillion IR encoding protocols.

Dave Baum posted the remote's encoding:

The remote control always sends the same sort of packet:

d2 xx yy

where xxyy is a sixteen bit bit-field indicating what features should be
activated:

xxyy
0001 Message 1
0002 Message 2
0004 Message 3
0008 Motor A Forward
0010 Motor B Forward
0020 Motor C Forward
0040 Motor A Backward
0080 Motor B Backward
0100 Motor C Backward
0200 Run Program 1
0400 Run Program 2
0800 Run Program 3
1000 Run Program 4
2000 Run Program 5
4000 Stop Program
8000 Beep

But I don't have clue as to how it is encoded on the IR beam.  When I
look at the demodulated output, I'm not smart enough to figure out their
encoding protocol ... even knowing what the encoded data should be!

Is there an IR communication expert here that can possibly give me some
much needed guidance?  I want to use the demodulated IR receiver output
as an input to a PIC ... have the PIC decode the bitstream and output a
hex code to represent the received command.  I do NOT want to use a LEGO
tower to do the reception/conversion.

Thanks,
- Nick -



1 Message in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR