ReactOS  0.4.15-dev-488-gc7a1924
sys.c File Reference
#include "lwip/opt.h"
#include "lwip/sys.h"
Include dependency graph for sys.c:

Go to the source code of this file.

Functions

void sys_msleep (u32_t ms)
 

Detailed Description

lwIP Operating System abstraction

Definition in file sys.c.

Function Documentation

◆ sys_msleep()

void sys_msleep ( u32_t  ms)

Sleep for some ms. Timeouts are NOT processed while sleeping.

Parameters
msnumber of milliseconds to sleep

Definition at line 55 of file sys.c.

56 {
57  if (ms > 0) {
58  sys_sem_t delaysem;
59  err_t err = sys_sem_new(&delaysem, 0);
60  if (err == ERR_OK) {
61  sys_arch_sem_wait(&delaysem, ms);
62  sys_sem_free(&delaysem);
63  }
64  }
65 }
void sys_sem_free(sys_sem_t *sem)
Definition: sys_arch.c:77
err_t sys_sem_new(sys_sem_t *sem, u8_t count)
Definition: sys_arch.c:51
s8_t err_t
Definition: err.h:47
#define ERR_OK
Definition: err.h:52
#define err(...)
u32_t sys_arch_sem_wait(sys_sem_t *sem, u32_t timeout)
Definition: sys_arch.c:91