Joe E.

Overlapping memory areas in TIA Portal

3 posts in this topic

I have a fair amount of experience with Simatic Manager, but I'm new to TIA Portal. This one has me stymied after a couple hours of hunting (this time). This is an issue we've encountered before with various machines programmed in Portal, but didn't have a chance to chase it down. Here's a simple and clear example.

This machine is from France and was programmed with Portal v14. The alarm bits are all contained in a global data block DB2. The alarm bits are individually SET in FC2 when conditions are right for each alarm. Each bit has its own -(S)- coil, which (as far as we can tell) is the only place it's written...EXCEPT...the first network in FC2 uses MOVE instructions to write "0" to DB2.DBD0 and DB2.DBD4 any time a "reset" pushbutton is pushed (there are 2). The problem we have is that all of the ways we've tried accessing the cross-reference for the program only show the individual bits (DBX), not the double words (DBD). If the MOVE instructions had been placed in another FB/FC/OB somewhere, we would have had a major devil of a time finding them. They just happened to be at the top of the alarm FC. Here's a screenshot of the MOVE instructions with the x-ref information shown for DB2:

5cf815721f1fd_PortalDBx-ref01.thumb.PNG.

In the Simatic Manager world, the Cross Reference will show where the different registers are used, whether as DBX, DBB, DBW, or DBD, but it seems to me that the Cross Reference in Portal only shows actual symbols, not addresses. Since there is no symbol defined for the DBD addresses (and I don't there CAN be, since they're defined as DBX bit addresses), they don't show in the x-ref. I opened the Cross-Reference window (which is different from the bottom-half cross-reference information tab above) and clicked on "Show overlapping access" on its toolbar, which opened another sub-window...which is blank and doesn't show the overlapping access to the DBD word (maybe because the MOVE instructions used absolute addresses instead of non-existent symbols?):

5cf815733c783_PortalDBx-ref02.thumb.PNG.

I came across a blog post about issues in TIA portal v13. One of the entries mentions a global address overview, which is tantalizingly close to the "show usage" tab of the old Simatic Manager x-ref but I can't find any way to get to it. This probably wouldn't help us track down a DBx.DBDy overlap, but would be useful for finding unused "M" memory:

5cf8167faa555_PortalDBx-ref03.PNG.4d2c87

Another "interesting" piece of information is how the HMI alarms are configured. They use trigger tags that are word-level, not double-level. In other words, alarm #1's trigger address is DB2.DBX1.0, which is part of Trigger tag Alarme_mot_0, which points to DB2.DBW0. The tag databases and x-refs for the PLC and HMI appear to be distinct and separate entities, contrary to the marketing presentation we attended for Portal which said that everything was in one place and easy to find. That's definitely not our experience so far.

5cf8230e31993_PortalDBx-ref04.thumb.PNG.

I found an article on Siemens' website about prepending "AT" to the beginning of a tag name to have overlapping tags but that only applies to the declaration areas of FBs and FCs. This is a global DB. And I'm not sure it would even work anyway, though I suspect it would IF the MOVE instructions used the tag names instead of the addresses.

Can anyone help me figure out a way to x-ref the DBD usage and to find the global address overview?

 

 

Share this post


Link to post
Share on other sites

Joe,

I'm no Siemens expert but I know not everything shows up in cross reference in TIA. Even simple things like being on a contact of a timer's Q bit does not show the timer. In TIA it's mostly possible to avoid using direct references to DB address. TIA is certainly a lot better than Step 7 classic with all the cretic addressing. You can still find them by doing a search for "DB2" in the entire project. In our last project for alarms we also set individual bits but they are part of a Structure with an array of INT so they can be cleared by the tag names and avoid the direct addressing that your French machine has.

Share this post


Link to post
Share on other sites

Hmmm....

I searched the project and it turned up where the words are used. It would be really nice if the search results had a column showing whether it was used as a read or as a write. As it is, you have to open each result and look at it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now