Batrium and Grafana

Announcement - Help us fight the BOTS! Please report all spam including stuff in your inbox!

kevinjaye

New member
Joined
Dec 5, 2018
Messages
28
Good day all,
I recently updated my watchmon 4 to 4.15 firmware and software 2.15.11 and lost communication with grafana.
I use node red to capture the info. I believe the UDP info has something to do with it. Has anyone experienced this problem or know if the UDP protocol has been changed with the new update?
 

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
Yes it have changed. You can find the latest protocol under the Watchmonudplistener page on Github. I guess you use NodeRed to capture the data and not the listener? If so you need to find the author or change it your self.
 

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
either run it with nodejs, or docker-compose.

Im preparing some new videos but basically you can do: https://diytechandrepairs.nu/setting-up-the-universal-solar-system/

Though note that i just got a bug filed where it doesnt add all data. https://github.com/Batrium/WatchMonUdpListener/issues/8
With that said its running fine here with all other data.
Note that above use MQTT and Influxdb. So if you dont have one or the other you need to disable it in the config or else the software will crash :)
 

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
Yes it have changed. You can find the latest protocol under the Watchmonudplistener page on Github
That's good info thanks for sharing. I have not updated the firmware or software yet but will in the future.
Has anyone experienced this problem
Not yet as I have not updated the firmware/ software. But this made me look at what has changed. The topics are pretty much the same and it looks like a couple got added,. There may be some changes in the java scripts but at first glance I don't see much.
In Node-red if you debug straight from the UDP listener are you getting any debug info?
Also If you debug from the "All Message Type numbers to Topic" node do you get a topic number?
Wolf
1615164359374.png
 

kevinjaye

New member
Joined
Dec 5, 2018
Messages
28
No topic number just a bunch of numbers.
 

Attachments

  • Screenshot 2021-03-07 215406.png
    Screenshot 2021-03-07 215406.png
    170.6 KB · Views: 70
  • Screenshot 2021-03-07 215455.png
    Screenshot 2021-03-07 215455.png
    167.2 KB · Views: 72

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
One Chance is that they went to binary instead of status messages. Ie type of message
 

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
No topic number just a bunch of numbers.

I get the same "bunch of numbers" if I do not enable the debugger to show complete message object.
Alright first thing you need to do is change both debug nodes to "complete msg object" and deploy.

1615206249191.png
Once you do that recheck the "All Message Type numbers to Topic" with the complete message object node.

Your output should look like this.
1615206549348.png
If you click on the payload arrow the object should open up and at the bottom show the topic like this.
1615206670039.png


One Chance is that they went to binary instead of status messages. Ie type of message
I doubt that! It would require way to much reprogramin of their already solid platform and comparing the old JScript with the new according to the Batrium github page all the Msg_****_*.js files are quite similar to the original. So I don't think there is that much to tweak.
Once I do the update I will figure it out but it will be on a weekend in the future.
1615207675744.png

Wolf
 

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
No they went to binary in the messages instead of status messages. I know this because i changed the code months back for it. ;)
Its only for some messages to lower message data amount. Ie instead of byte they do binary. Look here:
1615211064964.png
 

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
No they went to binary in the messages instead of status messages. I know this because i changed the code months back for it. ;)
Its only for some messages to lower message data amount. Ie instead of byte they do binary. Look here:
Got it. That's topic 7832 (A new one) HwShuntMetrics. It will take me some time to check the other topics for .bit strings.

I'm comparing them with the old Watchmon SW 1.0.30 UDP Outbound protocol sheet that is available.
Do you know if there is an updated version of that?

Thanks

Wolf
 

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
Check the payload folder on github. All 2months old are updated :)
You can also grep for bit(1) i guess but just checking when the payload updated is a good start.
 

kevinjaye

New member
Joined
Dec 5, 2018
Messages
28
As I am a noob in the programming world I am not exactly sure how to modify my existing configuration to capture the data and pass it on to grafana.
 

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
just checking when the payload updated is a good start.
Yep that's what I thought and am going through it. Thanks!
Update: Ah OK I see what's going on. Yes some of the topic numbers have changed.
So everything 2 month ago is new.
Shouldn't be to difficult to rewrite this in node red we will see. ;)
1615220470570.png
As I am a noob in the programming world I am not exactly sure how to modify my existing configuration to capture the data and pass it on to grafana.
So am I! Once you muddle through it though it starts to become clearer.
So did you enable debug nodes to "complete msg object" and deploy?
And what are your results?
Many parameters have not changed just the topic numbers.... I will investigate.
1615223818537.png
Wolf
 
Last edited:

kevinjaye

New member
Joined
Dec 5, 2018
Messages
28
Yes I enabled the debug node to "complete msg object" and got the following:
 

Attachments

  • Screenshot 2021-03-08 125747.png
    Screenshot 2021-03-08 125747.png
    615.9 KB · Views: 67

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
OK great now click on the little arrow and open the payload and see if there is a message "Topic" attached.
1615228973372.png
It should look like this.
1615228930595.png
Then see if the Topic Number shows up in the Switch node where it can be split out and manipulated.
1615230101506.png
If that topic number doesn't show up, that will be the problem, and the nodes will need to be recreated with the proper topic numbers and reprogrammed.
You can either do it daromers way with MQTT or tackle the node red issue yourself.
You won't hurt anything and may learn a couple of things or wait for me or someone else to update their watchmon 4 to the new firmware and be forced into it. I will do it in the near future. When, I cannot guarantee.
Just make a copy of the current flow and paste it into a new flow where you can manipulate and play with it.
Wolf
 
Last edited:

kevinjaye

New member
Joined
Dec 5, 2018
Messages
28
This is what I got. The topic is 3E33. The one programmed is 3E32. When I changed it to 3E33 I get an error.
 

Attachments

  • Screenshot 2021-03-08 153909.png
    Screenshot 2021-03-08 153909.png
    404.1 KB · Views: 62
  • Screenshot 2021-03-08 154325.png
    Screenshot 2021-03-08 154325.png
    635.8 KB · Views: 59

Wolf

Active member
Joined
Sep 25, 2018
Messages
1,578
This is what I got. The topic is 3E33. The one programmed is 3E32. When I changed it to 3E33 I get an error.
Yep now you are going to need to change the function node for 3e32 to the java script for 3e33.


As I said you won't break anything cause its already broken. You need to work with the debugger and figure out what's causing the problem.
I'm sorry I can't be much more help right now. I know it isn't easy believe me it took me a couple of months of almost 24-7 wrapping my head around this and this was with a huge head start from the original poster @Bloater of the node red flow and the batrium github page and I wont forget @daromer .
In the final analysis you want to get a result out of the debugger from the message 3e33 node like you see here.
Wolf
1615237984805.png
 
Last edited:

daromer

Moderator
Joined
Oct 8, 2016
Messages
5,659
Or easier route is just to run the watchmonudplistener in an container and you dont have to code :p
 
Top