Skip to content
Snippets Groups Projects
Commit 73c494aa authored by cnlohr's avatar cnlohr
Browse files

Fix bug where config didn't config specifically.

parent 49d8791d
No related branches found
No related tags found
No related merge requests found
......@@ -5182,7 +5182,7 @@ extern "C" {
#define PD7 55
#define funDigitalWrite( pin, value ) { GpioOf( pin )->BSHR = 1<<((value)*16 + ((pin) & 0xf)); }
#define funPinMode( pin, mode ) { GpioOf(pin)->CFGLR = (GpioOf(pin)->CFGLR & (~(0xf<<(4*((pin)&0xf))))) | ((GPIO_Speed_10MHz | GPIO_CNF_OUT_PP)<<(4*((pin)&0xf))); }
#define funPinMode( pin, mode ) { GpioOf(pin)->CFGLR = (GpioOf(pin)->CFGLR & (~(0xf<<(4*((pin)&0xf))))) | ((mode)<<(4*((pin)&0xf))); }
#define funGpioInitAll() { RCC->APB2PCENR |= ( RCC_APB2Periph_AFIO | RCC_APB2Periph_GPIOA | RCC_APB2Periph_GPIOC | RCC_APB2Periph_GPIOD ); }
#define funDigitalRead( pin ) ((GpioOf(pin)->INDR >> ((pin)&0xf)) & 1)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment