Round temperatures to tenths or whole numbers?

Greetings,

I just set up a SharpTools.io web dashboard for use with Hubitat with the intent of monitoring the temperature of various rooms/sensors around the house. Most of what I’ve done is use existing contact and motion sensors that have a “temperature” attribute, then changing that tile layout to use “Hero Attribute,” then selecting “Temperature” as the primary attribute.

That part was easy.

Now, however, I see some of my sensors have the degree down to the one-hundredth. See screenshot below:

SensorTemps

Is there something I can do to round this to the nearest whole number or at least (most?) the nearest tenth? I’m sure that this has something to do with how the sensor itself is reporting this attribute, but (calibration of the sensor aside) this is way more information than I need–so much that it makes it hard to tell at a glance whether some rooms are a similar temperature or not.

If I can already do this, let me know (besides the only/mega-effort workaround I can think of: creating virtual devices in Hubitat for each of these sensors that rounds the actual sensor reading to the precision of my pleasing and using that device here instead). Otherwise, I guess this is a feature request. :slight_smile:

2 Likes

You nailed it - it’s the way the device driver reports the value. The driver could be updated to report a rounded value, but I think it’s something that should be a configurable option in the SharpTools UI as well.

I totally agree. We’ve had a few other requests for this, so it’s on the list. I need to work through it to determine the best place to put a configuration option. A quick win might be to put a rounding option directly on the Hero Attribute tile configuration.

There have been some suggestions around applying this as a more generic user profile preference, but I think there are some potential challenges with that. For example, users who have their temperatures reported in °C may want their temperatures reported with at least one decimal place but may not care about decimals for other types of values. I’m open to suggestions and feedback on it though!

3 Likes

Today’s SharpTools.io release includes decimal rounding options for Hero Attribute tiles (among a number of other cool new features)! Check out the following post for more details:

2 Likes