Skip to content

Commit f4cfacd

Browse files
authored
Merge branch 'master' into esp-idf-v5.1-libs
2 parents 9aeed61 + 21b8865 commit f4cfacd

File tree

22 files changed

+1996
-1241
lines changed

22 files changed

+1996
-1241
lines changed

.github/ISSUE_TEMPLATE/Issue-report.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ body:
4141
options:
4242
- latest master (checkout manually)
4343
- latest development Release Candidate (RC-X)
44+
- v2.0.10
4445
- v2.0.9
4546
- v2.0.8
4647
- 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: 1422 additions & 1145 deletions
Large diffs are not rendered by default.

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
@@ -34,11 +34,10 @@
3434
#endif
3535
#else // ESP32 Before IDF 4.0
3636
#include "rom/gpio.h"
37+
#define GPIO_MATRIX_CONST_ZERO_INPUT GPIO_FUNC_IN_LOW
38+
#define GPIO_MATRIX_CONST_ONE_INPUT GPIO_FUNC_IN_HIGH
3739
#endif
3840

39-
#define MATRIX_DETACH_OUT_SIG 0x100
40-
#define MATRIX_DETACH_IN_LOW_PIN 0x30
41-
#define MATRIX_DETACH_IN_LOW_HIGH 0x38
4241

4342
void ARDUINO_ISR_ATTR pinMatrixOutAttach(uint8_t pin, uint8_t function, bool invertOut, bool invertEnable)
4443
{
@@ -47,7 +46,7 @@ void ARDUINO_ISR_ATTR pinMatrixOutAttach(uint8_t pin, uint8_t function, bool inv
4746

4847
void ARDUINO_ISR_ATTR pinMatrixOutDetach(uint8_t pin, bool invertOut, bool invertEnable)
4948
{
50-
gpio_matrix_out(pin, MATRIX_DETACH_OUT_SIG, invertOut, invertEnable);
49+
gpio_matrix_out(pin, SIG_GPIO_OUT_IDX, invertOut, invertEnable);
5150
}
5251

5352
void ARDUINO_ISR_ATTR pinMatrixInAttach(uint8_t pin, uint8_t signal, bool inverted)
@@ -57,7 +56,7 @@ void ARDUINO_ISR_ATTR pinMatrixInAttach(uint8_t pin, uint8_t signal, bool invert
5756

5857
void ARDUINO_ISR_ATTR pinMatrixInDetach(uint8_t signal, bool high, bool inverted)
5958
{
60-
gpio_matrix_in(high?MATRIX_DETACH_IN_LOW_HIGH:MATRIX_DETACH_IN_LOW_PIN, signal, inverted);
59+
gpio_matrix_in(high?GPIO_MATRIX_CONST_ONE_INPUT:GPIO_MATRIX_CONST_ZERO_INPUT, signal, inverted);
6160
}
6261
/*
6362
void ARDUINO_ISR_ATTR intrMatrixAttach(uint32_t source, uint32_t inum){

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)