Skip to content

Python code to simulate a virtual phone network! Phones are connected to switchboards, which connect to each other via trunk lines.

Notifications You must be signed in to change notification settings

MatthewDyson2/retrieverBell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

10 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸΆπŸ’› Retriever Bell πŸ””πŸ“ž

A simulated phone network using object oriented programming! Create phone objects that can interact across a switch, and connect switches with trunk lines to connect them to other switches. You can contact phone numbers to test your network and ensure that phones are set up correctly. This is all handled with provided commands.

Sample Diagram of a Network

image

Commands

display : Displays current network configuration including all switchboards, connections, and phone numbers.

switch-add [area code]: Creates a switch with a user-specified numeric area code.

switch-connect [area code] [area code]: Connects two switches of different area codes, so that the phones associated with those switches can communicate with each other.

phone-add [area code]-[ext1]-[ext2]: Creates a phone with the specified number based on an area code of an already created switch, as well as two extensions.

start-call [phone number] [phone number]: Initiates a "call" between two phone numbers. Logically, this just verifies a pathway across switches to both phone numbers.

end-call [phone number]: Ends the call between phone numbers

network-save [filename]: Saves the network to a file

network-load [filename]: Loads the network from a file and overrides the current network

Getting Started

  1. Download all .py files and run network.py
  2. Use switch-add to set up a switches with specifiic area codes
  3. Use phone-add to attach a phone to a switch's area code
  4. Connect those switches together with switch-connect
  5. Simulate an active connection with start-call
  6. Check on your network with display

About

Python code to simulate a virtual phone network! Phones are connected to switchboards, which connect to each other via trunk lines.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages