Line -... |
Line 1... |
- |
|
1 |
// i2c slave addresses |
1 |
#define MAG_ADDR_R 0x3D //addresa pro cteni |
2 |
#define HMC5883L_WRT_ADDR 0x3C |
2 |
#define MAG_ADDR_W 0x3C |
3 |
#define HMC5883L_READ_ADDR 0x3D |
3 |
|
4 |
|
- |
|
5 |
// Register addresses |
- |
|
6 |
#define HMC5883L_CFG_A_REG 0x00 |
- |
|
7 |
#define HMC5883L_CFG_B_REG 0x01 |
- |
|
8 |
#define HMC5883L_MODE_REG 0x02 |
- |
|
9 |
#define HMC5883L_X_MSB_REG 0x03 |
4 |
|
10 |
|
5 |
//Konstanty nastavujici rozsah |
11 |
//Konstanty nastavujici rozsah |
6 |
//pro void set_mag_roz (unsigned int8 h) |
12 |
//pro void set_mag_roz (unsigned int8 h) |
7 |
#define MAG_ROZ088 0x00 |
13 |
#define MAG_ROZ088 0x00 |
8 |
#define MAG_ROZ130 0x20 |
14 |
#define MAG_ROZ130 0x20 |