Time-related functions

Time-related functions include functions to read and to set the clock of the FP-I4C unit.

For compatibility with FPWEB2, the script functions FPWEB_SETCLOCK_RTC and FPWEB_SETCLOCK_DATETIME can still be used. However, we do not recommend to synchronize the internal clock of the FP-I4C unit with the PLC clock. Instead, the FP-I4C unit should get its time from an NTP server.

FPWEB_GETCLOCK_DATETIME

This function reads the internal clock of the FP-I4C unit.

This function is useful to forward the FP-I4C time to the PLC. The FP-I4C unit gets its time from NTP servers and is using the regional setting to handle the daylight saving time.

Call

FPWEB_GETCLOCK_DATETIME();

Result

The internal clock of the FP-I4C unit in the DT (DATETIME) format of Control FPWIN Pro7 (32-bit value)

Example

DT[1000] := FPWEB_GETCLOCK_DATETIME();

Modified on: 2021-11-15Feedback on this pagePanasonic hotline