--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/W_Eg07xAfPI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Those instructions are very specific to the case where the user is adding a separate module to create a new field rather than your case where you just want to extend the schema, my apologies, I should have read them in their entirety first. You should be fine following those instructions but using the file user/extensions.py rather than user/electricity.py. user/extensions.py should already exist and probably only has some comments and code to set the locale, just add the additional code at the end.
There is certainly more info in various post sources in the forums but I think this case is something that should be better covered in the guides. I will add it to the list.
Gary
Hi Gary,
Can you give a hint as to what the additional should be? Will this
extent the DB?
Ron
import schemas.wviewschema_with_humidex = schemas.wview.schema + [('humidex', 'REAL')]
[DataBindings][[wx_binding]]database = archive_sqlitetable_name = archivemanager = weewx.wxmanager.WXDaySummaryManagerschema = user.myschema.schema_with_himidex
It's been several years since I did this, but given that humidex is in the LOOP stuff, I *think* you just need to ...
That said, I never extend the weewx schema as of v3 supporting multiple databases. I've found that putting stuff in a separate db, even if it's just an archive with entries that are dateTime and humdex, makes me somehow feel better that I won't mess up the whole thing. So to me extending the weewx db schema is kind of superseded by 'adding a new custom db' for anything I've done since v3 came out. But the stuff above matches my very hazy recollection of how to add stuff to the weewx db schema.
Yep, clear as mud. The correct location turned out to be '/usr/share/weewx/user'.
good point I guess - it was just a thought, though I still feel that if the driver outputs the field the database should, by default, handle it. How this is achieved is another matter entirely, and wview compatability should, in 2018, be a by-product of weewx's flexibility rather than the driving force.