Hello everyone, I’m new to Home Assistant coming from Openhab, and I’ve been trying to figure out how to map numerical values to display text for my AC fan speed settings. In Openhab, it was straightforward with their selection item syntax, but I’m finding the process a bit more involved in HA.
Here’s what I’ve got so far: my AC fan has three settings—low, medium, and high—which correspond to the values 0, 1, and 2 respectively. I want these values, which come from my MQTT topic, to display as readable text in my UI.
I’ve tried setting up the options in my configuration like this:
yaml
- name: “AC Fan”
command_topic: “ha/mod/xxxx/XF”
state_topic: “ha/mod/xxxx/F”
options:- “Low”
- “Med”
- “High”
But it doesn’t seem to work as expected. I understand that HA might require some templating or custom logic to handle this mapping, but I’m not quite sure how to implement it properly.
After some research, I think using a template might be the way to go, but everything I’ve come across seems overly complex for such a simple task. I’m considering creating an intermediate object in Node-RED to handle the translation between the numerical values and their corresponding display text.
Has anyone successfully tackled a similar issue? I’d love to hear your solutions or workarounds. I’m sure there’s a more streamlined approach that I’m missing. Let’s collaborate and figure this out together! ![]()