Going Bigger with a Giga R1

Table of contents

RoadTest: Enroll to Review the Arduino GIGA R1 WiFi + Camera

Author: BigG

Creation date:

Evaluation Type: Development Boards & Tools

Did you receive all parts the manufacturer stated would be included in the package?: True

What other parts do you consider comparable to this product?: Dev boards with similar processor: Arduino Portenta H7, Teensy 4.1, STM32 NUCLEO-H7xxxxx, Seeed Studio Wio Lite AI, NXP i.MX RT10xx EVK's, DFRobot ART-Pi STM32H750

What were the biggest problems encountered?: Bluetooth did not work on the second M4 core using the ArduinoBLE library. I initially could not get the CAN-bus to work (there was a pin reference error in pins_arduino.h). Other than pin definitions for the inbuilt opamp, no explanation is given or examples provided on how to use, so I was not able to test.

Detailed Review:

Introduction

I would like to thank Element14 and Arduino for allowing me the opportunity to road test this board. It’s not everyday one gets super excited to receive a new dev board… and this was one of those days.

Just putting together my MEGA boards together for the above photo made me reminisce about projects past and then wonder about all the possible projects to come with this new Giga R1.

The really cool thing about Arduino is that all those boards still work and I can still use all of these boards with the current Arduino IDE. From what I’ve experienced over the years, there are not many other boards out there that have maintained this same longevity.

So, I’m pretty confident that this Arduino Giga R1 WiFi board will be around for many years to come. The question though is whether this board has earned the right to be upgraded from a MEGA to a Giga.

Let’s find out.

Unboxing and getting to blink

Unboxing

Ah, the simple pleasures of opening up a package containing a new Arduino dev board.

As you can see from the video, I received an Arduino Giga R1 WiFi board and a camera (OV6525) as part of this road test. The camera, as you’ll find later in this review, has a unique place on the Giga R1. But, more on that later.

{gallery}Arduino Giga unboxing

The Arduino Giga board comes inside a nicely printed silky smooth card box, which looks very similar to the original MEGA board in terms of size and colours used in the branding. The difference though, besides maybe the use of less colours, is that there is now more technical detail provided on the box itself. This is a welcomed improvement.

Then, as before, you get some customary stickers and a small folded pamphlet inside the box. The pamphlet itself is pretty much as before and provides some generic detail about how the product was made and the usual regulatory information.

In terms of directing the user on where to find further information, a product documentation reference web page (namely, DOCS.ARDUINO.CC/GIGA-R1-WIFI) is now printed on the box and the generic website link (arduino.cc) is on the pamphlet. I will review the documentation later in the review under the onboarding section.

A quick look at the Giga R1 WiFi board

{gallery}The Arduino Giga R1 WiFi

The board itself has some great improvements. I really do like the labelling on the pin headers as I find this to be really helpful during project setup. Add in the information provided on both the upper and lower silkscreens on the board is really a benchmark setter. Other dev board manufacturers should take note.

The layout on the board is also a little different to the original MEGA 2560.

I’ll start with the headers.

source: Arduino.cc

As you can see, the Giga R1 board has the same form factor as the MEGA/Due with identical edge female header receptacles and the (ICSP) 6 pin male header.

If I look at what is broken out, I can see that the Giga is almost identical to the Mega with UART in terms of offering 4 x UART RX/TX ports on the board. As before, these are all clearly marked on the board as TX/RX0 through to TX/RX3. But there is a subtle difference.

The Serial output via the USB is actually the 5th Serial port so unlike the MEGA, pins 0 and 1 are seen as Serial1 and not Serial. As such, if you connect a FTDI breakout board to pins 0 and 1, you can use the Serialpassthrough example where text transmitted via the USB connection (Serial) will be passed through to RX0 or Pin0, which is Serial1.

Then with I2C, there are now 3 x I2C buses broken out on the Giga, so the 2 pins next to AREF are now seen as I2C1 and the 2 pins next to RX1 are now the default I2C pins. There is also a 3rd I2C bus (I2C2), which is now found on digital pins 8 and 9.

SPI is slightly different to the MEGA but similar to the Due, in that SPI is not available on pins 50 through to 52. Instead we have the 6 pin header (ICSP) labelled SPI as the default SPI bus and SPI1 is now available on the same pins as Arduino UNO, namely pins 11, 12 & 13.

The only negative observation I have about the board's silkscreen labelling is that there is still no pinout reference provided for the 6 pin header (ICSP) labelled SPI. I find that unless you’ve memorised these pin references you have to keep referring back to the full pin-out PDF documentation, which slows you down.

The Giga, of course, has broken out even more pins with the addition of 2 double row connectors. The pin references are screen printed on the underside of the board (image source: Arduino.cc):

source: arduino.cc

There is now a double row pin header available (J6), which includes I2C1:SDA+SCL & pins 54 through to 67. This is pin compatible with the 20 pin Arducam camera connector camera format. It's worth noting that not all cameras have libraries available at the moment - the one shown in the picture is my own camera module and it does not have a library available… probably because it’s a rather old camera module.

The other new double row pin header (J7) is something very new to Arduino. This contains a Display Serial Interface (DSI) for high speed video interface through the MIPI-DSI interface and there is also an I2S bus interface broken out as well. I think this combo will work well for those wanting to create high-end video with digital sound applications.

I did not test this new MIPI-DSI interface during this road test but I did discover an application note (AN4860) online for STM32 MCU’s. This explains the different operating modes of the DSI host and also provides guidelines to help you choose the best operating mode depending on an application’s needs.

Moving on to the power rail.

The datasheet provides a great diagram illustrating how the power rails are configured:

As you can see, there is now no power jack. Instead, the only options available to power the board are via the new USB-C port, which is only 5.5V (max), or via the VIN pin, which has an input voltage range from 6V to 32V. The AP63200 used on the board is a 2A, synchronous buck converter. The above diagram notes max current of 1.5A.

The power rail pins (VIN, 5V, 3V and ground are also broken out on J7. This means you can even power the board from underneath.

{gallery:autoplay=false}Power Rail

For proper debugging, there is now a 1.27mm pitch 2x5 pin JTAG connector provided for debugging purposes. To use, you need a separate Segger or GDB JTAG debugger interface board. Neither of these interface boards were provided as part of the road test.

In terms of storage, the board now includes additional 128Mb serial flash (AT25SF128A) - this is great for storing images and other static data. There is also a USB host connector provided allowing you to use a memory stick... more on that later. Also next to the USB host is a 3 pin audio/microphone jack to allow you to experiment with ADC and DAC capabilities. More on that later too.

{gallery:autoplay=false}Storage options

Another awesome hardware inclusion is WiFi. This uses the Murata 1DX SoM.

If looking for the schematic, a PDF is provided online (shown via Altium WebViewer). What I really like are the little things that Arduino has now added to the schematic. For example, it now includes a graphic thumbnail of where you are on the board. When you’re unfamiliar with the component layout, I found this is really helpful.

So, phew, as you can there is plenty packed onto this new board.

Now, let’s get the relevant IDE and core hardware files for the board installed and get the board to blink to at least check that I am setup correctly and it's working.

Getting to the board to blink

As this is not my first time I’ve used an Arduino, I think I am in a similar position to many others, who might get an Arduino Giga R1 for the first time. In these cases it’s very easy to fall into the trap of working off assumptions, based on past experiences. This is not always a good thing as when you are in this situation, you tend to either skip or skim through the getting started section. Hence, I have consciously tried not to do this. So apologies in advance if I have unwittingly glanced over some key getting started aspects in this section.

I have included two videos here.

The first video includes a voice over where I explain the steps I took to get my new board correctly set up in my Arduino v1.8.16 IDE running on Linux Mint (Ubuntu 20.04) laptop and then uploading the common Blink Arduino sketch.

The 2nd video is just a screen capture recording (no audio) of me setting up my son’s Windows 11 laptop with the latest (at the time) Arduino v2.1 IDE and then, similarly, getting the board setup to run the Blink sketch.

In both cases, I experienced no issues with getting the Arduino Giga R1 set up and to blink an LED. It was very straightforward and it was the quickest setup process I have experienced, compared to other development boards out there.

The onboarding process - getting up to speed

As noted on the product documentation, the Arduino Giga R1’s online documentation landing page is: https://docs.arduino.cc/hardware/giga-r1-wifi

As you can see, on the landing page there are four buttons to help you get started. Two of these buttons are only really useful at the very start. Then, once setup the “SETUP GUIDE” and the “GET STARTED” buttons become superfluous.

The other two buttons "PINOUT" and "DATASHEET" you'll probably use on more than one occasion.

When the PINOUT button is clicked a pinout diagram is shown. However, I found this pinout diagram to be too rudimentary for such a big board. It really needs to show you the full pinout PDF. As a side note, I noticed that this is the same under the Resources section. Only the simple pinout image is shown. You have to go to the Downloads section to find the full Pinout diagram, as shown in here.

The DATASHEET button brings up another useful document, but I found it not nearly as useful as the “Cheat Sheet”, which is a link found below when you scroll down.

However, there is one very useful tit bit found within the datasheet. Namely, what to do when there is a MbedOS fail, which happens every now and then:

In case a sketch locks up the processor and the board is not reachable anymore via USB, it is possible to enter bootloader mode by double-tapping the reset button right after the power-up.

Then back on the landing page there is a second menu bar and there is a “Main Features” section. These can easily be overlooked (well I missed it to start) - you have to scroll down to find it.

I have found that the “Main Features” section is the key to getting all the information you need and I have been constantly referring back to this section throughout the road test.

For example, the “Cheat Sheet” is a very handy reference - although it does miss the pinout diagrams for completeness.

The “Essentials” section is useful too although, I think it needs a link to the hardware page so I can quickly find the board’s specifications.

The “Mbed Core Libraries” link sends you to the GitHub repository listing all the different Giga libraries, many of which are not included in the core library set for the Giga board (i.e. the ones that are included in the board management files).

The “Tutorials” section seems to be a repeat of the “Main Features” listing, which is somewhat confusing. I am not sure this duplication is necessary.

Finally there is the “Resources” section, which gives you a range of documents from Schematics, Pinouts through to 3D STEP and 2D CAD files.

Once you get familiar with the layout structure, the documentation portal is a great point of reference. It is clean and tidy and I never once got lost.

Getting to know the board through examples

Anyone familiar with Arduino will know, there are just far too many examples to choose from, if you include all those provided by 3rd parties with their libraries.

To get a flavour of what this board is capable of, I decided to focus on a few examples that will highlight the Giga’s unique features.

TFT Display (bit-bashing speed test)

As noted in the previous section, the double row pin header (J7) is targeted at video output using the MIPI-DSI interface, but as I did not have anything suitable I thought to use a TFT screen to try and demonstrate just how fast this board was. I was not disappointed.

In this video, I used a very old 2.2” TFT shield, which routes the SPI bus to pins 3 to 5 for some reason. So you have to use software SPI, or bit bashing to get this TFT display driver to work.

It’s pretty clear to see that the Giga wins this speed race.

Audio using AdvancedAnalog library

Of course, with video you sometime want to incorporate audio and here I relied on the tutorial provided in the Giga Docs portal to guide me: https://docs.arduino.cc/tutorials/giga-r1-wifi/giga-audio

A separate software library called Arduino_AdvancedAnalog is required. The link is provided in the tutorial or you can search for it inside the Arduino IDE.

This library includes quite a few examples, which has been split into “Beginner” and “Advanced” examples. The example I tested was found in the beginner folder and is titled “Audio_Playback”. For some reason the AUDIO_SAMPLE.wav was corrupted but when I went to the relevant GitHub repository to download this specific file, the example worked perfectly.

One thing to bear in mind (and this is highlighted in the tutorial) is that the GIGA R1 does NOT have an amplifying circuit onboard. I found that PC speakers work perfectly, as shown in the video demo. I loved the sound quality.

While getting the speakers to work was quite straightforward, I could not find an off-the-shelf microphone that would work via the 3.5mm audio jack. This was a little disappointing. Instead you have to use the assigned pin headers, which opens up the question of why offer such an audio jack configuration.

USB Mass Storage

The next feature I wanted to try out was the USB Host capability via the USB-A connector. There is a tutorial provided for this too: https://docs.arduino.cc/tutorials/giga-r1-wifi/giga-usb

The example I tried, relied on the Arduino_USBHostMbed5 library. This library allows you to plug in a USB memory stick as a mass storage device, which I think is incredibly useful. This feature opens up a range of possibilities, like being able to store and use the DOOM computer game’s data files (note that a DOOM example is available on GitHub for the Giga but this uses the embedded flash).

Dual Core

The next feature I tried was the Giga R1 Dual core. Once again there is an excellent tutorial to get you started: https://docs.arduino.cc/tutorials/giga-r1-wifi/giga-dual-core

An important point to note here is the use of the UART Serial bus. This only works in the main M7 core.

Another important point to note is that you need to allocate flash memory for the M4 core before trying to upload any sketch to the M4 core, as the default option provides no memory allocation for the M4.

I then tried the default RPC examples but had little joy getting these to work. I tried the first example within the RPC examples, called BootM4_from_SDRAM, but I could not get this to work. I kept getting a "Please run WiFiFirmwareUpdater once" error, even though this instruction was done. The other two examples provided little to no instruction on what to do to get these to work and had no success either.

It's a real pity is that there is no linkage between the tutorial, which actually is very helpful, and the default RPC examples provided in the IDE.

What actually helped my understand how the RPC (Remote Procedure Call) library works was that I had spotted a query on the Arduino forum asking for help with getting ArduinoBLE to work on the M4 core. Through my endeavours to try and get this to work I learnt that the behaviour is quite similar to the Raspberry Pi Pico.

Camera (OV7675) Demo

{gallery:autoplay=false}Camera_DisplayViaProcessing

Now for the main course, which is to enjoy playing with the OV7675 camera module (this was provided as part of the roadtest package).

Will it be sweet or will it leave a sour taste in the mouth?

As with the other features, guidance is provided by way of a tutorial: https://docs.arduino.cc/tutorials/giga-r1-wifi/giga-camera

As there is a dedicated camera header provided it starts by simply plugging in the camera. This is a huge benefit. Otherwise you are grappling with 20 pins.

Thankfully this time there is a little bit of overlap between the single example explained in the tutorial (i.e. CameraCaptureRawBytes) and the 4 examples provided in the IDE.

This example is fairly straightforward but it is let down by silly errors in both the Arduino and the Processing examples. For example there is no ov7670.h file (as shown in the tutorial for Arduino). It should be ov767x.h. Then with the Processing example it has "useGrayScale = true" while the Arduino example is using Colour. So it does not work correctly.

These have to be fixed manually, which is easily done. Then you get a pretty image on your computer screen.

I then wanted to see if I could get the camera working on a TFT display and I initially looked at using GigaCameraDisplay example. This example was initially targeted at a STM display, but I now see that this example has very recently been changed to be specifically targeted at the DSI-MIPI interface. This is more useful, but I don't have a peripheral that works with DSI-MIPI.

So I will highlight my own example, which I created for a ILI9341 TFT display.

{gallery:autoplay=false}TFT Camera Display

At first I got the digital equivalent of white noise. This was resolved by changing the bit order (Endianness). This I was getting wonky images and then flipped images. These were resolved by changing the sorting algorithm.

Once this was resolved, I got a nice clean image.

Here is part 1 of the code:

/***************************************************
  This example uses the Adafruit ILI9341 library
  ----> www.adafruit.com/.../1651

  Check out the links above for our tutorials and wiring diagrams
  These displays use SPI to communicate, 4 or 5 pins are required to
  interface (RST is optional)
  Adafruit invests time and resources providing this open source code,
  please support Adafruit and open-source hardware by purchasing
  products from Adafruit!

  Adafruit libraries written by Limor Fried/Ladyada for Adafruit Industries.
  MIT license, all text above must be included in any redistribution
 ****************************************************/

#include "SPI.h"
#include "Adafruit_GFX.h"
#include "Adafruit_ILI9341.h"

#include "camera.h"
#include "ov767x.h"

// This define colour mode CAMERA_RGB565 (otherwise use CAMERA_GRAYSCALE for greyscale)
#define IMAGE_MODE CAMERA_RGB565

// For the TFT Display using SPI interface
#define TFT_RST     8
#define TFT_DC      9
#define TFT_CS      10
#define TFT_MOSI    11
#define TFT_CLK     13

const int CAMPIXELCNT = 320 * 240 * 2;        // 2 bytes per pixel

// uncomment the correct camera in use
OV7675 ov767x;
Camera cam(ov767x);

FrameBuffer fb(320,240,2);        // this defines a buffer to handle colour images - width, height & bits per pixel (change last parameter to 1 for greyscale)

unsigned long lastUpdate = 0;

// Using a breakout, change pins as desired
Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC, TFT_MOSI, TFT_CLK, TFT_RST, 12);

void blinkLED(uint32_t count = 0xFFFFFFFF)
{
  pinMode(LED_BUILTIN, OUTPUT);
  while (count--) {
    digitalWrite(LED_BUILTIN, LOW);  // turn the LED on (HIGH is the voltage level)
    delay(50);                       // wait for a second
    digitalWrite(LED_BUILTIN, HIGH); // turn the LED off by making the voltage LOW
    delay(50);                       // wait for a second
  }
}


void setup() {
  // put your setup code here, to run once:
  Serial.begin(230400);
  while(!Serial) continue;
  Serial.println("Camera display on TFT demo!");
 
  tft.begin();
 
  // Init the cam QVGA, 30FPS
  if (!cam.begin(CAMERA_R320x240, CAMERA_RGB565, 15)) {
    blinkLED();
  }
 
  blinkLED(5);

  tft.setRotation(0);

  tft.fillScreen(ILI9341_BLACK);
  yield();
  tft.fillScreen(ILI9341_RED);
  yield();
  tft.fillScreen(ILI9341_GREEN);
  yield();
  tft.fillScreen(ILI9341_BLUE);
  yield();
  tft.fillScreen(ILI9341_BLACK);
  yield();
}

void loop() {

  lastUpdate = millis();
 
  // Grab frame and write to serial
  if (cam.grabFrame(fb, 3000) == 0) {
    static FrameBuffer outfb(0x30000000);
    for (int i = 0; i < 320; i++) {
      for (int j = 0; j < 240; j++) {
        ((uint16_t*)outfb.getBuffer())[j + (i * 240)] = ((uint16_t*)fb.getBuffer())[319 - i + j * 320];
        uint8_t lo_hi[] = { (uint8_t)((uint16_t*)outfb.getBuffer())[j + i * 240], (uint8_t)(((uint16_t*)outfb.getBuffer())[j + i * 240] >> 8) };
        ((uint16_t*)outfb.getBuffer())[j + (i * 240)] = (lo_hi[0] << 8) + lo_hi[1];
      }
    }
    tft.drawRGBBitmap(0,0,(uint16_t*)outfb.getBuffer(), 240, 320);
    //delay(2000);
  } else {
    blinkLED(20);
  }

}

WiFi and Bluetooth

I then moved onto testing WiFi and Bluetooth. Once again I used the link on the main features section within the Arduino landing page as my guide. However, when clicking on WiFi and Bluetooth link, it opens up the Cheat Sheet instead of a dedicated tutorial. Instead you need to click on the examples link provided in the Cheat Sheet. This then opens up a range of examples.

For WiFi this opens up: https://docs.arduino.cc/tutorials/giga-r1-wifi/giga-wifi

While for Bluetooth it opens up the reference page for the ArduinoBLE library: https://reference.arduino.cc/reference/en/libraries/arduinoble/

It is worth noting what it tells us in the Arduino Giga datasheet, that only Bluetooth® Low Energy (version 5.X via Cordio stack, version 4.2 via Arduino Stack) is provided. No provision, as yet, has been made to offer Bluetooth classic (EDR), which should be possible with the Murata 1DX module.

I had no issues with trying out the examples here.

Ethernet using Ethernet Shield (SPI bus)

Finally, I've found an Arduino board where an Ethernet shield just works (I was using a shield with a WIZ5100 chip). Getting connected via Ethernet was quick for a change. Happy days.

It is worth noting that the STM32H7 chipset includes an Ethernet PHY/MAC so all you potentially need is an Ethernet transceiver to get connectivity. This is quite powerful.

CAN-Bus

Last but not least, I tried out CAN-bus. This needs a separate CAN-bus receiver. I just used an off-the-shelf module found on Amazon.

It did initially take awhile to figure out, but once I discovered the error in the pins_arduino.h it worked perfectly.

Reflections

I really, really enjoyed using this board. I really liked the little things they have added to the board itself. It is well thought out and it is aimed at making prototyping more efficient. Even the schematic had little additions that made life easier.

Yes, I discovered a few software niggles and bugs but as the community grabs hold of this board I believe these will be quickly resolved. There is plenty of capability here, from simply using pure Arduino code, through to embracing the more advanced software features of MbedOS as a proper RTOS. Then there are also options to use STM32H7 libraries itself, but that is really advanced.

Overall, I believe they have exposed the key features of the STM32H7 chipset, which will allow users to create some really powerful applications.

So has this board earned the right to be upgraded from a MEGA to a Giga?

Most definitely.

Anonymous
  • Thanks for the comment.

    The Arducam website still has this very same camera for sale on their website: https://www.arducam.com/product/ov7675-vga-color-20-pin-dvp-camera-module-for-arduino-giga-r1-wifi-board/

    At those low prices, they'll sell but as it's only 0.3MP maybe users will select something better on offer... like this one: https://www.arducam.com/product/2mp-gc2145-color-dvp-camera-module-for-arduino-giga-r1-wifi-board/

    And if seeking even better, like wanting to use a Raspberry Pi camera, who knows, maybe there is an opportunity to create a FPC Raspberry Pi Camera Interface converter board to allow a Raspberry Pi camera to work here. Shouldn't be too difficult.

    On the topic of using STM32Cube... Personally I find it a bit fiddly to get going. I have a STM32 NUCLEO-H7 board on my desk and it has taken me much more time to get to grips with it. I'm having far more fun with the Giga at the moment.

  • Good review. I was most curious to see your camera experience.

    I received one of these boards back in May. At the time, I reported multiple issues in the documentation directly to Arduino. So it is sad to see that they STILL have not fixed those examples--even though I provided the fixes.

    Additionally, I found the choice of camera pinout to be exceptionally strange. Aducam no longer sells those modules, and Arduino doesn't appear to have a plan to release their own. So you can only buy those modules from shady grey market stores.

    Overall, I was left wondering what the point of the camera and display headers were. It seems such a shame that with such a powerful microprocessor, there isn't a good way to get video in and out of it.

    At that point, I put the board back in the box, and it has sat on my shelf since then.

    I do have a project in mind, but I'll probably use STM32Cube since I'm only interested in harnessing the power of the STM32H7.

  • Interesting review - there was a lot of capability to explore.

  • Very useful and detailed review, thanks for sharing!