Skip to content

Commit a5609e1

Browse files
committed
teensy: Provide dummy implementation of extint_register_pin.
1 parent fd860dc commit a5609e1

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

teensy/teensy_hal.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
#include <string.h>
33

44
#include "py/mpstate.h"
5+
#include "py/runtime.h"
56
#include "py/mphal.h"
67
#include "usb.h"
78
#include "uart.h"
@@ -58,3 +59,7 @@ void mp_hal_stdout_tx_strn_cooked(const char *str, size_t len) {
5859

5960
void mp_hal_gpio_clock_enable(GPIO_TypeDef *gpio) {
6061
}
62+
63+
void extint_register_pin(const void *pin, uint32_t mode, int hard_irq, mp_obj_t callback_obj) {
64+
mp_not_implemented(NULL);
65+
}

teensy/teensy_hal.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ typedef struct {
5757
#define GPIO_MODE_AF_PP ((uint32_t)0x00000002)
5858
#define GPIO_MODE_AF_OD ((uint32_t)0x00000012)
5959
#define GPIO_MODE_ANALOG ((uint32_t)0x00000003)
60+
#define GPIO_MODE_IT_RISING ((uint32_t)1)
61+
#define GPIO_MODE_IT_FALLING ((uint32_t)2)
6062

6163
#define IS_GPIO_MODE(MODE) (((MODE) == GPIO_MODE_INPUT) ||\
6264
((MODE) == GPIO_MODE_OUTPUT_PP) ||\

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy