Siemens FC and FB instructions

helphelphelp

Member
Join Date
Feb 2020
Location
Canada
Posts
41
Hello, I am very new to Siemens troubleshooting, I had previously only worked with Allen Bradley. I would like to get more understanding on how to trouble shoot FC instructions and what the difference is between an FC and an FB? Is there any way to open an FC instruction like I would an AOI in Allen Bradley to see the logic inside that block? If so how would I go about doing that?

Any help is appreciated.

Thanks!
 
FC an FB

Hi,


I've nver used Allen-Bradley so I can't compare with them. I'd describe them as follows:



FC are functions that take inputs and write to outputs lika a function in C or other programming language. Inside of the FC you can use only the block inputs and outputs (and get a reusable block) ou use Flags (Mxx.x), Inputs (Ixx.x), Outputs (Qxx.x) or external datablocks (DBxx.DBxxx.x).


If the block needs to be reusable (i.e. a Motor block) you would need to use a lot of Inputs and Outputs to keep the internal state of the block.


FBs a functions that in every use (i.e. for each motor) have a different datablock (DB) that keeps the internal state of that call.


Best regards,
Kelkoon
 
Yes you can open FBs and FCs, unless they are protected blocks.
Google "Siemens STEP7 getting started" and you should get tons of links inkl. youtube videos. There is a big difference between the older STEP7 'Classic' for S7-300/400 and the newer TIA portal for S7-1200/1500, so you must distinguish between these TIA can also be used for S7-300/400, but that is a can of worms.

As to "what the difference is between an FC and an FB?".
An FC does not have memory by itself. A rookie mistake is to use TEMPs in the FC and assume that these are retained between scans. All the IO and the other memory must be passed in and out of the FC.
An FB is like an FC, except it has its own memory (called STATs). Because of the memory, every call of an FB must have an instance-DB (IDB) assigned to it.
Think of the FB+IDB as an 'object'.
 
Hello, I am very new to Siemens troubleshooting, I had previously only worked with Allen Bradley. I would like to get more understanding on how to trouble shoot FC instructions and what the difference is between an FC and an FB? Is there any way to open an FC instruction like I would an AOI in Allen Bradley to see the logic inside that block? If so how would I go about doing that?

Any help is appreciated.

Thanks!

Function Block is like AOI. You can create and edit FB
 
I’m not sure if it’s somatic or TIA. It’s about 12 years old so I assume simatic? Basically the problem I’m running into is seeing lots of FC instructions with all the inputs and outputs but not sure of exactly how to read these instructions for troubleshooting. I’m an electrician who can read ladder diagrams but never had the experience programming. I’m only a troubleshooter essentially.
 
I’m not sure if it’s somatic or TIA. It’s about 12 years old so I assume simatic? Basically the problem I’m running into is seeing lots of FC instructions with all the inputs and outputs but not sure of exactly how to read these instructions for troubleshooting. I’m an electrician who can read ladder diagrams but never had the experience programming. I’m only a troubleshooter essentially.
If you're intention is to learn then there's plenty of resources to get you on your way.
If you are troubleshooting something and need timely help the post screenshots and we're likely to ask for more specific screenshots afterwards to help you out.
 

Similar Topics

Hi, I am working with an old S5 program and need some information on a couple of instructions or a reference that details the operation of these...
Replies
2
Views
1,409
dear friends i dont know the process of communication between modicon plc and pc please help me in this procedure of communication so...
Replies
3
Views
2,408
help me need instructions on siemens 230rl 240 ac 12 inputs 8 relay out 10amp instructions please ?
Replies
6
Views
7,821
HI everyone, i am new to Siemens plc programming and i am in need of some help. yesterday we had an S7-1200 CPU 1214C fail to turn on an output to...
Replies
7
Views
164
Hi PLC people, think about this scenario: The PLC is somehow connected to the same network with the facilities` network. Then someone connects to...
Replies
2
Views
84
Back
Top Bottom