projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
altos/stm32f4: Place ARM.exidx sections after .text
[fw/altos]
/
src
/
stm-demo
/
ao_demo.c
diff --git
a/src/stm-demo/ao_demo.c
b/src/stm-demo/ao_demo.c
index ffc5d2d873b3f7d8e176d3edc2cf2d7428af3b8a..4b963e4281fa3e5ebb3e5478d3deae5e9395284f 100644
(file)
--- a/
src/stm-demo/ao_demo.c
+++ b/
src/stm-demo/ao_demo.c
@@
-3,7
+3,8
@@
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
@@
-124,7
+125,7
@@
ao_i2c_write(void) {
for (i = 0; i < 10; i++) {
ao_i2c_get(0);
if (ao_i2c_start(0, 0x55))
for (i = 0; i < 10; i++) {
ao_i2c_get(0);
if (ao_i2c_start(0, 0x55))
- ao_i2c_send(data, 4, 0,
TRUE
);
+ ao_i2c_send(data, 4, 0,
true
);
else {
printf ("i2c start failed\n");
ao_i2c_put(0);
else {
printf ("i2c start failed\n");
ao_i2c_put(0);
@@
-196,7
+197,7
@@
ao_blink_toggle(void)
}
}
-
__code
struct ao_cmds ao_demo_cmds[] = {
+
const
struct ao_cmds ao_demo_cmds[] = {
{ ao_dma_test, "D\0DMA test" },
{ ao_spi_write, "W\0SPI write" },
{ ao_spi_read, "R\0SPI read" },
{ ao_dma_test, "D\0DMA test" },
{ ao_spi_write, "W\0SPI write" },
{ ao_spi_read, "R\0SPI read" },
@@
-222,11
+223,12
@@
main(void)
ao_cmd_init();
// ao_lcd_stm_init();
// ao_lcd_font_init();
ao_cmd_init();
// ao_lcd_stm_init();
// ao_lcd_font_init();
-
//
ao_spi_init();
+
ao_spi_init();
// ao_i2c_init();
// ao_exti_init();
// ao_quadrature_init();
// ao_button_init();
// ao_i2c_init();
// ao_exti_init();
// ao_quadrature_init();
// ao_button_init();
+ ao_storage_init();
// ao_timer_set_adc_interval(100);
// ao_timer_set_adc_interval(100);