Am Using WinCC 5.0 Version and S7-400 range of PLC , WinCC is for 1024 Tags. Currently am considering a single digital Input or Digital Output as a single WinCC External tag. With this considered for 400 Digital I/O, i am using 400 WinCC External Tags. Is there any efficient method to configure digital i/os' so that i could optimise my WinCC External Tags ie. some method with which i could read about 16 or 32 Digital I/Os' in a single WinCC tag or something on similar lines. With this done i could save my WinCC External tags.
Could some one suggest me something on same lines.
You can use a unsigned 16 bit or a unsigned 32 bit Tag en read it with GetTagWord/SetTagWord or GetTagDWord/SetTagDWord.
Another way to it and read a datablock from the plc is use rawdata tags so you can do it with 1 one tag voor reading and 1 tag for writing.
Both ways are from the point of engineering and maintenance of software a bad way of programming. When you use single tags or structures of tags you can do it without c-scripts and you can replace objects in a easy way. So at the end you've got better software but it use more tags.
Jan de Liefde
First of All i would like to thank you for ur reply.
I can read my digital tags in a unsigned 32 bit tag with GetTagWord/ GetTagDWord, but then how do i decode my each digital inputs for further dispaly in Graphics or for alarms. For this also do i need to use C-Script.
Please throw some light on this.
To display the inidividual bits of the tag on a graphic, you can use the Dynamic Dialog wizard against the objects property.
To write to individual bits of a tag you can use the wizard from the Dynamic Wizard toolbar. This will create the C-script for you.
It may be true that you need to script bit-picking in WinCC, but as long as you use the supplied wizards you can usually accomplish the task without having to write a single piece of code :)
Let me know if you need any more clarification on the above
hope this helps
<P>The best way (as far as I have concluded) is to use the 32-bit Tag. With this you can pick up a Double Word (32 bits) values. To decode this at the WinCC end, you will need to the WinCC Dynamic Wizard. With the wizard, you can pick up the required bit without the need for C-Script (The Wizard does it for you).</P>
<P>However, there is a catch: The bits in the PLC and HMI are not mapped 1-to-1 (probably due to the different HW architecture!!!). The mapping is as below:</P>
HMI PLC HMI PLC HMI PLC HMI PLC
0 24 8 16 16 8 24 0
1 25 9 17 17 9 25 1
2 26 10 18 18 10 26 2
3 27 11 19 19 11 27 3
4 28 12 20 20 12 28 4
5 29 13 21 21 13 29 5
6 30 14 22 22 14 30 6
7 31 15 23 23 15 31 7
To overcome come this mapping problem, I usually use a byte tag (8-bit). That way, the mapping is 1-to-1 and I do not have to refer to the above
mapping table all the time :)