Hi,

I have defined sys_msleep() to vTaskDelay() - (1 tick == 1 ms) in
sys_arch.h, because the default implementation is quite tricky.
However the compiler complains about vTaskDelay() redefinition thus I
had to modify sys.c, see below. Is this modification correct?

As I know, sys_msleep is called only from pppInputThread(void *arg)
and there is not need to do define it but ...

Thank you for your answers

Martin
---------------------------------------------------------
#ifndef sys_msleep
void
sys_msleep(u32_t ms)
{
  if (ms > 0) {
    sys_sem_t delaysem;
    err_t err = sys_sem_new(&delaysem, 0);
    if (err == ERR_OK) {
      sys_arch_sem_wait(&delaysem, ms);
      sys_sem_free(&delaysem);
    }
  }
}
#endif

_______________________________________________
lwip-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to