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

Add B&G WS320 related PGNs (65309 and 65312) #224

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

theikkila
Copy link

This PR will add new PGNs related to B&G WS320 anemometer.
65309 is about signal strenght when using wireless sensor.
65312 is about battery status and charging for the same sensor.

Captured with Yacht Devices YDNU-02

{"canId":486481152,"prio":7,"src":0,"dst":255,"pgn":65309,"time":"1628312401044;A;06:25:52.641","input":["1628312401044;A;06:25:52.641 R 1CFF1D00 13 99 00 4E 0A FF FF 7F"],"fields":{"Manufacturer Code":"Navico","Industry Code":"Marine Industry","Status":0,"Battery Status":78,"Battery Charge Status":10,"Reserved2":8388607},"description":"Navico: Wireless Battery Status","timestamp":"2021-09-05T14:43:06.818Z"}
{
source: 'Battery Status',
node: function(n2k){
return `instruments.wireless.${n2k.src}.batteryStatus`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think using src as the instance identifier makes sense, as it can change essentially randomly when the bus reshuffles addresses. @sbender9 should this be canId?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, it should probably use canId. The canId may not be there initially, so should ignore messages until it is there.

@sbender9
Copy link
Member

Please add tests.

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.

3 participants