diff --git a/firmware/components/driver_display_hub75/driver_hub75_bits.c b/firmware/components/driver_display_hub75/driver_hub75_bits.c index 00c649ac..6a2b0ef7 100644 --- a/firmware/components/driver_display_hub75/driver_hub75_bits.c +++ b/firmware/components/driver_display_hub75/driver_hub75_bits.c @@ -13,14 +13,9 @@ #include "include/driver_hub75_bits.h" #include "include/i2s_parallel.h" -#ifndef DRIVER_HUB75_DMA_DATA_TEST -#include "esp_heap_caps.h" -#endif - - - #ifdef DRIVER_HUB75_DMA_DATA_TEST +#define CONFIG_DRIVER_HUB75_ENABLE #define CONFIG_HUB75_WIDTH 32 #define MALLOC_CAP_DMA (-1) #include @@ -28,8 +23,12 @@ void *heap_caps_calloc(size_t nmemb, size_t size, int cap) { return calloc(nmemb, size); } void i2sparallel_init(i2s_parallel_buffer_desc_t *bufa, i2s_parallel_buffer_desc_t *bufb) { } void i2sparallel_flipBuffer(int bufid) { } +#else +#include "esp_heap_caps.h" #endif +#ifdef CONFIG_DRIVER_HUB75_ENABLE + #define BIT_RED (1<<0) //connected to GPIO2 here #define BIT_GREEN (1<<1) //connected to GPIO15 here #define BIT_BLUE (1<<2) //connected to GPIO4 here @@ -596,3 +595,6 @@ int main(int argc, char *argv[]) } #endif // DRIVER_HUB75_DMA_DATA_TEST + + +#endif // CONFIG_DRIVER_HUB75_ENABLE