### Install JciHitachi Integration via Shell Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Provides command-line instructions for installing the integration manually by creating the custom_components directory and copying the source files. ```bash mkdir -p config/custom_components cp -r jcihitachi_tw config/custom_components/ # Restart Home Assistant ``` -------------------------------- ### Configure JciHitachi via YAML Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Example configuration for the Home Assistant configuration.yaml file, including required credentials and optional device filtering. ```yaml jcihitachi_tw: email: yourname@yourdomain.com password: your_password retry: 5 devices: - Living Room AC - Bedroom Dehumidifier - Office Heat Exchanger ``` -------------------------------- ### Install JciHitachiHA Integration via HACS Source: https://github.com/qqaatw/jcihitachiha/blob/master/README.md This snippet shows how to install the JciHitachiHA integration using HACS by providing a badge that links to Home Assistant's HACS repository configuration page. It requires Home Assistant and HACS to be installed. ```markdown [![Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.](https://my.home-assistant.io/badges/hacs_repository.svg)](https://my.home-assistant.io/redirect/hacs_repository/?owner=qqaatw&repository=JciHitachiHA) ``` -------------------------------- ### YAML Home Assistant Services for Month Selector Source: https://context7.com/qqaatw/jcihitachiha/llms.txt YAML examples demonstrating how to use Home Assistant services to set the value of a number entity, specifically for the month selector. This allows users to select historical months for viewing power consumption data. ```yaml # Set month selector to view data from 3 months ago service: number.set_value target: entity_id: number.living_room_ac_month_selector data: value: 3 # Reset to current month service: number.set_value target: entity_id: number.living_room_ac_month_selector data: value: 0 ``` -------------------------------- ### Control Humidifier Entity via Home Assistant Services Source: https://context7.com/qqaatw/jcihitachiha/llms.txt YAML service call examples for toggling power, setting modes, and adjusting target humidity on dehumidifier entities. ```yaml service: humidifier.turn_on target: entity_id: humidifier.bedroom_dehumidifier service: humidifier.set_mode target: entity_id: humidifier.bedroom_dehumidifier data: mode: "Clothes Dry" service: humidifier.set_humidity target: entity_id: humidifier.bedroom_dehumidifier data: humidity: 55 ``` -------------------------------- ### Control Climate Entity via Home Assistant Services Source: https://context7.com/qqaatw/jcihitachiha/llms.txt YAML service call examples for managing HVAC modes, temperature, fan speed, swing, and preset modes for climate entities. ```yaml service: climate.set_hvac_mode target: entity_id: climate.living_room_ac data: hvac_mode: cool service: climate.set_temperature target: entity_id: climate.living_room_ac data: temperature: 24 service: climate.set_fan_mode target: entity_id: climate.living_room_ac data: fan_mode: medium service: climate.set_swing_mode target: entity_id: climate.living_room_ac data: swing_mode: both service: climate.set_preset_mode target: entity_id: climate.living_room_ac data: preset_mode: eco ``` -------------------------------- ### Define HVAC Swing and Preset Modes Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Configuration constants defining the supported swing patterns and energy-saving preset modes for Hitachi climate entities. ```python SUPPORT_SWING = [ SWING_OFF, SWING_VERTICAL, SWING_HORIZONTAL, SWING_BOTH, SWING_HORIZONTAL_LEFTMOST, SWING_HORIZONTAL_MIDDLE_LEFT, SWING_HORIZONTAL_MIDDLE_RIGHT, SWING_HORIZONTAL_RIGHTMOST, SWING_HORIZONTAL_LEFTMOST_VERTICAL_SWING, SWING_HORIZONTAL_MIDDLE_LEFT_VERTICAL_SWING, SWING_HORIZONTAL_MIDDLE_RIGHT_VERTICAL_SWING, SWING_HORIZONTAL_RIGHTMOST_VERTICAL_SWING ] PRESET_MODES = [ PRESET_NONE, PRESET_ECO, PRESET_MOLD_PREVENTION, PRESET_ECO_MOLD_PREVENTION, PRESET_BOOST ] ``` -------------------------------- ### Configure JciHitachiHA via configuration.yaml Source: https://github.com/qqaatw/jcihitachiha/blob/master/README.md This snippet demonstrates how to configure the JciHitachiHA integration by adding device details to the Home Assistant configuration.yaml file. It requires the integration files to be in the custom_components folder and a Home Assistant restart after configuration. ```yaml jcihitachi_tw: - email: "YOUR_EMAIL" password: "YOUR_PASSWORD" device_name: "YOUR_DEVICE_NAME" ``` -------------------------------- ### Define Configuration Schema Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Defines the validation schema for the integration using Voluptuous, ensuring correct types for email, password, and optional settings. ```python import homeassistant.helpers.config_validation as cv import voluptuous as vol from homeassistant.const import CONF_DEVICES, CONF_EMAIL, CONF_PASSWORD DOMAIN = "jcihitachi_tw" CONF_RETRY = "retry" CONFIG_SCHEMA = vol.Schema( { DOMAIN: vol.Schema( { vol.Required(CONF_EMAIL): cv.string, vol.Required(CONF_PASSWORD): cv.string, vol.Optional(CONF_RETRY, default=5): cv.positive_int, vol.Optional(CONF_DEVICES, default=[]): vol.All(cv.ensure_list, list), } ) }, extra=vol.ALLOW_EXTRA, ) ``` -------------------------------- ### Define Fan and Heat Exchanger Speeds Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Configuration constants for ordered fan speeds and heat exchanger ventilation preset modes. ```python ORDERED_NAMED_FAN_SPEEDS = ["auto", "silent", "low", "moderate", "high"] HEAT_EXCHANGER_PRESET_MODES = ["auto", "energy_recovery", "normal"] ``` -------------------------------- ### Control Display Brightness via Light Services Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Shows how to control the dehumidifier's display brightness using Home Assistant light service calls. This includes turning the display on at full brightness, setting it to a specific level, or turning it off completely. ```yaml # Turn on display at full brightness service: light.turn_on target: entity_id: light.bedroom_dehumidifier_panel_led ``` ```yaml # Set display to specific brightness level service: light.turn_on target: entity_id: light.bedroom_dehumidifier_panel_led data: brightness: 170 # Dim mode ``` ```yaml # Turn off display completely service: light.turn_off target: entity_id: light.bedroom_dehumidifier_panel_led ``` -------------------------------- ### Control Dehumidifier Display Brightness (Light Entity) Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Explains the light entity used for controlling the dehumidifier panel LED brightness. It maps specific brightness levels ('bright', 'dark', 'off', 'all_off') to Home Assistant brightness values. ```python # Brightness levels mapping brightness_mapping = { "bright": 255, # Full brightness (HA brightness > 170) "dark": 170, # Dim brightness (85 < HA brightness <= 170) "off": 85, # Very dim (3 < HA brightness <= 85) "all_off": 0, # Completely off (HA brightness <= 3) } # Entity name: "{device_name} panel LED" # Example: light.bedroom_dehumidifier_panel_led ``` -------------------------------- ### Monitor Sensor Entities Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Details various sensor entities for monitoring environmental conditions and power consumption. Includes sensors for Air Conditioners, Dehumidifiers, and Heat Exchangers, providing data like power usage, humidity, temperature, and air quality. ```python # Air Conditioner sensors: # - Power Consumption: Total energy usage in kWh (state_class: total_increasing) # - Monthly Power Consumption: Monthly energy usage in kWh # - Month Indicator: Current month for power data in YYYY-MM format # Dehumidifier sensors: # - Indoor Humidity: Current room humidity in % # - PM2.5: Particulate matter concentration in µg/m³ # - Odor Level: Air quality indicator (Low, Middle, High) # - Power Consumption: Total energy usage in kWh # - Monthly Power Consumption: Monthly energy usage in kWh # - Month Indicator: Current month for power data # Heat Exchanger sensors: # - Indoor Temperature: Current room temperature in °C # Example sensor entity IDs: # sensor.living_room_ac_power_consumption # sensor.living_room_ac_monthly_power_consumption # sensor.living_room_ac_month_indicator # sensor.bedroom_dehumidifier_indoor_humidity # sensor.bedroom_dehumidifier_pm2_5 # sensor.bedroom_dehumidifier_odor_level # sensor.office_heat_exchanger_indoor_temperature ``` -------------------------------- ### Define Climate Entity Capabilities Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Lists the supported HVAC and fan modes for the climate entity, mapping Hitachi device features to Home Assistant constants. ```python SUPPORT_HVAC = [HVACMode.OFF, HVACMode.COOL, HVACMode.DRY, HVACMode.FAN_ONLY, HVACMode.AUTO, HVACMode.HEAT] SUPPORT_FAN = [FAN_AUTO, FAN_SILENT, FAN_LOW, FAN_MEDIUM, FAN_HIGH, FAN_RAPID, FAN_EXPRESS] ``` -------------------------------- ### Define Humidifier Modes Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Constants defining the available operation modes for Hitachi dehumidifier entities. ```python AVAILABLE_MODES = [ MODE_AUTO, MODE_CUSTOM, MODE_CONTINUOUS, MODE_CLOTHES_DRY, MODE_AIR_PURIFY, MODE_MOLD_PREV, MODE_LOW_HUMIDITY, MODE_ECO_COMFORT ] ``` -------------------------------- ### Control Dehumidifier Features via Switch Services Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Demonstrates how to use Home Assistant switch services to control dehumidifier features. This includes enabling/disabling the air cleaning filter, mold prevention, ion generator, keypad lock, and louver swing. ```yaml # Enable air cleaning filter service: switch.turn_on target: entity_id: switch.bedroom_dehumidifier_air_cleaning_filter_setting ``` ```yaml # Disable air cleaning filter service: switch.turn_off target: entity_id: switch.bedroom_dehumidifier_air_cleaning_filter_setting ``` ```yaml # Enable mold prevention service: switch.turn_on target: entity_id: switch.bedroom_dehumidifier_mold_prevention ``` ```yaml # Enable negative ion generator service: switch.turn_on target: entity_id: switch.bedroom_dehumidifier_ion ``` ```yaml # Lock keypad service: switch.turn_on target: entity_id: switch.bedroom_dehumidifier_keypad_lock ``` ```yaml # Enable louver swing service: switch.turn_on target: entity_id: switch.bedroom_dehumidifier_wind_swingable ``` -------------------------------- ### YAML Automation: AC Eco Mode During Peak Hours Source: https://context7.com/qqaatw/jcihitachiha/llms.txt A Home Assistant automation in YAML that enables eco mode for the living room AC at 2 PM, provided the AC is not already off. This is useful for managing energy consumption during peak hours. ```yaml # Enable eco mode during peak hours automation: - alias: "AC Eco Mode During Peak Hours" trigger: - platform: time at: "14:00:00" condition: - condition: not conditions: - condition: state entity_id: climate.living_room_ac state: "off" action: - service: climate.set_preset_mode target: entity_id: climate.living_room_ac data: preset_mode: eco ``` -------------------------------- ### Monitor Binary Sensor Entities Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Describes binary sensor entities used for monitoring dehumidifier error states and water tank status. These sensors indicate problems such as device errors or a full water tank. ```python # Dehumidifier binary sensors: # - Error: Indicates device error (device_class: problem) # - is_on: True when error_code != 0 # - Water Full Warning: Indicates full water tank (device_class: problem) # - is_on: True when water_full_warning == "on" # Example entity IDs: # binary_sensor.bedroom_dehumidifier_error # binary_sensor.bedroom_dehumidifier_water_full_warning ``` -------------------------------- ### Python Number Entity for Month Selection Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Python code snippet for a number entity used as a month selector for historical power consumption data. It defines the range of selectable months (0 for current, 12 for 12 months ago) and outlines the API call triggered when a value is set. ```python # Month selector for historical power data # - native_min_value: 0 (current month) # - native_max_value: 12 (12 months ago) # - Entity name: "{device_name} Month Selector" # When value is set, it triggers: # api.refresh_monthly_data(int(month_value), device_name) ``` -------------------------------- ### Control Fan Operations Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Provides services to turn fans on, turn them off, set their percentage speed, and set preset modes like 'auto' or 'energy_recovery'. These services interact with specific fan entities. ```yaml service: fan.turn_on target: entity_id: fan.bedroom_dehumidifier_air_speed ``` ```yaml service: fan.turn_off target: entity_id: fan.bedroom_dehumidifier_air_speed ``` ```yaml service: fan.set_percentage target: entity_id: fan.bedroom_dehumidifier_air_speed data: percentage: 60 ``` ```yaml service: fan.set_preset_mode target: entity_id: fan.bedroom_dehumidifier_air_speed data: preset_mode: auto ``` ```yaml service: fan.set_preset_mode target: entity_id: fan.office_heat_exchanger_air_speed data: preset_mode: energy_recovery ``` -------------------------------- ### YAML Automation: Dehumidifier Water Full Alert Source: https://context7.com/qqaatw/jcihitachiha/llms.txt A Home Assistant automation in YAML that sends a notification to a mobile app when the dehumidifier's water tank is full, indicated by the `binary_sensor.bedroom_dehumidifier_water_full_warning` entity changing to 'on'. ```yaml # Alert when dehumidifier water tank is full automation: - alias: "Dehumidifier Water Full Alert" trigger: - platform: state entity_id: binary_sensor.bedroom_dehumidifier_water_full_warning to: "on" action: - service: notify.mobile_app data: title: "Dehumidifier Alert" message: "Water tank is full. Please empty it." ``` -------------------------------- ### Control Dehumidifier Switch Entities Source: https://context7.com/qqaatw/jcihitachiha/llms.txt Lists switch entities for controlling various dehumidifier features like the air cleaning filter, mold prevention, louver swing, ion generator, and keypad lock. These allow for toggling specific functionalities on or off. ```python # Dehumidifier switch entities: # - Air Cleaning Filter Setting: Enable/disable air cleaning filter # - Clean Filter Notification: Enable/disable filter cleaning alerts # - Mold Prevention: Enable/disable mold prevention feature # - Wind Swingable: Enable/disable louver swing # - Ion: Enable/disable negative ion generator # - Keypad Lock: Enable/disable physical keypad lock # Example entity IDs: # switch.bedroom_dehumidifier_air_cleaning_filter_setting # switch.bedroom_dehumidifier_clean_filter_notification # switch.bedroom_dehumidifier_mold_prevention # switch.bedroom_dehumidifier_wind_swingable # switch.bedroom_dehumidifier_ion # switch.bedroom_dehumidifier_keypad_lock ``` -------------------------------- ### YAML Automation: Auto AC Off When Cool Source: https://context7.com/qqaatw/jcihitachiha/llms.txt A Home Assistant automation written in YAML that automatically turns off the living room AC when the current temperature drops below 22 degrees Celsius and the AC is in 'cool' mode. ```yaml # Turn off AC when temperature drops below threshold automation: - alias: "Auto AC Off When Cool" trigger: - platform: numeric_state entity_id: climate.living_room_ac attribute: current_temperature below: 22 condition: - condition: state entity_id: climate.living_room_ac state: "cool" action: - service: climate.set_hvac_mode target: entity_id: climate.living_room_ac data: hvac_mode: "off" ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.