Closed chasenicholl closed 1 year ago
@DMBlakeley take a look when you get a chance - local udp API implementation!
@chasenicholl will take a look. Nice work!
Have the 4.0.0 version running on my MacBook and 3.0.3 version running on my Mac mini so I can easily compare between the two versions.
Thanks @DMBlakeley!
Hi @chasenicholl,
I have dug into v4.0.0 comparing it to v3.0.3 as well as the Tempest App directly. I have a number of recommended changes to a number of files:
config.schema.json
: remove !model.local_api &&
from sensor properties. Still need functionBody
for local API.README.md
: update Local API example to include functionBody
platformAccessory.ts
: picked up an error in the getCurrentWindSpeed()
function for windspeed that existed in v3.0.3.tempest.ts
: added equations for heatIndex
, feelsLike
and windChill
. Corrected units.For the tempest.ts
changes I was reminded how HomeKit handles metric vs standard units. For supported units such as temperature
, humidity
, and wind speed
calculations are done with metric units. How they are displayed is a function of the localization of your iOS or Mac device. The units for additional parameters that were added as dummy occupancy sensor are handled by the plugin settings.
All the updated files can be found in my directory (https://github.com/DMBlakeley/homebridge-weatherflow-tempest). Now need to figure out how to push to you.
config.schema.json
which was blocking selection of occupancy sensor types.precip_accum_local_day
is not available when using local_API. Still need to code to check for this condition.Changes are in my files.
@DMBlakeley thank you for the thoughtful feedback. Please feel free to checkout this branch locally, commit your changes and push here for one more round of reviews before we publish the big update!
edit* apologies I didn't realize I hadn't added you as an official collaborator yet. I just corrected that. You should now be able to directly contribute. Thank you again.
Hi Chase, As I am new to being an official collaborator I just wanted to make sure that I am adding or updating files correctly. I see 2 options:
local-websocket-support
branch and add / replace the files directly.Which do you prefer? Regards, Doug
@DMBlakeley great question. Lets have you create a branch from this branch. Make your changes. And open a new PR for me to review merging your changes back into this branch. Make sense?
@chasenicholl, I think that creating a PR against the local-wesocket-support
branch is the safest and cleanest approach.
Let me give my updates one more review and I will submit the PR for your review and merging into this branch and then back into main
.
@chasenicholl, I submitted PR #17 against the Local Socket API branch last evening. Let me know if there are any issues with this approach.
@DMBlakeley I've been running this branch locally now since I merged your PR without issues. How about yourself?
@chasenicholl, I have also been running v4.0.0 without issues. Have found very good correlation between v4.0.0 and the Tempest app. My recommendation would be to release.
[v4.0.0]
Added Local UDP API support! Now you can choose to listen to your Weather Stations observations directly over your local network. No Station ID or API Token needed. Observations are broadcasted every 60 seconds. This leverages the obs_st message. See documentation for more information.