lego programming

hey, kinda new to lego robotics programming here. I have a competition coming up where we have to make robots that combat one another in an obstacle course. I was wondering if anyone knew any commands that would disable a robot through infrared signals.

Thanks.

Wow you should check with your competition rules to see if that is allowed. I know Botball and FLL strictly prohibit it, but maybe your competition is a free for all.

Even if it was legal, I doubt that you could get either the RCX or the Scout to send the command you need, the Stop command. It comes from the remote that you can buy for the RCX and is just like pressing the Run button after the program has been started, it stops the program. Also, from this remote, you can start any program on the robot (1-5) and make it play a test tone. Good luck.

It is possible to do what you want, but you have to go very advanced.

To have direct access to the IR port, you have to use an alternate firmware, such as BrickOS or http://lejos.sourceforge.net/]LeJOS. Installation of either of these (especially BrickOS) is extremely difficult on Windows systems. I’ve never used either on Linux, but the installation should be (in theory), slightly easier.

BrickOS allows you to program the robot in C or C++, while LeJOS uses Java.

–EDIT–
As warned above, check the legality of sending shutdown commands to the RCX. Also, check if alternate firmware is allowed.

Yes, I have done just this.

You must use lejOS running some other software package (i used java). You then set up a command which sends out a fury of commands, (such as stop, reverse, etc). The only downfall of this is the limited range of the IR transmitter on the RCX.

It’s definitely worth playing with!

thanks a lot for the help. I might try playing around with that. I’m doing a combat obstacle course. It’s pretty much a free-for-all. I think there is a simpler way in this case though. the other robots have to be programmed to recieve a remote signal “message() ==1” to shut them down temporarily so if they don’t immediately disable their IR imput I’ll be able to broadcast this message and shut them down.

I will try some of the more complicated stuff you talked about though. Thanks a lot!

One more question:

I’m programming in NQC with Bricx Command Center. Can i broadcast the right signals using this language/compiler?

Otherwise I know the java language and I’ll probably try leJOS.

thanks

I don’t think so, but I could be wrong. You could send the IR message 1, of course.

we had alot of fun with this…

off.JPG


off.JPG