diff options
Diffstat (limited to 'software')
-rw-r--r-- | software/demo_gpio/demo_gpio.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/software/demo_gpio/demo_gpio.c b/software/demo_gpio/demo_gpio.c index 040d864..00bc8cd 100644 --- a/software/demo_gpio/demo_gpio.c +++ b/software/demo_gpio/demo_gpio.c @@ -232,10 +232,9 @@ int main(int argc, char **argv) * Atomics give a quick way to control a single bit. *************************************************************************/ uint32_t mask = (1 << PIN_19_OFFSET); - uint32_t other_mask = (1 << PIN_19_OFFSET); while (1){ - atomic_fetch_xor(&GPIO_REG(GPIO_OUTPUT_VAL), mask); + atomic_fetch_xor_explicit(&GPIO_REG(GPIO_OUTPUT_VAL), mask, memory_order_relaxed); } return 0; |