Project

General

Profile

Revision 580

Updated bom.c and bom.h to implement James' changes for BOM1.5

View differences:

bom.h
42 42
 * @addtogroup bom
43 43
 * @{
44 44
 **/
45
/** @brief Initializes a BOM v1.5 **/
46
void bom_15_init(void);
47
/** @brief Sets the mode of a BOM v1.5**/
48
void bom_RSSI_mode(void);
49
/** @brief Sets the mode of a BOM v1.5**/
50
void bom_normal_mode(void);
51
/** @brief Sets the emmitter pattern a BOM v1.5**/
52
void bom_set_emitters(int pattern);
53
/** @brief Returns the location of the maximum BOM reading. **/
54
int get_max_bom( void );
55
/** @brief Turns the BOM on. **/
45
 
46
/** @brief Include all elements in the 16-bit bitfield **/
47
#define BOM_ALL 0xFFFF
48
/** @brief Original BOM - No Range, No Individual LED control **/
49
#define BOM     0
50
/** @brief BOM 1.5 - No Range, Individual LED control **/
51
#define BOM15   1
52
/** @brief RBOM - Range, Individual LED control **/
53
#define RBOM    2
54
 
55
/** @brief Initialize the bom according to bom type **/
56
void bom_init(char type);
57
/** @brief Refresh bom_val[] with new values from analog8.  analog_init and bom_init must be called for this to work. **/
58
void bom_refresh(int bit_field);
59
/** @brief Gets the bom reading from bom_val[which].  Call bom_refresh beforehand to read new bom values. **/
60
int bom_get(int which);
61
/** @brief Compares all the values in bom_val[] and returns the index to the highest value element. **/
62
int bom_get_max(void);
63
/** @brief Turns on the selected bom leds. Only works with BOM_ALL if using the original bom. **/
64
void bom_leds_on(int bit_field);
65
/** @brief Turns off the selected bom leds. Only works with BOM_ALL if using the original bom. **/
66
void bom_leds_off(int bit_field);
67

  
68
/** @brief (DEPRECATED) Gets and compares all bom values.  Returns the index to the highest value element. **/
69
int get_max_bom(void);
70
/** @brief (DEPRECATED) Turns on all bom leds. **/
56 71
void bom_on(void);
57
/** @brief Turns the BOM off. **/
72
/** @brief (DEPRECATED) Turns off all bom leds. **/
58 73
void bom_off(void);
59 74

  
60 75
/** @} **/

Also available in: Unified diff