mentalilll / ha-vpd-chart

VPD Chart for Homeassistant
50 stars 0 forks source link

Values showing up at the wrong spot of the chart #18

Open jayme-github opened 2 months ago

jayme-github commented 2 months ago

Checklist

Describe the bug The tooltip is showing correct values, but the white dot seems to be placed in the wrong area of the chart (see screenshot).

Version of the card Version: 1.5.0

To Reproduce This is the configuration I used:

type: custom:ha-vpd-chart
sensors:
  - temperature: sensor.sonoff_snzb_02_1_temperature
    humidity: sensor.sonoff_snzb_02_1_humidity_calibrated
    leaf_temperature: sensor.sonoff_snzb_02_1_temperature
    name: Sonoff
vpd_phases:
  - upper: 0
    className: gray-danger-zone
    color: '#999999'
  - lower: 0
    upper: 0.4
    className: under-transpiration
    color: '#1a6c9c'
  - lower: 0.4
    upper: 0.8
    className: early-veg
    color: '#22ab9c'
  - lower: 0.8
    upper: 1.2
    className: late-veg
    color: '#9cc55b'
  - lower: 1.2
    upper: 1.6
    className: mid-late-flower
    color: '#e7c12b'
  - lower: 1.6
    className: danger-zone
    color: '#ce4234'
is_bar_view: false
min_temperature: 5
max_temperature: 35
min_humidity: 10
max_humidity: 90
min_height: 200
leaf_temperature_offset: 2
enable_tooltip: true
air_text: Air
rh_text: RH
kpa_text: kPa
enable_axes: true
enable_ghostclick: true
enable_ghostmap: true
enable_triangle: false
enable_crosshair: true
enable_fahrenheit: false
enable_zoom: true
enable_show_always_informations: true
enable_legend: false
ghostmap_hours: 24
unit_temperature: °C

Screenshots image

Desktop (please complete the following information):

flo269 commented 2 months ago

I'm having the same issue again as well. I am using a separate leaf temperature sensor. Please let me know if there's anything I can supply to help.

mentalilll commented 2 months ago

Hey,

use calculated rh. That's for recalculation of theoretical humidity.

Because Leaf Temperature Sensor is used on VPD Calculations, so there are 2 ways to render calculation. For that task, I need to calculate rH from Temperature and kPa.

Maybe I call that function LeafTemperature Positioning. Don't know what would here more sense.

image

lmnx commented 1 month ago

Hi, I'm having similar issue. I would like to recommend a few things to help. First, I think it should provide 2 different types of VPD calculations in this case, as some of us may not have leaf temperature sensors.

Some terminology changes could be useful too as "Calculated RH?" could be confusing (since I already provided RH value). On the other hand, distinguishing between "Air VPD", "Plant VPD", and "Calculated Plant VPD" would sound more intuitive imo.