Skip to content

Commit

Permalink
Tasmota changes (#123)
Browse files Browse the repository at this point in the history
* Initial S3 Support

Just so we can compile and test! Some things might/will not work. SPI and UART baud detect need to be looked at.

* Add S3 Toolchain

* Update Esptool and add some missing adjustments

* Add Dual-Core Support

* Fix bootloop issue and enable DSP optimization

* Run Arduino on Core1

* Rework USB selection

* Update HWCDC.cpp

* Update USB.cpp

* Update esp32-hal-tinyusb.c

* fix S3 flash image base (espressif#6208)

* Added my new Unexpected Maker ESP32-S3 boards (espressif#6211)

* Fixes UART_1 TX Pin setup

When passing the PR to this branch, it seems that the change to this line was forgotten.

* Initial SPI support and S3-Box variant

* Bootloader is at 0x0000 for S3 (espressif#6215)

* small adjustments for NVS and PSRAM init

* WIP: Initial support for PSRAM (QSPI and OPI)

* [FEATURE] Basic implementation of Arduino's I2S library (espressif#5304)

Basic version of Arduino's I2S library. We currently support only 16bps + 16000 Hz sampling frequency. Other bitrates and sample rates will print warning and continue to operate, however the resulting audio quality may be poor.
There will be further effort to fix these issues.

* [I2S] Fix lib-builder error

* Update idf_component.yml (espressif#6232)

took me a while

* Fixes RMT examples and adds ESP32-S3 config (espressif#6235)

* WIP: Initial OPI support

* Update Libs with the new lib-builder scripts

* Update board menu for ESP32-S3

* fix ethernet clock runtime setting (espressif#6340)

this was not possible anymore since the GPIO refactoring.

This superseeds espressif/esp32-arduino-lib-builder#60
(which works only for clock on GPIO17). A PR will provided to revert this.
@me-no-dev fyi

The fix is done from @arendst Credits go to him!

* Update IDF libs and fix missing BLE 4.2 features

* Update CI scripts

* script fixes

* Add guard to USB examples

* Disable some examples for ESP32-S3

* skip one more sketch and try again PIO

* Fox SPI example and add proper esptool for PIO CI

* Update ResetReason.ino

* Update IDF, Add ESP-SR and RainMaker

* Enable RainMaker on all chips

* Enable hardware test on ESP32-S3

* Adjust build dir for tests and sketches

* Update tests_build.sh

* Send event also if tests fail

* Add helper script for updating the core version

* [Docs] Added/Updated Lib builder docs (espressif#6401)

* [Docs] Added/Updated Lib builder docs

* [Docs] Fixes according to the PR review

* [Docs] Fixes according to the PR review

* SD_MMC: add ESP32-S3 support

* CmakeList + Rainmaker src files edit

* remove Rainmaker

* Tasmota change

* Fix Unicore WDT on HTTP OTA update

* Revert "ESP32-S3 SDMMC support" (#20)

* Fix reboot into download from TinyUSB on ESP32-S3

Requires manual reboot back into the new firmware after flashing has finished

* Fix psram crash pico d4 (#110)

* Fix reboot into download from TinyUSB on ESP32-S3 (#111)

Requires manual reboot back into the new firmware after flashing has finished

Co-authored-by: me-no-dev <[email protected]>

* Revert "Fix psram crash pico d4 (#110)" (#113)

This reverts commit 56cf555.

* Fix boot freeze when trying to init PSRAM on Pico D4

* revert tinyusb

* hal/usb_serial_jtag_ll.h only C3, H2, S3

* Fix sd mmc

* add wpa_supplicant as requirement

* Update platform.txt

* remove Rainmaker

* Update boards.txt

* Update HardwareSerial.h

* Update USBCDC.cpp

* Update esptool.py

* Update platformio-build-esp32.py

* Update platformio-build-esp32c3.py

* Update platformio-build-esp32s2.py

* Update platformio-build-esp32s3.py

* fix merge errors

* Reordering - HardwareSerial Constructor

* Update platformio-build-esp32.py

* Update platformio-build-esp32c3.py

* Update platformio-build-esp32s2.py

* Update platformio-build-esp32s3.py

* Update pins_arduino.h

* Update platformio-build-esp32.py

* Update platformio-build-esp32c3.py

* Update platformio-build-esp32s2.py

* Update platformio-build-esp32s3.py

Co-authored-by: me-no-dev <[email protected]>
Co-authored-by: Unexpected Maker <[email protected]>
Co-authored-by: Rodrigo Garcia <[email protected]>
Co-authored-by: Tomáš Pilný <[email protected]>
Co-authored-by: Me No Dev <[email protected]>
Co-authored-by: Pedro Minatel <[email protected]>
Co-authored-by: Ivan Grokhotkov <[email protected]>
Co-authored-by: Jan Procházka <[email protected]>
  • Loading branch information
9 people authored Mar 30, 2022
1 parent 1e388a2 commit 29856cf
Show file tree
Hide file tree
Showing 36 changed files with 14 additions and 3,760 deletions.
2 changes: 1 addition & 1 deletion .github/scripts/install-arduino-core-esp32.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ if [ ! -d "$ARDUINO_ESP32_PATH" ]; then
ln -s $GITHUB_WORKSPACE esp32
else
echo "Cloning Core Repository..."
git clone https:/espressif/arduino-esp32.git esp32 > /dev/null 2>&1
git clone https:/tasmota/arduino-esp32.git esp32 > /dev/null 2>&1
fi

#echo "Updating Submodules ..."
Expand Down
10 changes: 0 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,6 @@ set(LIBRARY_SRCS
libraries/I2S/src/I2S.cpp
libraries/NetBIOS/src/NetBIOS.cpp
libraries/Preferences/src/Preferences.cpp
libraries/RainMaker/src/RMaker.cpp
libraries/RainMaker/src/RMakerNode.cpp
libraries/RainMaker/src/RMakerParam.cpp
libraries/RainMaker/src/RMakerDevice.cpp
libraries/RainMaker/src/RMakerType.cpp
libraries/SD_MMC/src/SD_MMC.cpp
libraries/SD/src/SD.cpp
libraries/SD/src/sd_diskio.cpp
Expand Down Expand Up @@ -184,7 +179,6 @@ set(includedirs
libraries/I2S/src
libraries/NetBIOS/src
libraries/Preferences/src
libraries/RainMaker/src
libraries/SD_MMC/src
libraries/SD/src
libraries/SimpleBLE/src
Expand Down Expand Up @@ -239,10 +233,6 @@ endfunction()

maybe_add_component(esp-dsp)

if(CONFIG_ESP_RMAKER_WORK_QUEUE_TASK_STACK)
maybe_add_component(esp_rainmaker)
maybe_add_component(qrcode)
endif()
if(IDF_TARGET MATCHES "esp32s2|esp32s3" AND CONFIG_TINYUSB_ENABLED)
maybe_add_component(arduino_tinyusb)
endif()
Expand Down
14 changes: 9 additions & 5 deletions cores/esp32/Esp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ extern "C" {
#elif CONFIG_IDF_TARGET_ESP32C3
#include "esp32c3/rom/spi_flash.h"
#define ESP_FLASH_IMAGE_BASE 0x0000 // Esp32c3 is located at 0x0000
#else
#else
#error Target CONFIG_IDF_TARGET is not supported
#endif
#else // ESP32 Before IDF 4.0
Expand Down Expand Up @@ -192,7 +192,7 @@ static uint32_t sketchSize(sketchSize_t response) {
return data.image_len;
}
}

uint32_t EspClass::getSketchSize () {
return sketchSize(SKETCH_SIZE_TOTAL);
}
Expand Down Expand Up @@ -231,6 +231,10 @@ String EspClass::getSketchMD5()
md5.add(buf.get(), readBytes);
lengthLeft -= readBytes;
offset += readBytes;

#if CONFIG_FREERTOS_UNICORE
delay(1); // Fix solo WDT
#endif
}
md5.calculate();
result = md5.toString();
Expand Down Expand Up @@ -391,17 +395,17 @@ bool EspClass::flashRead(uint32_t offset, uint32_t *data, size_t size)
return spi_flash_read(offset, (uint32_t*) data, size) == ESP_OK;
}

bool EspClass::partitionEraseRange(const esp_partition_t *partition, uint32_t offset, size_t size)
bool EspClass::partitionEraseRange(const esp_partition_t *partition, uint32_t offset, size_t size)
{
return esp_partition_erase_range(partition, offset, size) == ESP_OK;
}

bool EspClass::partitionWrite(const esp_partition_t *partition, uint32_t offset, uint32_t *data, size_t size)
bool EspClass::partitionWrite(const esp_partition_t *partition, uint32_t offset, uint32_t *data, size_t size)
{
return esp_partition_write(partition, offset, data, size) == ESP_OK;
}

bool EspClass::partitionRead(const esp_partition_t *partition, uint32_t offset, uint32_t *data, size_t size)
bool EspClass::partitionRead(const esp_partition_t *partition, uint32_t offset, uint32_t *data, size_t size)
{
return esp_partition_read(partition, offset, data, size) == ESP_OK;
}
Expand Down
2 changes: 1 addition & 1 deletion libraries/ESP32/examples/RMT/RMTCallback/RMTCallback.ino
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,4 @@ void loop()
{
Serial.printf("GPIO 4: %08x 5: %08x 10: %08x\n", mp1.val(), mp2.val(), mp3.val());
delay(500);
}
}
3 changes: 0 additions & 3 deletions libraries/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,6 @@ arduino-esp32 includes libraries for Arduino compatibility along with some objec
### Preferences
Flash keystore using ESP32 NVS

### ESP RainMaker
End-to-end platform by Espressif that enables Makers to realize their IoT ideas faster

### SD
Secure Digital card filesystem using SPI access

Expand Down
Loading

0 comments on commit 29856cf

Please sign in to comment.