summaryrefslogtreecommitdiff
path: root/ucoo/dev/lcd
diff options
context:
space:
mode:
authorNicolas Schodet2016-07-25 15:18:40 +0200
committerNicolas Schodet2019-10-09 23:05:44 +0200
commit4695b47da68a5b2f75270bea21e15b8f1b9fd6ff (patch)
tree6e5ef4d34ee69bcd6c6627f25a0ca3aa902d47e3 /ucoo/dev/lcd
parentd7df91926bdb529e68eff9a215aef72072803b6e (diff)
Switch to CMSIS
Diffstat (limited to 'ucoo/dev/lcd')
-rw-r--r--ucoo/dev/lcd/test/test_lcd.cc16
1 files changed, 7 insertions, 9 deletions
diff --git a/ucoo/dev/lcd/test/test_lcd.cc b/ucoo/dev/lcd/test/test_lcd.cc
index c654287..d4c0f79 100644
--- a/ucoo/dev/lcd/test/test_lcd.cc
+++ b/ucoo/dev/lcd/test/test_lcd.cc
@@ -29,19 +29,17 @@
#include "ucoo/arch/arch.hh"
-#include <libopencm3/stm32/rcc.h>
-
int
main (int argc, const char **argv)
{
ucoo::arch_init (argc, argv);
- rcc_periph_clock_enable (RCC_GPIOB);
- ucoo::Gpio rw (GPIOB, 10);
- ucoo::Gpio rs (GPIOB, 11);
- ucoo::Gpio cs (GPIOB, 12);
- ucoo::Gpio sck (GPIOB, 13);
- ucoo::Gpio miso (GPIOB, 14);
- ucoo::Gpio mosi (GPIOB, 15);
+ ucoo::GPIOB.enable ();
+ ucoo::Gpio rw (ucoo::GPIOB[10]);
+ ucoo::Gpio rs (ucoo::GPIOB[11]);
+ ucoo::Gpio cs (ucoo::GPIOB[12]);
+ ucoo::Gpio sck (ucoo::GPIOB[13]);
+ ucoo::Gpio miso (ucoo::GPIOB[14]);
+ ucoo::Gpio mosi (ucoo::GPIOB[15]);
ucoo::SpiSoftMaster spi (sck, mosi, miso);
rw.reset ();
rw.output ();