Presentation is loading. Please wait.

Presentation is loading. Please wait.

ROBOLAB programming RCX to RCX communication Betsy Natter UNST 161 Winter 2004.

Similar presentations


Presentation on theme: "ROBOLAB programming RCX to RCX communication Betsy Natter UNST 161 Winter 2004."— Presentation transcript:

1 ROBOLAB programming RCX to RCX communication Betsy Natter UNST 161 Winter 2004

2 RCX Communication Badge See 4-27 Can send messages (“mail”) between two or more RCXs. Mail is any integer between 0 and 255. Sent and received over IR port. Cannot send and receive at the same time (like a walkie-talkie).

3 Send mail and fill mail functions on RCS Communication sub-menu. –You don’t have to wait for mail to receive it. Wait for mail function zeros the mailbox and waits to receive mail before proceeding. Mailbox holds only one integer.

4 Can work with mail like other numbers. –Mail containers can store values (so incoming mail won’t delete the previous message.) –Mail forks, mail loops, and mail events can be used to trigger actions depending on the mail received. e.g. can loop until the mail reaches a certain value. See 4-29 for “handshaking” protocol to ensure RCX’s are communicating. –e.g. can send mail for 1 second, then receive for 1 second. –Don’t do send mail and wait for mail in different tasks. That can create a hardware conflict where the send mail will always take priority.


Download ppt "ROBOLAB programming RCX to RCX communication Betsy Natter UNST 161 Winter 2004."

Similar presentations


Ads by Google