Infrared Communication



What is IR?

Infrared (IR) is a type of light that is not visible to the human eye. The following are both good introductions to IR:

How can you use IR to communicate?

Put very simply, a transmitter produces rapid pulses of IR light in specific patterns, which a receiver can interpret. You most likely use IR for communication on a daily basis: that's how television remotes work!

How does the RCX use IR?

The IR port on the RCX is the shiny black bit above the numbered input ports. Primarily, you use this port to download new programs to the RCX (through the IR tower that plugs into your computer). However, the port can also send messages out.

The RCX sends IR messages in "packets." Each packet consists of a specific "header" followed by the "payload" or actual data. The packet ends with a checksum, which is a method of verifying that the data was read correctly. The header is there so that the RCX knows where the packet starts. When you send a message from one RCX to another, the payload is two bytes long: the first just indicates that the second byte is a message (as opposed to code to download, for example -- the same packet form is used by the IR tower!). So when you want to send messages between two RCX bricks, you can only send one byte at a time. (What is a byte?) If you are interested in specifics pertaining to the RCX, check out Stef Mientki's page on Mindstorms IR-communication.

What are some problems with IR communication?

IR is a fairly cheap and easy way for two things to communicate. However, it does have a number of problems, including:



Home


LEGO, LEGO Mindstorms, Robotics Invention System, and RCX are registered trademarks of the LEGO Group, Inc.

This project is funded by Carnegie Mellon's Undergraduate Research Initiative. These results represent the views of the author and not those of Carnegie Mellon University.


All material contained within this site is
© 2003 Rachel Gockley
except where otherwise noted.