diff options
| author | Scott Shawcroft <scott@tannewt.org> | 2021-01-20 16:47:18 -0800 |
|---|---|---|
| committer | Scott Shawcroft <scott@tannewt.org> | 2021-01-20 19:16:56 -0800 |
| commit | 733094aead6e84b42da54655b2b0a5d0dbd1a503 (patch) | |
| tree | 2ff6a1aabf8b5ea8a042fdd012deb7682eca6864 /shared-bindings/microcontroller | |
| parent | eff68b0d9fb101176a808cb68f0158e1615ed8bf (diff) | |
Add initial RP2040 support
The RP2040 is new microcontroller from Raspberry Pi that features
two Cortex M0s and eight PIO state machines that are good for
crunching lots of data. It has 264k RAM and a built in UF2
bootloader too.
Datasheet: https://pico.raspberrypi.org/files/rp2040_datasheet.pdf
Diffstat (limited to 'shared-bindings/microcontroller')
| -rw-r--r-- | shared-bindings/microcontroller/__init__.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/shared-bindings/microcontroller/__init__.h b/shared-bindings/microcontroller/__init__.h index 0dafc74c7..39d3e718b 100644 --- a/shared-bindings/microcontroller/__init__.h +++ b/shared-bindings/microcontroller/__init__.h @@ -29,6 +29,7 @@ #include "py/obj.h" #include "py/mpconfig.h" +#include "py/objtuple.h" #include "common-hal/microcontroller/Processor.h" #include "shared-bindings/microcontroller/ResetReason.h" @@ -44,7 +45,13 @@ extern void common_hal_mcu_reset(void); extern const mp_obj_dict_t mcu_pin_globals; +#if CIRCUITPY_PROCESSOR_COUNT == 1 extern const mcu_processor_obj_t common_hal_mcu_processor_obj; +#elif CIRCUITPY_PROCESSOR_COUNT > 1 +extern const mp_rom_obj_tuple_t common_hal_mcu_processor_obj; +#else +#error "Invalid processor count" +#endif #if CIRCUITPY_INTERNAL_NVM_SIZE > 0 |
