Skip to content

Commit

Permalink
Update xiaomi_ir.yaml
Browse files Browse the repository at this point in the history
Updated for latest ESPHome version to fix compilation bugs
  • Loading branch information
AdamKGoddard authored Feb 28, 2023
1 parent dece122 commit 38bfb48
Showing 1 changed file with 37 additions and 36 deletions.
73 changes: 37 additions & 36 deletions xiaomi_ir.yaml
Original file line number Diff line number Diff line change
@@ -1,39 +1,40 @@
substitutions:
devicename: xiaomi_ir
upper_devicename: Xiaomi IR Remote

esphome:
name: $devicename
platform: ESP32
board: esp32doit-devkit-v1
name: xiaomi-ir
friendly_name: Xiaomi-IR
platformio_options:
extra_scripts: pre:../pre_extra_script.py
platform: [email protected]
platform_packages: |-4
framework-arduinoespressif32 @ https://github.com/pauln/arduino-esp32.git#solo-no-mac-crc/1.0.4
wifi:
ssid: "your_SSID_here"
password: "your_Password_here"
extra_scripts:
- pre:pre_extra_script.py
platform_packages:
- framework-arduinoespressif32 @ https://github.com/pauln/arduino-esp32.git#solo-no-mac-crc/1.0.6
platform:
- espressif32

# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Xiaomi Ir Fallback Hotspot"
password: "your_Password_here"

captive_portal:
esp32:
board: esp32doit-devkit-v1

# Enable logging
logger:

# Enable Home Assistant API
api:
password: "api_password_here"
encryption:
key: "your encryption key"

ota:
password: "ota_password_here"

password: "your ota password"

wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password

# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Xiaomi-Ir Fallback Hotspot"
password: "your fallback password"

captive_portal:

web_server:
port: 80

Expand All @@ -42,25 +43,25 @@ binary_sensor:
pin:
number: GPIO32
inverted: False
name: ${upper_devicename} Button A
name: ${friendly_name} Button A

- platform: gpio
pin:
number: GPIO33
inverted: False
name: ${upper_devicename} Button B
name: ${friendly_name} Button B

- platform: gpio
pin:
number: GPIO34
inverted: False
name: ${upper_devicename} Button C
name: ${friendly_name} Button C

- platform: gpio
pin:
number: GPIO35
inverted: False
name: ${upper_devicename} Button D
name: ${friendly_name} Button D

status_led:
pin:
Expand All @@ -74,25 +75,25 @@ output:

sensor:
- platform: wifi_signal
name: ${upper_devicename} WiFi Signal
name: ${friendly_name} WiFi Signal

- platform: uptime
name: ${upper_devicename} Uptime
name: ${friendly_name} Uptime

switch:
- platform: restart
name: ${upper_devicename} Restart
name: ${friendly_name} Restart

- platform: template
name: ${upper_devicename} LG TV Power On
name: ${friendly_name} LG TV Power On
turn_on_action:
- remote_transmitter.transmit_lg:
data: 0x02FD48B7
nbits: 32
transmitter_id: internal
transmitter_id: xiaomi

mqtt:
broker: "your_broker_ip_address"
broker: "your broker ip"
username: "your_mqtt_username"
password: "your_mqtt_password"
discovery: True
Expand All @@ -106,6 +107,6 @@ remote_receiver:
remote_transmitter:
pin:
number: GPIO26
inverted: False #Needs idle state to be set to high. Not currently feasible. Will cause board heating.
inverted: False
carrier_duty_percent: 50%
id: internal
id: xiaomi

0 comments on commit 38bfb48

Please sign in to comment.