How to disable OBs in Step7

Mihi88

Member
Join Date
Aug 2012
Location
home
Posts
5
Hi, I am not such experienced in Simatic Step 7.
My question is pretty clear: how to disable (if it's possible) OBs in Simatic Step7. I don't want to delete OBs.

Thanks.
sorry for my bad engrish ;)
 
Hi Jeebs, it's a normal Program cycle OB.
And why disable? Because I don't need this OB in this moment. It's simple example program.
I search some in Properties and in Call structure, but no luck as of yet.
 
The best way is probably to copy the code from the OB to an FC which you do not call.

Or put in BEU in top of the OB.

Or put in JU M001 // Jump to label M001
(code not to be executed)
M001: NOP 0

(mode code)

Kalle
 
JU M001 // Jump to label M001
(code not to be executed)
M001: NOP 0

KalleOlsen: yes, it's good option.
Better then enable bit on every Network.

Understand I that correctly the program will be even downloaded into PLC with this OB (that will do not anything)?
 
Hi Jeebs, it's a normal Program cycle OB.
And why disable? Because I don't need this OB in this moment. It's simple example program.
I search some in Properties and in Call structure, but no luck as of yet.

Is this for a S7 1200 PLC? With Step 7 TIA

For S7 TIA then "Organization blocks for cyclic program execution" ...... "You can use multiple OBs (OB numbers >= 123)"
 
Is this for a S7 1200 PLC? With Step 7 TIA

For S7 TIA then "Organization blocks for cyclic program execution" ...... "You can use multiple OBs (OB numbers >= 123)"

Yes, it is for a Simatic S7-1200 PLC in TIA Portal V11
Number may be in the range 1, 123-32767.
 
If you really need to keep the OB then in the first network program a -(JMP) to a "LABEL" that is in the last network of the OB, then everything in the OB is "bypassed"
 
I'll second the option of putting a BE at the start of your code. This means that if/when the block gets called it 'ends' straight away without executing the rest of the code. Also, by having the BE at the start, it is immediately clear to anyone looking at the code that the rest of the block isn't going to be executed.

;-)
 

Similar Topics

Hello, I am still new to PLC programming and I just got this job two year out of school so I don’t remember much. I was given a task were I have...
Replies
1
Views
165
How can we disable the DHCP server on a Stratix 5700 ethernet switch? It is running on a machine with Rockwell automation and drives. We...
Replies
6
Views
1,576
Hello. We have a Powerflex 700s phase II firmware 4.002, but the encoder card is burned. We want to disable it to use the Drive without motion...
Replies
0
Views
451
As above. I've been fishing around on TIA portal but haven't found a "Disable channel" tickbox. Is there one? If so, where is it? Cheers
Replies
9
Views
1,323
Hello, I have plc Schneider TM241CE40T with the hmi HMIS5T. Do you have idea how to disable a button after an emergency stop to vijeo designer ...
Replies
5
Views
1,431
Back
Top Bottom