Skip to content

Latest commit

 

History

History
123 lines (91 loc) · 6.71 KB

README.md

File metadata and controls

123 lines (91 loc) · 6.71 KB

⏻ Smart IR

HACS Badge License Latest Release Code style

Overview

SmartIR is a custom integration for controlling climate, media player, fan and light devices via infrared controllers.

SmartIR currently supports the following controllers:

More than 120 climate devices are currently supported out-of-the-box, mainly for the Broadlink controller, thanks to our awesome community.

Don't forget to star the repository if you had fun!

Disclaimer

This is a fork of the original repository smartHomeHub/SmartIR which seems to be unmaintained at the time with many pull requests pending. As some of those were useful to my usage I decided to fork and merge the work of the corresponding authors to allow for simple usage of the integration through HACS. Therefore all the corresponding rights belong to the original authors. I also lately started to fix some additional users issues, implementing HomeAssistant future compatibility changes and adding some functionality, trying to keep compatibility but please note, that there may be some breaking changes from the original version.

MIGRATION from original SmartIR

If you want to migrate from the original SmartIR project, please note following:

  1. Configuration is different! Do not use original configuration, refer to documentation for the proper syntax! Especially remove the smartir: section. I highly suggest to remove original SmartIR cnfiguration and create it from scratch based on configuration examples n the docs.
  2. Codes are different! Please use codes maintained within this project. If you have custom codes, those will likely need some rework - check documentation for proper code files syntax. If your code file is not working enable debug logging and see the logs.
  3. Code files placement is different! Please see following section before having nasty surprise!

WARNING - custom codes!

If you use any own/custom codes json files please backup such json files before migrating to this integration from the original one. After instalation (using HACS) please place your custom files into new custom_codes directory. codes directory is managed by HACS and you will loose all changes during any HACS update!

Installation

HACS

If you want HACS to handle installation and updates, add SmartIR url https://github.com/litinoveweedle/SmartIR as a custom repository in the HACS. This is preffered instalation method as it would allow for automatic updates.

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

Manual

Download latest smartir.zip file and place it's content in the custom_components folder in your HomeAssistant configuration custom_component/smartir directory. The resulting directory structure should look similar to this:

<config directory>/
|-- custom_components/
|   |-- smartir/
|       |-- __init__.py
|       |-- climate.py
        |-- controller.py
|       |-- fan.py
|       |-- media_player.py
        |--light.py
|       |-- codes/
|           |-- climate/
|               |-- 1000.json
|               |-- .....
|           |-- fan/
|               |-- 1000.json
|               |-- .....
|           |-- media_player/
|               |-- 1000.json
|               |-- .....
           |-- light/
|               |-- 1000.json
|               |-- .....
|       |-- custom_codes/
|           |-- climate/
|               |-- 1000.json
|               |-- .....
|           |-- fan/
|               |-- 1000.json
|               |-- .....
|           |-- media_player/
|               |-- 1000.json
|               |-- .....
          |-- light/
|               |-- 1000.json
|               |-- .....

Device Data - IR Codes

To properly function, specification of your controlled device data including IR codes shall exists either in codes or in custom_codes directory as a .JSON file. When installed both using HACS or manual method, codes directory is populated by device data files maintained by this project. If you would like to create your own device data file, place it in the custom_codes class climate|fan|media_player|light subdirectory, this directory is persistent and will be manitained accross HACS updates. Please don't forget to create PR for this new device data file and I will try to include it in a new releases.

Convert IR Codes from Broadlink to Z06/UFO-R11

Using https://gist.github.com/svyatogor/7839d00303998a9fa37eb48494dd680f?permalink_comment_id=5153002#gistcomment-5153002 you can convert Broadlink code file.

Example: python3 broadlink_to_tuya.py 1287.json > 9997.json

Platform setup instructions

Click on the links below for instructions on how to configure each platform.

Debug logging

In case of any issues, especially if you are going to open the issue, enable debug logging first and reproduce your isse.

    custom_components.smartir.climate: debug
    custom_components.smartir.fan: debug
    custom_components.smartir.media_player: debug
    custom_components.smartir.light: debug

See also