Task definitin ERROR!!!

Forum related to ERIKA Enterprise and RT-Druid version 2

Moderator: paolo.gai

Post Reply
findfrienda
Newbie
Posts: 28
Joined: Mon Dec 03, 2012 3:01 am

Task definitin ERROR!!!

Post by findfrienda » Sun Dec 09, 2012 2:05 pm

Hi, dear all,
I fond an error,while I try to compile the source code. The error is :
./src/code.c:79: error: [11703] syntax error before numeric constant

The source code is as follows:

Code: Select all

....
TASK(Task1)
{
    EE_hal_disableIRQ();
    for (int i = 0; i < 8; i++) {
        delay(100);
        led_off(i);
    }
    num = 0;
    EE_hal_enableIRQ();
}
...

int main() 
{
    led_init();

    /* Implement Alarms with either cmp0 or cmp1 */
    //EE_tc179x_stm_cmp0_init(STM_VECTOR, STM_TIM0.reg + 10000);

    ActivateTask(Task1);

    while(1);

    return 0;
}
So, I wan to know how to define a task in ERIKA? By the way, the codes above is the source code.

Can someone give me some instructions?

Thanks!

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: Task definitin ERROR!!!

Post by paolo.gai » Sun Dec 09, 2012 6:10 pm

Did you define the task in the OIL file?

Please start from an example which works. There are plenty with the distribution of the kernel.

PJ

findfrienda
Newbie
Posts: 28
Joined: Mon Dec 03, 2012 3:01 am

Re: Task definitin ERROR!!!

Post by findfrienda » Mon Dec 10, 2012 4:27 am

Dear Paolo,
I didn't define the task by the OIL file, now, I didn't master the OIL usage. Next, I will try it.

By the way, it seems that Erika's project setting is based on Linux, however, now I used the HighTec's toolchain on Windows. So, it's not easy to configure the environment.

I try!

Thanks!

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: Task definitin ERROR!!!

Post by paolo.gai » Mon Dec 10, 2012 9:08 am

The compilers which are supported are listed in the Wiki pages for each architecture!

PJ

findfrienda
Newbie
Posts: 28
Joined: Mon Dec 03, 2012 3:01 am

Re: Task definitin ERROR!!!

Post by findfrienda » Tue Dec 11, 2012 10:54 am

Hi,Dear paolo,

Now, I met a problem when I compile the project:
This is the makefile content:

Code: Select all

    ....
   include $(EEBASE)/pkg/cfg/rules.mk 
    ...
Console output is :

Code: Select all

     cygpath: cannot create short name of `cygpath
     makefile:103: /pkg/cfg/rules.mk: No such file or directory
     C:\TriCoreTools\HIGHTEC\TRICORE\bin\make.exe: *** No rule to make target `/pkg/cfg/rules.mk'.  Stop.
Can you find info from the Console Output?
If so, where is the wrong?

Wy there is no rules.mk(/pkg/cfg/rules.mk)? Does it come from the CodeBase or generation from my project?
I was amused!!! :-[

Thanks!

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: Task definitin ERROR!!!

Post by paolo.gai » Tue Dec 11, 2012 11:32 am

I guess EEBASE is not defined in your environment. Please check that. Either it is in the makefile, or you should define it from the command shell.

PJ

nicola.serreli
Jr. Member
Posts: 68
Joined: Mon Aug 02, 2010 10:11 am

Re: Task definitin ERROR!!!

Post by nicola.serreli » Tue Dec 11, 2012 11:39 am

Please, note that EEBASE is intended to be used only inside erika makefiles, while ERIKA_FILES is the variable to set in the environment. (of course, this is true if you are using RT-Druid configuration with standard makefiles).

See more information at Regards,
Nicola

Post Reply