We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 89947f0 commit b8906e0Copy full SHA for b8906e0
cores/rp2040/Arduino.h
@@ -68,8 +68,8 @@ void noInterrupts();
68
#define portOutputRegister(port) ((volatile uint32_t*) sio_hw->gpio_out)
69
#define portInputRegister(port) ((volatile uint32_t*) sio_hw->gpio_in)
70
#define portModeRegister(port) ((volatile uint32_t*) sio_hw->gpio_oe)
71
-#define digitalWriteFast(pin, val) (val ? gpio_set_mask (1 << pin) : gpio_clr_mask(1 << pin))
72
-#define digitalReadFast(pin) gpio_get(pin)
+#define digitalWriteFast(pin, val) (val ? sio_hw->gpio_set = (1 << pin) : sio_hw->gpio_clr = (1 << pin))
+#define digitalReadFast(pin) ((1 << pin) & sio_hw->gpio_in)
73
74
// ADC RP2040-specific calls
75
void analogReadResolution(int bits);
0 commit comments