Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Master #18

Merged
merged 5 commits into from
Jan 11, 2022
Merged

Master #18

merged 5 commits into from
Jan 11, 2022

Conversation

zepiaf
Copy link
Owner

@zepiaf zepiaf commented Jan 10, 2022

Major refactoring :

  • winter_credit is now a module
  • hydro_api only handle hydro quebec API calls and auth
  • mqtt now publish the entire objects for both next event and state

Data format is now more versatile:

  • pre_start is now pre_heat and has configurable offset
  • reference periods are configurable and are calculated for the current day
  • all datetime fields have equivalent _ts that correspond to unix epoch (timestamp)

Configuration is now in yaml

Documentation has been updated

- winter_credit is now a module
- hydro_api only handle hydro quebec API calls and auth
- mqtt now publish the entire objects for both next event and state

Data format is now more versatile:

- pre_start is now pre_heat and has configurable offset
- reference periods are configurable and are calculated for the current day
- all datetime fields have equivalent _ts that correspond to unix epoch (timestamp)

Configuration is now in yaml

Documentation has been updated
- winter_credit is now a module
- hydro_api only handle hydro quebec API calls and auth
- mqtt now publish the entire objects for both next event and state

Data format is now more versatile:

- pre_start is now pre_heat and has configurable offset
- reference periods are configurable and are calculated for the current day
- all datetime fields have equivalent _ts that correspond to unix epoch (timestamp)

Configuration is now in yaml

Documentation has been updated
@mdallaire
Copy link
Collaborator

For the mqtt topic, I think that having a default base topic of "hydroqc" would be a good idea.
hydroqc/winterpeak/#

This would let us add more subtopic later on for other info fetched from the API. You may also want to add the contractid somewhere in there to accommodate future users with more than one contract.

hydroqc/123456/winterpeak/
hydroqc/123456/otherstats
hydroqc/789123/winterpeak
hydroqc/789123/otherstats

And the cherry on top would be to have a default of hydroqc for the topic but have it configurable in the config.yaml file. I think this structure would also help with an eventual integration of hass mqtt discovery further down the road.

This allows for more flexibility (even if multi-contract is not supported yet)
@zepiaf
Copy link
Owner Author

zepiaf commented Jan 10, 2022

basetopic and contract added

@zepiaf zepiaf merged commit b1337e6 into main Jan 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants