STILL DEBUGGING
Dependencies: ST_INTERFACES X_NUCLEO_COMMON
Fork of X_NUCLEO_IKS01A1 by
Diff: x_nucleo_iks01a1.cpp
- Revision:
- 92:d1c67d482bad
- Parent:
- 73:e5b028bdd350
--- a/x_nucleo_iks01a1.cpp Thu Mar 23 13:05:15 2017 +0000 +++ b/x_nucleo_iks01a1.cpp Fri Mar 24 10:57:29 2017 +0100 @@ -144,7 +144,7 @@ HUM_TEMP_InitTypeDef InitStructure; /* Check presence */ - if((ht_sensor->ReadID(&ht_id) != HUM_TEMP_OK) || + if((ht_sensor->read_id(&ht_id) != HUM_TEMP_OK) || (ht_id != I_AM_HTS221)) { delete ht_sensor; @@ -155,7 +155,7 @@ /* Configure sensor */ InitStructure.OutputDataRate = HTS221_ODR_12_5Hz; - if(ht_sensor->Init(&InitStructure) != HUM_TEMP_OK) + if(ht_sensor->init(&InitStructure) != HUM_TEMP_OK) { return false; } @@ -173,7 +173,7 @@ MAGNETO_InitTypeDef InitStructure; /* Check presence */ - if((magnetometer->ReadID(&m_id) != MAGNETO_OK) || + if((magnetometer->read_id(&m_id) != MAGNETO_OK) || (m_id != I_AM_LIS3MDL_M)) { delete magnetometer; @@ -187,7 +187,7 @@ InitStructure.M_XYOperativeMode = LIS3MDL_M_OM_HP; InitStructure.M_OutputDataRate = LIS3MDL_M_DO_80; - if(magnetometer->Init(&InitStructure) != MAGNETO_OK) + if(magnetometer->init(&InitStructure) != MAGNETO_OK) { return false; } @@ -205,7 +205,7 @@ PRESSURE_InitTypeDef InitStructure; /* Check presence */ - if((pt_sensor->ReadID(&p_id) != PRESSURE_OK) || + if((pt_sensor->read_id(&p_id) != PRESSURE_OK) || (p_id != I_AM_LPS25H)) { delete pt_sensor; @@ -221,7 +221,7 @@ InitStructure.PressureResolution = LPS25H_P_RES_AVG_32; InitStructure.TemperatureResolution = LPS25H_T_RES_AVG_16; - if(pt_sensor->Init(&InitStructure) != PRESSURE_OK) + if(pt_sensor->init(&InitStructure) != PRESSURE_OK) { return false; } @@ -240,7 +240,7 @@ /* Check presence */ if((gyro_lsm6ds3 != NULL) || // by default do not instantiate two gyroscopes - (gyro_lsm6ds0->ReadID(&xg_id) != IMU_6AXES_OK) || + (gyro_lsm6ds0->read_id(&xg_id) != IMU_6AXES_OK) || (xg_id != I_AM_LSM6DS0_XG)) { delete gyro_lsm6ds0; @@ -261,7 +261,7 @@ InitStructure.X_Y_Axis = 1; /* Enable */ InitStructure.X_Z_Axis = 1; /* Enable */ - if(gyro_lsm6ds0->Init(&InitStructure) != IMU_6AXES_OK) + if(gyro_lsm6ds0->init(&InitStructure) != IMU_6AXES_OK) { return false; } @@ -281,7 +281,7 @@ /* Check presence */ if(gyro_lsm6ds3 == NULL) return true; - if((gyro_lsm6ds3->ReadID(&xg_id) != IMU_6AXES_OK) || + if((gyro_lsm6ds3->read_id(&xg_id) != IMU_6AXES_OK) || (xg_id != I_AM_LSM6DS3_XG)) { delete gyro_lsm6ds3; @@ -302,7 +302,7 @@ InitStructure.X_Y_Axis = 1; /* Enable */ InitStructure.X_Z_Axis = 1; /* Enable */ - if(gyro_lsm6ds3->Init(&InitStructure) != IMU_6AXES_OK) + if(gyro_lsm6ds3->init(&InitStructure) != IMU_6AXES_OK) { return false; }