You are on page 1of 3

EET 277 Labs 11, 13 and 15

LogixPro Traffic Light


Lab 11: LogixPro Traffic Light.
First, play with the simulation when there is no program to run. Manually change the
lights and see when the cray dri!ers go or stop.
Program the Traffic Light using " timers:
Timer 1: 1 seconds while the lights are RedRed
Timer 2: 5 seconds while the lights are !reenRed
Timer 3: 3 seconds while the lights are "ellowRed
Timer #: 1 second while the lights are RedRed
Timer 5: 5 seconds while the lights are Red!reen
Timer $: 3 seconds while the lights are Red"ellow
"o% will either need to control each light indi&id%all' (ie: Left Red m%st be on d%ring times 1, #,
5 and $) or 'o% will need to latch and %nlatch each light d%ring each time (ie: Latch both reds
d%ring time 1 then %nlatch the *ro*er red light and latch *ro*er green light d%ring time 2)+ ,f 'o%
choose to do the direct control 'o% will ha&e *roblems with the transition from when Timer $ is
done to when T1 starts timing+
#nstructor$s %ignature:&&&&&&&&&&&&&&&&&&&&&&&&&&&
Lab 1': LogixPro Traffic Light with (ompare (ommands
Program the LogixPro Light sim%lator %sing 1 timer and word com*arison commands+
#nstructor$s %ignature:&&&&&&&&&&&&&&&&&&&&&&&&&&&
Lab 1)* LogixPro Traffic Light with %e+uencer
See the text example (Figure 12-12) to control a stop-light and use that method to work from.
Traffic Light (ontrol
Left Street
Right Street
EET 277 Labs 11, 13 and 15
LogixPro Traffic Light
There are 2 streets in the -im%lation: Right -t has cars r%nning right to left+ Left -treet has cars
r%nning left to right+ The normal light times sho%ld be as follows:
1) RedRed: 2 -econds
2) Right !reen, Left Red: 3. -econds
3) Right "ellow, Left Red: 5 -econds
#) RedRed: 2 -econds
5) Left !reen: Right Red: 2. -econds (/old in this *osition for Right0of 12a')
$) Left "ellow, Right Red: 5 -econds
,al-./on$t ,al- Lights
The 2al3 lights only come on if a cross-walk button is pressed+
4 *edestrian m%st be gi&en 12 seconds to cross the intersection+ The wal3 light will be on from
the time the b%tton is *ressed and the light is green %ntil there is 12 seconds remaining on the
!reen light c'cle, then will the wal3 light will flash %ntil the traffic light is 'ellow+ The 5on6t
2al3 Light will be on the remainder of the time+
,n the case of Right -treet6s !reen Light c'cle, it wo%ld loo3 li3e this:
RedRed (1) Right !reen (2) Right "ellow (3) RedRed (#)
2s 2.s 5s 2s
2s 7 12s 5s 2s
5on6t 2al3 2al3 2al3 8lashing 5on6t 2al3 5on6t 2al3
,f the cross0wal3 b%tton is *ressed while the wal3 light is flashing, 'o% m%st store the re9%est for
the next light c'cle+
,al-0Light 1ints: "o% will find it m%ch easier to control the wal3 lights witho%t %sing the
-:;+ 8or exam*le, id the -e9%encer is in *osition 2 (Right0!reen) for time . to 7 seconds t%rn
on the 2al3 Light, for time greater than 7 t%rn on the wal3 light thro%gh a flashing bit+
2esetting the %imulation to a!oid accidents:
2hen the -im%lation is r%nning and 'o% go to PR;! mode, then R<= mode the se9%encer
co%ld be >off se9%ence? and allow both cars to go, ca%sing an accident+ The R%ng below will
hel* eliminate this *roblem b' forcing the red lights >on? d%ring the first scan of the *rogram+
EET 277 Labs 11, 13 and 15
LogixPro Traffic Light
#nstructor$s %ignature:&&&&&&&&&&&&&&&&&&&&&&&&&&&

You might also like