neowx-material addininal values

174 views
Skip to first unread message

michae...@gmail.com

unread,
Jul 6, 2021, 1:03:13 PM7/6/21
to weewx-user
Hello,
the day before yesterday I installed neowx material as a skin. now i have added two additional fields in weewx, which are calledwohnHeiz andwohnSoll. Well I added

   #if $ day.wohnHeiz.has_data
   $ getChartJsCode ("wohnHeiz ", "wohnHeizchart", "area", "wohnHeiz ")
   #end if
  
   #if $ day.wohnSoll.has_data
   $ getChartJsCode ("wohnSoll ", "wohnSollchart", "area", "wohnSoll ")
   #end if

into the index.html.tmpl file
unfortunately it doesn't work then. Do I have to make an additional entry somewhere?

Greetings Michael

gjr80

unread,
Jul 6, 2021, 4:02:21 PM7/6/21
to weewx-user
The Neowx Material skin has been developed separately from WeeWX. As the per the Neowx Material web page I suggest you email the developer.

Gary

michae...@gmail.com

unread,
Jul 7, 2021, 11:08:40 AM7/7/21
to weewx-user
Thanks

Rainer Lang

unread,
Jul 8, 2021, 2:26:10 AM7/8/21
to weewx...@googlegroups.com

even though - to whom it may concern i.e. to whom who wants to use the new neowx-material skin and wants to add sensors/observations,
here is a mini-tutorial how to do this - in principle very simple due to the coding approach (shown below for the day charts only)

pre-requisite: the sensor/observation to be added has to exist in the weewx database and needs to have a value different from None in order to be shown (like in the Seasons skin)

2 changes need to be made in skin.conf

in the [[Appearance]] stanza the lines

value_order = outTemp,  ....
and
charts_order = outTemp, ....

the weewx database variables of the observation(s) need to be added at the position they are supposed to show

1 change (per variable) needs to be added to index.html.tmpl
usually towards the end before the </script> tag, assuming the chart to be displayed is of the "area" type ("default" type)

   #if $ day.variable1.has_data

   $ getChartJsCode ("variable1", "variable1chart", "area", "variable1")
   #end if

example:
if the variable were co2 and the desired position of the observation value(s) and chart were the last one on the skin
(N.B. in the neowx-material skin the value 'cards' show on the left hand side and the charts on the right hand side - like in the Seasons skin - only per observation there is a combined current/high/low 'card' per observation)

skin.conf would look like
[[Appearance]]
  // .... card order
value_order = outTemp,  ...., co2
 // .... chart order
charts_order = outTemp, ...., co2

and the end of index.html.tmpl would look like

..................
  // CO2 sensor - values in ppm

  #if $ day.co2.has_data

   $ getChartJsCode ("co2", "co2chart", "area", "co2")
   #end if

</script>

The result can be seen at http://meshka.eu  - Link: Neowx Material powered by weewx (WH2650)

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/4d46c655-14ad-4af8-b4e4-1454d9a2910dn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages