- 255.255.255.0
- 255.255.255.128
- 255.255.255.192
- 255.255.255.224
- 255.255.255.240
- 255.255.255.248
- 255.255.255.252
Why do I receive an error indicating the Subnet in this block is the same as or is a subset of the subnet calculated in ''block''?
21 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
MathWorks Support Team
il 17 Feb 2021
Modificato: MathWorks Support Team
il 27 Mar 2023
Why am I receiving the following error?
The subnet in this block is the same as or is a subset of the subnet calculated in ''block''. The block calculates the subnet by ANDing the IP address bitwise with the subnet mask.
How do I configure the IP addresses and subnet masks in my Simulink model to resolve this error message?
Risposta accettata
MathWorks Support Team
il 26 Mar 2023
Modificato: MathWorks Support Team
il 27 Mar 2023
Subnet masks are used in TCP/IP addressing protocols to split an IP address into two parts: the host, or computer, and the network to which it belongs. Comparing the IP address and the subnet mask, the local computer can determine whether the signal came from the local computer or a specific remote network.
Each subnet mask divides the full IP address range into subdivisions called subnets. The subnet masks in the "Configure UDP" blocks do not need to be unique; however, the subnets cannot be duplicates or subsets of each other. This is the reason for the error message.
An example of the subnet (host address range) obtained by the IP address "192.168.0.1" and the subnet mask of "255.255.255.0" is "192.168.0.1 -- 192.168.0.254". This means that only 1 IP address in all the "Configure UDP" blocks in the model can be of the form "192.168.0.X". An IP address of "192.168.0.150" with a subnet mask of "255.255.255.128" would produce the error above. To divide the subnet (host address range) into smaller ranges, the last number in the subnet mask can be increased. Common examples of subnet masks are:
Take note that when represented in binary notation, any 1's present in the subnet mask must be contiguous. Also, IP addresses ending in 0 or 255 are not valid. The 0 address specifies a network without a host, and the 255 address specifies all hosts on a network.
The following link can be helpful in visualizing how combinations of IP addresses and subnet masks result in different subnets (IP address ranges).
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Direct Interface Communication in Simulink in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!