upgrade to IDF v5.1.5

remove some errors due to merging master

Signed-off-by: Karl Osterseher <karli_o@gmx.at>
This commit is contained in:
Karl Osterseher
2025-01-19 09:24:46 +01:00
Unverified
parent 79991d51fa
commit 7252b699ea
5 changed files with 76 additions and 4081 deletions

4007
.project

File diff suppressed because it is too large Load Diff

View File

@@ -25,7 +25,7 @@ which made it impossible to get good results for multiroom syncing.
### Codebase
The codebase is split into components and build on <b>ESP-IDF v5.1.1</b>. I still
The codebase is split into components and build on <b>ESP-IDF v5.1.5</b>. I still
have some refactoring on the todo list as the concept has started to settle and
allow for new features can be added in a structured manner. In the code you
will find parts that are only partly related features and still not on the task
@@ -112,13 +112,13 @@ git clone https://github.com/CarlosDerSeher/snapclient
cd snapclient
```
Update third party code (opus, flac and esp-dsp):
Update third party code (opus, flac, esp-dsp, improv_wifi):
```
git submodule update --init
```
### ESP-IDF environnement configuration
- <b>If you're on Windows :</b> Install [ESP-IDF v5.1.1](https://github.com/espressif/esp-idf/releases/tag/v5.1.1) locally ([More info](https://docs.espressif.com/projects/esp-idf/en/latest/esp32/get-started/windows-setup-update.html)).
- <b>If you're on Windows :</b> Install [ESP-IDF v5.1.5](https://github.com/espressif/esp-idf/releases/tag/v5.1.5) locally ([More info](https://docs.espressif.com/projects/esp-idf/en/latest/esp32/get-started/windows-setup-update.html)).
- <b>If you're on Linux (docker) :</b> Use the image for ESP-IDF by following [docker build](doc/docker_build.md) doc
- <b>If you're on Linux :</b> follow [official Espressif](https://docs.espressif.com/projects/esp-idf/en/stable/esp32/get-started/linux-macos-setup.html) instructions
For debian based systems you'll need to do the following:
@@ -126,7 +126,7 @@ git submodule update --init
sudo apt-get install git wget flex bison gperf python3 python3-pip python3-venv cmake ninja-build ccache libffi-dev libssl-dev dfu-util libusb-1.0-0
mkdir -p ~/esp
cd ~/esp
git clone -b v5.1.1 --recursive https://github.com/espressif/esp-idf.git
git clone -b v5.1.5 --recursive https://github.com/espressif/esp-idf.git
cd ~/esp/esp-idf
./install.sh esp32
. ./export.sh
@@ -196,7 +196,7 @@ Setup a snapcast server on your network
On a linux box:
Clone snapcast build and start the server
Install [Snapcast](https://github.com/badaix/snapcast) and start the server. You won't need the following command if you installed it as a service.
./snapserver

View File

@@ -202,9 +202,6 @@ static esp_err_t player_setup_i2s(i2s_port_t i2sNum,
}
#endif
ESP_LOGI(TAG, "player_setup_i2s: dma_buf_len is %ld, dma_buf_count is %ld",
i2sDmaBufMaxLen, i2sDmaBufCnt);
if (tx_chan) {
my_i2s_channel_disable(tx_chan);
i2s_del_channel(tx_chan);
@@ -235,6 +232,11 @@ static esp_err_t player_setup_i2s(i2s_port_t i2sNum,
bits = I2S_DATA_BIT_WIDTH_16BIT;
}
ESP_LOGI(TAG,
"player_setup_i2s: dma_buf_len is %ld, dma_buf_count is %ld, sample "
"rate: %ld, bits: %d",
i2sDmaBufMaxLen, i2sDmaBufCnt, sr, bits);
i2s_std_clk_config_t i2s_clkcfg = {
.sample_rate_hz = sr,
#if CONFIG_USE_SAMPLE_INSERTION
@@ -250,8 +252,7 @@ static esp_err_t player_setup_i2s(i2s_port_t i2sNum,
.slot_cfg =
I2S_STD_MSB_SLOT_DEFAULT_CONFIG(setting->bits, I2S_SLOT_MODE_STEREO),
#else
.slot_cfg = I2S_STD_PHILIPS_SLOT_DEFAULT_CONFIG(setting->bits,
I2S_SLOT_MODE_STEREO),
.slot_cfg = I2S_STD_PHILIPS_SLOT_DEFAULT_CONFIG(bits, I2S_SLOT_MODE_STEREO),
#endif
.gpio_cfg =
{
@@ -1420,37 +1421,6 @@ static void player_task(void *pvParameters) {
// get actual age after alarm
age = (int64_t)timer_val - (-age);
// check if we need to write remaining data
if (size != 0) {
do {
written = 0;
if (i2s_custom_write(I2S_NUM_0, p_payload, (size_t)size, &written,
portMAX_DELAY) != ESP_OK) {
ESP_LOGE(TAG, "i2s_playback_task: I2S write error");
}
if (written < size) {
ESP_LOGE(TAG,
"i2s_playback_task: I2S didn't "
"write all data");
}
size -= written;
p_payload += written;
if (size == 0) {
if (fragment->nextFragment != NULL) {
fragment = fragment->nextFragment;
p_payload = fragment->payload;
size = fragment->size;
} else {
free_pcm_chunk(chnk);
chnk = NULL;
break;
}
}
} while (1);
}
initialSync = 1;
// TODO: use a timer to un-mute non blocking

View File

@@ -0,0 +1,32 @@
dependencies:
espressif/esp-dsp:
component_hash: fa7fe74305df6da25867437ebcd4213e047cbfc0556cf92067ab657fce537c6e
dependencies:
- name: idf
require: private
version: '>=4.2'
source:
registry_url: https://components.espressif.com/
type: service
version: 1.5.2
espressif/mdns:
component_hash: d36b265164be5139f92de993f08f5ecaa0de0c0acbf84deee1f10bb5902d04ff
dependencies:
- name: idf
require: private
version: '>=5.0'
source:
registry_url: https://components.espressif.com/
type: service
version: 1.4.3
idf:
source:
type: idf
version: 5.1.5
direct_dependencies:
- espressif/esp-dsp
- espressif/mdns
- idf
manifest_hash: 01df6f188570b9e5362f7a00a294b1d3403de1f5ce8cbd848004d3bc88aa09a8
target: esp32
version: 2.0.0

View File

@@ -12,7 +12,7 @@ No need to install ESP-IDF or anything else. All commands should be run in proje
### Start an interactive IDF environnement
In this interactive shell you can run menuconfig, build, flash and monitor command.
```
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.1
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.5
```
### Configure
@@ -37,12 +37,12 @@ Exit docker interactive shell: `exit`
If you want to execute a specific command or to generate a reusable .bin file.
### menuconfig
```
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.1 idf.py menuconfig
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.5 idf.py menuconfig
```
### Build
```
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.1 idf.py build
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.5 idf.py build
```
### Flash
@@ -67,7 +67,7 @@ idf.py --port 'rfc2217://host.docker.internal:4000?ign_set_control' flash monito
#### Merge bins into single firmware bin file
```
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.1 //runs terminal in idf container
docker run --rm -it -v .:/project -w /project -v /dev:/dev --privileged espressif/idf:v5.1.5 //runs terminal in idf container
esptool.py --chip esp32 merge_bin --output firmware.bin @flash_args // merges all bin files into firmware.bin
```