diff options
-rw-r--r-- | libmaple/exti.c | 6 | ||||
-rw-r--r-- | libmaple/include/libmaple/exti.h | 2 | ||||
-rw-r--r-- | wirish/ext_interrupts.cpp | 2 | ||||
-rw-r--r-- | wirish/include/wirish/ext_interrupts.h | 2 |
4 files changed, 6 insertions, 6 deletions
diff --git a/libmaple/exti.c b/libmaple/exti.c index b620c77..abd618d 100644 --- a/libmaple/exti.c +++ b/libmaple/exti.c @@ -92,7 +92,7 @@ void exti_attach_interrupt(exti_num num, exti_trigger_mode mode) { // Call callback version with arg being null - exti_attach_callback(num, port, handler, NULL, mode); + exti_attach_callback(num, port, (voidArgumentFuncPtr)handler, NULL, mode); } /** @@ -114,14 +114,14 @@ void exti_attach_interrupt(exti_num num, */ void exti_attach_callback(exti_num num, exti_cfg port, - voidFuncPtr handler, + voidArgumentFuncPtr handler, void *arg, exti_trigger_mode mode) { ASSERT(handler); /* Register the handler */ - exti_channels[num].handler = (voidArgumentFuncPtr)handler; + exti_channels[num].handler = handler; exti_channels[num].arg = arg; /* Set trigger mode */ diff --git a/libmaple/include/libmaple/exti.h b/libmaple/include/libmaple/exti.h index 530b442..1d201ac 100644 --- a/libmaple/include/libmaple/exti.h +++ b/libmaple/include/libmaple/exti.h @@ -117,7 +117,7 @@ void exti_attach_interrupt(exti_num num, exti_trigger_mode mode); void exti_attach_callback(exti_num num, exti_cfg port, - voidFuncPtr handler, + voidArgumentFuncPtr handler, void *arg, exti_trigger_mode mode); void exti_detach_interrupt(exti_num num); diff --git a/wirish/ext_interrupts.cpp b/wirish/ext_interrupts.cpp index f72efbf..7271eb3 100644 --- a/wirish/ext_interrupts.cpp +++ b/wirish/ext_interrupts.cpp @@ -73,7 +73,7 @@ void attachInterrupt(uint8 pin, voidFuncPtr handler, ExtIntTriggerMode mode) { * @sideeffect Registers a handler * @see detachInterrupt() */ -void attachInterrupt(uint8 pin, voidFuncPtr handler, void *arg, ExtIntTriggerMode mode) { +void attachInterrupt(uint8 pin, voidArgumentFuncPtr handler, void *arg, ExtIntTriggerMode mode) { if (pin >= BOARD_NR_GPIO_PINS || !handler) { return; } diff --git a/wirish/include/wirish/ext_interrupts.h b/wirish/include/wirish/ext_interrupts.h index 1bd7956..7f2bd6a 100644 --- a/wirish/include/wirish/ext_interrupts.h +++ b/wirish/include/wirish/ext_interrupts.h @@ -87,7 +87,7 @@ void attachInterrupt(uint8 pin, voidFuncPtr handler, ExtIntTriggerMode mode); * @sideeffect Registers a handler * @see detachInterrupt() */ -void attachInterrupt(uint8 pin, voidFuncPtr handler, void *arg, ExtIntTriggerMode mode); +void attachInterrupt(uint8 pin, voidArgumentFuncPtr handler, void *arg, ExtIntTriggerMode mode); /** * @brief Disable any registered external interrupt. |