You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -43,7 +34,7 @@ You can also visit the documentation platform for the [Arduino GIGA R1](/hardwar
43
34
## Datasheet
44
35
The full datasheets are available as a downloadable PDF from the link below:
45
36
46
-
-[Download the Arduino GIGA R1 datasheet]()
37
+
-[Download the Arduino GIGA R1 datasheet](docs.arduino.cc/resources/datasheets/ABX00067-datasheet.pdf)
47
38
48
39
## Power Supply
49
40
@@ -69,7 +60,7 @@ The **Arduino GIGA R1** can be programmed through:
69
60
To set the board up to be programmed with the OpenMV IDE in MicroPython, check out the [Boot0 section](#boot0) of this article.
70
61
71
62
### Core
72
-
The Arduino GIGA R1 uses the [GIGA core]().
63
+
The Arduino GIGA R1 uses the [Arduino Core for mbed devices](https://github.com/arduino/ArduinoCore-mbed).
73
64
74
65
### Boot0
75
66
Pressing and holding the button labelled `BOOT0` on the board while powering the board will boot it into DFU-mode (Device Firmware Update), letting you reflash the bootloader without the use of external hardware, if you were to ever need to.
@@ -78,15 +69,12 @@ Pressing and holding the button labelled `BOOT0` on the board while powering the
78
69
79
70
The state of this button can also be read from a sketch while it is running, giving you a basic interactive component without needing to do any wiring.
80
71
81
-
Booting the board into DFU-mode will also let you configure it with the OpenMV IDE to program the board with MicroPython, to for example deploy a trained ML model analysing a real time camera feed.
82
-
83
-
To learn more about this feature, and how you can use it, check out [this tutorial.]()
84
-
85
-
## Arduino IoT Cloud
86
-
87
-
The Arduino GIGA R1 is compatible with the [Arduino IoT Cloud](https://create.arduino.cc/iot/things), a cloud service that allows you to create IoT applications in just minutes.
72
+
To read the state of the Boot0 button in your sketch, you use this line of code:
73
+
```arduino
74
+
digitalRead(PC_13);
75
+
```
88
76
89
-
If you need help to get started, you can go through the [Arduino IoT Cloud getting started guide](https://docs.arduino.cc/arduino-cloud/getting-started/iot-cloud-getting-started).
77
+
Booting the board into DFU-mode will also let you configure it with the OpenMV IDE to program the board with MicroPython, to for example deploy a trained ML model analysing a real time camera feed.
90
78
91
79
## STM32H747XI Microcontroller
92
80
@@ -158,44 +146,106 @@ In the coming sections we will provide resources and basic information on how to
158
146
159
147
160
148
### Output
149
+
In order to output audio from the DAC, you can use the `AdvancedAnalogRedux` library from Arduino. You will need to connect a speaker to your board either with the headphone jack or the dac pins.
161
150
162
-
### Input
151
+
Include the library and setup the DAC with the following code in the beginning of your sketch, outside of the `void setup()` function:
163
152
164
-
## MIPI Display Interface
165
-
The **STM32H747XI** has an internal 2D graphics accelerator with support for resolutions up to 1024x768, it also has the ability to encode and decode JPEG codec. This is what allows the **Arduino GIGA R1** to boast a 2 lane MIPI display interface.
153
+
```arduino
154
+
#include "AdvancedDAC.h"
166
155
167
-
This means that the **Arduino GIGA R1** is capable of driving a touch-display large enough to build a substantial user interface. The [LVGL](https://lvgl.io) library is a powerful tool to quickly build a responsive interface.
156
+
AdvancedDAC dac(A12);
157
+
158
+
```
168
159
169
-
Check out [this tutorial]() to learn how to build an interface with the LVGL library.
160
+
Then, initialize the library, and check that everything went as expected with the following piece of code:
170
161
171
-
## USBHost
172
-
The USB-A port you find on the **Arduino GIGA R1** is configured as a host-only port, meaning that it cannot be used to program the board, instead it is used to connect peripherals to the board. The board can receive keyboard input, or be used to read files off of a USB flash drive, if you for example want to play audio files on a speaker you have plugged in the audio jack.
162
+
```arduino
163
+
if (!dac.begin(AN_RESOLUTION_12, 8000, 32, 64)) {
164
+
Serial.println("Failed to start DAC!");
165
+
while (1);
166
+
}
167
+
```
168
+
169
+
Then lastly, add the following code to `void loop()` to start:
170
+
```arduino
171
+
if (dac.available()) {
172
+
173
+
// Get a free buffer for writing
174
+
SampleBuffer buf = dac.dequeue();
175
+
176
+
// Write data to buffer
177
+
for (int i=0; i<buf.size(); i++) {
178
+
buf.data()[i] = (i % 2 == 0) ? 0: 0xfff;
179
+
}
180
+
181
+
// Write the buffer data to DAC
182
+
dac.write(buf);
183
+
}
184
+
```
185
+
186
+
The options for audio playback and generation on your Arduino GIGA R1 are **much** more vast than this, however. To learn about audio playback in depth, check out the [audio guide](../giga-audio/content.md).
173
187
174
-
-[Library for USB-Host]()
188
+
### Input
189
+
The audio jack on the Arduino GIGA R1 is not just connected to the DAC pins, however, but are also connected to pin A7, for microphone capabilities.
175
190
176
-
To learn in depth about how to use this powerful feature, read the [USBHost Guide.]()
191
+
To take advantage of this, you can use the `AdvancedAnalogRedux` library from Arduino, start off by including the library and setting up the pin as an advanced ADC pin in the beginning of your sketch, outside of `void setup()`.
177
192
178
-
## Dual Core Processing
179
-
As mentioned previously, the microcontroller on the **Arduino GIGA R1** is a dual core processor, and can therefore run two separate programs simultaneously. The cores can be programmed separately and are capable of sharing information with each other.
193
+
```arduino
194
+
#include "AdvancedADC.h"
180
195
181
-
When writing a program that is supposed to use both cores, you will be required to forcefully boot the second core. For most programs there really is no reason to use both, and for that reason it is by default unbooted. However it is a powerful option to have, and one that you can easily make use of if you want to continuously monitor and process sensor values.
196
+
AdvancedADC adc(A7);
197
+
```
182
198
183
-
You boot the second core by adding the function:
199
+
Now, initialise the library and run a check to make sure everything went as expected with the following code within `void setup()`:
184
200
```arduino
185
-
bootM4();
201
+
202
+
Serial.begin(9600);
203
+
204
+
// Resolution, sample rate, number of samples per channel, and queue depth of the ADC
205
+
if (!adc.begin(AN_RESOLUTION_16, 16000, 32, 64)) {
206
+
Serial.println("Failed to start analog acquisition!");
207
+
while (1);
208
+
}
186
209
```
187
-
at the beginning of the sketch for your primary core, in the board selector you choose to program either the primary M7 core, or the secondary M4 core.
210
+
Finally, read the ADC, and store it in a way that you can use it, do this within `void loop()`:
211
+
```arduino
212
+
if (adc.available()) {
213
+
SampleBuffer buf = adc.read();
214
+
215
+
// Print first sample
216
+
Serial.println(buf[0]);
217
+
218
+
// Release the buffer to return it to the pool
219
+
buf.release();
220
+
```
221
+
222
+
The options for audio input on your Arduino GIGA R1 are **much** more vast than this, however. To learn about audio recording in depth, check out the [audio guide](../giga-audio/content.md).
223
+
224
+
## MIPI Display Interface
225
+
The **STM32H747XI** has an internal 2D graphics accelerator with support for resolutions up to 1024x768, it also has the ability to encode and decode JPEG codec. This is what allows the **Arduino GIGA R1** to boast a 2 lane MIPI display interface.
226
+
227
+
This means that the **Arduino GIGA R1** is capable of driving a touch-display large enough to build a substantial user interface. The [LVGL](https://lvgl.io) library is a powerful tool to quickly build a responsive interface.
188
228
189
-
It is also possible to program both cores with just one sketch, though this quickly becomes an unwieldy, inefficient and **difficult** way to work.
229
+
## USBHost
230
+
The USB-A port you find on the **Arduino GIGA R1** is configured as a host-only port, meaning that it cannot be used to program the board, instead it is used to connect peripherals to the board. The board can receive keyboard input effectively enabling a few hundred more inputs without any wiring, or be used to read files off of a USB flash drive, if you for example want to play audio files on a speaker you have plugged in the audio jack.
190
231
191
-
To learn more about dual core processing on the **Arduino GIGA R1**, check out the tutorial below:
232
+
There are several libraries you can use for the USBHost capabilities of the Arduino GIGA R1:
Some of these libraries are built in to the core and therefore you won't be required to download them separately.
240
+
241
+
To learn in depth about how to use these powerful features, read the [USBHost Guide](../giga-usb/giga-usb.md) that contains in-depth walkthroughs for each of them.
194
242
195
243
## RTC
196
244
197
245
The **Arduino GIGA R1** features an RTC pin, giving you the ability to power the timekeeping circuitry with a coin cell battery to keep the time even when your board is turned off, for low power timekeeping.
198
246
247
+

248
+
199
249
The following sketch will continuously print the time in the Serial monitor.
200
250
```arduino
201
251
#include "mbed.h"
@@ -241,18 +291,16 @@ String getLocaltime()
241
291
242
292
To get accurate time, you'll want to change the values in `void RTCset()` to whatever time it is when you're starting this clock. As long as the VRTC pin is connected to power, the clock will keep ticking and time will be kept accurately.
243
293
244
-
To learn more about the Arduino GIGA R1's RTC capabilities, check out [this tutorial]() for an in-depth guide
245
-
246
294
## Camera Interface
247
295
The Arduino GIGA features an onboard arducam compatible connector, with support for **parallel**.
248
296
249
297
Programming the board in the **MicroPython** language using the **OpenMV IDE** easily lets you get started with a neural network analysing a realtime camera feed with ML.
250
298
299
+
To learn more about the camera capabilities of the Arduino GIGA R1, check out the [GIGA Camera Guide](../giga-camera/giga-camera.md)
300
+
251
301
## JTAG
252
302
The **Arduino GIGA R1** features a 2x5 pin JTAG (Joint Test Action Group) connector, giving advanced debug functionalities for more advanced users.
253
303
254
-
Check out [this tutorial]() to learn how to use the JTAG connector on the **Arduino GIGA R1**.
255
-
256
304

257
305
258
306
## CAN Bus
@@ -268,10 +316,6 @@ This makes the **Arduino GIGA R1** a powerful option for complex multilayered sy
268
316
269
317
The CAN pins on the **Arduino GIGA R1** are labelled `CANRX` and `CANTX`
270
318
271
-
For more information on how to use the CAN bus on your **Arduino GIGA R1**, check out [this tutorial.]()
272
-
273
-
-[Using the CAN bus on the Arduino GIGA]()
274
-
275
319
## SPI
276
320
The **Arduino GIGA R1** features two separate SPI (Serial Peripheral Interface) buses, one is configured on the 6 pin header labelled SPI, and the other is broken out into pin connections on the board.
277
321
@@ -539,8 +583,6 @@ On the **Arduino GIGA R1** you will find a pin labelled **"OFF"**. If you connec
539
583
540
584
You can install a flip-switch to the board to let you turn your device on and off easily, which can be a handy option for a more permanent fixture.
541
585
542
-
Read more about this feature, and learn when and how to use it by checking out this [this tutorial.]()
0 commit comments