The new Arduino UNO R4 Wi-Fi

It has been a while since my last post, but life gets in the way sometimes.

The UNO form factor and the claim it was a 5V board made me pay more attention this time to this new board from Arduino. Having an ESP32 for Wi-Fi support was a nice touch, so while I did not make it as a beta tester, I shelled out some cash and got a commercial unit as soon as it was launched. 


It is not only the built-in Wi-Fi but lots of other goodies, but you cannot but love the led matrix display <3

My first experience with the board was in an M1 Mac, which was completely trouble-free. The second test was with a Windows 10 machine, and the results were not good: I could not upload code to the board even though it was detected and the port was correctly set. I searched around and discovered this is a known issue. Bummer :-(


That error happened using the new 2.1.0 IDE, so I returned to the older version installed on my computer, which was a no-go too.


So I think that is all about it with Windows so far. So I will get back to my Mac to get the ball rolling. 

But wait ..., what if the old IDE needs the board to be unplugged. I quit the new IDE and disconnected and connected the board again, and ... voilá, the upload is now working and I can use the board in Windows 10. 


Some sample code I wrote for the led matrix (a kind of glorified Blink :-)

#include "Arduino_LED_Matrix.h"
#define MAX_Y 8
#define MAX_X 12
uint8_t grid[MAX_Y][MAX_X] = {
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 
    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
};
ArduinoLEDMatrix matrix;
void setup() {
  matrix.begin(); 
}
void loop() {
  for(int i = 0; i<97; i++) {
    int x = i % MAX_X; 
    int y = i / MAX_X;
    for(int j = 0; j < 4; j++) {
      grid[y][x] = 1;
      matrix.renderBitmap(grid, 8, 12);  
      grid[y][x] = 0;
      delay(100);
      matrix.renderBitmap(grid, 8, 12);
      delay(100);
    }
  }  
}

Comments

Popular posts from this blog

VFD control with Arduino using RS485 link

How to get sinusoidal s-curve for a stepper motor

Stepper motor step signal timing calculation