How to create a long time timer in LX5V?

Last modified by Jett on 2026/02/11 09:17

For LX5V, we can use counter and timer to do a long time timer.

05 Timer and counter - XWiki

1770715539111-438.png

Same as the example, T0 is a 100ms timer, [OUT T0 K10] make the timer become a 1S timer.

Using timing, D0 increases by 1 after every 1S.

And use count function ,we can record the number of seconds to make further judgments about the time.

03 Arithmetic operation - XWiki

11 Contact comparison - XWiki

1770716410505-221.png

Use [OUT T0 K3600] to create a 1hour timer.

D0 increases by 1 after every 24 hour, D1 increases by 1 after every 7 Day, then Y0 become a 1 week timer.