Professional Documents
Culture Documents
Group number 5
Page numbers 15
"I declare that in submitting all work for this assessment I have read, understood and
agreed to the content and expectations of the Assessment declaration."
Semester 2 – 2022
1
Table of Contents
Introduction/Background ...................................................... 3
Design and methodology ...................................................... 3
Design Explanation ............................................................... 6
Automatic system .................................................................. 6
Manual System ..................................................................... 8
Output and Testing.............................................................. 10
Automatic system ................................................................ 10
Manual System ................................................................... 11
Conclusion........................................................................... 13
Picture for testing ................................................................ 14
2
I. Introduction/Background
The project is programmed on the Simulink system with a basic traffic light
signal system that interacts between traffic lights and pedestrian lights. The car
light system is displayed with three light patterns including green, yellow and
red; And the lights for pedestrians will be displayed in two colours green and
red. The programmers will use the 'Counter Limited' block for about 15 seconds
to align the time to balance between the crosses of the beacons. The automatic
light system requires the design time for the vehicle to run (green light) with
about 7 seconds equivalent to 7 counts in the programming system, and the
yellow light 3 seconds equivalent to 3 counts to warn traffic vehicles. slow down
and prepare to stop at a red light with 6 seconds equals 6 counts. Therefore, a
red light for pedestrians to wait for about 10 seconds is equivalent to 10 counts,
and a green for pedestrians to cross the street before the system stops at 15
counts. In fact, the signal light system will be similar and repeated in a cycle to
ensure the safety of passers-by and ensure circulation between vehicles.
In addition, the project also requires programmers to design a light system with
a switch (manual operation system). And same with the automatic system, the
manual system also has a programming system with a counting system from 0
to 15 counts, and after pressing the 'Push Button' the light system also works
with the same principle as the system. Automatic system when the traffic lights
are green, the pedestrian lights will be red and vice versa; Only when the yellow
light signals that the vehicle needs to slow down before the red light comes on,
pedestrians will recognize the signal about to cross the road.
3
Counter-limit It lets the users select the
block maximum value. The block
counts up until reaching the
maximum value. The number
then resets to zero and resumes
counting up. The counter is
always reset to zero.
4
one (1). Otherwise, the blocks
will receive a value of zero (0).
The counter limit block was used to define a time interval of 0-15 counts (sec),
and this represents the range of beacons required by the project. The counter
5
limit block is linked with relational operators to check for each associated
signal condition.
There are three distinctly defined timelines:
6
Picture 1: Automatic System
The signals are designed and linked to the output blocks under certain conditions, if
the value of the signal is zero, the output block is equal to zero, then the signal
condition at that time will be off. If the value of the output block is equal to 1 the value
of the signal is also equal to 1 and the light is on.
7
Picture 3: Graph of test lights
Manual System:
8
Algorithm 2: Pedestrian crossing button/switch
9
Picture 3: The state-flow
A ‘Constant’ block that is attached to the ‘Push Button’ serves as the state
line's input. Because the node cannot be directly connected to the state
stream as its input in this case, we are using constant blocks instead. The
output and signal connection technique is the same as for an automated
system. Additionally, since the input will be utilised in the state stream, it must
have a value. The constant block's value initially is zero, but when the button
is pressed, it becomes one. The state stream will cycle in order and produce
each corresponding light system. When the conditions are right, the order will
be output as required by the programmer starting from green to yellow and
red, and in the pedestrian light system will be red to green. Therefore, when
the indicator light value is equal to 1 will be when the light is on and 0 will be
when the light is off.
10
First phase: seven (7) counts (0s to 6s)
Vehicles: Green
Pedestrian: Red
Picture 4.1.1
Vehicles: Yellow
Pedestrian: Red
Picture 4.1.2
Vehicles: Red
Pedestrian: Green
Picture 4.1.3
11
Process Picture
Vehicles: Green
Pedestrian: Red
Picture 4.2.1
Vehicles: Yellow
Pedestrian: Red
Picture 4.2.2
Vehicles: Red
Pedestrian: Green
Picture 4.2.3
12
V. Conclusion
The project is a basic program that exposes students to the actual traffic light
project, and the goal is to regulate safety and traffic between vehicles and
pedestrians. Simulink supports students to increase the arrangement of
running algorithm graphs and review reasonable conditions. The project gives
an overview of real-life projects such as traffic lights or conversion algorithms.
Our team's automatic and manual traffic light programming systems met the
set criteria, and the status flow and counting operations performed the
required checks. The program automatically responds to common signals and
the button program makes it easy for pedestrians to use in the state of
needing to cross. Pedestrian signals are still connected to traffic lights, with
the goal that when the green light for vehicles is running, it will be a red light
for pedestrians to wait before crossing the street. A yellow light signals the
driver of a vehicle to slow down for 3 'sec' before coming to a complete stop at
a red light. At this point, the pedestrian will walk with a green light before the
program is repeated as at the beginning.
● Automatic traffic light system: The operating program starts with a
counter-limited block and progresses to the relational operator to check
the condition. And after the system is tested, the successful conditions
will bring to the output blocks and light up the lights. In addition, the
'Logical operators' will connect the conditions and associations so that
the lights are on at the same time.
● Manual system (Pedestrian crossing button/switch): The program
system uses 'Push Button' instead of 'Counter-limited block' because it
is a manual system that requires direct action from the person who
wants to move across the street. In the manual program we don't use
the operator system, but we choose 'State-flow Chart Block' to output
each result in order when the users press 'Push Button'. In the end, the
results will remain the same as automatic; however, the program will
change status to yellow after pressing 'Push Button', and stay for 3
'sec' before changing to green pedestrian light.
13
VI. Picture for testing:
14
Picture 4.2.1 - Before pushing button of Interoperable button/switch for
pedestrians System
15