This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
|Try our online
PLC Simulator- FREE.
Click here now to try it.
New Here? Please read this important info!!!
|June 13th, 2013, 02:12 AM||#1|
Join Date: Mar 2009
Indirect addressing with WinCC Flexible
I'm having some problem with indirect addressing in WinCC Flexible RT (PC-based)
I've a DB structured as below: an array of 300element of UDT.
The udt consist in two variables:
So it's something similar to a table.
In this table, i've to do some operation like add elements, sorting by "code", delete and compact, modify.
On the plc side, there's no problem, i've already written all the function that i needed.
The difficult part is on HMI side.
I've to create a page to view the table. But beacause of the amount of the elements, i would like to have a view in a single page of at least 10 (maybe 20 is better) elements, so 2 columns (one for the code, the other for the description) and lets say 10row.
Then, with two button prev and next i can navigate into the DB Table's elements.
As i'm not an expert with indirect addressing and script, the only way i've got the things working it's like below:
I've create 10 fields "code".
Field1 contain variable Code_1, that point to DBxxx.DBW[code_index_01] (with multiplex address mode), Field2 contain Code_2 that point to DBxxx.DBW[code_index_02] and so on..
A default start value of the internal variables code_index_yy is set, so the first time i run the RT i've the indexes pointin g to the first ten elements.
Then when i press "next" button, it runs a script wich simple increments the variables code_index_yy to point to the next ten elements
But in my opinion is not a very elegant solution.
This HMI communicate with 3 different PLCs, each one have its own DB, so i've to repeat the variable for each one...
Maybe anyone of you have other ideas on how to do that? With a different approch maybe?
I've also attached some images, maybe with these it's easy to understand..
Maybe my explanation is not very clear, but i hope you'll understand the problem.
Thanks a lot for your support.
|June 13th, 2013, 05:54 AM||#2|
For this sort of thing I always do it the other way round now - create a single display page for the HMI and resrve a space in the PLC memory for this. I then map the data as required in the PLC - much easier than trying to do it in the HMI and you save a load of tags as well (although I believe that's no longer such a problem with WinCC Flex as it was with ProTool).
|June 13th, 2013, 10:41 AM||#3|
Lifetime Supporting Member
Join Date: Feb 2008
Location: Over there, next to those boxes
I'm with Roy on this one. A datablock in the PLC and then the data is mapped in via an Int in the PLC which is incremented or decremented by your navigation buttons indirectly.
|Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)|
|Thread||Thread Starter||Forum||Replies||Last Post|
|Siemens SIMATIC WinCC flexible 2008 Advanced - Installation Fails||Saulo35||LIVE PLC Questions And Answers||4||October 7th, 2013 07:14 AM|
|Citect Vs WinCC - Long||Doug_Adam||LIVE PLC Questions And Answers||20||May 28th, 2013 12:02 PM|
|Why cant OPs state the "Flexible" in WinCC Flexible ?||JesperMP||LIVE PLC Questions And Answers||0||August 5th, 2008 01:41 AM|
|WinCC Flexible Quirks||tvey||LIVE PLC Questions And Answers||5||May 3rd, 2007 05:57 AM|
|Simatic Wincc Flexible 2004 -->2005||STL???||LIVE PLC Questions And Answers||8||August 29th, 2006 05:42 AM|