Machine won't start after problem

Johanna

Member
Join Date
Sep 2002
Posts
7
Conc.: A control mechanism (eye) tells the PLC - with the aid of a timer - whether or not goods have passed within 8 sec.
If not, machine must stop.

Hello,
First of all I must tell you I'm a newbie big-time.
Am in the process of learning: Siemens, Simatic/Step5, version 7.2
A neighbour of mine is building a machine.
He knew I was (am) making programs with Paradox/Object Pal.
So he asked me whether or not I could help him with above mentioned program.
Well, it's a new challenge, so I said I would give it a try.
Secondly I must say I am a self-taught programmer, never had a technical education of a computerprogramming education for that matter

To test things my neighbour put together a "machine".
He installed (amongst other things) the following PLC:
Simatic S5 100U, CPU102.

Ok, well here's my problem:
Machine does stop when no goods have passed the installed eye.
All the outputs (relays) are reset.
All the flags are reset (as far as I can tell).
I now push on the Start-button:
-test mode/PC monitor shows zero's changing into one(1), as should be.
-the actual relays do NOT react, stay zero. :confused:

Two days now I've been trying to solve this, but nothings I do changes anything.
Must be overlooking something, but ran out of ideas.
So I hope one of you has the time to point me in the right direction.

Thanks in advance.
Johanna.

PS. Shall try to enclose what I've made so far (don't know if I've explained enough).
 
Check the outputs that turn on the relays, you may have a weak output. S5 is older so this may be a used plc which makes the above likely. MAINLY verify that your outputs are enabled then check the voltage output from the card if it is.

Double/triple check your code to make sure your arent setting a bit that will block outputs from coming on.
 
Thank you for your reply.
I know I'm the pupil here, but I'm wondering why the "machine" does not have a problem when it is turned off the normal way (through the STOP button).
Then I can start without a problem.

Could you please explain the bit-part.
I have a hard time putting that part together in my mind.
Never had to pay attention to that part of computerprogramming.
In theory I understand it - I think - but practise is often something else.
Tks
Johanna.
 
I have to apologize for not sending a complete zip-file the first time.
Have been trying so many things, forgot to change FB23 to the original state.

Have translated the file also into English

So, sorry for the mistake.
Johanna.


PS. this message might turn up twice, but could find the first one.
 
I am at home and cannot see your code but, Did you program your code in OB1? This operational block is the only one the cpu scans everytime. Also , does the led's on the output cards light up?
If these are 24VDC and you have the polarity wrong, the led will light but will not conduct current.
 
Hello Mike,
I'm learning by trial and error.
Did not (do not) know which type of blocks you have to make, and which ones you use when needed.
So one time I didn't transfer OB1 into the PLC (on purpose).
PLC didn't work, which told me that OB1 is a must.

As I understand correctly a DataBlock (DB) is made when you work with counters and timers or other fixed data.
I did not make a DB, cause as this point I do not use counters and a timer can also be used without the aid of a DB. (Might be wrong here)

At first the PLC didn't work at all.
So I asked my neighbour to check the test "machine".
He couldn't find anything wrong.
I made the mistake addressing the I/O modules the wrong way. :oops:
Have 4 modules: 2 Input (I0 & I1) & 2 Output.
So the Q-modules are Q2 and Q3, but I addressed them as Q0 & Q1.
Had read about it, but the example in the Manual confused me.
As I said: I'm learning the hard way (but I'll never make that mistake again).
Due to your question I've started the "machine" and payed special attention to the ledlights. They all lit up.

Maybe there is something wrong with the modules, but then one would think that if the STOP-button=1 + JC FB3 wouldn't work either.
That instruction performs everytime.

I am probably overlooking something which is very basic, but - as I said - ran out of ideas.

Kind regards,
Johanna.

PS. I get the most information from the S5-100U Manual.
It's an old manual (1988) and some codes have changed over the years.
So sometimes it's quite a search.
 
Mike,
Hope you had a good night's rest.

The modules are:
Digital input: 8 x 24V DC (6ES5 421 - 8MA12)

Digital output: 8 x 24V DC/0,5A (6ES5 441 - 8MA11)

To be on the safe site, the PLC used is:
Simatic S5/100U CPU102

Kind regards,

Johanna.
 
Johanna,

I have just had a quick look through your coding, I did find it a little difficult to understand first off, but I think I have got there. Is your problem that when timer 2 (8 seconds) times out the machine stops but will not restart? I beleive that the reason this is happening is because T2 is not being reset, thus once it is set the program is forever jumping to FB23 and shutting your machine off. Try putting the start button, I0.0 in the timer reset as well as the 'eye' I0.6. This might solve your problem.

Paul
 
You must remember, when you jump from operational block to a function block, with siemens once that function block is scanned it must return to the OB it jumped from to continue the scan. Make any sense?
 
Paul,
You are right, that's what caused the problem.
Timer2 was only Reset when the eye was activated.
I added a R T2 to FB23 and now the "machine" is working.
At least till I come up with something new.
Well, you have to learn one way or the other.
So, Paul, thanks for your answer.

Mike,
I did not really understand the scanning part.
I have a print-out of a program from a part of a plant (without a lay-out of it, which leaves me with many guesses) and did not understand why - at the end of the Fb's - there were no jumps present.
Now I understand you don't have to put them in.
The BE statement causes a return to where the JC FB.... was given.
That can be anywhere, can't it?

Johanna.
 
Right. The block end takes you back to the block it jumped from to start with. One thing I do not want to mislead you about is you can jump from a OB to FB to another FB. What I was trying to get across is, when the third FB listed here executes the BE, it goes back to the second FB, see's it's block end and then back to the OB. Just curious, are you writing your code in STL?
 
Hello Mike,

Shall study your answer conc. the jumps.
When I read the manuals it seems you can jump all over the place with little consequenses.

Yes, Mike, I'm writing my code in STL.
Why?
Ignorance, pure ignorance.
Never had a technical education, and Ladder Diagrams and Control System Flowcharts are difficult to understand. :unsure:
The manual, belonging to S5 (version 7.2), has 21 pages conc. LAD and 22 pages conc. CSF.
Not much to go on.
I use STL cause it's closer to home. Makes more sense to me.

I am not rejecting LAD or CSF, but think I will be better equiped in dealing with the subjects after I've learned to deal with STL (she said in an optimistic tone of voice)

Mike (and all others)thanks for your help.
Such help is indispensable for someone like me.
Johanna.
 
It seems you have a good attitude to learn programming. GOOD LUCK.
As for stl. vs. csf. vs. lad, I will take stl everytime. The way I see it, (and you will get pounded on this site very quick) is if you learn stl. first, the rest comes simple. Good look with future projects.
 

Similar Topics

Conc.: A control mechanism tells the PLC - with the aid of a timer - whether or not goods have passed within the 8 sec. If not, machine must stop...
Replies
0
Views
6,409
So, a WW PC's hard drive decided to go bunk. The local tech did use Windows 7 Back and Restore to save an image. However, the restored image...
Replies
0
Views
1,011
Hi guys, I had View studio 6.00 and it was working alright but we were forced to switch for 5.1 because almost all of our panelview are old. So...
Replies
12
Views
5,737
Has anybody used one of the range of devices from ****, the Talk2M website and their VPN software, eCatcher. It looks like the combination solves...
Replies
3
Views
2,011
Hello, As part of our project, we are using an M241 controller. This controller interfaces with an industrial computer and a router via a switch...
Replies
2
Views
72
Back
Top Bottom