0
0
SCADA systemsdevops~30 mins

Network redundancy (ring topology) in SCADA systems - Mini Project: Build & Apply

Choose your learning style9 modes available
Network redundancy (ring topology)
📖 Scenario: You are working with a SCADA system network that uses a ring topology to ensure network redundancy. This means each device is connected to two other devices, forming a closed loop. If one connection fails, data can still travel the other way around the ring.Your task is to represent this network in code and simulate checking the network's redundancy status.
🎯 Goal: Build a simple program that models a ring network of devices and checks if the network is redundant by verifying each device has exactly two connections.
📋 What You'll Learn
Create a dictionary called network with device names as keys and lists of connected devices as values.
Add a variable called expected_connections set to 2 to represent the ring topology requirement.
Write a loop to check each device's connections against expected_connections and store the results in a dictionary called redundancy_status.
Print the redundancy_status dictionary to show which devices have proper redundancy.
💡 Why This Matters
🌍 Real World
Ring topologies are common in SCADA systems to ensure continuous operation even if one connection fails.
💼 Career
Understanding network redundancy helps in maintaining reliable industrial control systems and troubleshooting network issues.
Progress0 / 4 steps
1
Create the network dictionary
Create a dictionary called network with these exact entries: 'DeviceA': ['DeviceB', 'DeviceE'], 'DeviceB': ['DeviceA', 'DeviceC'], 'DeviceC': ['DeviceB', 'DeviceD'], 'DeviceD': ['DeviceC', 'DeviceE'], 'DeviceE': ['DeviceD', 'DeviceA'].
SCADA systems
Need a hint?

Think of each device as a key and its connected devices as a list of values.

2
Set expected connections variable
Add a variable called expected_connections and set it to 2 to represent the number of connections each device should have in a ring topology.
SCADA systems
Need a hint?

Use a simple variable assignment to store the number 2.

3
Check redundancy for each device
Write a for loop using variables device and connections to iterate over network.items(). Inside the loop, create a dictionary called redundancy_status (before the loop) and add an entry for each device with value true if the length of connections equals expected_connections, otherwise false.
SCADA systems
Need a hint?

Initialize the dictionary before the loop. Use len(connections) to count connections.

4
Print the redundancy status
Write a print statement to display the redundancy_status dictionary.
SCADA systems
Need a hint?

Use print(redundancy_status) to show the results.