lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] RE: lwip-users Digest, Vol 7, Issue 11


From: Eric Shufro
Subject: [lwip-users] RE: lwip-users Digest, Vol 7, Issue 11
Date: Wed, 17 Mar 2004 08:09:02 -0500

What is the deal with the uCOS port in sys_arch.c for this function?

struct sys_timeouts *
sys_arch_timeouts(void)
{
    INT8S currPrio;

    currPrio = (OSPrioCur-LWIP_START_PRIO);

    if((currPrio < 0) || (currPrio >= LWIP_MAX_TASKS))
    {
        /* Error! */
      printf("sys_arch_timeouts: Prio not found\n");
        while(1);

    }

    return &timeoutlist[currPrio];
}

OSPrioCur returns the priority of the currently running task. This function
gets called indirectly from TASK 4, a startup task. Since making a new
netconn, or setting up an interface requires some memory, the cascading of
function calls ends up here.

The only problem is that LWIP_START_PRIO is 7.

And I always get -3 and stuck in that loop?

What is the logic behind that if statement? Is it trying to determine if the
LWIP thread has run yet or is running currently?

Thanks for the help,

--Eric Shufro
(working with Motorola hcs12)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]