32 Bit Up/Down CounterΒΆ

The function block CMS_IO_32BIT_CNT can be used to control one 32 bit up/down counter function CMS_IO_32BIT_CNT: CMS_IO_32BIT_CNT 32 Bit Counter

Possible operation modes: 1-1, 2-1, 5-1, 6-1 <no title>

Touch/Catch Operation

The touch/catch operation is the way to acquire the counting position synchronously with hardware external signal removing all the latency time of I/O-Bus and network. This operation allows synchronization between 2 different encoder devices if the same hardware signal is used for touch/catch input.

On edge of the physical external signal, the current counter value (ACT) is stored in a dedicated double word (CNT_TOUCH). The touch/catch operation could be settled on rising or falling edge depending on parameter EDGE_TOUCH.

../_images/dbe64d18e38b6e130a33139000eba54e1

Procedure and associated counting value with signal A

Touch/catch operation is enabled through control bit (EN_TOUCH). This resets the status flag (RDY_TOUCH), when the pre-determined edge occurs; the current counter value is stored in the touch value double word. In the same time, the status RDY_TOUCH is set to TRUE.

A rising edge at input DI0, DI1, DC2 or DC3 causes the function block to store the actual counter value and to display this value at output CNT_TOUCH.

SET Operation

A rising edge at input DI0, DI1, DC2 or DC3 causes the function block to store the START_VALUE value and to display this value at output ACT.

RESET Operation

A rising edge at input DI0, DI1, DC2 or DC3 causes the block to reset the value at output ACT.

Overflow Operation

The counter operates as infinite counter. An overflow occurs corresponding to the 32 bit value at 16#80000000 = 2147483648 and any exceeding or falling below of this value (depending to up and down use) OFL will set to TRUE.

../_images/203b22abe38b70a30a33139000eba54e1