initial commit
This commit is contained in:
6
.gitignore
vendored
Normal file
6
.gitignore
vendored
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
# Gitignore settings for ESPHome
|
||||||
|
# This is an example and may include too much for your use-case.
|
||||||
|
# You can modify this file to suit your needs.
|
||||||
|
/.esphome/
|
||||||
|
/secrets.yaml
|
||||||
|
/.sync-exclude.lst
|
||||||
97
air_ac.yaml
Normal file
97
air_ac.yaml
Normal file
@ -0,0 +1,97 @@
|
|||||||
|
substitutions:
|
||||||
|
name: "air-conditioner"
|
||||||
|
friendly_name: "Air Conditioner"
|
||||||
|
|
||||||
|
esphome:
|
||||||
|
name: "${name}"
|
||||||
|
friendly_name: "${friendly_name}"
|
||||||
|
platform: ESP8266
|
||||||
|
board: esp12e
|
||||||
|
name_add_mac_suffix: true
|
||||||
|
|
||||||
|
wifi:
|
||||||
|
ssid: !secret wifi_ssid
|
||||||
|
password: !secret wifi_password
|
||||||
|
ap:
|
||||||
|
ssid: ${friendly_name} Fallback
|
||||||
|
password: !secret fallback_password
|
||||||
|
|
||||||
|
captive_portal:
|
||||||
|
|
||||||
|
# Enable logging
|
||||||
|
logger:
|
||||||
|
level: INFO
|
||||||
|
baud_rate: 0
|
||||||
|
|
||||||
|
# Enable Home Assistant API
|
||||||
|
api:
|
||||||
|
ota:
|
||||||
|
|
||||||
|
uart:
|
||||||
|
tx_pin: 1
|
||||||
|
rx_pin: 3
|
||||||
|
baud_rate: 9600
|
||||||
|
|
||||||
|
remote_transmitter:
|
||||||
|
pin:
|
||||||
|
number: GPIO5
|
||||||
|
inverted: true
|
||||||
|
mode: OUTPUT_OPEN_DRAIN
|
||||||
|
carrier_duty_percent: 100%
|
||||||
|
|
||||||
|
climate:
|
||||||
|
- platform: midea
|
||||||
|
name: "midea" # Use a unique name.
|
||||||
|
period: 1s # Optional
|
||||||
|
timeout: 2s # Optional
|
||||||
|
num_attempts: 3 # Optional
|
||||||
|
autoconf: true # Autoconfigure most options.
|
||||||
|
beeper: false # Beep on commands.
|
||||||
|
visual: # Optional. Example of visual settings override.
|
||||||
|
min_temperature: 17 °C # min: 17
|
||||||
|
max_temperature: 30 °C # max: 30
|
||||||
|
temperature_step: 0.5 °C # min: 0.5
|
||||||
|
supported_modes: # All capabilities in this section detected by autoconf.
|
||||||
|
- FAN_ONLY # This capability is always used.
|
||||||
|
# - HEAT_COOL
|
||||||
|
- COOL
|
||||||
|
# - HEAT
|
||||||
|
- DRY
|
||||||
|
supported_presets: # All capabilities in this section detected by autoconf.
|
||||||
|
# - ECO
|
||||||
|
# - BOOST
|
||||||
|
# - SLEEP # This capability is always used.
|
||||||
|
# custom_presets: # All capabilities in this section detected by autoconf.
|
||||||
|
# - FREEZE_PROTECTION
|
||||||
|
supported_swing_modes:
|
||||||
|
- VERTICAL # This capability is always used.
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: homeassistant
|
||||||
|
id: external_temp
|
||||||
|
entity_id: sensor.temperature_humidity_sensor_bb09_temperature # Sensor from HASS
|
||||||
|
internal: false
|
||||||
|
filters:
|
||||||
|
- throttle: 5min
|
||||||
|
- heartbeat: 1min
|
||||||
|
on_value:
|
||||||
|
midea_ac.follow_me:
|
||||||
|
temperature: !lambda "return float((x - 32.0) * (5.0/9.0));"
|
||||||
|
beeper: false
|
||||||
|
|
||||||
|
switch:
|
||||||
|
- platform: template
|
||||||
|
name: Beeper
|
||||||
|
icon: mdi:volume-source
|
||||||
|
optimistic: true
|
||||||
|
turn_on_action:
|
||||||
|
midea_ac.beeper_on:
|
||||||
|
turn_off_action:
|
||||||
|
midea_ac.beeper_off:
|
||||||
|
|
||||||
|
button:
|
||||||
|
- platform: template
|
||||||
|
name: Display Toggle
|
||||||
|
icon: mdi:theme-light-dark
|
||||||
|
on_press:
|
||||||
|
midea_ac.display_toggle:
|
||||||
96
athom-rgbct-light.yaml
Normal file
96
athom-rgbct-light.yaml
Normal file
@ -0,0 +1,96 @@
|
|||||||
|
substitutions:
|
||||||
|
name: athom-rgbct-light
|
||||||
|
friendly_name: "Athom RGBCT Light"
|
||||||
|
light_restore_mode: ALWAYS_OFF
|
||||||
|
external_components:
|
||||||
|
- source:
|
||||||
|
type: git
|
||||||
|
url: https://github.com/KaufHA/common
|
||||||
|
components: [ ddp ]
|
||||||
|
refresh: always
|
||||||
|
packages:
|
||||||
|
athom.rgbct-light: github://cb513/athom-configs/athom-rgbct-light.yaml
|
||||||
|
esphome:
|
||||||
|
name: ${name}
|
||||||
|
name_add_mac_suffix: true
|
||||||
|
build_path: /tmp/esphome
|
||||||
|
esp8266:
|
||||||
|
restore_from_flash: false
|
||||||
|
wifi:
|
||||||
|
ssid: !secret wifi_ssid
|
||||||
|
password: !secret wifi_password
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
api:
|
||||||
|
encryption:
|
||||||
|
key: !secret encryption_key
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
debug:
|
||||||
|
|
||||||
|
ddp:
|
||||||
|
|
||||||
|
web_server: !remove
|
||||||
|
|
||||||
|
logger:
|
||||||
|
level: debug
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
light:
|
||||||
|
- id: !extend rgbct_light
|
||||||
|
name: ' '
|
||||||
|
default_transition_length: 0s
|
||||||
|
effects:
|
||||||
|
- ddp:
|
||||||
|
name: DDP
|
||||||
|
timeout: 10s
|
||||||
|
disable_gamma: true
|
||||||
|
brightness_scaling: none
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
time:
|
||||||
|
- id: !remove sntp_time
|
||||||
|
|
||||||
|
- platform: homeassistant
|
||||||
|
id: hass_time
|
||||||
|
on_time_sync:
|
||||||
|
then:
|
||||||
|
- if:
|
||||||
|
condition:
|
||||||
|
lambda: 'return id(device_last_restart).state == "";'
|
||||||
|
then:
|
||||||
|
- text_sensor.template.publish:
|
||||||
|
id: device_last_restart
|
||||||
|
state: !lambda '
|
||||||
|
char str[21];
|
||||||
|
time_t currTime = id(hass_time).now().timestamp;
|
||||||
|
strftime(str, sizeof(str), "%Y-%m-%dT%H:%M:%SZ", gmtime(&currTime));
|
||||||
|
return str;'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
text_sensor:
|
||||||
|
- id: !remove uptime_template
|
||||||
|
|
||||||
|
- platform: debug
|
||||||
|
reset_reason:
|
||||||
|
name: "Reset Reason"
|
||||||
|
|
||||||
|
- platform: template
|
||||||
|
id: !extend device_last_restart
|
||||||
|
device_class: timestamp
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: uptime
|
||||||
|
id: !remove uptime_sensor
|
||||||
|
|
||||||
|
- platform: copy
|
||||||
|
id: !remove wifi_signal_percent
|
||||||
|
|
||||||
|
- platform: wifi_signal
|
||||||
|
id: !extend wifi_signal_db
|
||||||
|
name: "WiFi Signal"
|
||||||
96
athom-rgbww-light.yaml
Normal file
96
athom-rgbww-light.yaml
Normal file
@ -0,0 +1,96 @@
|
|||||||
|
substitutions:
|
||||||
|
name: athom-rgbww-light
|
||||||
|
friendly_name: "Athom RGBWW Light"
|
||||||
|
light_restore_mode: ALWAYS_OFF
|
||||||
|
|
||||||
|
external_components:
|
||||||
|
- source:
|
||||||
|
type: git
|
||||||
|
url: https://github.com/KaufHA/common
|
||||||
|
components: [ ddp ]
|
||||||
|
refresh: always
|
||||||
|
packages:
|
||||||
|
athom.rgbww-light: github://cb513/athom-configs/athom-rgbww-light.yaml
|
||||||
|
esphome:
|
||||||
|
name: ${name}
|
||||||
|
name_add_mac_suffix: true
|
||||||
|
esp8266:
|
||||||
|
restore_from_flash: false
|
||||||
|
wifi:
|
||||||
|
ssid: !secret wifi_ssid
|
||||||
|
password: !secret wifi_password
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
api:
|
||||||
|
encryption:
|
||||||
|
key: !secret encryption_key
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
debug:
|
||||||
|
|
||||||
|
ddp:
|
||||||
|
|
||||||
|
web_server: !remove
|
||||||
|
|
||||||
|
logger:
|
||||||
|
level: debug
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
light:
|
||||||
|
- id: !extend rgbww_light
|
||||||
|
name: ' '
|
||||||
|
default_transition_length: 0s
|
||||||
|
effects:
|
||||||
|
- ddp:
|
||||||
|
name: DDP
|
||||||
|
timeout: 10s
|
||||||
|
disable_gamma: true
|
||||||
|
brightness_scaling: none
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
time:
|
||||||
|
- id: !remove sntp_time
|
||||||
|
|
||||||
|
- platform: homeassistant
|
||||||
|
id: hass_time
|
||||||
|
on_time_sync:
|
||||||
|
then:
|
||||||
|
- if:
|
||||||
|
condition:
|
||||||
|
lambda: 'return id(device_last_restart).state == "";'
|
||||||
|
then:
|
||||||
|
- text_sensor.template.publish:
|
||||||
|
id: device_last_restart
|
||||||
|
state: !lambda '
|
||||||
|
char str[21];
|
||||||
|
time_t currTime = id(hass_time).now().timestamp;
|
||||||
|
strftime(str, sizeof(str), "%Y-%m-%dT%H:%M:%SZ", gmtime(&currTime));
|
||||||
|
return str;'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
text_sensor:
|
||||||
|
- id: !remove uptime_template
|
||||||
|
|
||||||
|
- platform: debug
|
||||||
|
reset_reason:
|
||||||
|
name: "Reset Reason"
|
||||||
|
|
||||||
|
- platform: template
|
||||||
|
id: !extend device_last_restart
|
||||||
|
device_class: timestamp
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: uptime
|
||||||
|
id: !remove uptime_sensor
|
||||||
|
|
||||||
|
- platform: copy
|
||||||
|
id: !remove wifi_signal_percent
|
||||||
|
|
||||||
|
- platform: wifi_signal
|
||||||
|
id: !extend wifi_signal_db
|
||||||
|
name: "WiFi Signal"
|
||||||
74
esproxy.yaml
Normal file
74
esproxy.yaml
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
substitutions:
|
||||||
|
name: "esproxy"
|
||||||
|
friendly_name: "ESProxy"
|
||||||
|
|
||||||
|
esphome:
|
||||||
|
name: "${name}"
|
||||||
|
friendly_name: "${friendly_name}"
|
||||||
|
name_add_mac_suffix: true
|
||||||
|
build_path: /tmp/esphome
|
||||||
|
|
||||||
|
esp32:
|
||||||
|
board: nodemcu-32s
|
||||||
|
framework:
|
||||||
|
type: esp-idf
|
||||||
|
|
||||||
|
wifi:
|
||||||
|
ssid: !secret wifi_ssid
|
||||||
|
password: !secret wifi_password
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
logger:
|
||||||
|
|
||||||
|
api:
|
||||||
|
encryption:
|
||||||
|
key: !secret encryption_key
|
||||||
|
reboot_timeout: 0s
|
||||||
|
|
||||||
|
ota:
|
||||||
|
platform: esphome
|
||||||
|
|
||||||
|
esp32_ble_tracker:
|
||||||
|
scan_parameters:
|
||||||
|
active: true
|
||||||
|
|
||||||
|
bluetooth_proxy:
|
||||||
|
active: true
|
||||||
|
|
||||||
|
debug:
|
||||||
|
|
||||||
|
time:
|
||||||
|
- platform: homeassistant
|
||||||
|
id: hass_time
|
||||||
|
on_time_sync:
|
||||||
|
then:
|
||||||
|
- if:
|
||||||
|
condition:
|
||||||
|
lambda: 'return id(device_last_restart).state == "";'
|
||||||
|
then:
|
||||||
|
- text_sensor.template.publish:
|
||||||
|
id: device_last_restart
|
||||||
|
state: !lambda '
|
||||||
|
char str[21];
|
||||||
|
time_t currTime = id(hass_time).now().timestamp;
|
||||||
|
strftime(str, sizeof(str), "%Y-%m-%dT%H:%M:%SZ", gmtime(&currTime));
|
||||||
|
return str;'
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: wifi_signal
|
||||||
|
name: "WiFi Signal"
|
||||||
|
id: wifi_signal_db
|
||||||
|
update_interval: 60s
|
||||||
|
entity_category: "diagnostic"
|
||||||
|
|
||||||
|
text_sensor:
|
||||||
|
- platform: debug
|
||||||
|
reset_reason:
|
||||||
|
name: "Reset Reason"
|
||||||
|
|
||||||
|
- platform: template
|
||||||
|
name: 'Last Restart'
|
||||||
|
id: device_last_restart
|
||||||
|
icon: mdi:clock
|
||||||
|
entity_category: diagnostic
|
||||||
|
device_class: timestamp
|
||||||
Reference in New Issue
Block a user