dly_tsk

Outline

Delay task.

C format

 ER      dly_tsk (RELTIM dlytim);
Parameter(s)

I/O

Parameter

Description

I

 RELTIM  dlytim;
Amount of time to delay the invoking task (in millisecond).



Explanation

This service call moves the invoking task from the RUNNING state to the WAITING state (delayed state).

As a result, the invoking task is unlinked from the ready queue and excluded from the RI600PX scheduling subject.

The delayed state is cancelled in the following cases.

Delayed State Cancel Operation

Return Value

Delay time specified by parameter dlytim has elapsed.

E_OK

Forced release from waiting (accept rel_wai while waiting).

E_RLWAI

Forced release from waiting (accept irel_wai while waiting).

E_RLWAI



Note When 0 is specified as dlytim, the delay time is up to next base clock interrupt generation.

Return value

Macro

Value

Description

E_OK

0

Normal completion.

E_PAR

-17

Parameter error.

- dlytim > (0x7FFFFFFF - TIC_NUME) / TIC_DENO

E_CTX

-25

Context error.

- This service call was issued from a non-task.

- This service call was issued in the CPU locked state.

- This service call was issued in the dispatching disabled state.

- This service call was issued in the status "PSW.IPL > kernel interrupt mask level".

E_MACV

-26

Memory access violation.

- Stack pointer points out of user stack for invoking task.

E_RLWAI

-49

Forced release from the WAITING state.

- Accept rel_wai/irel_wai while waiting.