EasyManuals Logo

Siemens Simatic S7 Series System Manual

Siemens Simatic S7 Series
726 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #8 background imageLoading...
Page #8 background image
Table of contents
S7-200 SMART
8 System Manual, 09/2015, A5E03822230-AC
7.5.3 Number value to ASCII string conversion ............................................................................ 208
7.5.4 ASCII sub-string to number value conversion ..................................................................... 212
7.5.5 Encode and decode ............................................................................................................. 215
7.6 Counters ............................................................................................................................... 216
7.6.1 Counter instructions ............................................................................................................. 216
7.6.2 High-speed counter instructions .......................................................................................... 220
7.6.3 Noise reduction for high-speed inputs ................................................................................. 224
7.6.4 High-speed counter programming ....................................................................................... 226
7.6.5 Example initialization sequences for high-speed counters .................................................. 238
7.7 Pulse output ......................................................................................................................... 247
7.7.1 Pulse output instruction (PLS) ............................................................................................. 247
7.7.2 Pulse train output (PTO) ...................................................................................................... 249
7.7.3 Pulse width modulation (PWM) ............................................................................................ 251
7.7.4 Using SM locations to configure and control the PTO/PWM operation ............................... 252
7.7.5 Calculating the profile table values ...................................................................................... 255
7.8 Math ..................................................................................................................................... 259
7.8.1 Add, subtract, multiply, and divide ....................................................................................... 259
7.8.2 Multiply integer to double integer and divide integer with remainder ................................... 262
7.8.3 Trigonometry, natural logarithm/exponential, and square root ............................................ 264
7.8.4 Increment and decrement .................................................................................................... 266
7.9 PID ....................................................................................................................................... 268
7.9.1 Using the PID wizard ........................................................................................................... 269
7.9.2 PID algorithm ....................................................................................................................... 274
7.9.3 Converting and normalizing the loop inputs ......................................................................... 278
7.9.4 Converting the loop output to a scaled integer value........................................................... 279
7.9.5 Forward- or reverse-acting loops ......................................................................................... 279
7.10 Interrupt ................................................................................................................................ 282
7.10.1 Interrupt instructions ............................................................................................................ 282
7.10.2 Interrupt routine overview and CPU model event support ................................................... 284
7.10.3 Interrupt programming guidelines ........................................................................................ 285
7.10.4 Types of interrupt events that the S7-200 SMART CPU supports ...................................... 287
7.10.5 Interrupt priority, queuing, and example program ................................................................ 288
7.11 Logical operations ................................................................................................................ 293
7.11.1 Invert .................................................................................................................................... 293
7.11.2 AND, OR, and exclusive OR ................................................................................................ 294
7.12 Move ................................
.................................................................................................... 296
7.12.1 Move byte, word, double word, or real ................................................................................. 296
7.12.2 Block move ........................................................................................................................... 297
7.12.3 Swap bytes ........................................................................................................................... 298
7.12.4 Move byte immediate (read and write) ................................................................................ 299
7.13 Program control .................................................................................................................... 300
7.13.1 FOR-NEXT loop ................................................................................................................... 300
7.13.2 JMP (jump to label) .............................................................................................................. 301
7.13.3 SCR (sequence control relay) .............................................................................................. 303
7.13.4 END, STOP, and WDR (watchdog timer reset) ................................................................... 312
7.13.5 GET_ERROR (Get non-fatal error code) ............................................................................. 313
7.14 Shift and rotate ..................................................................................................................... 315
7.14.1 Shift and rotate ..................................................................................................................... 315

Table of Contents

Other manuals for Siemens Simatic S7 Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens Simatic S7 Series and is the answer not in the manual?

Siemens Simatic S7 Series Specifications

General IconGeneral
CPUVaries by model (e.g., S7-300, S7-400, S7-1200, S7-1500)
Communication InterfacesPROFIBUS, PROFINET, Ethernet, MPI
ProgrammingTIA Portal, STEP 7
Programming LanguagesLAD, FBD, STL, SCL, GRAPH
I/O ModulesDigital, Analog, Specialty modules available
Operating Temperature0°C to 60°C (standard models)
MountingDIN rail mounting
Operating Voltage24V DC or 120/230V AC (varies by model)
Protection ClassIP20 (standard models)
MemoryVaries depending on the S7 model. Includes work memory (RAM) for program execution, load memory (EEPROM or Flash) for program storage, and system memory for operating system functions. Memory sizes range from kilobytes to megabytes.

Related product manuals