fix #1966 min/max for sensors