VOLTTRON reading data from multiple BACnet IP to MSTP Routers puts Building Management System down - volttron

I have a BACnet network where multiple BACnet IP to MSTP routers are used.
The network configurations are as follows:
Network Configuration sketch
Now I am trying to read data from the network using Volttron. Previously no data was read, so I tried changing use_read_multiple:false in driver configurations. Still to make the request even smaller for the network I changed max_per_request: 1,
Now it is reading data but it shows an error after some time and puts the BMS down. This means we are not able to read or even discover devices on the BMS nor it gives data in VOLTTRON.
It gives an error on the router with most of AHUs, FCUs are attached. I tried testing just that Router (Say its identifier is 4900, now most of the devices like 4900:1, 4900:3, etc.) start giving an error on both BMS and my Laptop.
I have tried grouping too by making groups of 2-5 devices and setting "group_offset_interval" in Platform Driver configurations to some really high value to know whether it is a network congestion issue on the MSTP network. Sometime it starts working but after some time (an hour), it starts giving error on both sides BMS and VOLTTRON too. Although devices are ON.
It gives error on different Routers and sometimes many routers stop working.
How can I solve this issue?
Thanks in anticipation.
Specifications:
Volttron: 7.0
BACpypes: 0.16.7 (as required by Volttron for bacnet)

I could be wrong here (in adding this to the mix) - but as it's relating to MSTP (- BACnet MS/TP), but you might want to also consider if there's a (half-typical) MSTP physical/wiring issue - might not necessarily be the software (or at least not alone).
(You might end up having to consider bifurcating the network / keep 'divide & conquer'ing it into small/2-halves segments to see/locate a wiring issue.)

Related

Discover and connect to the devices running the same app around globally without a server

I want to create a mobile app which can connect to devices having the same app installed without having a server in between. The devices should act as server and client and discover nodes similar to them , like how it happens in block chain?i firstly want to know the discovery protocol that how these devices will discover each other . I have seen the samples of sockets , TCP connection but they know the ip address before , in my case we donot know the ip address , have to discover similar nodes also with security like cryptography happens in block chain so , random device don't mess up with my chain
I am starting to learn about it, and one of the first things that came to my mind is RPC, because is how Bitcoin works: link, and you can check also de P2P section in the link.
I will follow this and update my answer with the things I'll find.
Good luck.

Synchronize sqlite files without a public IP

I'm trying to come up with a way to sync a sqlite database between two computers.
If this were on a machine with a public IP this would not be difficult but I'm trying to find a way to make this work for ANY two devices, and most computers don't have a static IP.
What are some of the ways I can tackle this problem?
Assuming you just need to find the peers IP address...
Broadcast a Udp packet onto Lan, if machines are same lan segment. You can also try using admin scoped multicast, but mileage will vary according to the network setup and gear in use.
If trying to find two machines across the internet (assuming you can solve the NAT address translation issue), you need to bounce off a node that will hold info for you. Eg write a packet to dweet.io or sparkfun or other website that will hold store and forward data. You can also read twitter feeds etc, basically you need a known reference point to both talk too. Look into how malware create command and control networks for some ideas. Or search for rendezvous servers and protocols.
If the address range is small, probe all possible addresses. But be careful as you might trigger anti virus or ISP action
If wanting more browser based, look at webrtc, not quite what you are after but some of the techniques for discovery might be interesting.
If you have access, you can play with your DNS records. Essentially this is a variation of (2).
There are more options too, but that get more special purpose or become a bit too stelthy for general use. Also see how mesh networks are formed.

How to create a BACnet client in C

I am trying to create a client in C that will talk with a BACnet server. This BACnet server is stored on an industrial device (CAN2GO) and I am not sure how I could talk with this device.
I spent quite some time reading documentation for BACnet and I never found a clear example for a BACnet client. I already did some server and clients using TCP and UDP but I don't know how to start this BACnet client and I must say I am getting quite desperate.
I found a library which seems to correspond to what I want which is called BACnet protocol stack but when I tried the whois exemple no device was found (I expected to found the bacnet server but maybe I shouldn't ?).
So my question is : could you give me an exemple in C, or another language but C would be better, that would communicate with a BACnet server (nothing complicated just a question and analysing response). This example could be using the library I just wrote about or if you prefer another library I am of course open to everything.
Thank you very much for your time and answers.
I have used that stack and it is the best open source one you are going to find. If you cannot see anything using the demo\whois\bacwi example from that library, then there is something wrong with your setup. In particular, are you using IP? Are your BACnet client and BACnet server on different machines (they cannot be on the same without some serious tweaking)? Are the two machines on the same IP subnet? (They must be, once again, unless you do some serious tweaking (in this case, setting up BBMDs (BACnet Broadcast Management Devices))).
You will also want to try the "Read Property" example (demo\readprop\bacrp.exe) to actually read a value from the server.
If you are still stuck, then post your detailed problem at the link on Sourceforge, Steve, the author, is very responsive to questions.
I am currently using the stack - just started. I had a little trouble at first, not sure if my problem is the same but.. I basically am using some BAC components made from Schneider Electric (UNC-500) and an old un-supported platform (Niagara R2). On my laptop I created a host server and addressed it to a private LAN network between it and the UNC. My laptop was also using wifi, which was utilizing DHCP, so I had two separate interfaces going. This was my problem. I couldn't read or get 'I-AM' responses back from the UNC. As soon as I turned the WIFI off, I got the 'I-AM' broadcasts. Make sure that you are on the same network as your device, and that there are not other interfaces active. Maybe there is a way to assign the interface to use, IDK. I just started using it.

Why doesn't API mode work with two XBee units?

I have two XBee Pro Series 1 units. Both of them are in AP=2 mode (API mode). I have followed the instructions outlined under the "Series 1" section in XBee Configuration. I try to execute "ZnetSenderExample.java" and I can see it tries to send out a very simple "Xbee" string.
However, I keep getting timeouts on the receiving end saying it never gets any data.
Addtionally, I attempted the Unicast example on this page and found the same behavior. It does not work in X-CTU when in API mode.
I am using firmware 10EC.
How can I fix this problem?
Are the nodes on the same network? When you look at them in X-CTU, do they share the same operating network settings (channel, PAN ID)? Have you installed the API mode firmware, instead of the AT mode (sometimes called transparent serial) firmware?
Have you tried any of the examples on Digi's site, to confirm that the units are configured correctly?

Discover location of database

I am trying to find the location of the database where a particular website is saving to.
The website is saving to some local database in our system, but I am unable to discover where.
I have tried using WireShark to find the IP of the machine where the website sends data to (i.e. the machine which has the database) but currently the only packets showing up are those from the website to my machine and vice versa.
Any ideas?
Thanks
I would start by tracking through the code & website config. If you have sufficient access to run Wireshartk on the host can you not search for config files, find the serverside code, etc?
If you can't see packets on the network interface and you know you've found all network interfaces then it would appear possible the DB has to be on the same machine. Check for recently changed files with you favourite tool (Windows explorer/search, find on Unix, etc).
Is it caching so you haven't yet caused it to read/write to a remote DB while watching? Try watching Wireshark at boot up.
Depending on the nature of the data it could be an in memory DB or something that reads from a disk file into memory at boot up.

Resources