Search found 4 matches

by okami-ninja
24 Nov 2011, 14:10
Forum: Mindstorms Projects
Topic: Help with a line following program
Replies: 5
Views: 8596

Re: Help with a line following program

Sorry, I didn't realise you could do that. Thanks
by okami-ninja
23 Nov 2011, 14:38
Forum: Mindstorms Projects
Topic: Help with a line following program
Replies: 5
Views: 8596

Re: Help with a line following program

I've just finished writing a different version that uses 2 variables to compare the light in different places. Here's the code for the new one #define Threshold 50 //defines variables for sound and light #define SOUND_THRESHOLD 75 #define MIC SENSOR_2 int normSpeed = 45; //defines the different spee...
by okami-ninja
23 Nov 2011, 14:03
Forum: Mindstorms Projects
Topic: Help with a line following program
Replies: 5
Views: 8596

Re: Help with a line following program

I'm using bricx cc. Here's the code: #define Threshold 50 //define all thresholds and constants here long maxTurn = 1300; #define SOUND_THRESHOLD 75 #define MIC SENSOR_2 task main() { long t0, time; t0 = CurrentTick(); SetSensorLight(IN_3); SetSensorType(IN_3, SENSOR_TYPE_LIGHT_ACTIVE);//turns senso...
by okami-ninja
22 Nov 2011, 14:44
Forum: Mindstorms Projects
Topic: Help with a line following program
Replies: 5
Views: 8596

Help with a line following program

Hi I'm new to programming and lego mindstorms. I'm trying to write a program to make the robot move forward until it touches the line and then based on the angle it's touched it at position itself to follow the line. Then it stops until it here's a clap and then follows the line until there's anothe...