LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Not receiving UDP packets

'Netstat -an' is just a windows uitility that is already on your pc.

 

Just open a console window (run -> cmd). Then type netstat -an and you will get a list of all your open connections (and listeners),

 

You mention that it was working when you were running both wireshark and LV at the same time. Are you 100% sure that this wasn't luck and that there is something wrong in your DaVinci setup so by accident it was not sending any data at the moment you were not running wireshark and in a next attempt it did?

 

Succes!

---

25+ years long fan of LabVIEW. Move to Emerson looks to be for the better! See the last posts in subscription model thread.
0 Kudos
Message 11 of 19
(2,517 Views)

Thanks for the clarification. What I meant earlier is that I couldn't go online to check the forums so I didn't know to run the command. It's a big pain not to be able to go online at the same time I'm testing...

 

I am 99.9% sure it was not luck. Every time I started and stopped Wireshark, the packets started and stopped coming into LabVIEW. It was quite strange.

0 Kudos
Message 12 of 19
(2,514 Views)

strange it is for sure...

 

I also checked the reponse from netstat -na and if everything works fine your UDP listener should be listed as

UDP 0.0.0.0:<your portnumber>   *:*

 

When the UDP listener is active it should be there, no matter if there is any data coming in. If you stop the listener (either by the close UDP connection vi or closing LV) the listener should be gone.

---

25+ years long fan of LabVIEW. Move to Emerson looks to be for the better! See the last posts in subscription model thread.
0 Kudos
Message 13 of 19
(2,510 Views)

Hmm, so I tried running "netstat -an" and saw the appropriate line

UDP    0.0.0.0:3257    *:*

appear and disappear when I started and stopped the LabVIEW VI.

 

This line, however, was not correlated to when I started and stopped the Wireshark capture. If this happened, it would have given a bit more insight into the problem.

 

Still, I only received data when Wireshark was running.

 

Anyway, it seems it will remain a mystery why I can only receive UDP packets only when Wireshark is running.

 

Thanks to everyone who responded! If anyone has other ideas, I'll be happy to try them out.

0 Kudos
Message 14 of 19
(2,500 Views)

hmmm...

 

Can you try a different port number on your PC. The port you are currently using is also some part of windows... maybe this is eating away your data when you do not run wireshark... altough I cannot understand why....

 

http://en.wikipedia.org/wiki/Microsoft_Message_Queuing

 

One of the ports I use without any problem is 14503..

 

 

---

25+ years long fan of LabVIEW. Move to Emerson looks to be for the better! See the last posts in subscription model thread.
0 Kudos
Message 15 of 19
(2,495 Views)

is it work? i have same problem to conect another pc to my labview using udp to recive command from there.is any one use it successfully?

0 Kudos
Message 16 of 19
(2,235 Views)

@mehr wrote:

is it work? i have same problem to conect another pc to my labview using udp to recive command from there.is any one use it successfully?


Yes, properly set up, this works successfully!

 

We cannot really help unless you tell us what you tried so far and in what way it fails. Have you looked at the shipping examples? How is the windows firewall configured? Is there a NAT router between the PCs? What UDP ports do you use? What kind of error messages do you get?

 

Please describe the problem in much more details:

"... problem to conect another pc to my labview using udp to recive command from there..." is very ambiguous. Which site acts as client, which as server? Who sends commands? Are the commands send on request or continuoulsy? Where is "from there"? What is the format of the commands?

 

Can you show us your code?

0 Kudos
Message 17 of 19
(2,221 Views)

Thanks for your answer and i apologize for my bad English writing

we have two code one implemented in c++ and use opencv for image processing and use as server

another code is implemented to send commands to quad rotor uav and implemented in labview and is client

we connect two pc using cross Ethernet cable directly. And we want send image processing result to labview using udp protocol

server  sends data like “forward” ,”backward” ,”turn L” ,”turn R” ,…

i have run example of labview for udp receiver.vi but dont get data any packet from server

also iv disabled firewall in client pc.

port is 5033

server  ip is 192.168.1.113 (in c++ program)

and then we run both of programs in one pc and udp connection was successful and labview get data form c++.

but i want to know how can i use udp between two PCs?

thanks

0 Kudos
Message 18 of 19
(2,210 Views)

@mehr wrote:

also iv disabled firewall in client pc.


You should open the firewall on the server PC instead. Most firewalls allow outgoing connections.

0 Kudos
Message 19 of 19
(2,200 Views)