Packet Tracer – Explore the Smart Grid (Answers) Packet Tracer – Explore the Smart Grid (Instructor Version)



  • Explore a Smart Grid
  • Analyze the Usage of Cloud Computing in the Smart Grid

Background / Scenario

In this activity, you will explore the smart city, smart grid. The smart grid monitors the power being delivered from different sources and switches to the most efficient power source available.

The smart grid takes advantage of a smart switch to decide which power source to use.

Required Resource

  • Packet Tracer 7.1 or newer.

Part 1: Explore the Smart Grid

Step 1: Understanding the devices that comprise the smart grid

Different types of devices are necessary for smart grid operation. Network devices are required to allow communication within the smart grid. Solar cells, wind turbines, and a coal plant are responsible for generating energy. Meters and sensors are used to capture data and facilitate energy source monitoring.

a. Review the Smart Grid. How many routers do you see in the smart grid? What are their names?
3 routers: Wind_RT, Coal_RT, Main_RT

Note: Packet Tracer labels connections between network devices but it can be turned off for the sake of readability. To turn labelling on, go to Options > Preferences > Interfaces tab > and checkmark Always Show Port Labels in Logical Workspace.

b. What is the function of routers?
They are transfering data packets between networks (wind, coal, main)

c. A wireless access point is being used in the smart grid. What is its name? What is its function?
Power Acces Point – allows remote control of solar-cell via laptop

d. Is there a way to tell which power source is actively producing energy?
Yes – by power meter (on every device power source)

e. What device is responsible for switching between the different power sources?
Smart Power Grid Switch

f. How does the Smart Power Grid Switch decide which power source to use?
Its programmed on switch. It depends on producting energy. Order of power sources is: wind -> solar -> coal

g. What is the IP address of the Power IoT Server?
IP Address:

h. The Laptop is used by technicians to monitor the amount of power? Use the Web Browser to remotely connect to the Power IoT Server. You will need to know the username and password in order to login to the Server. You can discover the username and password by examining other devices in the Smart Grid.
What is the username and password and with which device did you discover it?
Username: Power | Password: power | Device – Solar Cells

Step 2: Exploring the Smart Power Grid Switch Program

The Smart Power Grid Switch has the capability of running programs. In this example, the program was written in Javascript. It monitors the power levels from all sources (wind farm, solar panels and coal plant) and decide what source is the best.

a. Click the Smart Power Grid Switch.

b. Navigate to the Programming tab. If the Programming tab is not visible, click the Advanced button at the bottom of the window to display the advanced tabs.

c. On the left side of the Programming tab, double-click power_switch(Javascript) and then double-click main.js. The Javascript program running on the Smart Power Grid Switch should appear on the right portion of the Programming tab.

The power grid’s location observes sunlight from 6h to 18h (6am to 6pm). Due to proximity to the ocean, the wind usually blows from 3h to 22h (3am to 10pm). The program ensures that solar power is the most preferable power source. If no solar power is available (no sunlight), the program switches over to wind power, if available. If no wind is blowing, the program falls back to coal-based power.

d. What is the section of the program that makes this preference (solar > wind > coal) clear?
In ” if ” statement

Part 2: Reflection

The key aspect of the IoT is the intelligence added to things. Programs allow devices to be more aware and make decisions based on events of triggers. Many programming languages are available and can be used for this matter.

Before programs can be executed by things, the proper hardware platform must be established, essentially turning the thing into a computer. Usually this is done by adding a CPU, memory and some kind of I/O capability.

Lastly, the newly created smart thing must have network communication capabilities to become part of the IoT.

In this smart grid example, the Smart Power Grid Switch was given processing capabilities to become able to run Javascript programs. Based on sensors and meters, it could then be aware of its environment and act upon a set of pre-defined conditions. The network devices and capabilities allow for the Smart Power Grid Switch to communicate over the network and join the IoT.

Part 3: Challenge Task (Optional)

a. Use Packet Tracer 7.1 to turn a window into an IoT device. The window must be monitor the rain level in the area and, upon rain detection, shut itself. Below are a few tips:

  • Use a regular PT 7.1 window.
  • Assign states open/shut a digital port in the Window. Make open = 1 and shut = 0.
  • Using the window’s programming tab, edit the code to detect and act upon rain (you may need to click the Advanced button to display the Programming tab).
  • The window should remember its last state (shut or open). When the rain is gone, the window should return to its recorded state.
  • Use PT 7.1’s Environment.get(“Wind Speed”); Javascript API call to read the rain value from PT 7.1’s simulated environment.
  • Have fun.

Download Packet Tracer – Explore the Smart Grid


Inline Feedbacks
View all comments
Would love your thoughts, please comment.x