help with a Step 7 program from a s7-300

Phanx11

Member
Join Date
Sep 2019
Location
Between the 1 and 0
Posts
17
Hello everyone

I'm new here and was hoping someone can help me out. I have a pneumatic punching/ bending machine that broke down running on a S7-300 that i'm trying to figure out the cause. Hardware all checks out so it has to be something in the PLC.

https://www.upload.ee/files/10492107/Assemb2.zip.html

I've uploaded the whole program. If someone could take a look and tell me:

in FB95 on network 19 there is an instance STAT258 (instance of FB32). If M202.0 on IO12 is True then Q33.1 on OUT10 should be true as well.

What would block Q33.1 from turning on?
 
No, all the pneumatic outputs are on a Festo Profibus valve board.Nothing wrong with the valve board or the profibus network. All valves work by forcing the outputs, all the actuator magnetic contacts return and are visible in the PLC. S7 has only 1 DO module and it's only for stuff like conveyor and belts, checked that too all working.

As anyone would of course i checked all the hardware 1st. I need some help with the program.
A better question, if someone can spot all the bits that need to be on after M202.0 for Q33.1 to turn on.
 
Last edited:
As anyone would of course i checked all the hardware 1st. I need some help with the program.


I'm sorry if I offended your capabilities. But the number of times I heard that sentence only to find that something was missed is simply too high for me not to ask.



I can have a look at the program later today and maybe understand it.
 
No offence taken. I also wouldn't wanna come to any place only to waste people's time with my own negligence.

I did indeed made sure all the hardware work for 2 days straight. Everything works mechanically as it should. The valve board function properly, no issues with the profibus network. All valves on the board can be forced on and off through the profibus from the S7-300 by using Step7.

Same with all the pneumatic actuator magnetic contact (2 per actuator, signaling cylinder high and low position) all return to the Festo valve board and all can be seen through Step7. CPU has only 1 DI and 1 DO modules, both work.

As always the program is long, un-commented. Most DI, DO that are actually present on the machine I've commented.

The problem with the machine is that all works, except two actuators responsible for bending. This is what i meant, in FB 95 on network 19 there is an instance of a FB32, STAT258 responsible for activating coil Q33.1. If M202.0 is on. That's another thing, because M202.0 is an IO on STAT258, it won't stay on. Something keeps turning it off as well.

I would like another pair of eyes to go over that, see and find everything that would prevent the coil from turning ON.
 
Last edited:
When you get the message from STEP7 that the project must be saved as "language neutral" for you to open it, then you cannot open the project and you cannot change it to language neutral. Catch-22.

Do like this:

In the project folder go to the GLOBAL sub-folder.
Find the file LANGUAGE (no extension) and copy it to a backup file LANG_BAK.
Open the LANGUAGE file with notepad for example.

There may be several lines like this:

0
2052
134
936
936
Chinese (PRC)

Change to this:

0
1033

and save again without extension.

The STEP7 project can now be opened.
 
JesperMP: Thank you for the valuable info. Though i read it after, i just converter my non-unicode settings to English US and re-uploaded the program after. Now i know a better way, thank you.

Indeed sometimes you get programs with Russian comments here and you can't read a thing.



cardosocea: Yes i cross-referenced, Q33.1 is only in DB95, and M202.0 is in 2 other other blocks, FC22 and FC48 but those aren't called and it's suppose to work without them. They are only for automatic production mode.
Problem is that it's written with many Stats to Stats and blocks inside of blocks. That's why i would like another pair of eyes on it. Been on it for days, might have tunnel vision.


English program:
https://www.upload.ee/files/10492381/Assemb.zip.html
 
Last edited:
When you get the message from STEP7 that the project must be saved as "language neutral" for you to open it, then you cannot open the project and you cannot change it to language neutral. Catch-22.

Do like this:

In the project folder go to the GLOBAL sub-folder.
Find the file LANGUAGE (no extension) and copy it to a backup file LANG_BAK.
Open the LANGUAGE file with notepad for example.

There may be several lines like this:

0
2052
134
936
936
Chinese (PRC)

Change to this:

0
1033

and save again without extension.

The STEP7 project can now be opened.

Ahhh, the mystic world of Step7 files. I'll keep this one along with the "removing password protection from blocks with Access 2003" tip. LOL

It didn't work, but I copied the contents of a blank project created in my PC and it worked then. Thanks.

As for the problem at hand... the guy writing this is a cheeky bugger...

In FB95 in Network 18, he writes into #STAT258.STAT20 and #STAT286.STAT20 there are six contacts there that interfere with this.
The #STAT258.STAT20 variable is described above must be high for the output to be made active inside FC33, Network 6.

I'm afraid that without being online, I can't quite tell what the problem is and chasing all of those signals is just not efficient.
 
That's the thing right, program is written awkwardly. I am online and also trying to run it through Sim. Machine is not even that complicate, bunch of pneumatic valves for the most part. The program on the other hand...
I'll continue to look at it online and simulated. Any help is more then welcomed. I can compensate time expenses on agreement.

Edit:

On Sim even if #STAT258.STAT20 and #STAT286.STAT20 are high still M202.0 can't stay high to turn on Q33.1
 
Last edited:
Show us the screenshot of FB95 in Network 18 online. Whatever signal is off on that network is what's stopping you.

I wouldn't say awkwardly. Someone that creates multi-instance FB's in Step7 would also know full well he shouldn't access instance DB data externally, but doing so creates a block for someone following the program as it's not something that you'd normally do.
 

Similar Topics

We are using siemens S135U PLC. We are not using one control loop since long back. Now we have to take it in to operation. we found that, total...
Replies
1
Views
2,433
I really struggle with STL in Siemens Step 7 Classic. I'll learn chunks, but then I don't use it enough to retain and build on the knowledge. When...
Replies
17
Views
3,215
Hi, Can someone translate this for me please, or at least help to explain what the instructions mean? SET SAVE =...
Replies
17
Views
4,617
Hello everyone I am new to Siemens Step 7 and having some issues I was going to add the a FC to OB1 (Network 28 In Image 1) But it was asking...
Replies
9
Views
2,392
If I go online via the PC Adapter, all the blocks are there and all is good. If I go online via the CP-443 via IE, all the blocks then disappear...
Replies
6
Views
1,474
Back
Top Bottom