Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

Something has been changed in the JSON of the V2 #118

Open
Kime203 opened this issue Feb 7, 2023 · 1 comment
Open

Something has been changed in the JSON of the V2 #118

Kime203 opened this issue Feb 7, 2023 · 1 comment

Comments

@Kime203
Copy link

Kime203 commented Feb 7, 2023

There may have been a change in the structure of the JSON in V2. I would have corrected it like this.

` // ******* Direct values ******* //

        $cumulus[2] = $wlJson->sensors[0]->data[0]->temp;
        $cumulus[3] = $wlJson->sensors[0]->data[0]->hum;
        $cumulus[4] = $wlJson->sensors[0]->data[0]->dew_point;                              // Dewpoint
        $cumulus[5] = $wlJson->sensors[0]->data[0]->wind_speed_last;                        // Used by W34 for trend calc. Wind this moment
        $cumulus[6] = $wlJson->sensors[0]->data[0]->wind_speed_avg_last_10_min;             // Wind 10 min avg
        $cumulus[7] = $wlJson->sensors[0]->data[0]->wind_dir_last;                          // Wind direction
        $cumulus[8] = $wlJson->sensors[0]->data[0]->rain_rate_last_in;                      // Rain rate in/h
        $cumulus[9] = $wlJson->sensors[0]->data[0]->rainfall_last_24_hr_in;                 // Rain in inches(in)
        $cumulus[10] = $wlJson->sensors[1]->data[0]->bar_absolute;                          // Pressure inches
        $cumulus[13] = "mph";                                                               // Windspeed unit 
        $cumulus[14] = "F";                                                                 // Temp unit
        $cumulus[15] = "in";                                                                // Pressure unit
        $cumulus[16] = "in";                                                                // Rain unit
        $cumulus[19] = $wlJson->sensors[0]->data[0]->rainfall_monthly_in;                   // Rain acc. Month inches
        $cumulus[20] = $wlJson->sensors[0]->data[0]->rainfall_year_in;                      // Rain acc. Year  
        $cumulus[22] = $wlJson->sensors[2]->data[0]->temp_in;                               // Inside temp
        $cumulus[23] = $wlJson->sensors[2]->data[0]->hum_in;                                // Inside humidity
        $cumulus[24] = $wlJson->sensors[0]->data[0]->wind_chill;                            // Wind chill
        $cumulus[40] = $wlJson->sensors[0]->data[0]->wind_speed_avg_last_10_min;            // Windgust avg. 10 min`
@MatsA
Copy link
Contributor

MatsA commented Mar 3, 2023

Hi !

Seems that you are referring to my interface software on how to create Cumulus data.
https://github.com/MatsA/weatherlink-data-pull_v2

I think there is no actual change but we have different sources for the weather data. I'm using a Vantage Pro2, cabled sensor type 2, with data structure type 2 and you are probably using something else with another data structure.

At this site https://weatherlink.github.io/v2-api/interactive-sensor-catalog you can check out the differences.

Thanks for your comment !
Mats

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

No branches or pull requests

2 participants