aboutsummaryrefslogtreecommitdiffstats
path: root/testhal/STM32/STM32F3xx
diff options
context:
space:
mode:
authorRocco Marco Guglielmi <roccomarco.guglielmi@live.com>2016-03-16 11:45:23 +0000
committerRocco Marco Guglielmi <roccomarco.guglielmi@live.com>2016-03-16 11:45:23 +0000
commit94bbc4d19ca17984db3262089ba7365fbf62c6de (patch)
tree5e60aebc4b1d082e721eba9516a123b09508640b /testhal/STM32/STM32F3xx
parent1914bcbbf422a9616dd2c1d6906a8ced3548921d (diff)
downloadChibiOS-94bbc4d19ca17984db3262089ba7365fbf62c6de.tar.gz
ChibiOS-94bbc4d19ca17984db3262089ba7365fbf62c6de.tar.bz2
ChibiOS-94bbc4d19ca17984db3262089ba7365fbf62c6de.zip
Improved Gyroscope methods. Updated L3GD20 files and demos.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9126 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'testhal/STM32/STM32F3xx')
-rw-r--r--testhal/STM32/STM32F3xx/SPI-L3GD20/.project38
-rw-r--r--testhal/STM32/STM32F3xx/SPI-L3GD20/main.c4
2 files changed, 40 insertions, 2 deletions
diff --git a/testhal/STM32/STM32F3xx/SPI-L3GD20/.project b/testhal/STM32/STM32F3xx/SPI-L3GD20/.project
new file mode 100644
index 000000000..80babdba1
--- /dev/null
+++ b/testhal/STM32/STM32F3xx/SPI-L3GD20/.project
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>STM32F3xx-SPI-L3GD20</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
+ <triggers>clean,full,incremental,</triggers>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
+ <triggers>full,incremental,</triggers>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.cdt.core.cnature</nature>
+ <nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
+ <nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
+ </natures>
+ <linkedResources>
+ <link>
+ <name>board</name>
+ <type>2</type>
+ <location>C:/ChibiStudio/chibios_trunk/os/hal/boards/ST_STM32F3_DISCOVERY</location>
+ </link>
+ <link>
+ <name>os</name>
+ <type>2</type>
+ <locationURI>CHIBIOS/os</locationURI>
+ </link>
+ </linkedResources>
+</projectDescription>
diff --git a/testhal/STM32/STM32F3xx/SPI-L3GD20/main.c b/testhal/STM32/STM32F3xx/SPI-L3GD20/main.c
index d9925b041..ec198ec7a 100644
--- a/testhal/STM32/STM32F3xx/SPI-L3GD20/main.c
+++ b/testhal/STM32/STM32F3xx/SPI-L3GD20/main.c
@@ -146,14 +146,14 @@ int main(void) {
}
palClearLine(LINE_LED10_RED);
- chprintf(chp, "Calibrating Gyroscope...\r\n");
+ chprintf(chp, "Calibrating Gyroscope sampling bias...\r\n");
chprintf(chp, "Keep it in the rest position while red LED is on\r\n");
chThdSleepMilliseconds(3000);
palSetLine(LINE_LED10_RED);
chThdSleepMilliseconds(1000);
- gyroscopeCalibrate(&L3GD20D1);
+ gyroscopeSampleBias(&L3GD20D1);
palClearLine(LINE_LED10_RED);
#if CHPRINTF_USE_ANSI_CODE
chprintf(chp, "\033[2J\033[1;1H");