Make a noupdate firmware, update auto update location
This commit is contained in:
parent
6bc92348ae
commit
81cef686fe
|
@ -30,10 +30,12 @@ jobs:
|
|||
run: echo "PLATFORMIO_BUILD_FLAGS=-DVERSION='\"${GITHUB_REF#refs/*/}\"'" >> $GITHUB_ENV
|
||||
if: startsWith(github.ref, 'refs/tags/')
|
||||
- name: Run PlatformIO
|
||||
run: pio run -e esp32 -e m5stickc -e m5stickc-plus -e m5atom-matrix
|
||||
run: pio run -e esp32 -e esp32-noupdate -e esp32-verbose -e m5stickc -e m5stickc-plus -e m5atom-matrix
|
||||
- name: Rename firmware
|
||||
run: |
|
||||
cp .pio/build/esp32/firmware.bin esp32.bin
|
||||
cp .pio/build/esp32-verbose/firmware.bin esp32-verbose.bin
|
||||
cp .pio/build/esp32-noupdate/firmware.bin esp32-noupdate.bin
|
||||
cp .pio/build/m5stickc/firmware.bin m5stickc.bin
|
||||
cp .pio/build/m5stickc-plus/firmware.bin m5stickc-plus.bin
|
||||
cp .pio/build/m5atom-matrix/firmware.bin m5atom-matrix.bin
|
||||
|
|
|
@ -11,11 +11,8 @@
|
|||
[platformio]
|
||||
default_envs = esp32
|
||||
|
||||
[env:esp32]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = esp32dev
|
||||
lib_deps =
|
||||
[common_env_data]
|
||||
lib_deps_external =
|
||||
haimoz/SoftFilters@^0.1.0
|
||||
marvinroger/AsyncMqttClient@^0.8.2
|
||||
bblanchon/ArduinoJson@^6.17.3
|
||||
|
@ -23,24 +20,46 @@ lib_deps =
|
|||
h2zero/NimBLE-Arduino@^1.2.0
|
||||
me-no-dev/AsyncTCP@^1.1.1
|
||||
bbx10/DNSServer@^1.1.0
|
||||
|
||||
[env:esp32]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = esp32dev
|
||||
lib_deps = ${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
-D FIRMWARE='"esp32"'
|
||||
|
||||
[env:esp32-noupdate]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = esp32dev
|
||||
lib_deps = ${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
-D FIRMWARE='"esp32-noupdate"'
|
||||
-D NOUPDATE
|
||||
|
||||
[env:esp32-verbose]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = esp32dev
|
||||
lib_deps = ${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
-D FIRMWARE='"esp32-verbose"'
|
||||
-D VERBOSE
|
||||
|
||||
[env:m5stickc]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = m5stick-c
|
||||
lib_deps =
|
||||
m5stack/M5StickC@^0.2.0
|
||||
haimoz/SoftFilters@^0.1.0
|
||||
marvinroger/AsyncMqttClient@^0.8.2
|
||||
bblanchon/ArduinoJson@^6.17.3
|
||||
juerd/ESP-WiFiSettings@^3.7.2
|
||||
h2zero/NimBLE-Arduino@^1.2.0
|
||||
me-no-dev/AsyncTCP@^1.1.1
|
||||
bbx10/DNSServer@^1.1.0
|
||||
${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
|
@ -53,12 +72,7 @@ framework = arduino
|
|||
board = m5stick-c
|
||||
lib_deps =
|
||||
m5stack/M5StickCPlus@^0.0.1
|
||||
haimoz/SoftFilters@^0.1.0
|
||||
marvinroger/AsyncMqttClient@^0.8.2
|
||||
bblanchon/ArduinoJson@^6.17.3
|
||||
juerd/ESP-WiFiSettings@^3.7.2
|
||||
h2zero/NimBLE-Arduino@^1.2.0
|
||||
bbx10/DNSServer@^1.1.0
|
||||
${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
|
@ -71,35 +85,10 @@ platform = espressif32
|
|||
framework = arduino
|
||||
board = m5stack-atom
|
||||
lib_deps =
|
||||
haimoz/SoftFilters@^0.1.0
|
||||
marvinroger/AsyncMqttClient@^0.8.2
|
||||
bblanchon/ArduinoJson@^6.17.3
|
||||
juerd/ESP-WiFiSettings@^3.7.2
|
||||
h2zero/NimBLE-Arduino@^1.2.0
|
||||
me-no-dev/AsyncTCP@^1.1.1
|
||||
bbx10/DNSServer@^1.1.0
|
||||
${common_env_data.lib_deps_external}
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
-D M5ATOM
|
||||
-D MATRIX
|
||||
-D FIRMWARE='"m5atom-matrix"'
|
||||
|
||||
[env:verbose]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
board = m5stick-c
|
||||
lib_deps =
|
||||
m5stack/M5StickC@^0.2.0
|
||||
haimoz/SoftFilters@^0.1.0
|
||||
marvinroger/AsyncMqttClient@^0.8.2
|
||||
bblanchon/ArduinoJson@^6.17.3
|
||||
juerd/ESP-WiFiSettings@^3.7.2
|
||||
h2zero/NimBLE-Arduino@^1.2.0
|
||||
me-no-dev/AsyncTCP@^1.1.1
|
||||
bbx10/DNSServer@^1.1.0
|
||||
board_build.partitions = partitions_singleapp.csv
|
||||
monitor_speed = 115200
|
||||
build_flags =
|
||||
-D FIRMWARE='"verbose"'
|
||||
-D VERBOSE
|
||||
|
|
|
@ -148,6 +148,7 @@ void configureOTA()
|
|||
|
||||
void firmwareUpdate()
|
||||
{
|
||||
#ifndef NOUPDATE
|
||||
#ifdef VERSION
|
||||
static long lastFirmwareCheck = 0;
|
||||
long uptime = getUptimeSeconds();
|
||||
|
@ -160,7 +161,7 @@ void firmwareUpdate()
|
|||
WiFiClientSecure client;
|
||||
client.setInsecure();
|
||||
|
||||
String firmwareUrl = Sprintf("https://github.com/DTTerastar/ESP32-mqtt-room/releases/latest/download/%s.bin", FIRMWARE);
|
||||
String firmwareUrl = Sprintf("https://github.com/ESPresense/ESPresense/releases/latest/download/%s.bin", FIRMWARE);
|
||||
if (!http.begin(client, firmwareUrl))
|
||||
return;
|
||||
|
||||
|
@ -198,6 +199,7 @@ void firmwareUpdate()
|
|||
|
||||
updateInProgress = false;
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
void spiffsInit()
|
||||
|
|
Loading…
Reference in New Issue