PLC Knight Rider programme.

gnccollege

Member
Join Date
Nov 2013
Location
UK
Posts
8
Hi Guys.

Im Programming a knightrider beam light using GX Developer on 8 leds flashing from Y0 to Y7 and back.

Anybody know how to do that?

i have done half the programme where leds are flashing from Y0 to Y7 but i dont know how to go back from Y7 to Y0. the programme also has to run forever until switched off.

I have started with T0 with Y0 as output and timer of T0 K5 and then i closed the loop with T0. this turn on Y0 for 0.5 second and move on to next output. i have done all my steps same like this. I just dont know how to go back from Y7 to Y0.

Pls give clear instructions as im new to plc.

Thanks
Ron.
 
Thanx for the reply shooter.

could u pls tell step by step.
my programme looks like this.

X0 T0 Y0
----!!----!----!/!------------()
! T0 K5
!------------------()

T0 T1 Y1
----!!----!----!/!------------()
! T1 K5
!------------------()


and so on.............
 
Thanx for the reply shooter.

could u pls tell step by step.
my programme looks like this.

----X0--------T0-----------Y0
----!!---------!/!------------()
---------!----------------T0 K5
---------!------------------()

----T0--------T1-----------Y1
----!!---------!/!------------()
---------!----------------T1 K5
---------!------------------()

and so on.............
 
Knight Rider

I'm assuming you want single LED lit, going left to right, then back, then recurring. If last timer initiates first it will cycle. Close x0 to trigger all cycling. Each LED has two conditions to trigger it. Shifting or numeric comparisons will allow a tighter program to achieve same then shown below.



| .. X0 ..TIM 4 ...............TIM 001/0.5 sec
|---| |---|/|---------------------( )-----------| Initiate timer for leftmost light. Close x0 to initiate sequence.
|
| .. x0 ..TIM 001 .................Y0
|---| |---|/|---------------------( )-----------| Fire leftmost light
|
| .. x0 TIM 001 ..............TIM 002/0.5 sec
|---| |---| |---------------------( )-----------| Initiate timer for middle light
|
| .. x0 . TIM 001 .. TIM 002 ......Y1
|---| |-+-| |----------|/|-----+--( )-----------| Fire middle light
| | |
| | TIM 003 .... TIM 004 |
| +-| |-----------|/|----+
|
|
| . x0 . TIM 002 ............TIM 003/0.5 sec
|---| |---| |---------------------( )-----------| Initiate timer for rightmost light
|
| . x0 . TIM 002 ....TIM 003 ..... Y2
|---| |---| |----------|/|--------( )-----------| Fire rightmost light
|
| . x0 . TIM 003 ............TIM 004/0.5 sec
|---| |---| |---------------------( )-----------| Initiate timer for middle light
|
 
Last edited:
Thanks for ur reply FSEIPEL.

im just using plc for the 1st time.

the sequence u told me, will it turn on all lights from Y0 to Y7 and back?
 
Could u tell me the 1st step for this programme so i can carry on.
and step to come back from y7 please?
thanks
 
Convert program below to ladder ("Ladder/Instruction View switch" button). It is tested:

0 LD>= D0 K15
5 MOV K0 D0
10 LD X000
11 ANI T1
12 OUT T1 K5
15 LDP T1
17 INC D0
20 LD X000
21 LD= D0 K0
26 OR= D0 K15
31 ANB
32 OUT Y000
33 LD X000
34 LD= D0 K1
39 OR= D0 K14
44 ANB
45 OUT Y001
46 LD X000
47 LD= D0 K2
52 OR= D0 K13
57 ANB
58 OUT Y002
59 LD X000
60 LD= D0 K3
65 OR= D0 K12
70 ANB
71 OUT Y003
72 LD X000
73 LD= D0 K4
78 OR= D0 K11
83 ANB
84 OUT Y004
85 LD X000
86 LD= D0 K5
91 OR= D0 K10
96 ANB
97 OUT Y005
98 LD X000
99 LD= D0 K6
104 OR= D0 K9
109 ANB
110 OUT Y006
111 LD X000
112 LD= D0 K7
117 OR= D0 K8
122 ANB
123 OUT Y007
124 END

Best regards,
Vuckovic Goran.
 
1. Copy it to text file,
2. then Project->Import file->Import from Text, CSV format file,
3. Then Alt+F1 to convert to Ladder...
 
I don't know GX Developer at all, so can't help with the programming.

However, before you get fully developed for a single LED going left to right, then back, I don't believe that KIT's lights were like that. I think they were "waved" across, like in the picture I've attached.

I've shown examples for 2, 3, 4, and 5 LEDs

If you are after realism, you might find one of these patterns better, and it might shape how you do your logic.

In Allen-Bradley, I would achieve these patterns using an instruction called "Sequencer Output", or SQO, and could do any of these light patterns in an Allen-Bradley PLC using only 2 instructions !! Perhaps there's a similar instruction in GX ?? IDK...

oops forgot to attach the pic...

Knightrider.jpg
 
Gnccollege,

Don't be lazy, you can always do it with you keyboard. Find bellow printscreen.

Best regards,
Vuckovic Goran.

gx developer.jpg
 
goghie

can i ask which gx developer version r u using?

GX IEC Developer
GX IEC Developer FX
GX Developer
GX Developer FX
 
I prefer GX IEC Developer (it is much much better - two light years in front comparing with GX Developer), but for this occasion, I have used GX Developer 8.101F, as you wrote that you are using it....
 

Similar Topics

I have a machine which is undergoing upgradation. As part of the process two SEW drives are being replaced., existing Gen B with new Gen C. The...
Replies
2
Views
81
I was loading a program onto an XE1e2 PLC and it got stuck on these two windows and won't progress. It won't let me connect from the PC to reload...
Replies
0
Views
51
I'm a beginner in the automation field and I've set up an automation system connecting several devices (datalogger, radio, etc.) via Modbus RS485...
Replies
5
Views
176
I have a file which I'm hoping is for a Mitsubishi A172SHCPUN processor but I can't see how to open it in GX Developer V8.102G The file is a zip...
Replies
4
Views
171
Hi everyone, i have a compact logic 1769-L18 PLC and I'm using FTalk View ME for the display. I wanted to do some visualization on Grafana. At...
Replies
1
Views
75
Back
Top Bottom