diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 08c5df7..f5cb18d 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -12,7 +12,7 @@ jobs: strategy: fail-fast: false matrix: - board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1] + board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1, esp32-gl-s10] build: [release] env: BOARD: ${{ matrix.board }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6c9b069..a43601c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,7 +18,7 @@ jobs: strategy: fail-fast: false matrix: - board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1] + board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1, esp32-gl-s10] build: [release] env: BOARD: ${{ matrix.board }} diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index f8cc550..28be9a7 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -34,7 +34,7 @@ jobs: strategy: fail-fast: false matrix: - board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1] + board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1, esp32-gl-s10] build: [release] env: BOARD: ${{ matrix.board }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 01c22d9..ed34bd1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,7 +12,7 @@ jobs: strategy: fail-fast: false matrix: - board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1] + board: [esp32, esp32-s3, esp32-s3-oct, esp32-c3, esp32-c6, esp32-h2, esp32-solo1, esp32-gl-s10] build: [release] env: BOARD: ${{ matrix.board }} diff --git a/boards/nuki-esp32gls10.json b/boards/nuki-esp32gls10.json new file mode 100644 index 0000000..6cf3af6 --- /dev/null +++ b/boards/nuki-esp32gls10.json @@ -0,0 +1,37 @@ +{ + "build": { + "arduino":{ + "ldscript": "esp32_out.ld" + }, + "core": "esp32", + "extra_flags": "-DARDUINO_ESP32_DEV -DBOARD_HAS_PSRAM -mfix-esp32-psram-cache-issue", + "f_cpu": "240000000L", + "f_flash": "40000000L", + "flash_mode": "dio", + "mcu": "esp32", + "variant": "doitESP32devkitV1" + }, + "connectivity": [ + "wifi", + "bluetooth", + "ethernet", + "can" + ], + "debug": { + "openocd_board": "esp-wroom-32.cfg" + }, + "frameworks": [ + "arduino", + "espidf" + ], + "name": "DOIT ESP32 DEVKIT V1", + "upload": { + "flash_size": "4MB", + "maximum_ram_size": 327680, + "maximum_size": 4194304, + "require_upload_port": true, + "speed": 460800 + }, + "url": "http://www.doit.am/", + "vendor": "DOIT" +} \ No newline at end of file diff --git a/pio_package_post.py b/pio_package_post.py index 1154d53..60fc392 100644 --- a/pio_package_post.py +++ b/pio_package_post.py @@ -9,6 +9,8 @@ def get_board_name(env): if env.get('BOARD') == 'nuki-esp32solo1': board = 'esp32solo1' + elif env.get('BOARD') == 'nuki-esp32gls10': + board = 'esp32gls10' elif env.get('BOARD') == 'nuki-esp32-s3-oct': board = 'esp32s3oct' return board diff --git a/platformio.ini b/platformio.ini index 74401d4..6a14791 100644 --- a/platformio.ini +++ b/platformio.ini @@ -78,6 +78,13 @@ build_flags = -DCONFIG_NIMBLE_CPP_LOG_LEVEL=0 -DCONFIG_BT_NIMBLE_LOG_LEVEL=0 +[env:esp32-gl-s10] +extends = env:esp32 +board = nuki-esp32gls10 +board_build.cmake_extra_args = + -DSDKCONFIG_DEFAULTS="sdkconfig.defaults;sdkconfig.release.defaults;sdkconfig.defaults.esp32;sdkconfig.gls10.defaults" + -DNUKI_TARGET_GL_S10=y + [env:esp32-c3] extends = env:esp32 board = esp32-c3-devkitc-02 @@ -136,6 +143,18 @@ build_flags = -DCONFIG_BT_NIMBLE_LOG_LEVEL=0 -DDEBUG_NUKIHUB +[env:esp32-gl-s10_dbg] +extends = env:esp32-gl-s10 +custom_build = debug +board_build.cmake_extra_args = + -DSDKCONFIG_DEFAULTS="sdkconfig.defaults;sdkconfig.debug.defaults;sdkconfig.defaults.esp32;sdkconfig.gls10.defaults" +build_flags = + ${env.build_flags} + -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG + -DCONFIG_NIMBLE_CPP_LOG_LEVEL=0 + -DCONFIG_BT_NIMBLE_LOG_LEVEL=0 + -DDEBUG_NUKIHUB + [env:esp32-c3_dbg] extends = env:esp32-c3 custom_build = debug diff --git a/resources/how-to-flash.txt b/resources/how-to-flash.txt index fc2737d..99c1956 100644 --- a/resources/how-to-flash.txt +++ b/resources/how-to-flash.txt @@ -29,6 +29,13 @@ e000 boot_app0.bin 10000 nuki_hub_esp32.bin 280000 nuki_hub_updater_esp32.bin +ESP32-GL-S10 +e000 boot_app0.bin +1000 bootloader.bin +8000 nuki_hub.partitions.bin +10000 nuki_hub_esp32.bin +280000 nuki_hub_updater_esp32.bin + ESP32-S3 e000 boot_app0.bin 0 bootloader.bin @@ -87,6 +94,10 @@ As an alternative to the Download Tools, you can also use the esptool from the E esptool.py --chip esp32 --port /dev/ttyUSB0 --baud 921600 --before default_reset --after hard_reset write_flash -z --flash_mode dio --flash_freq keep --flash_size detect 0xe000 boot_app0.bin 0x1000 bootloader.bin 0x10000 nuki_hub_esp32.bin 0x280000 nuki_hub_updater_esp32.bin 0x8000 nuki_hub.partitions.bin +## ESP32-GL-S10 + +esptool.py --chip esp32 --port /dev/ttyUSB0 --baud 921600 --before default_reset --after hard_reset write_flash -z --flash_mode dio --flash_freq keep --flash_size detect 0xe000 boot_app0.bin 0x1000 bootloader.bin 0x10000 nuki_hub_esp32.bin 0x280000 nuki_hub_updater_esp32.bin 0x8000 nuki_hub.partitions.bin + ## ESP32-S3 esptool.py --chip esp32s3 --port /dev/ttyUSB0 --baud 921600 --before default_reset --after hard_reset write_flash -z --flash_mode dio --flash_freq keep --flash_size detect 0xe000 boot_app0.bin 0x0 bootloader.bin 0x10000 nuki_hub_esp32s3.bin 0x280000 nuki_hub_updater_esp32s3.bin 0x8000 nuki_hub.partitions.bin diff --git a/sdkconfig.gls10.defaults b/sdkconfig.gls10.defaults new file mode 100644 index 0000000..71c8610 --- /dev/null +++ b/sdkconfig.gls10.defaults @@ -0,0 +1 @@ +CONFIG_D0WD_PSRAM_CLK_IO=6 \ No newline at end of file diff --git a/src/Config.h b/src/Config.h index cb8f868..1f7057d 100644 --- a/src/Config.h +++ b/src/Config.h @@ -107,6 +107,21 @@ #define GITHUB_MASTER_UPDATER_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/master/nuki_hub_updater_esp32-solo1.bin" #define NUKI_HUB_HW (char*)"ESP32-SOLO1" #define BOOT_BUTTON_GPIO (gpio_num_t)0 +#elif defined(NUKI_TARGET_GL_S10) +#define GITHUB_LATEST_RELEASE_BINARY_URL "https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_LATEST_UPDATER_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/nuki_hub_updater_esp32.bin" +#define GITHUB_BETA_RELEASE_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/beta/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_BETA_UPDATER_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/beta/nuki_hub_updater_esp32.bin" +#define GITHUB_MASTER_RELEASE_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/master/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_MASTER_UPDATER_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/master/nuki_hub_updater_esp32.bin" +#define GITHUB_LATEST_RELEASE_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_LATEST_UPDATER_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/nuki_hub_updater_esp32.bin" +#define GITHUB_BETA_RELEASE_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/beta/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_BETA_UPDATER_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/beta/nuki_hub_updater_esp32.bin" +#define GITHUB_MASTER_RELEASE_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/master/nuki_hub_esp32-gl-s10.bin" +#define GITHUB_MASTER_UPDATER_BINARY_URL_DBG (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/debug/master/nuki_hub_updater_esp32.bin" +#define NUKI_HUB_HW (char*)"ESP32-GL-S10" +#define BOOT_BUTTON_GPIO (gpio_num_t)0 #else #define GITHUB_LATEST_RELEASE_BINARY_URL "https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/nuki_hub_esp32.bin" #define GITHUB_LATEST_UPDATER_BINARY_URL (char*)"https://raw.githubusercontent.com/technyon/nuki_hub/binary/ota/nuki_hub_updater_esp32.bin" diff --git a/updater/pio_package_post.py b/updater/pio_package_post.py index 1c6f405..2bb6416 100644 --- a/updater/pio_package_post.py +++ b/updater/pio_package_post.py @@ -8,6 +8,8 @@ def get_board_name(env): board = env.get('BOARD_MCU') if env.get('BOARD') == 'nuki-esp32solo1': board = 'esp32solo1' + elif env.get('BOARD') == 'nuki-esp32gls10': + board = 'esp32gls10' elif env.get('BOARD') == 'nuki-esp32-s3-oct': board = 'esp32s3oct' return board diff --git a/updater/platformio.ini b/updater/platformio.ini index 99e37d8..254af6a 100644 --- a/updater/platformio.ini +++ b/updater/platformio.ini @@ -67,6 +67,13 @@ extra_scripts = board_build.cmake_extra_args = -DSDKCONFIG_DEFAULTS="sdkconfig.defaults;sdkconfig.defaults.esp32" +[env:updater_esp32-gl-s10] +extends = env:updater_esp32 +board = nuki-esp32gls10 +board_build.cmake_extra_args = + -DSDKCONFIG_DEFAULTS="sdkconfig.defaults;sdkconfig.defaults.esp32;sdkconfig.gls10.defaults" + -DNUKI_TARGET_GL_S10=y + [env:updater_esp32-c3] extends = env:updater_esp32 board = esp32-c3-devkitc-02 diff --git a/updater/sdkconfig.gls10.defaults b/updater/sdkconfig.gls10.defaults new file mode 100644 index 0000000..71c8610 --- /dev/null +++ b/updater/sdkconfig.gls10.defaults @@ -0,0 +1 @@ +CONFIG_D0WD_PSRAM_CLK_IO=6 \ No newline at end of file