aboutsummaryrefslogtreecommitdiffstats
path: root/os/ex/ST/l3gd20.c
diff options
context:
space:
mode:
authorRocco Marco Guglielmi <roccomarco.guglielmi@gmail.com>2018-02-05 10:31:52 +0000
committerRocco Marco Guglielmi <roccomarco.guglielmi@gmail.com>2018-02-05 10:31:52 +0000
commit2268a0e69a9d8a966157672178a3524d9eb474c7 (patch)
tree6cc72e53e5720fce393248cd5ae409fb9f2d8df3 /os/ex/ST/l3gd20.c
parent4ddc3c188bbd834f05bd8d635e6e26fb3ecc6ae2 (diff)
downloadChibiOS-2268a0e69a9d8a966157672178a3524d9eb474c7.tar.gz
ChibiOS-2268a0e69a9d8a966157672178a3524d9eb474c7.tar.bz2
ChibiOS-2268a0e69a9d8a966157672178a3524d9eb474c7.zip
Updated L3GD20 driver to v 1.0.5 (Fixing Bug #915).
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@11442 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/ex/ST/l3gd20.c')
-rw-r--r--os/ex/ST/l3gd20.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/os/ex/ST/l3gd20.c b/os/ex/ST/l3gd20.c
index 066e11962..3396c93e6 100644
--- a/os/ex/ST/l3gd20.c
+++ b/os/ex/ST/l3gd20.c
@@ -304,17 +304,11 @@ static msg_t set_full_scale(void *ip, l3gd20_fs_t fs) {
return MSG_OK;
}
-static const struct BaseSensorVMT vmt_basesensor = {
+static const struct BaseSensorVMT vmt_sensor = {
get_axes_number, read_raw, read_cooked
};
-static const struct BaseGyroscopeVMT vmt_basegyroscope = {
- get_axes_number, read_raw, read_cooked,
- sample_bias, set_bias, reset_bias,
- set_sensivity, reset_sensivity
-};
-
-static const struct L3GD20VMT vmt_l3gd20 = {
+static const struct L3GD20GyroscopeVMT vmt_gyroscope = {
get_axes_number, read_raw, read_cooked,
sample_bias, set_bias, reset_bias,
set_sensivity, reset_sensivity,
@@ -334,9 +328,8 @@ static const struct L3GD20VMT vmt_l3gd20 = {
*/
void l3gd20ObjectInit(L3GD20Driver *devp) {
uint32_t i;
- devp->vmt_basesensor = &vmt_basesensor;
- devp->vmt_basegyroscope = &vmt_basegyroscope;
- devp->vmt_l3gd20 = &vmt_l3gd20;
+ devp->vmt_sensor = &vmt_sensor;
+ devp->vmt_gyroscope = &vmt_gyroscope;
devp->config = NULL;
for(i = 0; i < L3GD20_NUMBER_OF_AXES; i++)
devp->bias[i] = 0.0f;