5 #include <util/delay.h> 8 #define WHO_AM_I 0b10001101 9 #define AM_TEMP 0b11010001 11 #define ACCEL_OUT_X_H 0b10000001 12 #define ACCEL_OUT_X_L 0b10000010 13 #define ACCEL_OUT_Y_H 0b10000011 14 #define ACCEL_OUT_Y_L 0b10000100 15 #define ACCEL_OUT_Z_H 0b10000101 16 #define ACCEL_OUT_Z_L 0b10000110 18 #define XYZ_DATA_CFG 0b00001110 20 #define MAG_OUT_X_H 0b10110011 21 #define MAG_OUT_X_L 0b10110100 22 #define MAG_OUT_Y_H 0b10110101 23 #define MAG_OUT_Y_L 0b10110110 24 #define MAG_OUT_Z_H 0b10110111 25 #define MAG_OUT_Z_L 0b10111000 27 #define ACCEL_SENSITIVITY 1024 // 8g - LSB/g 28 #define MAG_SENSITIVITTY 0.1 // μT/LSB 30 unsigned char accel_x_high, accel_y_high, accel_z_high;
31 unsigned char accel_x_low, accel_y_low, accel_z_low;
33 unsigned char mag_x_high, mag_y_high, mag_z_high;
34 unsigned char mag_x_low, mag_y_low, mag_z_low;
36 volatile short raw_accel_x, raw_accel_y, raw_accel_z;
37 volatile short raw_mag_x, raw_mag_y, raw_mag_z;
39 unsigned char who_am_i;
40 volatile short raw_temp;
41 volatile float celsius;
47 #endif // FXOS8700CQ_H void getAccelMagTemp(void)
Definition: fxos8700cq.c:97
void getMagData(void)
Definition: fxos8700cq.c:64
void setupFXOS8700CQ(void)
Definition: fxos8700cq.c:9
void getAccelData(void)
Definition: fxos8700cq.c:33