forked from platformio/bintray-secure-ota
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathplatformio.ini
executable file
·63 lines (56 loc) · 1.75 KB
/
platformio.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
[platformio]
default_envs = debug
; default_envs = release
[bintray]
user = r0oland
repository = OTA_Repo
package = OTA_Tutorial
api_token = ${sysenv.BIN_TOKEN}
; Wi-Fi network settings OTA_test (Generic)
; replace with your values or set user/system variable
[wifi]
ssid = ${sysenv.WIFI_SSID}
password = ${sysenv.WIFI_PWD}
; adjust all settings to match your microcontroller
[common]
; Change this to force OTA update of firmware, int values > 0
release_version = 0
platform = espressif32 ;stable version
board = lolin_d32_pro ;change to your board here!
upload_port = COM6 ; Custom serial monitor / upload port
serial_speed = 921600 ; used for upload and serial port monitoring
; extra dependencies
lib_deps = ArduinoJson@<6 ; 6.x JSon no longer works
; build configuration based on Bintray and Wi-Fi settings
build_flags =
'-D WIFI_SSID = "${wifi.ssid}"'
'-D WIFI_PASS = "${wifi.password}"'
'-D SERIAL_SPEED = ${common.serial_speed}'
'-D BINTRAY_USER = "${bintray.user}"'
'-D BINTRAY_REPO = "${bintray.repository}"'
'-D BINTRAY_PACKAGE = "${bintray.package}"'
; Build environments
[env:debug]
framework = arduino
platform = ${common.platform}
board = ${common.board}
build_flags =
${common.build_flags}
-D VERSION=0
lib_deps = ${common.lib_deps}
upload_speed = ${common.serial_speed}
monitor_speed = ${common.serial_speed}
upload_port = ${common.upload_port}
monitor_port = ${common.upload_port}
[env:release]
framework = arduino
platform = ${common.platform}
board = ${common.board}
build_flags =
${common.build_flags}
-D VERSION=${common.release_version}
-D BINTRAY_TOKEN=${bintray.api_token}
lib_deps = ${common.lib_deps}
upload_protocol = custom
extra_scripts = pre:publish_firmware.py
monitor_speed = ${common.serial_speed}