mirror of https://github.com/rusefi/ChibiOS.git
Updated LIS3DSH demos in testex demos to be close to the pattern used in testhal demos. Minor changes to field names in LIS3DSH.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@15439 27425a3e-05d8-49a3-a47f-9c15f0e5edd8
This commit is contained in:
parent
9f7c12e7fd
commit
e9918a4413
|
@ -478,9 +478,9 @@ void lis3dshStart(LIS3DSHDriver *devp, const LIS3DSHConfig *config) {
|
|||
/* Control register 4 configuration block.*/
|
||||
{
|
||||
cr = LIS3DSH_CTRL_REG4_XEN | LIS3DSH_CTRL_REG4_YEN | LIS3DSH_CTRL_REG4_ZEN |
|
||||
devp->config->accoutputdatarate;
|
||||
devp->config->accodr;
|
||||
#if LIS3DSH_USE_ADVANCED || defined(__DOXYGEN__)
|
||||
cr |= devp->config->accblockdataupdate;
|
||||
cr |= devp->config->accbdu;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
@ -522,7 +522,7 @@ void lis3dshStart(LIS3DSHDriver *devp, const LIS3DSHConfig *config) {
|
|||
{
|
||||
cr = LIS3DSH_CTRL_REG6_ADD_INC;
|
||||
#if LIS3DSH_USE_ADVANCED || defined(__DOXYGEN__)
|
||||
cr |= devp->config->accblockdataupdate;
|
||||
cr |= devp->config->accbdu;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@
|
|||
/**
|
||||
* @brief LIS3DSH driver version string.
|
||||
*/
|
||||
#define EX_LIS3DSH_VERSION "1.1.2"
|
||||
#define EX_LIS3DSH_VERSION "1.1.3"
|
||||
|
||||
/**
|
||||
* @brief LIS3DSH driver version major number.
|
||||
|
@ -58,7 +58,7 @@
|
|||
/**
|
||||
* @brief LIS3DSH driver version patch number.
|
||||
*/
|
||||
#define EX_LIS3DSH_PATCH 2
|
||||
#define EX_LIS3DSH_PATCH 3
|
||||
/** @} */
|
||||
|
||||
/**
|
||||
|
@ -480,7 +480,7 @@ typedef struct {
|
|||
/**
|
||||
* @brief LIS3DSH output data rate selection.
|
||||
*/
|
||||
lis3dsh_acc_odr_t accoutputdatarate;
|
||||
lis3dsh_acc_odr_t accodr;
|
||||
#if LIS3DSH_USE_ADVANCED || defined(__DOXYGEN__)
|
||||
/**
|
||||
* @brief LIS3DSH anti-aliasing bandwidth.
|
||||
|
@ -489,7 +489,7 @@ typedef struct {
|
|||
/**
|
||||
* @brief LIS3DSH block data update.
|
||||
*/
|
||||
lis3dsh_acc_bdu_t accblockdataupdate;
|
||||
lis3dsh_acc_bdu_t accbdu;
|
||||
#endif
|
||||
} LIS3DSHConfig;
|
||||
|
||||
|
|
|
@ -47,15 +47,15 @@ static const SPIConfig spicfg = {
|
|||
};
|
||||
|
||||
static LIS3DSHConfig lis3dshcfg = {
|
||||
&SPID1,
|
||||
&spicfg,
|
||||
NULL,
|
||||
NULL,
|
||||
LIS3DSH_ACC_FS_2G,
|
||||
LIS3DSH_ACC_ODR_100HZ,
|
||||
.spip = &SPID1,
|
||||
.spicfg = &spicfg,
|
||||
.accsensitivity = NULL,
|
||||
.accbias = NULL,
|
||||
.accfullscale = LIS3DSH_ACC_FS_2G,
|
||||
.accodr = LIS3DSH_ACC_ODR_100HZ,
|
||||
#if LIS3DSH_USE_ADVANCED
|
||||
LIS3DSH_ACC_BW_400HZ,
|
||||
LIS3DSH_ACC_BDU_CONTINUOUS,
|
||||
.accantialiasing = LIS3DSH_ACC_BW_400HZ,
|
||||
.accbdu = LIS3DSH_ACC_BDU_CONTINUOUS
|
||||
#endif
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue