Everything

set_tim

iset_tim

Outline
Set system time.
C format
 ER      set_tim (SYSTIM *p_systim);
 ER      iset_tim (SYSTIM *p_systim);
Parameter(s)
I/O
Parameter
Description
I
 SYSTIM  *p_systim;
Time to set as system time.

[System time packet: SYSTIM]
 typedef struct  systim {
     UH      utime;          /*System time (higher 16 bits)*/
     UW      ltime;          /*System time (lower 32 bits)*/
 } SYSTIM;

Explanation
These service calls change the RI600V4 system time (unit: msec) to the time specified by parameter p_systim.
Note Even if the system time is changed, the actual time at which the time management requests made before that (e.g., task time-outs, task delay by dly_tsk, cyclic handlers, and alarm handlers) are generated will not change.
Return value
Macro
Value
Description
E_OK
0
Normal completion.
E_CTX
-25
Context error.
- This service call was issued in the CPU locked state.
- This service call was issued in the status PSW.IPL > kernel interrupt mask level.
Note When the iset_tim is issued from task or the set_tim is issued from non-task, the context error is not detected and normal operation of the system is not guaranteed.