-
Notifications
You must be signed in to change notification settings - Fork 1
/
platformio.ini
184 lines (176 loc) · 6.4 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html
[platformio]
extra_configs = secrets.ini
; env_default = smartostat_oled
[common_env_data]
platform = [email protected]
board = d1_mini
platform_esp32 = [email protected]
monitor_filters_esp32 = esp32_exception_decoder
framework = arduino
;platform_packages = platformio/framework-arduinoespressif8266 @ https://github.com/esp8266/Arduino.git#0e5d358c3c15cff4b12fd89d9e605ff9fa0709a6
; set frequency to 160MHz 160000000L oppure 80000000L // 160MHz is not good for the IR library
f_cpu = 160000000L
; flash.4m.ld, flash.4m1m.ld, flash.4m2m.ld, flash.4m3m.ld Less memory for SPIFFS faster the upload
monitor_speed = 115200
upload_speed = 921600
filesystem = littlefs
monitor_filters = esp8266_exception_decoder, colorize
extra_scripts =
pre:platformio_version_increment/version_increment_pre.py
post:platformio_version_increment/version_increment_post.py
lib_deps =
bblanchon/ArduinoJson
knolleary/PubSubClient
adafruit/Adafruit GFX Library
adafruit/Adafruit BusIO
adafruit/Adafruit SSD1306
adafruit/Adafruit Unified Sensor
adafruit/Adafruit BME680 Library
crankyoldgit/IRremoteESP8266
; ArduinoBootstrapper=https://github.com/sblantipodi/arduino_bootstrapper.git#master
lib_extra_dirs = arduino_bootstrapper
common_build_flags =
'-D AUTHOR="DPsoftware"'
'-D SERIAL_RATE=115200'
'-D DEBUG_QUEUE_MSG=false'
'-D DISPLAY_ENABLED=true'
'-D GATEWAY_IP="192.168.1.1"'
'-D SUBNET_IP="255.255.255.0"'
'-D MQTT_SERVER_IP="192.168.1.3"'
'-D MQTT_SERVER_PORT="1883"'
'-D MAX_RECONNECT=500'
'-D MAX_JSON_OBJECT_SIZE=50'
'-D MQTT_MAX_PACKET_SIZE=1024'
'-D WIFI_SSID="${secrets.wifi_ssid}"'
'-D WIFI_PWD="${secrets.wifi_password}"'
'-D MQTT_USER="${secrets.mqtt_username}"'
'-D MQTT_PWD="${secrets.mqtt_password}"'
'-D OTA_PWD="${secrets.ota_password}"'
[env:smartoled]
platform = ${common_env_data.platform}
board = ${common_env_data.board}
framework = ${common_env_data.framework}
;platform_packages = ${common_env_data.platform_packages}
; set frequency to 160MHz 160000000L
board_build.f_cpu = ${common_env_data.f_cpu}
; flash.4m.ld, flash.4m1m.ld, flash.4m2m.ld, flash.4m3m.ld Less memory for SPIFFS faster the upload
build_flags =
-D TARGET_SMARTOLED
'-D WIFI_DEVICE_NAME="SMARTOLED"'
'-D MICROCONTROLLER_OTA_PORT=8278'
'-D WIFI_SIGNAL_STRENGTH=0'
'-D MICROCONTROLLER_IP="192.168.1.51"'
${common_env_data.common_build_flags}
board_build.ldscript = eagle.flash.4m1m.ld
monitor_speed = ${common_env_data.monitor_speed}
upload_speed = ${common_env_data.upload_speed}
board_build.filesystem = ${common_env_data.filesystem}
monitor_filters = ${common_env_data.monitor_filters}
monitor_port = COM3
upload_port = COM3
;upload_protocol = espota
;upload_port = 192.168.1.51
;upload_flags =
; --port=8278
; --auth=${secrets.ota_password}
lib_ldf_mode = chain+
extra_scripts = ${common_env_data.extra_scripts}
lib_deps = ${common_env_data.lib_deps}
lib_extra_dirs = ${common_env_data.lib_extra_dirs}
[env:smartoled_esp32]
platform = ${common_env_data.platform_esp32}
board = lolin_s3_mini
board_build.mcu = esp32s3
board_build.partitions = partitions/ESP32_4M_1800K_FLASH_300K_FS_OTA.csv
framework = ${common_env_data.framework}
;platform_packages = ${common_env_data.platform_packages}
build_unflags = -DARDUINO_USB_MODE=1
build_flags =
-D TARGET_SMARTOLED_ESP32
'-D ARDUINO_USB_MODE=0'
'-D ARDUINO_USB_CDC_ON_BOOT=1'
'-D WIFI_DEVICE_NAME="SMARTOLED"'
'-D MICROCONTROLLER_OTA_PORT=8278'
'-D WIFI_SIGNAL_STRENGTH=0'
'-D MICROCONTROLLER_IP="192.168.1.51"'
${common_env_data.common_build_flags}
monitor_speed = ${common_env_data.monitor_speed}
upload_speed = ${common_env_data.upload_speed}
board_build.filesystem = ${common_env_data.filesystem}
monitor_filters = ${common_env_data.monitor_filters_esp32}
monitor_port = COM17
;upload_port = COM17
upload_protocol = espota
upload_port = 192.168.1.51
upload_flags =
--port=8278
--auth=${secrets.ota_password}
extra_scripts = ${common_env_data.extra_scripts}
lib_deps = ${common_env_data.lib_deps}
lib_extra_dirs = ${common_env_data.lib_extra_dirs}
[env:smartostat]
platform = ${common_env_data.platform}
board = ${common_env_data.board}
framework = ${common_env_data.framework}
;platform_packages = ${common_env_data.platform_packages}
; set frequency to 160MHz
board_build.f_cpu = ${common_env_data.f_cpu}
; flash.4m.ld, flash.4m1m.ld, flash.4m2m.ld, flash.4m3m.ld Less memory for SPIFFS faster the upload
build_flags =
-D TARGET_SMARTOSTAT
'-D WIFI_DEVICE_NAME="SMARTOSTAT"'
'-D MICROCONTROLLER_OTA_PORT=8268'
'-D WIFI_SIGNAL_STRENGTH=20.5'
'-D MICROCONTROLLER_IP="192.168.1.50"'
${common_env_data.common_build_flags}
board_build.ldscript = eagle.flash.4m1m.ld
monitor_speed = ${common_env_data.monitor_speed}
upload_speed = ${common_env_data.upload_speed}
monitor_port = COM7
;upload_port = COM7
upload_protocol = espota
upload_port = 192.168.1.50
upload_flags =
--port=8268
--auth=${secrets.ota_password}
lib_ldf_mode = chain+
extra_scripts = ${common_env_data.extra_scripts}
lib_deps = ${common_env_data.lib_deps}
lib_extra_dirs = ${common_env_data.lib_extra_dirs}
[env:smartostat_esp32]
platform = ${common_env_data.platform_esp32}
board = lolin_s3_mini
board_build.mcu = esp32s3
board_build.partitions = partitions/ESP32_4M_1800K_FLASH_300K_FS_OTA.csv
framework = ${common_env_data.framework}
build_unflags = -DARDUINO_USB_MODE=1
build_flags =
-D TARGET_SMARTOSTAT_ESP32
'-D ARDUINO_USB_MODE=0'
'-D ARDUINO_USB_CDC_ON_BOOT=1'
'-D WIFI_DEVICE_NAME="SMARTOSTAT"'
'-D MICROCONTROLLER_OTA_PORT=8268'
'-D WIFI_SIGNAL_STRENGTH=20.5'
'-D MICROCONTROLLER_IP="192.168.1.50"'
${common_env_data.common_build_flags}
monitor_speed = ${common_env_data.monitor_speed}
upload_speed = ${common_env_data.upload_speed}
monitor_port = COM13
;upload_port = COM12
upload_protocol = espota
upload_port = 192.168.1.50
upload_flags =
--port=8268
--auth=${secrets.ota_password}
extra_scripts = ${common_env_data.extra_scripts}
lib_deps = ${common_env_data.lib_deps}
lib_extra_dirs = ${common_env_data.lib_extra_dirs}