05-29-2006 07:29 AM
Hi Rainer,
yes, using TCP/IP communication I can communicate to both devices. There is a parameter "board" in the TCP/IP initialization function but this has not the meaning of the network card number, funnily. This strange parameter must be zero and then I can communicate to both devices with known IP addresses without any problems. Just the UDP broadcast does return one device only, and this is the device which is connected to the network card which is the first one known to Windows (first entry in Windows network cards list).
To start an UDP broadcast, the C++ software sends two queries (in case of two network cards installed). Each query uses a socket with the IP address which corresponds to one network card of the client (local PC). This IP address is found by a function "Get Adapters Info". The receiver address is always the same (255.255.255.255) but the sender address changes. Doing the same with "INADDR_ANY" as the client IP address does only return one device - same as the LabVIEW UDP broadcast.
The LabVIEW UDP broadcast VI has none of those functions and so I also thought that it would return all devices from all network cards
Greetings,
Gabs
05-29-2006 01:40 PM - edited 05-29-2006 01:40 PM
Message Edité par JeanPierre le 05-29-2006 02:42 PM
LabVIEW, C'est LabVIEW
05-30-2006 02:44 AM
05-30-2006 05:26 AM
05-30-2006 07:08 AM
05-30-2006 07:29 AM
11-28-2007 04:26 PM
11-28-2007 10:12 PM - edited 11-28-2007 10:13 PM
Are you sure that the device that you are connected to has an IP address assigned? If you are connected by way of a Xover cable, then you have your own mini network with only your PC and the device on it. There is no DHCP server to dynamically assign an IP to that device, so it probably have a default IP of 0.0.0.0
I guess it's possible the PC could act as a DHCP server for the that mini network, but that would be over my head on how to set up. All I know is that when I have connected a PC to a device by way of a cross over cable (in my case a PXI to a cFP), I had to statically assign an IP to the device.
11-29-2007 02:02 AM
11-29-2007 02:39 AM - edited 11-29-2007 02:42 AM
JeanPierre wrote:
You can specify the subnet when broadcasting. 255.255.255.255 is general but you can also use the subnet. If the network adapters are on subnets 192.168.1.* and 192.168.2.* then make two broadcasts at 192.168.1.255 and 192.168.2.255. The last digit 255 is the broadcast address for the subnet. When the subnet is specified the corresponding network adapter is automatically selected.
Message Edité par JeanPierre le 05-29-2006 02:42 PM