How do i broadcast to every machine on a LAN using the indy UDPClient?
I have set the broadcast property to true and am using:
UDPClient.broadcast('hello',8090)
to broadcast the message.
What host address should i use?
The PC's on the network have address's like: 192.168.2.225 and 192.168.1.73.
They all have 255.255.252.0 as a subnet.
Looking on the internet i have found several suggestions and thus tried
255.255.252.255 and 192.168.0.255
Thanks for any suggestions :)
Pete
In binary, your netmask is 1111 1111.1111 1111.1111 1100.0000 0000;
that first host is 1100 0000.1010 1000.0000 0010.1110 0001;
the other host is 1100 0000.1010 1000.0000 0001.0100 1001;
making the network address 1100 0000.1010 1000.0000 00--.---- ----,
and the broadcast address ---- ----.---- ----.---- --11.1111 1111.
The netmask splits a full IP address into a network part (where the
mask has ones) and a host part (where the mask has zeroes). Local
broadcast is host (-1). So the broadcast address is 192.168.3.255.
Groetjes,
Maarten Wiltink
The above was cut from
http://www.star.net.uk/support/support_technology_tcpip.asp
Clive.
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.443 / Virus Database: 248 - Release Date: 10/01/2003