diff options
| author | Damien George <damien@micropython.org> | 2023-10-09 12:12:18 +1100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-10-20 17:39:57 +1100 |
| commit | f2f3ef162d8915096379030838c314071b445ef4 (patch) | |
| tree | 5bf8705687c855b941da572f18f30e10b8a0faa2 /extmod/modmachine.h | |
| parent | 7e7af715271c8c3ca3ec8c600b835aa388624461 (diff) | |
extmod/machine_i2s: Factor ports' I2S Python bindings to common code.
This factors the basic top-level I2S class code from the ports into
extmod/machine_i2s.c:
- I2S class definition and method table.
- The init and deinit method wrappers.
- The make_new code.
Further factoring will follow.
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'extmod/modmachine.h')
| -rw-r--r-- | extmod/modmachine.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/extmod/modmachine.h b/extmod/modmachine.h index 22bd0d625..b0235dcf6 100644 --- a/extmod/modmachine.h +++ b/extmod/modmachine.h @@ -30,6 +30,7 @@ #include "py/obj.h" // A port must provide these types, but they are otherwise opaque. +typedef struct _machine_i2s_obj_t machine_i2s_obj_t; typedef struct _machine_pwm_obj_t machine_pwm_obj_t; typedef struct _machine_wdt_obj_t machine_wdt_obj_t; @@ -37,6 +38,7 @@ typedef struct _machine_wdt_obj_t machine_wdt_obj_t; // Their Python bindings are implemented in extmod, and their implementation // is provided by a port. extern const mp_obj_type_t machine_i2c_type; +extern const mp_obj_type_t machine_i2s_type; extern const mp_obj_type_t machine_pwm_type; extern const mp_obj_type_t machine_spi_type; extern const mp_obj_type_t machine_timer_type; |
