1 |
sys_arch interface for lwIP 0.5 |
sys_arch interface for lwIP 0.6++ |
2 |
|
|
3 |
Author: Adam Dunkels |
Author: Adam Dunkels |
4 |
|
|
60 |
only be blocked for the specified time (measured in |
only be blocked for the specified time (measured in |
61 |
milliseconds). |
milliseconds). |
62 |
|
|
63 |
If the timeout argument is non-zero, the return value is the amount |
If the timeout argument is non-zero, the return value is the number of |
64 |
of time spent waiting for the semaphore to be signaled. If the |
milliseconds spent waiting for the semaphore to be signaled. If the |
65 |
semaphore wasn't signaled within the specified time, the return |
semaphore wasn't signaled within the specified time, the return value is |
66 |
value is zero. If the thread didn't have to wait for the semaphore |
0xffffffff. If the thread didn't have to wait for the semaphore (i.e., it |
67 |
(i.e., it was already signaled), care must be taken to ensure that |
was already signaled), the function may return zero. |
|
the function does not return a zero value since this is used to |
|
|
indicate that a timeout occured. A suitable way to implement this is |
|
|
to check if the time spent waiting is zero and if so, the value 1 is |
|
|
returned. |
|
68 |
|
|
69 |
Notice that lwIP implements a function with a similar name, |
Notice that lwIP implements a function with a similar name, |
70 |
sys_sem_wait(), that uses the sys_arch_sem_wait() function. |
sys_sem_wait(), that uses the sys_arch_sem_wait() function. |
120 |
|
|
121 |
Starts a new thread with priority "prio" that will begin its execution in the |
Starts a new thread with priority "prio" that will begin its execution in the |
122 |
function "thread()". The "arg" argument will be passed as an argument to the |
function "thread()". The "arg" argument will be passed as an argument to the |
123 |
thread() function. The id of the new thread is returned. |
thread() function. The id of the new thread is returned. Both the id and |
124 |
|
the priority are system dependent. |
125 |
|
|
126 |
- sys_prot_t sys_arch_protect(void) |
- sys_prot_t sys_arch_protect(void) |
127 |
|
|