Skip to content

Commit f43f196

Browse files
authored
Merge branch 'master' into pr_btserial
2 parents cf5724c + d8a99ed commit f43f196

File tree

136 files changed

+979
-434
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+979
-434
lines changed

Diff for: .github/ISSUE_TEMPLATE/Issue-report.yml

+5-4
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ body:
3939
label: Version
4040
description: What version of Arduino ESP32 are you running? If possible, consider updating to the latest version.
4141
options:
42-
- latest master
42+
- latest master (checkout manually)
43+
- latest development Release Candidate (RC-X)
4344
- v2.0.2
4445
- v2.0.1
4546
- v2.0.0
@@ -52,7 +53,7 @@ body:
5253
attributes:
5354
label: IDE Name
5455
description: What IDE are you using?
55-
placeholder: eg. Arduino IDE, PlatformIO, IDF component...
56+
placeholder: eg. Arduino IDE, PlatformIO, Sloeber...
5657
validations:
5758
required: true
5859
- type: input
@@ -101,8 +102,8 @@ body:
101102
id: sketch
102103
attributes:
103104
label: Sketch
104-
description: Please provide your sketch/code which was run
105-
placeholder: ex. related part of the code
105+
description: Please provide full minimal sketch/code which can be run to reproduce your issue
106+
placeholder: ex. Related part of the code to replicate the issue
106107
render: cpp
107108
validations:
108109
required: true

Diff for: .github/PULL_REQUEST_TEMPLATE.md

+13-8
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,23 @@
1-
*By completing this PR sufficiently, you help us to improve the quality of Release Notes*
1+
*By completing this PR sufficiently, you help us to review this Pull Request quicker and also help improve the quality of Release Notes*
22

33
### Checklist
4-
1. [ ] Please provide specific title of the PR describing the change, including the component name (eg. *„Update of Documentation link on Readme.md“*)
5-
2. [ ] Please provide related links (eg. Issue, other Project, submodule PR..)
6-
3. [ ] Please check [Contributing guide](https://docs.espressif.com/projects/arduino-esp32/en/latest/contributing.html)
4+
1. [ ] Please provide specific title of the PR describing the change, including the component name (*eg. „Update of Documentation link on Readme.md“*)
5+
2. [ ] Please provide related links (*eg. Issue which will be closed by this Pull Request*)
6+
3. [ ] Please **update relevant Documentation** if applicable
7+
4. [ ] Please check [Contributing guide](https://docs.espressif.com/projects/arduino-esp32/en/latest/contributing.html)
78

89
*This entire section above can be deleted if all items are checked.*
910

1011
-----------
11-
## Summary
12-
Please describe your proposed PR and what it contains.
12+
## Description of Change
13+
Please describe your proposed Pull Request and it's impact.
1314

14-
## Impact
15-
Please describe impact of your PR and it's function.
15+
## Tests scenarios
16+
Please describe on what Hardware and Software combinations you have tested this Pull Request and how.
17+
18+
(*eg. I have tested my Pull Request on Arduino-esp32 core v2.0.2 with ESP32 and ESP32-S2 Board with this scenario*)
1619

1720
## Related links
1821
Please provide links to related issue, PRs etc.
22+
23+
(*eg. Closes #number of issue*)

Diff for: .github/scripts/install-platformio-esp32.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22

33
export PLATFORMIO_ESP32_PATH="$HOME/.platformio/packages/framework-arduinoespressif32"
4-
PLATFORMIO_ESP32_URL="https://github.com/platformio/platform-espressif32.git#feature/arduino-idf-master"
4+
PLATFORMIO_ESP32_URL="https://github.com/platformio/platform-espressif32.git"
55

66
TOOLCHAIN_VERSION="8.4.0+2021r2-patch3"
77
ESPTOOLPY_VERSION="~1.30100.0"

Diff for: .github/scripts/sketch_utils.sh

+9-6
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,22 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <fqbn> <path-to-i
77
return 1
88
fi
99

10-
ARDUINO_CACHE_DIR="$HOME/.arduino/cache.tmp"
11-
if [ -z "$ARDUINO_BUILD_DIR" ]; then
12-
build_dir="$(dirname $sketch)/build"
13-
else
14-
build_dir="$ARDUINO_BUILD_DIR"
15-
fi
1610
local ide_path=$1
1711
local usr_path=$2
1812
local fqbn=$3
1913
local sketch=$4
2014
local xtra_opts=$5
2115
local win_opts=$6
2216

17+
ARDUINO_CACHE_DIR="$HOME/.arduino/cache.tmp"
18+
if [ -z "$ARDUINO_BUILD_DIR" ]; then
19+
build_dir="$(dirname $sketch)/build"
20+
else
21+
build_dir="$ARDUINO_BUILD_DIR"
22+
fi
23+
24+
echo $sketch
25+
2326
rm -rf "$build_dir"
2427
mkdir -p "$build_dir"
2528
mkdir -p "$ARDUINO_CACHE_DIR"

Diff for: .github/stale.yml

-26
This file was deleted.

Diff for: .github/workflows/hil.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,12 @@ jobs:
6767
Test:
6868
needs: [gen_chunks, Build]
6969
name: ${{matrix.chip}}-Test#${{matrix.chunks}}
70-
runs-on: ESP32
70+
runs-on:
71+
- ESP32
72+
- ESP32-S2
73+
- ESP32-S3
74+
- ESP32-C3
75+
7176
strategy:
7277
fail-fast: false
7378
matrix:
@@ -87,11 +92,6 @@ jobs:
8792
name: ${{matrix.chip}}-${{matrix.chunks}}.artifacts
8893
path: tests/
8994

90-
- name: Check Artifacts
91-
run: |
92-
ls -R tests
93-
cat tests/*/build/build.options.json
94-
9595
- name: Install dependencies
9696
run: |
9797
pip install -U pip

Diff for: .github/workflows/publish.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ jobs:
1414
runs-on: ubuntu-latest
1515
if: |
1616
github.event.workflow_run.event == 'pull_request' &&
17-
github.event.workflow_run.conclusion != 'skipped'
17+
(github.event.workflow_run.conclusion == 'success' ||
18+
github.event.workflow_run.conclusion == 'failure')
1819
steps:
1920
- name: Download and Extract Artifacts
2021
env:

Diff for: README.md

+16-5
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,33 @@
22

33
![Build Status](https://github.com/espressif/arduino-esp32/workflows/ESP32%20Arduino%20CI/badge.svg) [![Documentation Status](https://readthedocs.com/projects/espressif-arduino-esp32/badge/?version=latest)](https://docs.espressif.com/projects/arduino-esp32/en/latest/?badge=latest)
44

5-
### Need help or have a question? Join the chat at [![https://gitter.im/espressif/arduino-esp32](https://badges.gitter.im/espressif/arduino-esp32.svg)](https://gitter.im/espressif/arduino-esp32?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
5+
### Need help or have a question? Join the chat at [![https://gitter.im/espressif/arduino-esp32](https://badges.gitter.im/espressif/arduino-esp32.svg)](https://gitter.im/espressif/arduino-esp32?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) or [open a new Discussion](https://github.com/espressif/arduino-esp32/discussions)
66

77
## Contents
88

9-
- [Development Status](#development-status)
10-
- [Decoding Exceptions](#decoding-exceptions)
11-
- [Issue/Bug report template](#issuebug-report-template)
9+
- [Development Status](#development-status)
10+
- [Development Planning](#development-planning)
11+
- [Documentation](#documentation)
12+
- [Supported Chips](#supported-chips)
13+
- [Decoding exceptions](#decoding-exceptions)
14+
- [Issue/Bug report template](#issuebug-report-template)
15+
- [Contributing](#contributing)
1216

1317
### Development Status
1418

1519
Latest Stable Release [![Release Version](https://img.shields.io/github/release/espressif/arduino-esp32.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/latest/) [![Release Date](https://img.shields.io/github/release-date/espressif/arduino-esp32.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/latest/) [![Downloads](https://img.shields.io/github/downloads/espressif/arduino-esp32/latest/total.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/latest/)
1620

1721
Latest Development Release [![Release Version](https://img.shields.io/github/release/espressif/arduino-esp32/all.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/) [![Release Date](https://img.shields.io/github/release-date-pre/espressif/arduino-esp32.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/) [![Downloads](https://img.shields.io/github/downloads-pre/espressif/arduino-esp32/latest/total.svg?style=plastic)](https://github.com/espressif/arduino-esp32/releases/)
1822

23+
### Development Planning
24+
25+
Our Development is fully tracked on this public **[Roadmap 🎉](https://github.com/orgs/espressif/projects/3)**
26+
27+
For even more information you can take a look at [Sprint Meeting notes](https://github.com/espressif/arduino-esp32/discussions/categories/sprints-meeting-notes) or join [Monthly Community Meetings 🔔](https://github.com/espressif/arduino-esp32/discussions/categories/monthly-community-meetings)
28+
1929
### Documentation
2030

21-
You can use [Arduino-ESP32 Online Documentation](https://docs.espressif.com/projects/arduino-esp32/en/latest/) to get all information about this project.
31+
You can use the [Arduino-ESP32 Online Documentation](https://docs.espressif.com/projects/arduino-esp32/en/latest/) to get all information about this project.
2232

2333
* [Getting Started](https://docs.espressif.com/projects/arduino-esp32/en/latest/getting_started.html)
2434
* [Installing (Windows, Linux and macOS)](https://docs.espressif.com/projects/arduino-esp32/en/latest/installing.html)
@@ -36,6 +46,7 @@ Visit the [supported chips](https://docs.espressif.com/projects/arduino-esp32/en
3646
You can use [EspExceptionDecoder](https://github.com/me-no-dev/EspExceptionDecoder) to get meaningful call trace.
3747

3848
### Issue/Bug report template
49+
3950
Before reporting an issue, make sure you've searched for similar one that was already created. Also make sure to go through all the issues labelled as [Type: For reference](https://github.com/espressif/arduino-esp32/issues?q=is%3Aissue+label%3A%22Type%3A+For+reference%22+).
4051

4152
Finally, if you are sure no one else had the issue, follow the **Issue template** or **Feature request template** while reporting any [new Issue](https://github.com/espressif/arduino-esp32/issues/new/choose).

Diff for: boards.txt

+9
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,9 @@ esp32s3.menu.PartitionScheme.fatflash.upload.maximum_size=2097152
184184
esp32s3.menu.PartitionScheme.app3M_fat9M_16MB=16M Flash (3MB APP/9MB FATFS)
185185
esp32s3.menu.PartitionScheme.app3M_fat9M_16MB.build.partitions=app3M_fat9M_16MB
186186
esp32s3.menu.PartitionScheme.app3M_fat9M_16MB.upload.maximum_size=3145728
187+
esp32s3.menu.PartitionScheme.rainmaker=RainMaker
188+
esp32s3.menu.PartitionScheme.rainmaker.build.partitions=rainmaker
189+
esp32s3.menu.PartitionScheme.rainmaker.upload.maximum_size=3145728
187190

188191
esp32s3.menu.CPUFreq.240=240MHz (WiFi)
189192
esp32s3.menu.CPUFreq.240.build.f_cpu=240000000L
@@ -304,6 +307,9 @@ esp32c3.menu.PartitionScheme.fatflash.upload.maximum_size=2097152
304307
esp32c3.menu.PartitionScheme.app3M_fat9M_16MB=16M Flash (3MB APP/9MB FATFS)
305308
esp32c3.menu.PartitionScheme.app3M_fat9M_16MB.build.partitions=app3M_fat9M_16MB
306309
esp32c3.menu.PartitionScheme.app3M_fat9M_16MB.upload.maximum_size=3145728
310+
esp32c3.menu.PartitionScheme.rainmaker=RainMaker
311+
esp32c3.menu.PartitionScheme.rainmaker.build.partitions=rainmaker
312+
esp32c3.menu.PartitionScheme.rainmaker.upload.maximum_size=3145728
307313

308314
esp32c3.menu.CPUFreq.160=160MHz (WiFi)
309315
esp32c3.menu.CPUFreq.160.build.f_cpu=160000000L
@@ -475,6 +481,9 @@ esp32s2.menu.PartitionScheme.fatflash.upload.maximum_size=2097152
475481
esp32s2.menu.PartitionScheme.app3M_fat9M_16MB=16M Flash (3MB APP/9MB FATFS)
476482
esp32s2.menu.PartitionScheme.app3M_fat9M_16MB.build.partitions=app3M_fat9M_16MB
477483
esp32s2.menu.PartitionScheme.app3M_fat9M_16MB.upload.maximum_size=3145728
484+
esp32s2.menu.PartitionScheme.rainmaker=RainMaker
485+
esp32s2.menu.PartitionScheme.rainmaker.build.partitions=rainmaker
486+
esp32s2.menu.PartitionScheme.rainmaker.upload.maximum_size=3145728
478487

479488
esp32s2.menu.CPUFreq.240=240MHz (WiFi)
480489
esp32s2.menu.CPUFreq.240.build.f_cpu=240000000L

Diff for: cores/esp32/esp32-hal-gpio.h

+3-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ extern "C" {
4242

4343
//GPIO FUNCTIONS
4444
#define INPUT 0x01
45-
#define OUTPUT 0x02
45+
// Changed OUTPUT from 0x02 to behave the same as Arduino pinMode(pin,OUTPUT)
46+
// where you can read the state of pin even when it is set as OUTPUT
47+
#define OUTPUT 0x03
4648
#define PULLUP 0x04
4749
#define INPUT_PULLUP 0x05
4850
#define PULLDOWN 0x08

Diff for: cores/esp32/esp32-hal-ledc.c

+7-7
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454

5555
uint8_t channels_resolution[LEDC_CHANNELS] = {0};
5656

57-
double ledcSetup(uint8_t chan, double freq, uint8_t bit_num)
57+
uint32_t ledcSetup(uint8_t chan, uint32_t freq, uint8_t bit_num)
5858
{
5959
if(chan >= LEDC_CHANNELS || bit_num > LEDC_MAX_BIT_WIDTH){
6060
log_e("No more LEDC channels available! (maximum %u) or bit width too big (maximum %u)", LEDC_CHANNELS, LEDC_MAX_BIT_WIDTH);
@@ -106,7 +106,7 @@ uint32_t ledcRead(uint8_t chan)
106106
return ledc_get_duty(group,channel);
107107
}
108108

109-
double ledcReadFreq(uint8_t chan)
109+
uint32_t ledcReadFreq(uint8_t chan)
110110
{
111111
if(!ledcRead(chan)){
112112
return 0;
@@ -115,7 +115,7 @@ double ledcReadFreq(uint8_t chan)
115115
return ledc_get_freq(group,timer);
116116
}
117117

118-
double ledcWriteTone(uint8_t chan, double freq)
118+
uint32_t ledcWriteTone(uint8_t chan, uint32_t freq)
119119
{
120120
if(chan >= LEDC_CHANNELS){
121121
return 0;
@@ -142,12 +142,12 @@ double ledcWriteTone(uint8_t chan, double freq)
142142
}
143143
channels_resolution[chan] = 10;
144144

145-
double res_freq = ledc_get_freq(group,timer);
145+
uint32_t res_freq = ledc_get_freq(group,timer);
146146
ledcWrite(chan, 0x1FF);
147147
return res_freq;
148148
}
149149

150-
double ledcWriteNote(uint8_t chan, note_t note, uint8_t octave){
150+
uint32_t ledcWriteNote(uint8_t chan, note_t note, uint8_t octave){
151151
const uint16_t noteFrequencyBase[12] = {
152152
// C C# D Eb E F F# G G# A Bb B
153153
4186, 4435, 4699, 4978, 5274, 5588, 5920, 6272, 6645, 7040, 7459, 7902
@@ -156,7 +156,7 @@ double ledcWriteNote(uint8_t chan, note_t note, uint8_t octave){
156156
if(octave > 8 || note >= NOTE_MAX){
157157
return 0;
158158
}
159-
double noteFreq = (double)noteFrequencyBase[note] / (double)(1 << (8-octave));
159+
uint32_t noteFreq = (uint32_t)noteFrequencyBase[note] / (uint32_t)(1 << (8-octave));
160160
return ledcWriteTone(chan, noteFreq);
161161
}
162162

@@ -184,7 +184,7 @@ void ledcDetachPin(uint8_t pin)
184184
pinMatrixOutDetach(pin, false, false);
185185
}
186186

187-
double ledcChangeFrequency(uint8_t chan, double freq, uint8_t bit_num)
187+
uint32_t ledcChangeFrequency(uint8_t chan, uint32_t freq, uint8_t bit_num)
188188
{
189189
if(chan >= LEDC_CHANNELS || bit_num > LEDC_MAX_BIT_WIDTH){
190190
log_e("LEDC channel not available! (maximum %u) or bit width too big (maximum %u)", LEDC_CHANNELS, LEDC_MAX_BIT_WIDTH);

Diff for: cores/esp32/esp32-hal-ledc.h

+5-5
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ typedef enum {
2727
} note_t;
2828

2929
//channel 0-15 resolution 1-16bits freq limits depend on resolution
30-
double ledcSetup(uint8_t channel, double freq, uint8_t resolution_bits);
30+
uint32_t ledcSetup(uint8_t channel, uint32_t freq, uint8_t resolution_bits);
3131
void ledcWrite(uint8_t channel, uint32_t duty);
32-
double ledcWriteTone(uint8_t channel, double freq);
33-
double ledcWriteNote(uint8_t channel, note_t note, uint8_t octave);
32+
uint32_t ledcWriteTone(uint8_t channel, uint32_t freq);
33+
uint32_t ledcWriteNote(uint8_t channel, note_t note, uint8_t octave);
3434
uint32_t ledcRead(uint8_t channel);
35-
double ledcReadFreq(uint8_t channel);
35+
uint32_t ledcReadFreq(uint8_t channel);
3636
void ledcAttachPin(uint8_t pin, uint8_t channel);
3737
void ledcDetachPin(uint8_t pin);
38-
double ledcChangeFrequency(uint8_t channel, double freq, uint8_t resolution_bits);
38+
uint32_t ledcChangeFrequency(uint8_t channel, uint32_t freq, uint8_t resolution_bits);
3939

4040

4141
#ifdef __cplusplus

0 commit comments

Comments
 (0)