Revision 1951 trunk/code/projects/linefollowing/lineFollow.c

View differences:

lineFollow.c
15 15

  
16 16
//! The number of bits expected in a barcode
17 17
#define CODESIZE 5 
18
#define LINE_COLOR 200
18 19

  
20

  
19 21
int countHi = 0;
20 22
int countLo = 0;
21 23
int maxAvg, avg;
......
256 258
void updateLine(int* values)
257 259
{	
258 260
	for(int i = 0; i<5; i++)
259
		values[i] = (read_line(4-i) < 150 ? LWHITE : LBLACK);
261
		values[i] = (read_line(4-i) < LINE_COLOR ? LWHITE : LBLACK);
260 262
}
261 263

  
262 264

  

Also available in: Unified diff