Example program in Simatic manager

tulip

Member
Join Date
Oct 2005
Location
ist
Posts
236
I want write a example program with S7 Simatic manager.24 pieces digital output are exist.One strobe input for start and stop.Scenario:When strobe input is active then outputs are energised one by one ( energising,passing and waiting time will be adjustable).Like a shift register it must continuosly run.if Cycle is finished,after a wait time will work again.
 
There are aprox. 57892 ways to achive your goal. One interesting way is to write a simple FB that will drive one output. Then daisychain 24 instances of that FB, passing the output from the first to an input of the second.
 
I came up with 68438 ways - I'm glad this came up up as i needed an idea for the April puzzle:)
 
Last edited:
Gentlemans please dont make fun of me :) sometimes brain of everybody is stopped opposite of very simple events......
 
Here's an example program. DB1 contains the times and the Q addresses. Start the sequence with I0.0, stop with I0.1
 
I've added my solution to L D's project. My sequencer consists of 25 instances of FB5, "One_State". You'll find the sequencer in FB 10 "Sequencer". Again I0.0 and I0.1 for start/stop.

If everybody joins in we'll find out once and forever how many solutions there actually are. Tulip: We are not making fun of you it's just that a problem likes yours overloads a programmers mind with all the possible ways to go. See the extreme difference in L D's ultra compact solution, and mine. Another way could be by using the SRD, CAD, CAW instructions...
 
Thanks Bakkei
for your efforts.I tried your program it is okay but I can not change interval times ,because it continuously shift very short interval.May be I could not explain my example.When I give an enable system will run.Firstly q0.0 will be on ( rest are off)and this on time of q0.0 is adjustable,end of this time a timer will be triggered (waiting time for all of intervals)at the waiting time is finished q0.1 will be on (rest are off) etc...end of cycle ,that is q2.7 will be on and off,more after another a timer will triggered ,at the this time is finished start cycle again...
 
Thanks Bakkei
for your efforts.I tried your program it is okay but I can not change interval times ,because it continuously shift very short interval.May be I could not explain my example.When I give an enable system will run.Firstly q0.0 will be on ( rest are off)and this on time of q0.0 is adjustable,end of this time a timer will be triggered (waiting time for all of intervals)at the waiting time is finished q0.1 will be on (rest are off) etc...end of cycle ,that is q2.7 will be on and off,more after another a timer will triggered ,at the this time is finished start cycle again...

As far as I understand that's exactly what my program does. Check FB 10, it drives outputs Q4.0 - Q 6.7 as the outputs Q0.0 - Q2.7 are already used by L D's program.

- the i_Time_Pulse of a state defines how long an output is high
- the i_Time_Pause of a state defines the delay between two states.
 
LD program:
Qn on for 1 sec, off for 3 sec then
Qn+1 on for 1 sec, off for 3 sec, then
Qn+2 etc.

Bakkei program:
Qn on for 500ms, off for 1 sec then
Qn+1 on for 500 ms, off for 1 sec, then
Qn+2 etc.

What do you require ?
 
Sorry L D and Bakkei.I tested your program on my PC.(But including SFB4)Therefore I loaded your programs to plc and checked it also all of them are operating like what I mean.sorry again and thanks....
 
Sorry L D and Bakkei.I tested your program on my PC.(But including SFB4)Therefore I loaded your programs to plc and checked it also all of them are operating like what I mean.sorry again and thanks....


Do you mean you used PLCSim? In that case you should install the latest servicepack & hotfix. There is a known bug with the use of SFB4.
 

Similar Topics

Hello, someone have an example of an comunication between an Omron CJ2M CPU33 with FINS TCP to PC? Thanks for help
Replies
1
Views
1,374
Good Morning , I seen that FactoryTalk View has Recipe Manager , but like you guys "preach", it makes sense to do everything in the PLC...
Replies
6
Views
2,743
Need help with or example of a plc logic that will feed material through a conveyor using a selector switch. In one position it feed material...
Replies
21
Views
5,325
For TIA Portal13 on SCL.I can not find anything for 1200 series :confused: Only for 300/400
Replies
2
Views
2,492
Dear all, I am new to the PLC programming , and i have to do a program for Delta plc using WPL SOFT software and input should be...
Replies
2
Views
2,648
Back
Top Bottom