Internet PLC Forum
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
Home
Help
Search
Login
Register
Internet PLC Forum
»
General
»
Technical support
»
Real time clock and day
« previous
next »
Print
Pages: [
1
]
Author
Topic: Real time clock and day (Read 10827 times)
tobor0216
Newbie
Posts: 24
I'm a llama!
Real time clock and day
«
on:
July 17, 2009, 03:14:12 AM »
I have a FA1616-BA controller,and I am wondering how I can control a I/O based on the day of the week. For example I want to set or clear I/O's Monday through Friday, but on Sat and Sun I do not want to do abything with the I/O's?
Logged
support
Global Moderator
Hero Member
Posts: 3174
Re:Real time clock and day
«
Reply #1 on:
July 19, 2009, 07:54:13 AM »
The day of the week is in the variable DATE[4]. So you can use IF THEN ELSE statement to make decision on what to do.
E.g. IF DATE[4] < 6 THEN
SETIO XXX
ELSE
CLRIO XXX
ENDIF
You only need to run this check only when TIME[1] = 0.
Logged
Email: support@triplc.com
Tel: 1-877-TRI-PLCS
Print
Pages: [
1
]
« previous
next »
Internet PLC Forum
»
General
»
Technical support
»
Real time clock and day