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
@@ -47,22 +47,33 @@ This board is based on the [Arduino ESP32 Core](https://github.com/arduino/ardui
47
47
48
48

49
49
50
-
To install the core, go the **board manager** and search for **Nano ESP32**. If you need more instructions to install the core, please refer to the [Getting Started with Nano ESP32]() article.
50
+
To install the core, go the **board manager** and search for **Nano ESP32**. If you need more instructions to install the core, please refer to the [Getting Started with Nano ESP32](/tutorials/nano-esp32/getting-started-nano-esp32) article.
51
51
52
52
You can also program your board via the [Arduino Web Editor](arduino-cloud/getting-started/getting-started-web-editor), an online IDE.
53
53
54
54
## API
55
55
56
-
Please refer to the well documented [ESP32-S3 API](https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/index.html#) for more information regarding the API and accessing the boards peripherals.
56
+
The Nano ESP32 can be programmed using the same API as for other Arduino boards (see [language reference](https://www.arduino.cc/reference/en/)).
57
57
58
-
To access the ESP32-S3's peripherals (e.g. ADC, I2C, SPI), refer to the [Peripherals API section](https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/peripherals/index.html#).
58
+
However, the ESP32 platform provides additional libraries and built-in functionalities that may not available in the standard Arduino API.
59
59
60
+
For more information, see the [ESP32-S3 API](https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/index.html#)
61
+
62
+
### Peripherals API
63
+
64
+
To learn more about the ESP32-S3's peripherals (e.g. ADC, I2C, SPI, I2S, RTC), refer to the [Peripherals API section](https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/peripherals/index.html#).
65
+
66
+
### Sleep Modes
67
+
68
+
The Nano ESP32 can be programmed to draw a minimal amount of power, making it suitable for power constrained designs, such as solar/battery powered projects.
69
+
70
+
The [Sleep Modes](https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-reference/system/sleep_modes.html) section in the ESP32 docs explains how to configure your board to draw minimal power, introducing the **light sleep** and **deep sleep**
60
71
61
72
## MicroPython
62
73
63
74
The Nano ESP32 has support for MicroPython, a micro-implementation of Python that can easily be installed on your board.
64
75
65
-
To get started with MicroPython, please visit [MicroPython 101](), a course dedicated towards learning MicroPython on the Nano ESP32.
76
+
To get started with MicroPython, please visit [MicroPython 101](/micropython-course), a course dedicated towards learning MicroPython on the Nano ESP32.
66
77
67
78
In this course, you will fundamental knowledge to get started, as well as a large selection of examples for popular third-party components.
68
79
@@ -97,53 +108,178 @@ This measure is taken to prevent the board's microcontroller from accidentially
97
108
98
109
The Nano ESP32 has two headers: the **analog** and **digital**. Listed here are the **default** pins that comply with previous Nano form factor designs.
| A4 | Analog | Analog input 4 / **I2C** Serial Datal (SDA) |
167
+
| A5 | Analog | Analog input 5 / **I2C** Serial Clock (SCL) |
168
+
| A6 | Analog | Analog input 6 |
169
+
| A7 | Analog | Analog input 7 |
170
+
171
+
### PWM
172
+
173
+
Pulse width modulation (PWM) is supported on all digital pins (D0-D13).
174
+
175
+
### Boot Pins
140
176
141
177
To enter bootloader mode (chip boot mode), you can use either the BOOT0 or BOOT1 pins, which are connected to the ESP32-S3's `GPIO0` and `GPIO46`.
142
178
143
179
Shorting these to GND + pressing the reset button will enter a bootloader mode. Note that while shorting these pins, a corresponding LED will
144
180
145
181
You can read more about different this in the [Strapping Pins section](https://www.espressif.com/sites/default/files/documentation/esp32-s3_datasheet_en.pdf#page=23) in the ESP32-S3's datasheet.
146
182
183
+
## I2C
184
+
185
+
The default pins used for I2C on the Nano ESP32 are the following:
186
+
- SDA - A4
187
+
- SCL - A5
188
+
189
+
![I2C Pins]()
190
+
191
+
To connect I2C devices you will need to include the [Wire](https://www.arduino.cc/reference/en/language/functions/communication/wire/) library at the top of your sketch.
192
+
193
+
```arduino
194
+
#include <Wire.h>
195
+
```
196
+
197
+
Inside `void setup()` you need to initialize the library, and initialize the I2C port you want to use.
198
+
199
+
```arduino
200
+
Wire.begin() //SDA & SDL
201
+
```
202
+
203
+
And to write something to a device connected via I2C, we can use the following commands:
204
+
205
+
```arduino
206
+
Wire.beginTransmission(1); //begin transmit to device 1
The pins used for UART on the Nano ESP32 are the following:
255
+
256
+
| Pin | Function |
257
+
| --- | -------- |
258
+
| D0 | RX0 |
259
+
| D1 | TX0 |
260
+
261
+
To send and receive data through UART, we will first need to set the baud rate inside `void setup()`. Note that when using the UART (RX/TX pins), we use the `Serial1` object.
262
+
263
+
```arduino
264
+
Serial1.begin(9600);
265
+
```
266
+
267
+
To read incoming data, we can use a while loop() to read each individual character and add it to a string.
268
+
269
+
```arduino
270
+
while(Serial1.available()){
271
+
delay(2);
272
+
char c = Serial1.read();
273
+
incoming += c;
274
+
}
275
+
```
276
+
277
+
And to write something, we can use the following command:
278
+
279
+
```arduino
280
+
Serial1.write("Hello world!");
281
+
```
282
+
147
283
## IO Mux & GPIO Matrix
148
284
149
285
The ESP32-S3 SoC features an IO mux (input/output multiplexer) and a GPIO matrix. The IO mux acts as a data selector and allows for different peripherals to be connected to a physical pin.
0 commit comments