Evaluate Statusword, Errorword And Warningword - Siemens SIMATIC S7-1500 Function Manual

Update 3
Hide thumbs Also See for SIMATIC S7-1500:
Table of Contents

Advertisement

7.2.3

Evaluate StatusWord, ErrorWord and WarningWord

To be able to use individual status and error information from the "StatusWord", "ErrorWord"
and "WarningWord" data double words, the evaluation can be performed as described
below. For consistent evaluation, you should avoid using bit addressing to access these data
double words in the technology data block. Access to an individual bit in the technology data
block only lasts as long as the access to the entire data word.
When required, copy the required data double word into a tag of a data structure and query
the individual bits of the tag.
A description of the data double words and the allocation of the individual bits can be found
in the Appendix:
● StatusWord (Page 351)
● ErrorWord (Page 353)
● WarningWord (Page 356)
Requirements
The technology object has been created.
Procedure
To evaluate the individual bits in the data word "StatusWord", proceed as follows:
1. Crate a global data structure. Name the data structure, e.g. as "Status".
2. Create a double word (DWORD) in the data structure "Status". Name the data structure,
3. Create 32 Boolean tags in the "Status" data structure. You can obtain a clearer overview
4. Copy the tag <TO>.StatusWord as needed from the technology data block to the double
5. Copy the bits of dword "Temp" to the corresponding Boolean tags by means of bit
6. Use the Boolean tags to query the status bits.
Evaluate the "ErrorWord" and "WarningWord" data words as specified in steps 1 to 6.
S7-1500 Motion Control V13 Update 3
Function Manual, 07/2014, A5E03879256-AC
e.g. as "Temp".
by naming Booleanhe Boolean tags as defined for the bits in the technology DB
(e.g. name the fifth Boolean tag "HomingDone").
word "Temp" in your data structure.
access.
Programming
7.2 Technology data block
175

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic s7-1500 motion control v13

Table of Contents