Multi-task RTOS usage

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Multi-task RTOS usage


      I've putting a system together which has a number of RTOS (FreeRTOS 9.0.1) tasks running, a single task is dedicated to the GUI which calls GUI_Delay() every 20ms. This task also creates all windows at system startup time and switches to different windows based on user touch input. Now I've got another RTOS task which is processing some data from an external source (ADC), I need to update a table with some data in this task, i.e.

      Task 1 - Creates a pile of widgets (specifically a listview), runs GUI_Delay() every 20ms.
      Task 2 - Deals with data from an external source (ADC) every second or so.

      I would like to be able to add data to the listview (created in task 1) from task 2. Howver it seems the UI is not being updated, if I run a test and add data to the listview from task 1 (i.e. the same task that created the widget) it works OK. Is there a restriction where widgets can only be updated from the task they are created in? I'm hoping this is not the case otherwise I'll need to queue events myself back to task 1.

      I've implemented all the usual RTOS routines in GUI_X_OS.c and the version of emWin definitely has been compiled with OS support.


      N.B. This is STemWin v 5.4.0 - we are planning on moving to emWin asap.
    • can you brief on how you solve the problem.
      i have similar function to update the adc value in an edit window.
      all goes well for few 10 seconds and then after my program hangs but, i see the adc value is continuing to updated in debugger view.