This commit is contained in:
mrfaptastic 2021-08-16 13:29:44 +01:00
parent 6527907ac5
commit fd7629e52c
3 changed files with 3 additions and 4 deletions

View file

@ -754,7 +754,7 @@ void MatrixPanel_I2S_DMA::brtCtrlOE(int brt, const bool _buff_id){
/* /*
* overload for compatibility * overload for compatibility
*/ */
bool MatrixPanel_I2S_DMA::begin(int r1, int g1, int b1, int r2, int g2, int b2, int a, int b, int c, int d, int e, int lat, int oe, int clk){ bool MatrixPanel_I2S_DMA::begin(int r1, int g1, int b1, int r2, int g2, int b2, int a, int b, int c, int d, int e, int lat, int oe, int clk) {
// RGB // RGB
m_cfg.gpio.r1 = r1; m_cfg.gpio.g1 = g1; m_cfg.gpio.b1 = b1; m_cfg.gpio.r1 = r1; m_cfg.gpio.g1 = g1; m_cfg.gpio.b1 = b1;

View file

@ -350,6 +350,8 @@ class MatrixPanel_I2S_DMA {
/* Propagate the DMA pin configuration, allocate DMA buffs and start data ouput, initialy blank */ /* Propagate the DMA pin configuration, allocate DMA buffs and start data ouput, initialy blank */
bool begin(){ bool begin(){
if (initialized) return; // we don't do this twice or more!
// Change 'if' to '1' to enable, 0 to not include this Serial output in compiled program // Change 'if' to '1' to enable, 0 to not include this Serial output in compiled program
#if SERIAL_DEBUG #if SERIAL_DEBUG

View file

@ -111,9 +111,6 @@ void setup() {
dma_display->clearScreen(); dma_display->clearScreen();
dma_display->fillScreen(myWHITE); dma_display->fillScreen(myWHITE);
//
dma_display->begin(); // use default pins
// fix the screen with green // fix the screen with green
dma_display->fillRect(0, 0, dma_display->width(), dma_display->height(), dma_display->color444(0, 15, 0)); dma_display->fillRect(0, 0, dma_display->width(), dma_display->height(), dma_display->color444(0, 15, 0));
delay(500); delay(500);