diff options
author | Keith Packard <keithp@keithp.com> | 2012-08-06 19:35:02 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2012-08-06 19:35:02 -0700 |
commit | ab379493dbe9923db8e458d2f4e0344df17d331c (patch) | |
tree | bf6c2dd6c6ae9bf7d0e70eee0030d9ebd8501cf0 /src/stm-demo | |
parent | b0b52ca73bc836336ecc70247a9ed1dd633920d9 (diff) |
Signed-off-by: Keith Packard <keithp@keithp.com>
altos: Test quadrature driver
Diffstat (limited to 'src/stm-demo')
-rw-r--r-- | src/stm-demo/Makefile | 4 | ||||
-rw-r--r-- | src/stm-demo/ao_demo.c | 4 | ||||
-rw-r--r-- | src/stm-demo/ao_pins.h | 4 |
3 files changed, 11 insertions, 1 deletions
diff --git a/src/stm-demo/Makefile b/src/stm-demo/Makefile index 055a73af..52bb7b51 100644 --- a/src/stm-demo/Makefile +++ b/src/stm-demo/Makefile @@ -33,7 +33,9 @@ ALTOS_SRC = \ ao_spi_stm.c \ ao_adc_stm.c \ ao_i2c_stm.c \ - ao_usb_stm.c + ao_usb_stm.c \ + ao_exti_stm.c \ + ao_quadrature.c PRODUCT=StmDemo-v0.0 PRODUCT_DEF=-DSTM_DEMO diff --git a/src/stm-demo/ao_demo.c b/src/stm-demo/ao_demo.c index 9a581ff9..1b9813fe 100644 --- a/src/stm-demo/ao_demo.c +++ b/src/stm-demo/ao_demo.c @@ -16,6 +16,8 @@ */ #include "ao.h" +#include <ao_exti.h> +#include <ao_quadrature.h> struct ao_task demo_task; @@ -170,6 +172,8 @@ main(void) // ao_lcd_font_init(); ao_spi_init(); ao_i2c_init(); + ao_exti_init(); + ao_quadrature_init(); ao_timer_set_adc_interval(100); diff --git a/src/stm-demo/ao_pins.h b/src/stm-demo/ao_pins.h index 7e222122..17a76bd0 100644 --- a/src/stm-demo/ao_pins.h +++ b/src/stm-demo/ao_pins.h @@ -170,4 +170,8 @@ struct ao_adc { #define HAS_I2C_2 0 #define I2C_2_PB10_PB11 0 +#define AO_QUADRATURE_PORT &stm_gpioc +#define AO_QUADRATURE_A 0 +#define AO_QUADRATURE_B 1 + #endif /* _AO_PINS_H_ */ |