Samsung Air Conditioner

I’m probably missing something here, but how do I get my devices to be controlled by the custom integration and have the extra feature after installing the integration and restarting Home Assistant?

My AC still does no show the new features.

This repo deserves more attention. I wasted my whole day setting up restful commands (successfully, after many attempts, but for sure less elegantly than using this integration), while here is the definitive solution and it was super easy to set it up. Thank you for linking it.

1 Like

For no reason the smartthings integration disappeared from devices&integrations. On the logs the only thing I can see is that the integration was loaded:

How can I fix this?

EDITED: It looks like samsung change something on authentication. Added the integration again and it is ok.

can anyone comment if this integration is still working well? and also can it be exposed to homekit?

can anyone comment on the reliability of this? particularly someone using a windfree aircon?

Hello,
I am using the smartthings integration togeter with veista/smartthings
(GitHub - veista/smartthings: A fork of the Home Assistant SmartThings Integration. This adds better support for Samsung OCF Devices.) for the windfree airco.

Works fine, almost all options are available. I am only missing the option to set ‘comfort mode’

  • Copy files from veista to '/config/custom_components/smartthings'
  • Add smartthings integration
  • That one creates a webhook which is tested by the integration
  • If OK it connects to smartthings.It asks for the token of the airco
  • Smartthings want soms answers on questions and then the connection is made.
  • Windfree airco is active in HA. It seems to find the files from veista on its own.
1 Like

Hi,

I have successfully integrated my Samsung smartthings account into the home hosted HA.
I can see and control the ACs, but the values of the power and energy are not changing.
The energy was loaded initially with 76kwh and never changed . The power does always ay at 0W.
Also reloading the integration does not change the behaviour.

Did someone got this working?
Thanks a lot , Mark

Hello friends,

I tried getting the token for my Samsung Windfree 2019 AC, but I get an error message when I ran the actest.py command:

SamsungAC % python3 actest.py
Traceback (most recent call last):
File “/Users/mjeshurun/Desktop/SamsungAC/actest.py”, line 1, in
import requests
ModuleNotFoundError: No module named ‘requests’
mjeshurun@Miki-MacBook-Pro SamsungAC % python3 actest.py
Traceback (most recent call last):
File “/Users/mjeshurun/Desktop/SamsungAC/actest.py”, line 1, in
import requests
ModuleNotFoundError: No module named ‘requests’

Am I doing something wrong?Preformatted text

Hello,

See this topic:

1 Like

I’ve been trying to retrieve a token for my ~10 year old Samsung ‘Smart’ WiFi enabled AC to avoid having to consider a more costly alternative to incorporating into HA but have not been successful thus far. all methods that i’ve been able to attempt all seem to end up with an SSL error, notably SSL: CA_MD_TOO_WEAK. From my research, this is due to usage of SHA5 signature that is either no longer supported or able to be used?

Is there an alternative way to bypass this or re-sign a new cert that is currently compatible some how?

Hello,

I tried different solutions to integrate the OCF Devices functions in my HA but nothing worked fine.

  1. My Samsung AC doen’t have the 8888 or 2878 opened so I can’t use the samsungrac integration couse I’m not able to get the token from my devices
  2. veista/smartthings is not being updated and i lose some important entities from the last official smartthings integration.
  3. I’m not so skilled to modify climate.py and device.py as suggested by JRFabbi in this post.

For that reasons I tried a more dirty solution based on rest command.

Fisrt of all I read from the API the value of the capability

####      entities      ####
  - platform: rest
    name: "Device_name_acMode"
    resource: https://api.smartthings.com/v1/devices/{device_id}/components/main/capabilities/airConditionerMode/status
    method: GET
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    value_template: '{{ value_json.airConditionerMode.value }}'
    scan_interval: 5

  - platform: rest
    name: "Device_name_acOptionalMode"
    resource: https://api.smartthings.com/v1/devices/{device_id}/components/main/capabilities/custom.airConditionerOptionalMode/status
    method: GET
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    value_template: '{{ value_json.acOptionalMode.value }}'
    scan_interval: 5
    
  - platform: rest
    name: "Device_name_acFanOscillationMode"
    resource: https://api.smartthings.com/v1/devices/{device_id}/components/main/capabilities/fanOscillationMode/status
    method: GET
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    value_template: '{{ value_json.fanOscillationMode.value }}'
    scan_interval: 5
    
  - platform: rest
    name: "Device_name_acFanMode"
    resource: https://api.smartthings.com/v1/devices/{device_id}/components/main/capabilities/airConditionerFanMode/status
    method: GET
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    value_template: '{{ value_json.fanMode.value }}'
    scan_interval: 5

Secondly I set some command to change the capabilty value

####      command      ####
rest_command:
  Device_name_acmode_cool:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerMode",  "command": "setAirConditionerMode",  "arguments": [ "cool" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acmode_auto:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerMode",  "command": "setAirConditionerMode",  "arguments": [ "auto" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acmode_dry:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerMode",  "command": "setAirConditionerMode",  "arguments": [ "dry" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acmode_wind:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerMode",  "command": "setAirConditionerMode",  "arguments": [ "wind" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acmode_heat:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerMode",  "command": "setAirConditionerMode",  "arguments": [ "heat" ]}  ]}'
    content_type: 'application/json; charset=utf-8' 

  Device_name_acoptionalmode_off:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "custom.airConditionerOptionalMode",  "command": "setAcOptionalMode",  "arguments": [ "off" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acoptionalmode_quiet:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "custom.airConditionerOptionalMode",  "command": "setAcOptionalMode",  "arguments": [ "sleep" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acoptionalmode_speed:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "custom.airConditionerOptionalMode",  "command": "setAcOptionalMode",  "arguments": [ "speed" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acoptionalmode_windfree:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "custom.airConditionerOptionalMode",  "command": "setAcOptionalMode",  "arguments": [ "windFree" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanoscillationmode_fixed:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "fanOscillationMode",  "command": "setFanOscillationMode",  "arguments": [ "fixed" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanoscillationmode_all:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "fanOscillationMode",  "command": "setFanOscillationMode",  "arguments": [ "all" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanoscillationmode_vertical:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "fanOscillationMode",  "command": "setFanOscillationMode",  "arguments": [ "vertical" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanoscillationmode_horizontal:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "fanOscillationMode",  "command": "setFanOscillationMode",  "arguments": [ "horizontal" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanmode_auto:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerFanMode",  "command": "setFanMode",  "arguments": [ "auto" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanmode_low:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerFanMode",  "command": "setFanMode",  "arguments": [ "low" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanmode_medium:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerFanMode",  "command": "setFanMode",  "arguments": [ "medium" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanmode_high:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerFanMode",  "command": "setFanMode",  "arguments": [ "high" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

  Device_name_acfanmode_turbo:
    url: https://api.smartthings.com/v1/devices/{device_id}/commands
    method: POST
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    payload: '{  "commands": [{  "component": "main",  "capability": "airConditionerFanMode",  "command": "setFanMode",  "arguments": [ "turbo" ]}  ]}'
    content_type: 'application/json; charset=utf-8'

Finally I create a card (mushroom template) with some buttons to control all the capability

Screenshot 2023-10-21 135709

I hope this could help someone but anyway I’ll be very gald to receive some suggestions to improve my configuration!

In particular on the card, I would like to use Simple thermostat but I’m not able to create new buttons and use the rest_command on these.

Screenshot 2023-10-21 140156

Thank you for sharing this. I optimized a bit the retrieval part.

rest:
  - resource: https://api.smartthings.com/v1/devices/{device-id}/status
    method: GET
    headers:
      authorization: !secret smartthings_token
      accept: 'application/json'
      user-agent: 'Home-Assistant'
    scan_interval: 60
    sensor:
      - name: "Living Room AC Status"
        value_template: '{{ value_json.components.main.switch.switch.value }}'
      - name: "Living Room AC Humidity"
        device_class: humidity
        value_template: '{{ value_json.components.main.relativeHumidityMeasurement.humidity.value }}'
      - name: "Living Room AC Temperature"
        device_class: temperature
        unit_of_measurement: "°C"
        value_template: '{{ value_json.components.main.temperatureMeasurement.temperature.value }}'
      - name: "Living Room AC Mode"
        value_template: '{{ value_json.components.main.airConditionerMode.airConditionerMode.value }}'
      - name: "Living Room AC Oscillation Mode"
        value_template: '{{ value_json.components.main.fanOscillationMode.fanOscillationMode.value }}'
      - name: "Living Room AC Fan Mode"
        value_template: '{{ value_json.components.main.airConditionerFanMode.fanMode.value }}'

Maybe it’s possible to combine status and commands eventually as a template. I am having a look.

This is my current config

Hope it helps some body else as well

@viennacalling Cool, thanks for sharing. For a while I have been trying to implement something like this but to allow me to turn off the display. Have you explored the API and found a command that will allow us to turn off the display ? This is specially useful during the night if we want to automate the turn on\off of the internal units and not have the annoying display lighting the room during the night.

not sure. maybe it’s the custom.donotdisturbe mode… you can find the commands available for your device here: https://my.smartthings.com/advanced/devices though they lack of documentation

Good news, now the official integration has originalli the - hvac, - fan, - swing control and also the - preset the allow to use windfree

This js the result with simple-thermostat card with only the original integration.

1 Like

great news! did you build this card? Greetings, I’m Italian too

Hello everyone! :wave:

I wanted to share a project that might be of great interest to those looking to integrate their Samsung WindFree air conditioners into Home Assistant with advanced monitoring and control capabilities.

:star2: Project Overview

Our ESPHome Samsung HVAC Bus Integration project (link below) is a comprehensive solution for connecting Samsung WindFree and other HVAC units to Home Assistant using the ESP32 platform. We’ve focused on enabling seamless communication, precise energy monitoring, and detailed control over various features of your HVAC units.

:link: Project Wiki & Setup Guide

Key Features:

  • Support for NASA and Non-NASA protocols: Our integration covers both NASA (Networked Air Solution Architecture) and Non-NASA units, providing compatibility with a wide range of Samsung HVAC models.
  • Energy Monitoring Sensors: We’ve included sensors for tracking outdoor instantaneous power consumption and cumulative energy usage, helping you manage and optimize energy consumption effectively.
  • Temperature and Environmental Monitoring: Get precise readings of outdoor and indoor temperatures, supporting smarter climate management in Home Assistant.
  • Advanced Control Features: Control fan speed, operation mode, swing settings, and more directly from your Home Assistant dashboard.
  • Optimized Codebase: Significant refactoring and memory optimizations have been implemented to ensure reliable performance even on low-power devices like the M5Stack ATOM Lite with RS-485 modules.

:globe_with_meridians: Who is this for?

This project is ideal for Home Assistant enthusiasts and tech-savvy individuals who want deeper control and visibility over their Samsung HVAC systems. It’s an open-source solution, and we actively engage with the community to continuously improve it.

Feel free to check out our detailed documentation and installation guide on the project’s GitHub Wiki. If you have any questions or suggestions, your feedback is more than welcome!

image image

Was that integration ever created? I lost the last 3 nights trying to fetch the token from my AC without success. My computer is a Windows 11 machine and I can’t make ANY of the python scripts I found work properly. With newer versions of python it rejects the security level in the curl request. If I use the windows curl it doesn’t accept the cert.pem file. I don’t know what else to do to get the token.

Have you solved this? Which version are you trying to get the token from? 8888 or 2878?