diff --git a/cores/arduino/wiring_LL.h b/cores/arduino/wiring_LL.h index 6e8a399..687371c 100644 --- a/cores/arduino/wiring_LL.h +++ b/cores/arduino/wiring_LL.h @@ -5,6 +5,7 @@ #include "mik32_hal_gpio.h" #include "mik32_hal_scr1_timer.h" #include "mik32_hal_timer16.h" +#include "pad_config.h" // ----------------- COMMON ----------------- // // convert pin mask from HAL_PinsTypeDef to pin number @@ -61,8 +62,6 @@ // return config of pin with pinNumber(0...16) in portReg (config, pupd, ds for ports 0...2) #define PIN_GET_PAD_CONFIG(portReg, pinNumber) ((PAD_CONFIG->portReg >> (pinNumber<<1)) & 0b11) #define PIN_SET_PAD_CONFIG(portReg, pinNumber, value) (PAD_CONFIG->portReg = (PAD_CONFIG->portReg & (~PAD_CONFIG_PIN_M(pinNumber))) \ - | PAD_CONFIG_PIN(pinNumber, value)) - - + | PAD_CONFIG_PIN(pinNumber, value)) #endif /* _WIRING_LL_H_ */ \ No newline at end of file