Paparazzi UAS  v5.10_stable-5-g83a0da5-dirty
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
l3gd20_regs.h
Go to the documentation of this file.
1 /*
2  * Copyright (C)2014 Federico Ruiz Ugalde
3  *
4  * This file is part of paparazzi.
5  *
6  * paparazzi is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2, or (at your option)
9  * any later version.
10  *
11  * paparazzi is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with paparazzi; see the file COPYING. If not, write to
18  * the Free Software Foundation, 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21 
28 #ifndef L3GD20_REGS_H
29 #define L3GD20_REGS_H
30 
31 /* Registers */
32 #define L3GD20_REG_WHO_AM_I 0x0F
33 #define L3GD20_REG_CTRL_REG1 0x20
34 #define L3GD20_REG_CTRL_REG2 0x21
35 #define L3GD20_REG_CTRL_REG3 0x22
36 #define L3GD20_REG_CTRL_REG4 0x23
37 #define L3GD20_REG_STATUS_REG 0x27
38 #define L3GD20_REG_OUT_X_L 0x28
39 #define L3GD20_REG_OUT_X_H 0x29
40 #define L3GD20_REG_OUT_Y_L 0x2A
41 #define L3GD20_REG_OUT_Y_H 0x2B
42 #define L3GD20_REG_OUT_Z_L 0x2C
43 #define L3GD20_REG_OUT_Z_H 0x2D
44 
46 #define L3GD20_WHO_AM_I 0xD4
47 
48 #define L3GD20_DR_MASK 0xC0
49 #define L3GD20_BW_MASK 0x30
50 
51 
52 #define L3GD20_PD (1 << 3)
53 #define L3GD20_Xen (1 << 0)
54 #define L3GD20_Yen (1 << 1)
55 #define L3GD20_Zen (1 << 2)
56 
57 #define L3GD20_FS_MASK 0x30
58 #define L3GD20_BDU (1 << 7)
59 
60 enum L3gd20DRBW {
77 };
78 
83  L3GD20_FS_2000dps2 = 3, //yep, the same as L3GD20_FS_2000dps
84 };
85 
86 
87 #endif /* L3GD20_REGS_H */
L3gd20DRBW
Definition: l3gd20_regs.h:60
L3gd20FullScale
Definition: l3gd20_regs.h:79