mirror of
https://github.com/UtilitechAS/amsreader-firmware.git
synced 2026-02-26 08:54:36 +00:00
PlatformIO configuration
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -6,3 +6,4 @@
|
||||
*.sw[op]
|
||||
.vscode
|
||||
.pio
|
||||
platformio-user.ini
|
||||
@@ -5,8 +5,8 @@
|
||||
*/
|
||||
|
||||
|
||||
#define HAS_DALLAS_TEMP_SENSOR 1 // Set to zero if Dallas one wire temp sensor is not present
|
||||
#define IS_CUSTOM_AMS_BOARD 1 // Set to zero if using NodeMCU or board not designed by Roar Fredriksen
|
||||
//#define HAS_DALLAS_TEMP_SENSOR 1 // Set to zero if Dallas one wire temp sensor is not present
|
||||
//#define IS_CUSTOM_AMS_BOARD 1 // Set to zero if using NodeMCU or board not designed by Roar Fredriksen
|
||||
|
||||
#include <ArduinoJson.h>
|
||||
#include <MQTT.h>
|
||||
|
||||
13
platformio-user.ini-example
Normal file
13
platformio-user.ini-example
Normal file
@@ -0,0 +1,13 @@
|
||||
[platformio]
|
||||
default_envs = dev
|
||||
|
||||
[env:dev]
|
||||
platform = espressif8266
|
||||
board = esp12e
|
||||
framework = ${common.framework}
|
||||
lib_deps = ${common.lib_deps}
|
||||
build_flags =
|
||||
-D HAS_DALLAS_TEMP_SENSOR=0
|
||||
-D IS_CUSTOM_AMS_BOARD=0
|
||||
monitor_speed = 2400
|
||||
monitor_flags = --parity E
|
||||
@@ -1,22 +1,26 @@
|
||||
;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]
|
||||
src_dir = Arduino Code/AmsToMqttBridge
|
||||
lib_dir = Arduino Code/Arduino Libraries/
|
||||
extra_configs = platformio-user.ini
|
||||
|
||||
[common]
|
||||
framework = arduino
|
||||
lib_deps = HanConfigAp@1.0.0, HanReader@1.0.0, HanToJson@1.0.0, ArduinoJson@^6.0.0, MQTT@^2.4.0, DallasTemperature@^3.8.0
|
||||
|
||||
[env:esp12e]
|
||||
platform = espressif8266
|
||||
board = esp12e
|
||||
framework = arduino
|
||||
monitor_speed = 2400
|
||||
lib_deps = HanConfigAp@1.0.0, HanReader@1.0.0, HanToJson@1.0.0, ArduinoJson@^6.0.0, MQTT@^2.4.0, DallasTemperature@^3.8.0
|
||||
monitor_flags=
|
||||
--parity
|
||||
E
|
||||
framework = ${common.framework}
|
||||
lib_deps = ${common.lib_deps}
|
||||
build_flags =
|
||||
-D HAS_DALLAS_TEMP_SENSOR=0
|
||||
-D IS_CUSTOM_AMS_BOARD=0
|
||||
|
||||
[env:hw1esp12e]
|
||||
platform = espressif8266
|
||||
board = esp12e
|
||||
framework = ${common.framework}
|
||||
lib_deps = ${common.lib_deps}
|
||||
build_flags =
|
||||
-D HAS_DALLAS_TEMP_SENSOR=1
|
||||
-D IS_CUSTOM_AMS_BOARD=1
|
||||
|
||||
Reference in New Issue
Block a user