What is Data Block in Siemens S7?

Riche Robledo

Member
Join Date
May 2011
Location
Dubai,UAE
Posts
36
I am pursuing to learn PLC specially Siemens brand not because of i like but most
of PLC i handled here in our company is Siemens.I should learn more and i have to give myself to focus.
I have an idea to make a logic or sequence in ladder diagram but i am not satisfy for that and i have to upgrade my skills.

Here is my few question in Siemens:
1.What is Data Block?
2.How many bits/byte/word in one Data block?
3.What is the function of data block?
4.Where is the site that i may learn the addressing of PLC memory?

Please let me know because i want to erase my DOUBT in my mind...
Anyone may give any idea is my blessing to me.

Thanking you, :confused:
RR
 
1, A data block is an area of memory that can be freely setup for any type of data you like. This can be bits, bytes, words, ints, reals or even your own data types.
2, Size of the data block depends on the PLC. Consult the manual for that PLC. Generally, 1024 bytes is safe for all S7 300 and 400. Most are capable of more.
3, Function of the data block is to allow you to setup the memory area in a convenient manner for your program. As a secondary function, it allows you to set aside memory for the FB type of function. This type of function retains its memory between calls, therefore needs a place to store the "instance" of the function block.
4, I found the help files for S7 to be quite good. That, along with looking at other people's code and experimentation was the best way to learn.
 
regarding question 3:

You can save your data into merkers (example MW20) but they are very limited in numbers so with them you can not work with a lot of data.

If you need to work with much data you should use datablocks.

A functionblock (FB) is automatically assigned with a datablock (DB). In this DB the status of the FB his 'in', 'out', 'in/out', and 'stat' variables are saved or given a default value. The default value is the 'initia'l value what you gave them when you created that variable inside the FB.
 

Similar Topics

Hello all, PLC-programming noob here. I have multiple clients accessing some data on my Siemens S7 1211C PLC; some OPC clients and some direct...
Replies
30
Views
8,263
Hello all, Newbie in Siemens, I want to ask if there will be any issue when I download the instance datablock of a certain Function block? Also...
Replies
6
Views
4,394
Just a quick question I can't find an answer on yet. I have created my own recipe structure using a Global DB and when I came in this morning...
Replies
2
Views
2,014
Hello, I am trying to find an easy way to create data blocks in Step 7 with ~100K tags other than manually defining each tag in the LAD/STL/FDB...
Replies
8
Views
14,134
Hello All, Is there a way in Step 7 5.5 SIMATIC Manager to export a data block so that it can be imported into another project with all...
Replies
11
Views
3,707
Back
Top Bottom