Project

General

Profile

Revision 1280

Implemented ibom_set and ibom_read functions.

View differences:

hardware_ibom.c
10 10
	if (on)
11 11
	{
12 12
		usb_puts ("# Turning IBOM light on" NL);
13
		// FIXME implement
13
		digital_output(IBOM_EMITTER_PIN, 1);
14 14
	}
15 15
	else
16 16
	{
17 17
		usb_puts ("# Turning IBOM light off" NL);
18
		// FIXME implement
18
		digital_output(IBOM_EMITTER_PIN, 0);
19 19
	}
20 20
}
21 21

  
22 22
void ibom_read (uint16_t *top, uint16_t *left, uint16_t *right)
23 23
{
24
	// FIXME implement
25
	
26
	*top=0;
27
	*left=0;
28
	*right=0;
24
	*top	=analog10(IBOM_SENSOR_TOP);
25
	*left	=analog10(IBOM_SENSOR_LEFT);
26
	*right	=analog10(IBOM_SENSOR_RIGHT);
29 27
}
30 28

  
31 29
void ibom_update (void)

Also available in: Unified diff