====== Software installation manual ====== The MitsuRunner source code can be downloaded here: https://github.com/VeliML/MitsuRunner/ ====== ESPHome Installation Guide (Windows) ====== Install ESPHome Development Environment on a Windows Machine * ESPHome uses Python, so download and install if necessary from https://python.org/ * Open the Windows "Command Prompt" and install ESPHome by entering the command: pip3 install esphome Additional instructions can be found here: https://www.esphome.io/guides/getting_started_hassio.html ⇒ ESPHome will be installed (you can ignore any WARNINGs that may occur during installation). Now the development environment is on your machine, and you can close the "Command Prompt." Test your assembled device with the "hw_check" program: https://github.com/VeliML/MitsuRunner/blob/main/hw_check/hw_check.yaml * Save the "hw_check.yaml" file to your desired directory (e.g., Runner) * Edit the file with your home network's WiFi parameters and OTI password * Ensure that the pin configurations for temperature sensors and relay control match your wiring * Connect your assembled device to your Windows machine via USB * Open the Windows Command Prompt, navigate to the "Runner" directory (using the "cd" command and the directory path). Enter the command "esphome hw_check.yaml run" If the compilation is successful, the program will ask for the upload method (USB or OTI). Choose USB. ⇒ the code will be uploaded to the device via USB. !! If the upload fails, make sure that the USB driver for WeMos_D1 is installed on your Windows machine. After installing HW_check, check: * The relay clicks (0.5 sec ON every 5 sec) * The computer screen displays a log showing: * The device is connected to your home network * DS18B20 temperature sensor IDs - make a note of these, you will need them later - and the measured temperatures * Also, test the OTI update by entering "esphome mitsurunner.yaml run" again, but this time select OTI as the upload method. ---- ====== ESPHome Installation Guide (Linux) ====== As a Linux user, you probably know how to find the instructions yourself on the internet ;) Instructions for installing ESPHome: https://esphome.io/guides/installing_esphome.html#linux Check the other instructions above. ---- ====== MitsuRunner Software Installation Guide ====== Download Mitsurunner from https://github.com/VeliML/MitsuRunner , select “Download ZIP” under “CODE” Extract the package to a folder of your choice. Edit //mitsu_conf.yaml// to match your Mitsurunner configuration (HW platform and reporting method). You can do this either by deleting unnecessary lines or by adding/removing comment characters “#” at the beginning of the line. Some examples: **a) mitsu_conf.yaml for Wemos-Mitsurunner with IoT-Guru** <<: !include platform_wemos.yaml ## Update file! packages: wifi_base: !include secrets.yaml ## Update file! dallas_base: !include dallas_hub.yaml mqtt_base: !include mqtt_Guru.yaml ## Update file! core_base: !include mitsurunner.yaml esphome: includes: - constants.h - state.h **b) mitsu_conf.yaml for Sonoff_Elite-Mitsurunner with HomeAssistant** <<: !include platform_elite.yaml ## Update file! packages: wifi_base: !include secrets.yaml ## Update file! dallas_base: !include dallas_hub.yaml mqtt_base: !include mqtt_disabled.yaml core_base: !include mitsurunner.yaml esphome: includes: - constants.h - state.h **c) mitsu_conf.yaml for Wemos-Mitsurunner without WiFi-connention** <<: !include platform_wemos.yaml ## Update file! packages: wifi_base: !include secrets_sa.yaml ## Update file! dallas_base: !include dallas_hub_status_Led.yaml ## On-boad LED blinks regularly when the device is working properly. mqtt_base: !include mqtt_disabled.yaml core_base: !include mitsurunner.yaml esphome: includes: - constants.h - state.h **Update the parameters to the files you are using** Detailed instructions for updating the parameters in each file. **1.platform_wemos.yaml / platform_elite.yaml** *DS18B20 sensor IDs *Used GPIO pins (DS18B20 1-wire and relay control) *When using HomeAssistant, enable the HomeAssistant api *Add a comment “#” to the beginning of the “level: INFO” line for more detailed trace data, this may be helpful during the Mitsurunner installation process **2.secrets.yaml / screts_sa.yaml** *WiFi-SSID and password *manual_ip address (if you remove all manual_ip configuration lines, a dynamic IP address is used) **3.mqtt_Guru.yaml / mqtt_local.yaml** *username, client_id, password *prefix **4. constants.h** file defines the operating parameters of Mitsurunner (timers, temperature limits). Usually the default values ​​work well, but you can also modify those if necessary. =========================================== ==== Compiling, downloading and testing the program with ESPTool ==== * Connect Mitsurunner with a USB cable, compile code and install binar to the device with the command esphome run mitsu_conf.yaml program starts, trace-log is printed on the screen. From trace-log check: * Mitsurunner is connected to your home network * The temperatures of the DS18B20 sensors are correct * Mitsurunner is connected to the MQTT server (if MQTT is enabled) * The information you have specified is updated to the MQTT server * If you use IoT-Guru without a USB connection, the trace-log will not be printed on the screen. However, you can see the log by going to the Mitsurunner IP address in a browser. ====Compiling, uploading and testing the program with the HomeAssistant ESPHome_Builder tool==== Mitsurunner software can also be compiled and uploaded with //HomeAssistant ESPHome_Builder// tool There are several ways to do this, one straightforward way is described below. Mitsurunner program created in this way can be uploaded as OTA over the version created with ESPTool without USB upload. 1) Create a new directory **mitsu** in the **HomeAssistant/esphome** directory 2) Copy the files defined in **mitsu_conf.yaml** directory to the **HomeAssistant/esphome/mitsu** directory 3) Edit **mitsu_conf.yaml** file by specifying the directory where the files are located. <<: !include mitsu/platform_wemos.yaml packages: wifi_base: !include mitsu/secrets.yaml dallas_base: !include mitsu/dallas_hub.yaml mqtt_base: !include mitsu/mqtt_disabled.yaml core_base: !include mitsu/mitsurunner.yaml esphome: includes: - mitsu/constants.h - mitsu/state.h 4) Add the **mitsu_conf.yaml** file you edited to the **HomeAssistant/esphome** directory. 5) Open //HomeAssistant ESPHome Builder//, there you will now see "Device" as **mitsu_conf** Select **edit**, you will see the contents of the "mitsu_conf.yaml" file, the first time the download is done via USB as follows: 6) Compile the code by selecting **install** --> **Manual download** --> a window will open where you can see the progress of the compilation. If/when the translation goes without errors, save the generated **mitsurunner.bin** file and close the window 7) Select //ESPHome/Device// on the **Mitsurunner/Edit** * select **install** again in the upper right corner * select **Plug into this computer** * select **Open ESPHome Web** * select **Connect** * select **USB port** * select **Establish connection** * select **Install** * select the previously saved **mitsurunner.bin** file * select **Install** Mitsurunner software is now downloaded and Mitsurunner should work. By selecting ESPHome/Device** Mitsurunner/logs** you can see the trace_log data sent by Mitsurunner. You can do the following downloads via OTA connection ESPHome/Device **Mitsurunner"/Edit** **install** ==> **Wirelessly**