Hello.
I wrote a code for my MCU which has MCK 120Mhz.
Problem is about this part of code:
its part of display driver code
uint8_t DATA[420][238];
uint32_t TRANSFER[256];
y=19 (not changed during loop)
x=0;
while(x<420){
PIOC->PIO_ODSR = TRANSFER[DATA[x][y]];
asm("nop");
asm("nop");
x++;
}
And core of problem is tihs:
When this code is compiled with optimizer, data are drived to port at 3MHz rate.
But I need to have optimizer OFF and than it isnt so fast. Could anyone help how to make this code faster?
Many Thanks