I want to change out my UNO R3 for an UNO Wifi Rev2, for the extra speed, memory and free UART port (Serial1). I like the compatibility with the UNO shields as well, the reason I prefer the UNO wifi over other MCUs. The 3rd party code I'm using uses timing registers that are not equivalent in the UNO wifi:
** TCCR2A = 0; //Make sure that the TCCR2A register is set to zero**
** TCCR2B = 0; //Make sure that the TCCR2A register is set to zero**
** TIMSK2 |= (1 << OCIE2A); //Set the interupt enable bit OCIE2A in the TIMSK2 register**
** TCCR2B |= (1 << CS21); //Set the CS21 bit in the TCCRB register to set the prescaler to 8**
** OCR2A = 39; //The compare register is set to 39 => 20us / (1s / (16.000.000MHz / 8)) -
I tried using Atmega328 compatibility mode in the UNO Wifi board parameters, but this did not work (someone on this forum said it worked for them). I still can't compile the program because of these registers. I know a little about registers from my work PIC MCUS years ago but not sure how to make the UNO wifi compatible. Has anyone gone beyond this, or had the capatibility mode work? I have latest IDE, library has been updated numerous times.