diff options
| author | Damien George | 2021-02-18 21:24:34 +1100 |
|---|---|---|
| committer | Damien George | 2021-04-15 10:31:06 +1000 |
| commit | 66a86a061530eeee51191c3c667e9bc3cfcfda40 (patch) | |
| tree | e2e0e6d63f4dc16d47a7f0a855dd2b43f07ebc5b /ports/esp32/machine_dac.c | |
| parent | 8459f538eb45fd8e1e4d614298449cf18de84d75 (diff) | |
esp32: Add initial support for ESP32S2 SoCs.
Builds against IDF v4.3-beta2.
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'ports/esp32/machine_dac.c')
| -rw-r--r-- | ports/esp32/machine_dac.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ports/esp32/machine_dac.c b/ports/esp32/machine_dac.c index 02855fcf8..146ef60aa 100644 --- a/ports/esp32/machine_dac.c +++ b/ports/esp32/machine_dac.c @@ -43,8 +43,13 @@ typedef struct _mdac_obj_t { } mdac_obj_t; STATIC const mdac_obj_t mdac_obj[] = { + #if CONFIG_IDF_TARGET_ESP32 {{&machine_dac_type}, GPIO_NUM_25, DAC_CHANNEL_1}, {{&machine_dac_type}, GPIO_NUM_26, DAC_CHANNEL_2}, + #else + {{&machine_dac_type}, GPIO_NUM_17, DAC_CHANNEL_1}, + {{&machine_dac_type}, GPIO_NUM_18, DAC_CHANNEL_2}, + #endif }; STATIC mp_obj_t mdac_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, |
