diff --git a/src/rp2040/hardware_regs/include/hardware/platform_defs.h b/src/rp2040/hardware_regs/include/hardware/platform_defs.h index 70ee75b..88e12af 100644 --- a/src/rp2040/hardware_regs/include/hardware/platform_defs.h +++ b/src/rp2040/hardware_regs/include/hardware/platform_defs.h @@ -9,35 +9,6 @@ // This header is included from C and assembler - only define macros -#define NUM_CORES 2u -#define NUM_DMA_CHANNELS 12u -#define NUM_IRQS 32u -#define NUM_PIOS 2u -#define NUM_PIO_STATE_MACHINES 4u -#define NUM_PWM_SLICES 8u -#define NUM_SPIN_LOCKS 32u -#define NUM_UARTS 2u -#define NUM_BANK0_GPIOS 30u - -#define PIO_INSTRUCTION_COUNT 32u - -#define XOSC_MHZ 12u - -// PICO_CONFIG: PICO_STACK_SIZE, Stack Size, min=0x100, default=0x800, advanced=true, group=pico_standard_link -#ifndef PICO_STACK_SIZE -#define PICO_STACK_SIZE 0x800u -#endif - -// PICO_CONFIG: PICO_HEAP_SIZE, Heap size to reserve, min=0x100, default=0x800, advanced=true, group=pico_standard_link -#ifndef PICO_HEAP_SIZE -#define PICO_HEAP_SIZE 0x800 -#endif - -// PICO_CONFIG: PICO_NO_RAM_VECTOR_TABLE, Enable/disable the RAM vector table, type=bool, default=0, advanced=true, group=pico_runtime -#ifndef PICO_NO_RAM_VECTOR_TABLE -#define PICO_NO_RAM_VECTOR_TABLE 0 -#endif - #ifndef _u #ifdef __ASSEMBLER__ #define _u(x) x @@ -46,5 +17,34 @@ #endif #endif +#define NUM_CORES _u(2) +#define NUM_DMA_CHANNELS _u(12) +#define NUM_IRQS _u(32) +#define NUM_PIOS _u(2) +#define NUM_PIO_STATE_MACHINES _u(4) +#define NUM_PWM_SLICES _u(8) +#define NUM_SPIN_LOCKS _u(32) +#define NUM_UARTS _u(2) +#define NUM_BANK0_GPIOS _u(30) + +#define PIO_INSTRUCTION_COUNT _u(32) + +#define XOSC_MHZ _u(12) + +// PICO_CONFIG: PICO_STACK_SIZE, Stack Size, min=0x100, default=0x800, advanced=true, group=pico_standard_link +#ifndef PICO_STACK_SIZE +#define PICO_STACK_SIZE _u(0x800) +#endif + +// PICO_CONFIG: PICO_HEAP_SIZE, Heap size to reserve, min=0x100, default=0x800, advanced=true, group=pico_standard_link +#ifndef PICO_HEAP_SIZE +#define PICO_HEAP_SIZE _u(0x800) +#endif + +// PICO_CONFIG: PICO_NO_RAM_VECTOR_TABLE, Enable/disable the RAM vector table, type=bool, default=0, advanced=true, group=pico_runtime +#ifndef PICO_NO_RAM_VECTOR_TABLE +#define PICO_NO_RAM_VECTOR_TABLE 0 +#endif + #endif