hi im having difficulties using color sensor heres what i have in mind
Code:
if (SensorValue[S1]==REDCOLOR) { motor[Left]=0; motor[Right]=100; }
is this even right? im making a line tracer robot that detects red line. thanks in advance
Mon Mar 11, 2013 7:40 am
NeXT-Generation
Senior Roboticist
Joined: Wed Sep 28, 2011 10:13 pm Posts: 510 Location: Totally not spying on Hassenplug to see what he has for the Brickworld Chicago 2013 sumo contest.
Re: color sensor need help!
Yes that should be right. Is it not working? Have you defined S1 as the LEGO Color Sensor? Could you please post the whole program, and maybe describe what your doing, and what exactly isn't working in more detail?
_________________ A.K.A. inxt-generation Self-proclaimed genius, and future world dominator. My Brickshelf Folder "Don't they teach recreational mathematics anymore?" - The Tenth Doctor Bow down to Nikola Tesla, King of the Geek Gods.
Mon Mar 11, 2013 10:25 am
ernestclyde
Rookie
Joined: Mon Mar 11, 2013 7:34 am Posts: 2
Re: color sensor need help!
oh i figure it out, thanks for the reply silly me, im using old version which causes compiling error
Users browsing this forum: No registered users and 5 guests
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum