Rev 591 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
253 | killagreg | 1 | #ifndef __NCMAG_H |
2 | #define __NCMAG_H |
||
242 | killagreg | 3 | |
253 | killagreg | 4 | #include "compass.h" |
489 | killagreg | 5 | #include "i2c.h" |
253 | killagreg | 6 | |
489 | killagreg | 7 | #define NCMAG_PORT_EXTERN I2C0 |
8 | #define NCMAG_PORT_INTERN I2C1 |
||
243 | killagreg | 9 | |
584 | holgerb | 10 | // supported magnetic sensor types |
11 | #define TYPE_NONE 0 |
||
12 | #define TYPE_HMC5843 1 |
||
13 | #define TYPE_LSM303DLH 2 |
||
14 | #define TYPE_LSM303DLM 3 |
||
591 | holgerb | 15 | #define TYPE_LSM303D 4 |
584 | holgerb | 16 | |
426 | holgerb | 17 | extern u8 NCMAG_Present; |
18 | extern u8 NCMAG_IsCalibrated; |
||
489 | killagreg | 19 | extern u8 NCMAG_Orientation; |
584 | holgerb | 20 | extern u8 NCMAG_SensorType; |
242 | killagreg | 21 | |
489 | killagreg | 22 | u8 NCMAG_Init(void); |
23 | void NCMAG_Update(u8 init); |
||
24 | u8 NCMAG_GetOrientationFromAcc(void); |
||
25 | void NCMAG_CheckOrientation(void); |
||
473 | holgerb | 26 | |
253 | killagreg | 27 | #endif // __NCMAG_H |
242 | killagreg | 28 |