emWin with KeilOS

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

  • emWin with KeilOS

    Hi,

    I am running the emWin in a Multitasking system and it is working well. But there is one Problem. In the User Manual is a discription of GUI_X_WAIT_EVENT and GUI_X_SIGNAL_EVENT. I defined the Macros with the folloing code:

    static OS_TID os_evt_id;

    void GUI_X_WaitEvent(void)
    {
    os_evt_id = os_tsk_self();
    os_evt_wait_or(1,0xFFF0);
    }
    void GUI_X_SignalEvent(void)
    {
    if (os_evt_id)
    {
    os_evt_set(1, os_evt_id);
    }
    }


    While the SignalEven funktion ist called automatic within the emWin, the wait funktion isn't.
    Should I call the wait funktion by my self? I don't realy understand the use of the Macros.
  • Hi,

    per default these functions are not used. As you can see in the documentation in chapter '13.5 GUI configuration macros for multitasking support' the default behaviour is using the function GUI_X_ExecIdle(). You have to add the following lines to GUIConf.h:

    #define GUI_X_WAIT_EVENT() GUI_X_WaitEvent()
    #define GUI_X_SIGNAL_EVENT() GUI_X_SignalEvent()

    After this the functions should be used.

    Regards,

    F.Berkel