Skip to content

Commit 873b01f

Browse files
authored
Merge branch 'espressif:master' into master
2 parents 8cace55 + 099b432 commit 873b01f

File tree

18 files changed

+538
-98
lines changed

18 files changed

+538
-98
lines changed

.github/ISSUE_TEMPLATE/Issue-report.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ body:
4141
options:
4242
- latest master (checkout manually)
4343
- latest development Release Candidate (RC-X)
44+
- v2.0.11
45+
- v2.0.10
4446
- v2.0.9
4547
- v2.0.8
4648
- v2.0.7

.github/workflows/docs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717

1818
build-docs:
1919
name: Build ReadTheDocs
20-
runs-on: ubuntu-latest
20+
runs-on: ubuntu-22.04
2121
defaults:
2222
run:
2323
shell: bash
@@ -27,7 +27,7 @@ jobs:
2727
submodules: true
2828
- uses: actions/setup-python@v4
2929
with:
30-
python-version: '3.x'
30+
python-version: '3.10'
3131
- name: Build
3232
run: |
3333
sudo apt update

.readthedocs.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# .readthedocs.yaml
2+
# Read the Docs configuration file
3+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
4+
5+
# Required
6+
version: 2
7+
8+
# Set the version of Python and other tools you might need
9+
build:
10+
os: ubuntu-22.04
11+
tools:
12+
python: "3.10"
13+
14+
# Build documentation in the docs/ directory with Sphinx
15+
sphinx:
16+
configuration: docs/source/conf.py
17+
18+
python:
19+
install:
20+
- requirements: docs/requirements.txt

.readthedocs.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# .readthedocs.yaml
2+
# Read the Docs configuration file
3+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
4+
5+
# Required
6+
version: 2
7+
8+
# Set the version of Python and other tools you might need
9+
build:
10+
os: ubuntu-22.04
11+
tools:
12+
python: "3.10"
13+
14+
# Build documentation in the docs/ directory with Sphinx
15+
sphinx:
16+
configuration: docs/conf.py
17+
18+
# We recommend specifying your dependencies to enable reproducible builds:
19+
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
20+
# python:
21+
# install:
22+
# - requirements: docs/requirements.txt

boards.txt

Lines changed: 78 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11755,7 +11755,7 @@ esp32-gateway.menu.Revision.RevC=Revision C or older
1175511755
esp32-gateway.menu.Revision.RevC.build.board=ESP32_GATEWAY_C
1175611756
esp32-gateway.menu.Revision.RevE=Revision E
1175711757
esp32-gateway.menu.Revision.RevE.build.board=ESP32_GATEWAY_E
11758-
esp32-gateway.menu.Revision.RevF=Revision F
11758+
esp32-gateway.menu.Revision.RevF=Revision F or newer
1175911759
esp32-gateway.menu.Revision.RevF.build.board=ESP32_GATEWAY_F
1176011760

1176111761
esp32-gateway.build.f_cpu=240000000L
@@ -11770,6 +11770,8 @@ esp32-gateway.menu.FlashFreq.80.build.flash_freq=80m
1177011770
esp32-gateway.menu.FlashFreq.40=40MHz
1177111771
esp32-gateway.menu.FlashFreq.40.build.flash_freq=40m
1177211772

11773+
esp32-gateway.menu.UploadSpeed.921600=921600
11774+
esp32-gateway.menu.UploadSpeed.921600.upload.speed=921600
1177311775
esp32-gateway.menu.UploadSpeed.115200=115200
1177411776
esp32-gateway.menu.UploadSpeed.115200.upload.speed=115200
1177511777

@@ -13407,6 +13409,81 @@ stamp-s3.menu.EraseFlash.none.upload.erase_cmd=
1340713409
stamp-s3.menu.EraseFlash.all=Enabled
1340813410
stamp-s3.menu.EraseFlash.all.upload.erase_cmd=-e
1340913411

13412+
###############################################################
13413+
13414+
m5stamp-pico.name=M5Stamp-Pico
13415+
13416+
m5stamp-pico.bootloader.tool=esptool_py
13417+
m5stamp-pico.bootloader.tool.default=esptool_py
13418+
13419+
m5stamp-pico.upload.tool=esptool_py
13420+
m5stamp-pico.upload.tool.default=esptool_py
13421+
m5stamp-pico.upload.tool.network=esp_ota
13422+
13423+
m5stamp-pico.upload.maximum_size=1310720
13424+
m5stamp-pico.upload.maximum_data_size=327680
13425+
m5stamp-pico.upload.wait_for_upload_port=true
13426+
m5stamp-pico.upload.flags=
13427+
m5stamp-pico.upload.extra_flags=
13428+
13429+
m5stamp-pico.serial.disableDTR=true
13430+
m5stamp-pico.serial.disableRTS=true
13431+
13432+
m5stamp-pico.build.tarch=xtensa
13433+
m5stamp-pico.build.bootloader_addr=0x1000
13434+
m5stamp-pico.build.target=esp32
13435+
m5stamp-pico.build.mcu=esp32
13436+
m5stamp-pico.build.core=esp32
13437+
m5stamp-pico.build.variant=m5stack_stamp_pico
13438+
m5stamp-pico.build.board=M5Stamp_Pico
13439+
13440+
m5stamp-pico.build.f_cpu=240000000L
13441+
m5stamp-pico.build.flash_size=4MB
13442+
m5stamp-pico.build.flash_freq=80m
13443+
m5stamp-pico.build.flash_mode=dio
13444+
m5stamp-pico.build.boot=dio
13445+
m5stamp-pico.build.partitions=default
13446+
m5stamp-pico.build.defines=
13447+
13448+
m5stamp-pico.menu.PartitionScheme.default=Default
13449+
m5stamp-pico.menu.PartitionScheme.default.build.partitions=default
13450+
m5stamp-pico.menu.PartitionScheme.no_ota=No OTA (Large APP)
13451+
m5stamp-pico.menu.PartitionScheme.no_ota.build.partitions=no_ota
13452+
m5stamp-pico.menu.PartitionScheme.no_ota.upload.maximum_size=2097152
13453+
m5stamp-pico.menu.PartitionScheme.min_spiffs=Minimal SPIFFS (Large APPS with OTA)
13454+
m5stamp-pico.menu.PartitionScheme.min_spiffs.build.partitions=min_spiffs
13455+
m5stamp-pico.menu.PartitionScheme.min_spiffs.upload.maximum_size=1966080
13456+
13457+
13458+
m5stamp-pico.menu.UploadSpeed.1500000=1500000
13459+
m5stamp-pico.menu.UploadSpeed.1500000.upload.speed=1500000
13460+
m5stamp-pico.menu.UploadSpeed.750000=750000
13461+
m5stamp-pico.menu.UploadSpeed.750000.upload.speed=750000
13462+
m5stamp-pico.menu.UploadSpeed.500000=500000
13463+
m5stamp-pico.menu.UploadSpeed.500000.upload.speed=500000
13464+
m5stamp-pico.menu.UploadSpeed.250000=250000
13465+
m5stamp-pico.menu.UploadSpeed.250000.upload.speed=250000
13466+
m5stamp-pico.menu.UploadSpeed.115200=115200
13467+
m5stamp-pico.menu.UploadSpeed.115200.upload.speed=115200
13468+
13469+
m5stamp-pico.menu.DebugLevel.none=None
13470+
m5stamp-pico.menu.DebugLevel.none.build.code_debug=0
13471+
m5stamp-pico.menu.DebugLevel.error=Error
13472+
m5stamp-pico.menu.DebugLevel.error.build.code_debug=1
13473+
m5stamp-pico.menu.DebugLevel.warn=Warn
13474+
m5stamp-pico.menu.DebugLevel.warn.build.code_debug=2
13475+
m5stamp-pico.menu.DebugLevel.info=Info
13476+
m5stamp-pico.menu.DebugLevel.info.build.code_debug=3
13477+
m5stamp-pico.menu.DebugLevel.debug=Debug
13478+
m5stamp-pico.menu.DebugLevel.debug.build.code_debug=4
13479+
m5stamp-pico.menu.DebugLevel.verbose=Verbose
13480+
m5stamp-pico.menu.DebugLevel.verbose.build.code_debug=5
13481+
13482+
m5stamp-pico.menu.EraseFlash.none=Disabled
13483+
m5stamp-pico.menu.EraseFlash.none.upload.erase_cmd=
13484+
m5stamp-pico.menu.EraseFlash.all=Enabled
13485+
m5stamp-pico.menu.EraseFlash.all.upload.erase_cmd=-e
13486+
1341013487
##############################################################
1341113488

1341213489
odroid_esp32.name=ODROID ESP32

cores/esp32/esp32-hal-matrix.c

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717

1818
#include "esp_system.h"
1919
#ifdef ESP_IDF_VERSION_MAJOR // IDF 4+
20+
#include "soc/gpio_pins.h"
2021
#if CONFIG_IDF_TARGET_ESP32 // ESP32/PICO-D4
21-
#include "esp32/rom/gpio.h"
2222
#elif CONFIG_IDF_TARGET_ESP32S2
2323
#include "esp32s2/rom/gpio.h"
2424
#elif CONFIG_IDF_TARGET_ESP32S3
@@ -30,11 +30,10 @@
3030
#endif
3131
#else // ESP32 Before IDF 4.0
3232
#include "rom/gpio.h"
33+
#define GPIO_MATRIX_CONST_ZERO_INPUT GPIO_FUNC_IN_LOW
34+
#define GPIO_MATRIX_CONST_ONE_INPUT GPIO_FUNC_IN_HIGH
3335
#endif
3436

35-
#define MATRIX_DETACH_OUT_SIG 0x100
36-
#define MATRIX_DETACH_IN_LOW_PIN 0x30
37-
#define MATRIX_DETACH_IN_LOW_HIGH 0x38
3837

3938
void ARDUINO_ISR_ATTR pinMatrixOutAttach(uint8_t pin, uint8_t function, bool invertOut, bool invertEnable)
4039
{
@@ -43,7 +42,7 @@ void ARDUINO_ISR_ATTR pinMatrixOutAttach(uint8_t pin, uint8_t function, bool inv
4342

4443
void ARDUINO_ISR_ATTR pinMatrixOutDetach(uint8_t pin, bool invertOut, bool invertEnable)
4544
{
46-
gpio_matrix_out(pin, MATRIX_DETACH_OUT_SIG, invertOut, invertEnable);
45+
gpio_matrix_out(pin, SIG_GPIO_OUT_IDX, invertOut, invertEnable);
4746
}
4847

4948
void ARDUINO_ISR_ATTR pinMatrixInAttach(uint8_t pin, uint8_t signal, bool inverted)
@@ -53,7 +52,7 @@ void ARDUINO_ISR_ATTR pinMatrixInAttach(uint8_t pin, uint8_t signal, bool invert
5352

5453
void ARDUINO_ISR_ATTR pinMatrixInDetach(uint8_t signal, bool high, bool inverted)
5554
{
56-
gpio_matrix_in(high?MATRIX_DETACH_IN_LOW_HIGH:MATRIX_DETACH_IN_LOW_PIN, signal, inverted);
55+
gpio_matrix_in(high?GPIO_MATRIX_CONST_ONE_INPUT:GPIO_MATRIX_CONST_ZERO_INPUT, signal, inverted);
5756
}
5857
/*
5958
void ARDUINO_ISR_ATTR intrMatrixAttach(uint32_t source, uint32_t inum){

docs/source/api/gpio.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ The GPIO peripheral on the ESP32 supports interruptions.
8787
attachInterrupt
8888
***************
8989

90-
The function ``attachInterruptArg`` is used to attach the interrupt to the defined pin.
90+
The function ``attachInterrupt`` is used to attach the interrupt to the defined pin.
9191

9292
.. code-block:: arduino
9393

docs/source/api/wifi.rst

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,15 @@ Get the softAP subnet CIDR.
222222
223223
uint8_t softAPSubnetCIDR();
224224
225+
softAPSubnetMask
226+
****************
227+
228+
Get the softAP subnet mask.
229+
230+
.. code-block:: arduino
231+
232+
IPAddress softAPSubnetMask();
233+
225234
softAPenableIpV6
226235
****************
227236

Original file line numberDiff line numberDiff line change
@@ -1,75 +1,75 @@
1-
/*
2-
Simple Sketch for testing HardwareSerial with different CPU Frequencies
3-
Changing the CPU Frequency may affect peripherals and Wireless functionality
4-
In ESP32 Arduino, UART shall work correctly in order to let the user see DGB info
5-
and other application messages.
6-
7-
CPU Frequency is usually lowered in sleep modes
8-
and some other Low Power configurations
9-
10-
*/
11-
12-
int cpufreqs[6] = {240, 160, 80, 40, 20, 10};
13-
#define NUM_CPU_FREQS (sizeof(cpufreqs) / sizeof(int))
14-
15-
void setup() {
16-
17-
Serial.begin(115200);
18-
delay(1000);
19-
Serial.println("\n Starting...\n");
20-
Serial.flush();
21-
22-
// initial information
23-
uint32_t Freq = getCpuFrequencyMhz();
24-
Serial.print("CPU Freq = ");
25-
Serial.print(Freq);
26-
Serial.println(" MHz");
27-
Freq = getXtalFrequencyMhz();
28-
Serial.print("XTAL Freq = ");
29-
Serial.print(Freq);
30-
Serial.println(" MHz");
31-
Freq = getApbFrequency();
32-
Serial.print("APB Freq = ");
33-
Serial.print(Freq);
34-
Serial.println(" Hz");
35-
delay(500);
36-
37-
// ESP32-C3 and other RISC-V target may not support 240MHz
38-
#ifdef CONFIG_IDF_TARGET_ESP32C3
39-
uint8_t firstFreq = 1;
40-
#else
41-
uint8_t firstFreq = 0;
42-
#endif
43-
44-
// testing HardwareSerial for all possible CPU/APB Frequencies
45-
for (uint8_t i = firstFreq; i < NUM_CPU_FREQS; i++) {
46-
Serial.printf("\n------- Trying CPU Freq = %d ---------\n", cpufreqs[i]);
47-
Serial.flush(); // wait to empty the UART FIFO before changing the CPU Freq.
48-
setCpuFrequencyMhz(cpufreqs[i]);
49-
Serial.updateBaudRate(115200);
50-
51-
Freq = getCpuFrequencyMhz();
52-
Serial.print("CPU Freq = ");
53-
Serial.print(Freq);
54-
Serial.println(" MHz");
55-
Freq = getXtalFrequencyMhz();
56-
Serial.print("XTAL Freq = ");
57-
Serial.print(Freq);
58-
Serial.println(" MHz");
59-
Freq = getApbFrequency();
60-
Serial.print("APB Freq = ");
61-
Serial.print(Freq);
62-
Serial.println(" Hz");
63-
if (i < NUM_CPU_FREQS - 1) {
64-
Serial.println("Moving to the next frequency after a pause of 2 seconds.");
65-
delay(2000);
66-
}
67-
}
68-
Serial.println("\n-------------------\n");
69-
Serial.println("End of testing...");
70-
Serial.println("\n-------------------\n");
71-
}
72-
73-
void loop() {
74-
// Nothing here so far
75-
}
1+
/*
2+
Simple Sketch for testing HardwareSerial with different CPU Frequencies
3+
Changing the CPU Frequency may affect peripherals and Wireless functionality
4+
In ESP32 Arduino, UART shall work correctly in order to let the user see DGB info
5+
and other application messages.
6+
7+
CPU Frequency is usually lowered in sleep modes
8+
and some other Low Power configurations
9+
10+
*/
11+
12+
int cpufreqs[6] = {240, 160, 80, 40, 20, 10};
13+
#define NUM_CPU_FREQS (sizeof(cpufreqs) / sizeof(int))
14+
15+
void setup() {
16+
17+
Serial.begin(115200);
18+
delay(1000);
19+
Serial.println("\n Starting...\n");
20+
Serial.flush();
21+
22+
// initial information
23+
uint32_t Freq = getCpuFrequencyMhz();
24+
Serial.print("CPU Freq = ");
25+
Serial.print(Freq);
26+
Serial.println(" MHz");
27+
Freq = getXtalFrequencyMhz();
28+
Serial.print("XTAL Freq = ");
29+
Serial.print(Freq);
30+
Serial.println(" MHz");
31+
Freq = getApbFrequency();
32+
Serial.print("APB Freq = ");
33+
Serial.print(Freq);
34+
Serial.println(" Hz");
35+
delay(500);
36+
37+
// ESP32-C3 and other RISC-V target may not support 240MHz
38+
#ifdef CONFIG_IDF_TARGET_ESP32C3
39+
uint8_t firstFreq = 1;
40+
#else
41+
uint8_t firstFreq = 0;
42+
#endif
43+
44+
// testing HardwareSerial for all possible CPU/APB Frequencies
45+
for (uint8_t i = firstFreq; i < NUM_CPU_FREQS; i++) {
46+
Serial.printf("\n------- Trying CPU Freq = %d ---------\n", cpufreqs[i]);
47+
Serial.flush(); // wait to empty the UART FIFO before changing the CPU Freq.
48+
setCpuFrequencyMhz(cpufreqs[i]);
49+
Serial.updateBaudRate(115200);
50+
51+
Freq = getCpuFrequencyMhz();
52+
Serial.print("CPU Freq = ");
53+
Serial.print(Freq);
54+
Serial.println(" MHz");
55+
Freq = getXtalFrequencyMhz();
56+
Serial.print("XTAL Freq = ");
57+
Serial.print(Freq);
58+
Serial.println(" MHz");
59+
Freq = getApbFrequency();
60+
Serial.print("APB Freq = ");
61+
Serial.print(Freq);
62+
Serial.println(" Hz");
63+
if (i < NUM_CPU_FREQS - 1) {
64+
Serial.println("Moving to the next frequency after a pause of 2 seconds.");
65+
delay(2000);
66+
}
67+
}
68+
Serial.println("\n-------------------\n");
69+
Serial.println("End of testing...");
70+
Serial.println("\n-------------------\n");
71+
}
72+
73+
void loop() {
74+
// Nothing here so far
75+
}

0 commit comments

Comments
 (0)