Results 1 to 2 of 2

Thread: uC/OS-II Stack Size always at maximum defined

  1. #1
    Join Date
    Nov 2009
    Posts
    103
    Rep Power
    1

    Exclamation uC/OS-II Stack Size always at maximum defined

    Hi,

    I need help in understanding what could be the cause of the phenomena I see.
    I have a webserver application (started from the altera example) to which I added a couple of other threads
    - Database - a thread polling a large number of periphery components (i2c, Avalon-MM) and updates the latest value in a global array
    - Http - accepts connections, fetches files from ZipFS, parses them and replaces certain strings with the values from the large array
    - watchdog, etc...
    - terminal --> I have also implemented a stack checking command.

    Scenario:
    1. application up, no link -> Http not started; DATABASE uses ~4KB of stack
    2. http started, 1st request -> Database uses maximum defined.


    Interesting, if I allocate 64KB or 4MB (which it uses completely), the application is stable in both cases, no difference.
    The whole application uses ~ 1MB, so the I can't explain how it reaches those numbers...

    My questions:
    1. What could be the reason the OSStatChk is reporting me these numbers?
    2. From my observation, this numbers returned by OSStatChk are the maximum ever used since startup. Is there a way to reset these counters?

    Code:
    *********************************************************
    *** OS_TASK ***         used [B]        free [B] 
    *********************************************************
    HTTP_TASK               28356           37180
    TERMINAL_TASK           3776            4416
    DATABASE_TASK           262144          0
    PHYMON_TASK             3968            4224
    WATCHDOG_TASK           3812            4380
    TELNET_TASK             5996            10388
    Last edited by dipling; February 14th, 2014 at 07:02 AM.

  2. #2
    Join Date
    Aug 2004
    Location
    Texas Y'all
    Posts
    2,329
    Rep Power
    1

    Default Re: uC/OS-II Stack Size always at maximum defined

    Moving to the new "Other Operating Systems" forum. This is where all non-Linux OS related questions will go moving forward.

Similar Threads

  1. Maximum memory size
    By yafpga in forum General Altera Discussion
    Replies: 3
    Last Post: September 5th, 2012, 09:41 PM
  2. Maximum RAM Size
    By srfilipek in forum Linux Forum
    Replies: 0
    Last Post: August 3rd, 2011, 04:36 AM
  3. Nios2 stack size?
    By FredFlintstone in forum General Software Forum
    Replies: 5
    Last Post: June 28th, 2011, 02:50 AM
  4. How to validate ram and stack size
    By larsen in forum General Software Forum
    Replies: 1
    Last Post: February 27th, 2005, 07:52 PM
  5. How to validate ram and stack size
    By larsen in forum General Software Forum
    Replies: 0
    Last Post: February 27th, 2005, 07:43 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •