Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- esphome:
- name: esphome_network_cab_bt
- platform: ESP32
- board: esp32doit-devkit-v1
- wifi:
- ssid: xxx
- password:xxx
- use_address:xxx
- # Enable fallback hotspot (captive portal) in case wifi connection fails
- ap:
- ssid: 'FB Portal'
- password: xxxxx
- captive_portal:
- # Enable logging
- logger:
- level: DEBUG
- # Enable Home Assistant API
- api:
- password: xxx
- ota:
- password: xxxx
- status_led:
- pin:
- number: GPIO02
- inverted: True
- switch:
- - platform: restart
- name: "Restart Network Cab ESPHome"
- esp32_ble_tracker:
- text_sensor:
- - platform: template
- name: "ATC Heartbeat (4D)"
- id: heartbeat43d
- sensor:
- #-------------------------------------------------------------------------------
- #A
- - platform: pvvx_mithermometer
- mac_address: "A4:C1:38:4F:19:3D"
- temperature:
- name: "ATC Temperature (4)"
- on_value:
- - text_sensor.template.publish:
- id: heartbeat4d
- state: !lambda |-
- time_t rawtime;
- struct tm * timeinfo;
- char buffer [80];
- time (&rawtime);
- timeinfo = localtime (&rawtime);
- strftime (buffer,80,"%m/%d/%Y %H:%M:%S",timeinfo);
- return std::string(buffer);
- humidity:
- name: "ATC Humidity (4)"
- on_value:
- - text_sensor.template.publish:
- id: heartbeat4fd
- state: !lambda |-
- time_t rawtime;
- struct tm * timeinfo;
- char buffer [80];
- time (&rawtime);
- timeinfo = localtime (&rawtime);
- strftime (buffer,80,"%m/%d/%Y %H:%M:%S",timeinfo);
- return std::string(buffer);
- battery_level:
- name: "ATC Battery-Level (4)"
- on_value:
- - text_sensor.template.publish:
- id: heartbeat4f
- state: !lambda |-
- time_t rawtime;
- struct tm * timeinfo;
- char buffer [80];
- time (&rawtime);
- timeinfo = localtime (&rawtime);
- strftime (buffer,80,"%m/%d/%Y %H:%M:%S",timeinfo);
- return std::string(buffer);
- flag_value:
- name: "ATC Flag Value (4)"
- battery_voltage:
- name: "ATC Battery-Voltage (4)"
- binary_sensor:
- - platform: pvvx_mithermometer
- mac_address: "A"
- reed_switch:
- name: "ATC Reed Switch (4D)"
- #===================================================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement