Mapping certain floating point values to string

Hi,

I have the following definition of a thermostat item:

Number HeizungBadTargetTemp “Solltemp. Bad [%.1f °C]” (HeizungBad) [ “TargetTemperature” ]{channel=“innogysmarthome:RST:SMARTHOME08:212d005247cf45c8a4e9fac801ce22f1:set_temperature”}

A value of 6.0 ist shown as “Aus” (german for “Off”) on the physical thermostat and I would like this also to be shown in the OpenHAB app. I thought this should be possible with mapping value like this:

Number HeizungBadTargetTemp “Solltemp. Bad [MAP(thermostat.map):%.1f °C]” (HeizungBad) [ “TargetTemperature” ]{channel=“innogysmarthome:RST:SMARTHOME08:212d005247cf45c8a4e9fac801ce22f1:set_temperature”}

…with the thermostat.map like this:

6.0=“Aus”

But it seems that this doesn’t work. Can anyone tell me how this can be done or if it just isn’t possible?

Thanks in advance!

regards,
Stephan

MAP doesn’t work so well for numbers. 6 or 6.00 will not match in your map.

You don’t say, but I expect you want other numbers like 18.3 to pass through without being mapped? Can’t do that.

What you can do is use a javascript transform to single out values for special treatment, and return either special text or the original number.