Updated LPS22HB demos in testex demos to be close to the pattern used in testhal demos.

git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@15443 27425a3e-05d8-49a3-a47f-9c15f0e5edd8
This commit is contained in:
Rocco Marco Guglielmi 2022-02-08 08:08:11 +00:00
parent 184deb923d
commit 12217c049f
2 changed files with 38 additions and 39 deletions

View File

@ -65,16 +65,15 @@ static const HTS221Config hts221cfg = {
static LPS22HBDriver LPS22HBD1; static LPS22HBDriver LPS22HBD1;
static const LPS22HBConfig lps22hbcfg = { static const LPS22HBConfig lps22hbcfg = {
&I2CD1, .i2cp = &I2CD1,
&i2ccfg, .i2ccfg = &i2ccfg,
LPS22HB_SAD_VCC, .slaveaddress = LPS22HB_SAD_VCC,
NULL, .barosensitivity = NULL,
NULL, .barobias = NULL,
NULL, .thermosensitivity = NULL,
NULL, .thermobias = NULL,
LPS22HB_ODR_10HZ, .outputdatarate = LPS22HB_ODR_10HZ
}; };
/*===========================================================================*/ /*===========================================================================*/
/* LSM303AGR related. */ /* LSM303AGR related. */
/*===========================================================================*/ /*===========================================================================*/

View File

@ -40,17 +40,17 @@ static const I2CConfig i2ccfg = {
}; };
static const LPS22HBConfig lps22hbcfg = { static const LPS22HBConfig lps22hbcfg = {
&I2CD1, .i2cp = &I2CD1,
&i2ccfg, .i2ccfg = &i2ccfg,
LPS22HB_SAD_VCC, .slaveaddress = LPS22HB_SAD_VCC,
NULL, .barosensitivity = NULL,
NULL, .barobias = NULL,
NULL, .thermosensitivity = NULL,
NULL, .thermobias = NULL,
LPS22HB_ODR_10HZ, .outputdatarate = LPS22HB_ODR_10HZ,
#if LPS22HB_USE_ADVANCED #if LPS22HB_USE_ADVANCED
LPS22HB_BDU_CONTINUOUS, .blockdataupdate = LPS22HB_BDU_CONTINUOUS,
LPS22HB_LP_ODR_9 .lowpass_filter = LPS22HB_LP_ODR_9
#endif #endif
}; };