MMM-Netatmo icon indicating copy to clipboard operation
MMM-Netatmo copied to clipboard

display measurements with respect to the users unit settings

Open CFenner opened this issue 7 years ago • 4 comments

see #23

CFenner avatar Oct 11 '16 09:10 CFenner

Christopher, in the discussion of issue #23, you mentioned that your understanding of the Weather API was that the data was being sent in the correct units. I believe the documentation provided in the introduction to the API contradicts that.

From the technical data provided in the introduction to the Weather Station API, it seems Netatmo is providing weather data in the following format: screen shot 2017-01-16 at 5 49 58 pm

Netatmo users are provided with the following regional preference setting options from their browser (the settings are similar in the iOS/android apps): screen shot 2017-01-16 at 5 46 00 pm

The 'user' parameter within the API gives the necessary data to correct the returned data within the application: screen shot 2017-01-16 at 5 54 17 pm

I am very new to coding (esp. in Javascript) so please forgive any errors in syntax I may make. Is it feasible to build three arguments to implement these 'unit', 'windunit' and 'pressureunit' parameters in the "formatter" function?

macogle avatar Jan 17 '17 03:01 macogle

linked to #148

CFenner avatar Aug 15 '23 13:08 CFenner

We already get this from the station data API call:

Bildschirmfoto 2023-08-15 um 15 39 04

CFenner avatar Aug 15 '23 13:08 CFenner

So the issue is NetAtmo's API always returns the measurement values in a specific set of units... but it also provides user units preferences so it can be converted afterwards, right?

It's indeed a weird implementation... but couldn't the preferences be fetched and stored when initiating the module, then simply convert the fetched measurement values, and display the proper units, based on that? Or something like that? Is there any other part of information missing?

y0m1g avatar May 13 '24 15:05 y0m1g