| 
| #define  | l3gd20GyroscopeGetAxesNumber(devp)   gyroscopeGetAxesNumber(&((devp)->gyro_if)) | 
|   | Return the number of axes of the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeReadRaw(devp,  axes)   gyroscopeReadRaw(&((devp)->gyro_if), axes) | 
|   | Retrieves raw data from the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeReadCooked(devp,  axes)   gyroscopeReadCooked(&((devp)->gyro_if), axes) | 
|   | Retrieves cooked data from the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeSampleBias(devp)   gyroscopeSampleBias(&((devp)->gyro_if)) | 
|   | Samples bias values for the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeSetBias(devp,  bp)   gyroscopeSetBias(&((devp)->gyro_if), bp) | 
|   | Set bias values for the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeResetBias(devp)   gyroscopeResetBias(&((devp)->gyro_if)) | 
|   | Reset bias values for the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeSetSensitivity(devp,  sp)   gyroscopeSetSensitivity(&((devp)->gyro_if), sp) | 
|   | Set sensitivity values for the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeResetSensitivity(devp)   gyroscopeResetSensitivity(&((devp)->gyro_if)) | 
|   | Reset sensitivity values for the BaseGyroscope.  More...
  | 
|   | 
| #define  | l3gd20GyroscopeSetFullScale(devp,  fs)   (devp)->vmt->acc_set_full_scale(devp, fs) | 
|   | Changes the L3GD20Driver gyroscope fullscale value.  More...
  | 
|   | 
 | 
| 
#define  | L3GD20_AD_WHO_AM_I   0x0F | 
|   | 
| 
#define  | L3GD20_AD_CTRL_REG1   0x20 | 
|   | 
| 
#define  | L3GD20_AD_CTRL_REG2   0x21 | 
|   | 
| 
#define  | L3GD20_AD_CTRL_REG3   0x22 | 
|   | 
| 
#define  | L3GD20_AD_CTRL_REG4   0x23 | 
|   | 
| 
#define  | L3GD20_AD_CTRL_REG5   0x24 | 
|   | 
| 
#define  | L3GD20_AD_REFERENCE   0x25 | 
|   | 
| 
#define  | L3GD20_AD_OUT_TEMP   0x26 | 
|   | 
| 
#define  | L3GD20_AD_STATUS_REG   0x27 | 
|   | 
| 
#define  | L3GD20_AD_OUT_X_L   0x28 | 
|   | 
| 
#define  | L3GD20_AD_OUT_X_H   0x29 | 
|   | 
| 
#define  | L3GD20_AD_OUT_Y_L   0x2A | 
|   | 
| 
#define  | L3GD20_AD_OUT_Y_H   0x2B | 
|   | 
| 
#define  | L3GD20_AD_OUT_Z_L   0x2C | 
|   | 
| 
#define  | L3GD20_AD_OUT_Z_H   0x2D | 
|   | 
| 
#define  | L3GD20_AD_FIFO_CTRL_REG   0x2E | 
|   | 
| 
#define  | L3GD20_AD_FIFO_SRC_REG   0x2F | 
|   | 
| 
#define  | L3GD20_AD_INT1_CFG   0x30 | 
|   | 
| 
#define  | L3GD20_AD_INT1_SRC   0x31 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_XH   0x32 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_XL   0x33 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_YH   0x34 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_YL   0x35 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_ZH   0x36 | 
|   | 
| 
#define  | L3GD20_AD_INT1_THS_ZL   0x37 | 
|   | 
| 
#define  | L3GD20_AD_INT1_DURATION   0x38 | 
|   | 
 | 
| 
#define  | L3GD20_CTRL_REG1_MASK   0xFF | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_XEN   (1 << 0) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_YEN   (1 << 1) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_ZEN   (1 << 2) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_PD   (1 << 3) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_BW0   (1 << 4) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_BW1   (1 << 5) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_DR0   (1 << 6) | 
|   | 
| 
#define  | L3GD20_CTRL_REG1_DR1   (1 << 7) | 
|   | 
 | 
| 
#define  | L3GD20_CTRL_REG3_MASK   0xFF | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I2_EMPTY   (1 << 0) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I2_ORUN   (1 << 1) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I2_WTM   (1 << 2) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I2_DRDY   (1 << 3) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_PP_OD   (1 << 4) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_H_LACTIVE   (1 << 5) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I1_BOOT   (1 << 6) | 
|   | 
| 
#define  | L3GD20_CTRL_REG3_I1_INT1   (1 << 7) | 
|   | 
 | 
| 
#define  | L3GD20_INT1_CFG_MASK   0xFF | 
|   | 
| 
#define  | L3GD20_INT1_CFG_XLIE   (1 << 0) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_XHIE   (1 << 1) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_YLIE   (1 << 2) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_YHIE   (1 << 3) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_ZLIE   (1 << 4) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_ZHIE   (1 << 5) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_LIR   (1 << 6) | 
|   | 
| 
#define  | L3GD20_INT1_CFG_AND_OR   (1 << 7) | 
|   | 
 | 
| static void  | l3gd20SPIReadRegister (SPIDriver *spip, uint8_t reg, size_t n, uint8_t *b) | 
|   | Reads a generic register value using SPI.  More...
  | 
|   | 
| static void  | l3gd20SPIWriteRegister (SPIDriver *spip, uint8_t reg, size_t n, uint8_t *b) | 
|   | Writes a value into a generic register using SPI.  More...
  | 
|   | 
| static size_t  | gyro_get_axes_number (void *ip) | 
|   | Return the number of axes of the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_read_raw (void *ip, int32_t axes[L3GD20_GYRO_NUMBER_OF_AXES]) | 
|   | Retrieves raw data from the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_read_cooked (void *ip, float axes[]) | 
|   | Retrieves cooked data from the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_sample_bias (void *ip) | 
|   | Samples bias values for the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_set_bias (void *ip, float *bp) | 
|   | Set bias values for the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_reset_bias (void *ip) | 
|   | Reset bias values for the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_set_sensivity (void *ip, float *sp) | 
|   | Set sensitivity values for the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_reset_sensivity (void *ip) | 
|   | Reset sensitivity values for the BaseGyroscope.  More...
  | 
|   | 
| static msg_t  | gyro_set_full_scale (L3GD20Driver *devp, l3gd20_fs_t fs) | 
|   | Changes the L3GD20Driver gyroscope fullscale value.  More...
  | 
|   | 
| void  | l3gd20ObjectInit (L3GD20Driver *devp) | 
|   | Initializes an instance.  More...
  | 
|   | 
| void  | l3gd20Start (L3GD20Driver *devp, const L3GD20Config *config) | 
|   | Configures and activates L3GD20 Complex Driver peripheral.  More...
  | 
|   | 
| void  | l3gd20Stop (L3GD20Driver *devp) | 
|   | Deactivates the L3GD20 Complex Driver peripheral.  More...
  | 
|   | 
  
  
      
        
          | static msg_t gyro_read_raw  | 
          ( | 
          void *  | 
          ip,  | 
         
        
           | 
           | 
          int32_t  | 
          axes[L3GD20_GYRO_NUMBER_OF_AXES]  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
Retrieves raw data from the BaseGyroscope. 
- Note
 - This data is retrieved from MEMS register without any algebraical manipulation. 
 
- 
The axes array must be at least the same size of the BaseGyroscope axes number.
 
- Parameters
 - 
  
    | [in] | ip | pointer to BaseGyroscope interface.  | 
    | [out] | axes | a buffer which would be filled with raw data. | 
  
   
- Returns
 - The operation status. 
 
- Return values
 - 
  
    | MSG_OK | if the function succeeded.  | 
  
   
Definition at line 115 of file l3gd20.c.
References L3GD20_GYRO_NUMBER_OF_AXES, L3GD20_READY, l3gd20SPIReadRegister(), MSG_OK, objGetInstance, osalDbgAssert, osalDbgCheck, SPI_READY, spiAcquireBus(), spiReleaseBus(), and spiStart().
Referenced by gyro_read_cooked(), gyro_sample_bias(), and gyro_set_full_scale().
 
 
  
  
      
        
          | static msg_t gyro_sample_bias  | 
          ( | 
          void *  | 
          ip | ) | 
           | 
         
       
   | 
  
static   | 
  
 
Samples bias values for the BaseGyroscope. 
- Note
 - The L3GD20 shall not be moved during the whole procedure. 
 
- 
After this function internal bias is automatically updated. 
 
- 
The behavior of this function depends on 
L3GD20_BIAS_ACQ_TIMES and L3GD20_BIAS_SETTLING_US. 
- Parameters
 - 
  
  
 
- Returns
 - The operation status. 
 
- Return values
 - 
  
    | MSG_OK | if the function succeeded.  | 
  
   
Definition at line 200 of file l3gd20.c.
References gyro_read_raw(), L3GD20_BIAS_ACQ_TIMES, L3GD20_BIAS_SETTLING_US, L3GD20_GYRO_NUMBER_OF_AXES, L3GD20_READY, MSG_OK, objGetInstance, osalDbgAssert, osalDbgCheck, osalThreadSleepMicroseconds, and SPI_READY.
Referenced by gyro_set_full_scale().
 
 
Changes the L3GD20Driver gyroscope fullscale value. 
- Note
 - This function also rescale sensitivities and biases based on previous and next fullscale value. 
 
- 
A recalibration is highly suggested after calling this function.
 
- Parameters
 - 
  
    | [in] | devp | pointer to BaseGyroscope interface.  | 
    | [in] | fs | new fullscale value. | 
  
   
- Returns
 - The operation status. 
 
- Return values
 - 
  
    | MSG_OK | if the function succeeded.  | 
    | MSG_RESET | otherwise.  | 
  
   
Definition at line 378 of file l3gd20.c.
References gyro_get_axes_number(), gyro_read_cooked(), gyro_read_raw(), gyro_reset_bias(), gyro_reset_sensivity(), gyro_sample_bias(), gyro_set_bias(), gyro_set_sensivity(), L3GD20_FS_2000DPS, L3GD20_FS_250DPS, L3GD20_FS_500DPS, L3GD20_GYRO_NUMBER_OF_AXES, L3GD20_READY, l3gd20SPIReadRegister(), l3gd20SPIWriteRegister(), MSG_OK, MSG_RESET, osalDbgAssert, osalDbgCheck, SPI_READY, spiAcquireBus(), spiReleaseBus(), and spiStart().