Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Ranges for tempOffset and humidityOffset #1802

Open
ldeora opened this issue Dec 9, 2024 · 0 comments
Open

Update Ranges for tempOffset and humidityOffset #1802

ldeora opened this issue Dec 9, 2024 · 0 comments

Comments

@ldeora
Copy link

ldeora commented Dec 9, 2024

Description:
The current ranges for tempOffset and humidityOffset configurations are too limited. The tempOffset is restricted to -10 to 10, and the humidityOffset is also restricted to -10 to 10. To provide greater flexibility for calibration, these ranges need to be expanded:

  • tempOffset: -20 to 20
  • humidityOffset: -20 to 20

Steps to Reproduce:

  1. Access the tempOffset or humidityOffset in device preferences of a temperature/humidity sensor.
  2. Attempt to set values outside the respective ranges (-10 to 10 for both).
  3. Observe that the system rejects these values.

Expected Behavior:
Both tempOffset and humidityOffset should support expanded ranges:

  • tempOffset: Accept values between -20 and 20.
  • humidityOffset: Accept values between -20 and 20.

Actual Behavior:

  • tempOffset is restricted to values between -10 and 10.
  • humidityOffset is restricted to values between -10 and 10.

Suggested Fix:
Update the tempOffset and humidityOffset range definitions in the firmware (I guess):

tempOffset = {
  definition = {
    default = 0,
    maximum = 20,
    minimum = -20,
  },
  description = "Temperature Offset",
  preferenceType = "number",
  title = "TempOffset",
}

humidityOffset = {
  definition = {
    default = 0,
    maximum = 20,
    minimum = -20,
  },
  description = "Enter a percentage to adjust the humidity.",
  preferenceType = "integer",
  title = "Humidity Offset",
}

Additional Context:
Expanding these ranges ensures compatibility with a wider variety of cases that require larger calibration adjustments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant