Question BACnet with C#.net

dibrony

New member
Joined
Jan 17, 2021
Messages
2
Programming Experience
10+
Hi,

I am integrating the BacNet in my C# application using the BacnetIpUdpProtocolTransport procedure.
When I use it as: BacnetIpUdpProtocolTransport udp_transport = new BacnetIpUdpProtocolTransport(c_bacnetPort,false) it works perfect but the problem is that I have 2 network cards on my PC and sometimes it sends the data through the wrong card.
I tried: BacnetIpUdpProtocolTransport udp_transport = new BacnetIpUdpProtocolTransport(c_bacnetPort,false,false,1472,bacnet_IP); here the data is sent on the specified card (mentioned in bacnet_IP) however it is reserving the network card (i am not able to launch the BacShark to check the result, I can see it via the yabe application, but I have to use BACShark...).
Can anyone help in solving this issue please.

c_bacnetPort is always equal to 47808
bacnet_IP is the IP of my PC, let's say "10.110.45.20"

Thanks
 
Since it looks like you are using a niche library, it may help us of you provided a link to the library documentation/code. Also, if that library has a specific support channel, your question maybe more appropriate there because you'll get the specialized help that you seem to need.

Right now on the surface, this does not look like a C# or .NET Framework issue, but rather a bug (or feature?) of the library that you are using?

If the library you are using is open source, have you tried tracing into the library code to see what it is doing that is causing the network card to be "reserved"?
 
Have you tried opening an issue in their issues page? That would likely get you the most context appropriate help with regards to your problem.

I don't have any recommendations for alternatives since I am not even familiar with the problem space.
 
It sounds like you need to enter into the world of debugging. You can find a tutorial in my signature. Once you step into the code, you should be able to identify where the issue is. If it's in the library, and there is no obvious or documented way to select a specific net-card, then you will need to find something else to use instead.
 

Latest posts

Back
Top Bottom