diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ca0609a..4361b12 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -79,6 +79,7 @@ jobs: - "theengs-bridge" - "esp32dev-ble-idf" - "theengs-bridge-v11" + - "theengs-plug" - "esp32dev-ble-broker" runs-on: ubuntu-latest name: Build with PlatformIO diff --git a/environments.ini b/environments.ini index 8f4fc49..d7ac3a8 100644 --- a/environments.ini +++ b/environments.ini @@ -126,6 +126,64 @@ build_flags = custom_description = BLE gateway with external antenna and Ethernet/WiFi connectivity, [user guide](https://tbridge02.theengs.io/) custom_hardware = Theengs Bridge gateway ethernet +; DISCLAIMER: This is the default environment for Theengs Plug. +; Any modifications to this configuration are not covered by warranty. +; Proceed with caution when making changes. +; +; SAFETY WARNING: Do not modify values related to current limits MAX_CURRENT_ACTUATOR or other +; safety-critical parameters. Doing so may lead to fire hazards or damage to the device. +[env:theengs-plug] +platform = ${com.esp32_platform} +board = esp32dev +board_build.partitions = min_spiffs.csv +extra_scripts = ${com-esp32.extra_scripts} +lib_deps = + ${com-esp32.lib_deps} + ${libraries.ble} + ${libraries.decoder} + ${libraries.adafruit_neopixel} + ${libraries.rn8209} +build_flags = + ${env.build_flags} + ${com-esp32.build_flags} + '-DZgatewayBT="BT"' + '-DZsensorRN8209="RN8209"' + '-DRN8209_KU=18570' + '-DRN8209_KIA=265263' + '-DRN8209_EC=26675' + '-DTRIGGER_GPIO=4' + '-DZactuatorONOFF="ONOFF"' + '-DACTUATOR_ON=1' + '-DACTUATOR_OFF=0' + '-DACTUATOR_BUTTON_TRIGGER_LEVEL=0' + '-ACTUATOR_TRIGGER=true' + '-DZsensorGPIOInput="GPIOInput"' + '-DINPUT_GPIO=4' + '-DACTUATOR_ONOFF_GPIO=25' + '-DAttemptBLEConnect=false' + '-DLED_ADDRESSABLE=true' + '-DLED_ADDRESSABLE_PIN1=26' + '-DLED_ADDRESSABLE_PIN2=27' + '-DLED_ADDRESSABLE_NUM=2' + '-DLED_ADDRESSABLE_POWER=16' + '-DLED_ERROR=0' + '-DLED_PROCESSING=0' + '-DLED_BROKER=0' + '-DLED_NETWORK=0' + '-DLED_ACTUATOR_ONOFF=1' + ; Maximum current in A DO NOT MODIFY MAX_CURRENT_ACTUATOR + ;----------------------------- + '-DMAX_CURRENT_ACTUATOR=15.0' + ;----------------------------- + '-DWM_PWD_FROM_MAC=true' + '-DUSE_MAC_AS_GATEWAY_NAME' + '-DDEFAULT_LOW_POWER_MODE=DEACTIVATED' + '-DGATEWAY_MANUFACTURER="Theengs"' + '-DGATEWAY_MODEL="TPLUG01"' + '-UZwebUI="WebUI"' ; Disable WebUI +custom_description = Smart Plug, BLE Gateway and energy monitoring, [user guide](https://tplug01.theengs.io/) +custom_hardware = Theengs Plug + [env:esp32dev-all-test] platform = ${com.esp32_platform} board = esp32dev