HMI + PLC Programming
In this simple supervision project, the Task is to simulate and control a simple cross road Traffic lights system.
The image of the system to be simulated:
PART 1:
A)- HMI (Human Machine Interface) design
Program used is Vijeo Designer Basic
We start by creating a new project in Vijeo look basic then draw all the parts of the system.
Parts to be drawn are the following:
4 Poles for Traffic lights (Color Display object
Numeric Display ( for Countdown display )
Button to Switch to Settings Panel
B)- Communication Setup:
C) - Variable declaration :
We have 4 Boolean Variables (bool1 to bool4) that each holds 1 bit 2 variables for the 2 pairs of traffic lights on vertical road and the other 2 for the Horizontal road
Another 2 Integer variables to display the value of the countdown for each color displayed
The 3 Integer variables (GREEN_TIME RED_TIME and YELLOW_TIME) to hold value of the wait time set in Settings
PART 2: PLC setup and config
Software used is Schneider's EcoStructure Machine Expert the PLC is gonna be the M221
A) - Setup Ethernet communication to the HMI in Vijeo designer
for Memory bit variables
I'm using 2 Memory bits for each traffic lights because I chose one LED object to represent all 3 colors (Green , Yellow and RED) so 2 binary bits will have 4 states which is sufficient to produce 3 colors
For word variable
Program + Simulation
Contact me @fethiOuerdane on Twitter for more information on the project