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
Copy file name to clipboardExpand all lines: content/hardware/03.nano/boards/nano-r4/tutorials/01.user-manual/content.md
+152-1Lines changed: 152 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,7 +31,7 @@ This user manual provides a comprehensive overview of the Nano R4 board, highlig
31
31
32
32
### Software Requirements
33
33
34
-
-[Arduino IDE 2.0+](https://www.arduino.cc/en/software) or [Arduino Web Editor](https://create.arduino.cc/editor)
34
+
-[Arduino IDE](https://www.arduino.cc/en/software) or [Arduino Cloud Editor](https://create.arduino.cc/editor)
35
35
-[Arduino UNO R4 Boards core](https://github.com/arduino/ArduinoCore-renesas)
36
36
37
37
***The Nano R4 is compatible with the complete Arduino ecosystem and can be programmed directly as a standalone device.***
@@ -2290,6 +2290,157 @@ When working with HID on the Nano R4, there are several key points to keep in mi
2290
2290
- The Nano R4 can function as both a keyboard and mouse simultaneously, allowing for complex automation sequences that combine typing, shortcuts and mouse control.
2291
2291
- Remember that different operating systems may have slightly different keyboard layouts and shortcuts, so test your HID projects on your target platform to ensure compatibility.
2292
2292
2293
+
## Qwiic Connector
2294
+
2295
+
The Nano R4 board features an onboard Qwiic connector that provides a simple, tool-free solution for connecting I²C devices. The Qwiic ecosystem, developed by SparkFun Electronics, has become an industry standard for rapid prototyping with I²C devices, allowing you to connect sensors, displays, and other peripherals without soldering or complex wiring. This makes it perfect for quickly building sensor networks, adding displays, or expanding your project's capabilities with minimal effort.
2296
+
2297
+

2298
+
2299
+
The Qwiic connector enhances the Nano R4's versatility by providing a dedicated interface for the extensive ecosystem of +3.3 VDC I²C modules. While the Nano R4's native +5 VDC operation ensures compatibility with classic Arduino shields and components, the Qwiic interface adds seamless integration with modern sensors and modules. The board includes built-in level translation between the +5 VDC microcontroller and the +3.3 VDC Qwiic bus, giving you the best of both worlds: full compatibility with traditional Arduino hardware on the main pins, plus instant access to the latest Qwiic-compatible devices.
2300
+
2301
+
### Qwiic Specifications
2302
+
2303
+
The Nano R4's Qwiic connector offers the following specifications:
| Pin Order |`GND`, `VCC`, `SDA`, `SCL`| Standard Qwiic pinout |
2312
+
2313
+
The Qwiic connector is a small 4-pin connector with a 1.00 mm pitch. The mechanical details of the connector can be found in the connector's [datasheet](https://www.jst-mfg.com/product/pdf/eng/eSH.pdf).
2314
+
2315
+
The pin layout of the Qwiic connector is the following:
2316
+
2317
+
-`GND`: Ground
2318
+
-`VCC`: +3.3 VDC power supply
2319
+
-`SDA`: I²C data line
2320
+
-`SCL`: I²C clock line
2321
+
2322
+
The `VCC` pin provides a stable +3.3 VDC output from the onboard regulator when the board is powered. The manufacturer part number of the Qwiic connector is [SM04B-SRSS-TB](https://www.jst-mfg.com/product/pdf/eng/eSH.pdf), and its matching cable assemblies use the [SHR-04V-S-B](https://www.jst-mfg.com/product/pdf/eng/eSH.pdf) receptacle.
2323
+
2324
+
### Understanding the Dual I²C Architecture
2325
+
2326
+
The Nano R4 implements a dual I²C bus architecture that separates +5 VDC and +3.3 VDC devices:
***__Important note__: The Qwiic connector uses `Wire1` object, not the standard `Wire` object. This is different from boards with a single I²C bus. Always use `Wire1.begin()` and related `Wire1` functions when communicating with Qwiic devices.***
2334
+
2335
+
### Connecting Qwiic Devices
2336
+
2337
+
Connecting Qwiic devices to your Nano R4 board is straightforward. Simply get a standard Qwiic cable (available in various lengths) and plug one end into the Nano R4's Qwiic connector and the other into your Qwiic device. Most Qwiic devices have two connectors, allowing you to daisy-chain multiple devices without any soldering or breadboarding. The polarized connectors prevent incorrect connections, making the setup process foolproof.
2338
+
2339
+

2340
+
2341
+
The Qwiic system's key advantages include:
2342
+
2343
+
-**Plug-and-play connectivity**: No breadboards, jumper wires, or soldering required
-**Daisy-chain capability**: Connect multiple devices in series
2346
+
-**Built-in pull-up resistors**: No external resistors needed
2347
+
-**Standard pinout**: Compatible across all Qwiic ecosystem devices
2348
+
2349
+
### Working with Qwiic Devices
2350
+
2351
+
The following example demonstrates how to use the [Arduino Modulino Movement](https://store.arduino.cc/collections/modulino/products/modulino-movement) sensor via the Qwiic connector:
2352
+
2353
+
```arduino
2354
+
/**
2355
+
Modulino Movement Example for the Arduino Nano R4 Board
2356
+
Name: nano_r4_modulino_movement.ino
2357
+
Purpose: This sketch demonstrates reading motion data from the
2358
+
Modulino Movement sensor via the Qwiic connector.
2359
+
2360
+
@author Arduino Product Experience Team
2361
+
@version 1.0 01/06/25
2362
+
*/
2363
+
2364
+
#include <Modulino.h>
2365
+
#include <Wire.h>
2366
+
2367
+
// Create Modulino Movement object
2368
+
ModulinoMovement movement;
2369
+
2370
+
// Variables for sensor data
2371
+
float x, y, z;
2372
+
float roll, pitch, yaw;
2373
+
2374
+
void setup() {
2375
+
// Initialize serial communication and wait up to 2.5 seconds for a connection
Serial.println("- Arduino Nano R4 - Modulino Movement Example started...");
2380
+
2381
+
// Initialize Wire1 for Qwiic connector
2382
+
Wire1.begin();
2383
+
2384
+
// Initialize Modulino system
2385
+
Modulino.begin();
2386
+
2387
+
// Initialize Movement sensor
2388
+
movement.begin();
2389
+
2390
+
Serial.println("- Modulino Movement connected successfully!");
2391
+
Serial.println("- Reading motion data...\n");
2392
+
}
2393
+
2394
+
void loop() {
2395
+
// Read new movement data from the sensor
2396
+
movement.update();
2397
+
2398
+
// Get acceleration values
2399
+
x = movement.getX();
2400
+
y = movement.getY();
2401
+
z = movement.getZ();
2402
+
2403
+
// Get gyroscope values
2404
+
roll = movement.getRoll();
2405
+
pitch = movement.getPitch();
2406
+
yaw = movement.getYaw();
2407
+
2408
+
// Display acceleration
2409
+
Serial.print("- Accel (g): X=");
2410
+
Serial.print(x, 2);
2411
+
Serial.print(" Y=");
2412
+
Serial.print(y, 2);
2413
+
Serial.print(" Z=");
2414
+
Serial.print(z, 2);
2415
+
2416
+
// Display gyroscope
2417
+
Serial.print(" | Gyro (dps): Roll=");
2418
+
Serial.print(roll, 1);
2419
+
Serial.print(" Pitch=");
2420
+
Serial.print(pitch, 1);
2421
+
Serial.print(" Yaw=");
2422
+
Serial.print(yaw, 1);
2423
+
2424
+
Serial.println();
2425
+
2426
+
// Update at 10Hz
2427
+
delay(100);
2428
+
}
2429
+
```
2430
+
2431
+
***To test this example, you need an [Arduino Modulino Movement](https://store.arduino.cc/collections/modulino/products/modulino-movement) connected to the Nano R4's Qwiic connector via a Qwiic cable. Install the Modulino library from the Arduino IDE Library Manager (Tools > Manage Libraries > Search "Modulino").***
2432
+
2433
+
You can open the Arduino IDE's Serial Monitor (Tools > Serial Monitor) to see the real-time acceleration and gyroscope data. Try moving or rotating the sensor to see the values change.
2434
+
2435
+

2436
+
2437
+
This example demonstrates the key aspects of using Qwiic devices with the Nano R4:
2438
+
2439
+
- Using `Wire1.begin()` instead of `Wire.begin()` for the Qwiic connector
2440
+
- Direct plug-and-play connection without additional wiring
2441
+
- Automatic +3.3 VDC power and level translation
2442
+
- Access to Arduino's ecosystem of Modulino sensors
2443
+
2293
2444
## Bootloader
2294
2445
2295
2446
The Nano R4 board features a built-in bootloader that enables sketch uploading directly from the Arduino IDE without requiring external programming hardware. The bootloader is a small program stored in a protected area of the RA4M1 microcontroller's flash memory that runs each time the board powers on or resets. It manages the critical communication between your computer and the board during sketch uploads, making the development process simple and accessible.
0 commit comments