Special memory (SM) and system symbol names
D.14 SMB36-45 (HSC0), SMB46-55 (HSC1), SMB56-65 (HSC2), SMB136-145 (HSC3): high-speed counters
S7-200 SMART
System Manual, 09/2015, A5E03822230-AC
675
SMB36-45 (HSC0), SMB46-55 (HSC1), SMB56-65 (HSC2),
SMB136-145 (HSC3): high-speed counters
These addresses provide high-speed counter configuration and operation, for HSC0, HSC1,
HSC2, and HSC3.
Table D- 9 High-speed counter 0 configuration and operation
: Counter status bits are valid only while an interrupt routine triggered
by a high-speed counter event is being executed.
SM36.0–SM36.4 Reserved
HSC0 current counting direction status bit: 1 = counting up
HSC0 current value equals preset value status bit: 1 = equal
HSC0 current value is greater than preset value status bit: 1 = greater than
HSC0_Reset_Level SM37.0 Active level control bit for Reset: 0 = Reset is active high, 1 = Reset is active
HSC0_Rate SM37.2 HSC0 count rate selection for AB quadrature phase counters: 0 = 4x count-
ing rate; 1= 1x counting rate
HSC0 direction control bit: 1 = count up
HSC0 update direction: 1 = update direction
HSC0 update preset value: 1 = write new preset value to HSC0 preset
HSC0 update current value: 1 = write new current value to HSC0 current
HSC0 enable bit: 1 = enable
SMD38 is used to set HSC0 current value to any value you choose. To
update the current value, write SMD38 with the desired new current value,
write SM37.6 to 1, and execute the HSC instruction. The new current value
is then written to HSC0's current count register.
SMD42 is used to set HSC0 preset value to any value you choose. To up-
date the current value, write SMD42 with the desired new current value,
write SM37.5 to 1, and execute the HSC instruction. The new preset value
is then written to HSC0's preset register.