More help on FreeRTOS?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

More help on FreeRTOS?

985 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by jaybee on Fri Mar 09 00:30:15 MST 2012
Hi guys,

I am a newbie hobbyist trying out the freeRTOS examples. I bought the freertos lpc17xx book and reference but however cannot test from of the programs written in it. I copied the task listing exactly, but when i compile, some examples always had errors, such as undeclared variables, etc. Where can i find the complete set of the codes as listed in the freeRTOS user manual?

I have no experience in rtos and minimum experience with mcus
0 项奖励
回复
6 回复数

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by jaybee on Sat Mar 10 14:13:57 MST 2012
oic, thanks mdkendall for the link.

Haha I was so used to getting spoonfed by dummy tutorial books that assumed the listed codes to work. I am at page 110+ semaphores, hoping to finish the basic tutorial this weekend its a really good read. :)
0 项奖励
回复

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Rob65 on Fri Mar 09 17:42:08 MST 2012
what specific examples did you try.
I also bought the FreeRTOS book(s), if you provide some info as to which example (page/chapter number) and preferrably post your project somewhere (use the export projects wizard and place your .zip file somewhere) then we could give you some more detailed input.

There are just too many places were things could be wrong: wrong parameter settings in FreeRTOSconfig.h, forgetting to recompile the FreeRTOS library or just forgetting the variable declarations that were left out of the listings from the code in the manual.

you should be able to run the code from the link provided by mdkendall but then, this does not learn you what you did wrong in your project.

The FreeRTOS project wizard looks nice to start from but what I did not like is that the FreeRTOS source is now part of your main project. The other (older) examples that NXP provided contained a structure where the FreeRTOSconfig.h was inside the project resulting the executable program with the FreeRTOS code being in another project - this placed a strange dependency from the FreeRTOS project onto the executable (which is a very strange dependency).
Both things are 'fixed'  in the official examples that mdkendall points to.

Regards,
[INDENT]Rob
[/INDENT]
0 项奖励
回复

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mdkendall on Fri Mar 09 13:13:53 MST 2012
The listings in the manual are typically abbreviated to best illustrate the topic being discussed. They do not necessarily include all the details necessary to actually compile. Full code for the examples (that will compile) can be downloaded from:

http://www.freertos.org/Documentation/code/source-code-for-LPC17xx-edition-examples.zip
0 项奖励
回复

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by stalisman on Fri Mar 09 02:30:06 MST 2012
There is a file called FreeRTOSConfig.h that nust be modified correctly if you want to use semaphores/mutexes.

If the line is as follows:

[B][SIZE=2][COLOR=#7f0055][SIZE=2][COLOR=#7f0055]#define[/B][/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] configUSE_MUTEXES 0[/SIZE]
[SIZE=2][/SIZE]
[SIZE=2]then you wont have access to semaphores.[/SIZE]
[SIZE=2][/SIZE]
[SIZE=2]if it is   [/SIZE]
[SIZE=2][B][SIZE=2][COLOR=#7f0055][SIZE=2][COLOR=#7f0055]
#define[/B][/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] configUSE_MUTEXES 1[/SIZE]

then you should.

It is worth studying this file.[/SIZE][SIZE=2]
[/SIZE]
0 项奖励
回复

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by jaybee on Fri Mar 09 01:05:51 MST 2012
Oh yes, I tried the RTOSdemo-1768, since i have a rdb1768 board. It worked great. I want to create something like this from just the 'freeRTOS' project selection in the lpcxpresso.

Right now, from the new project "freertos project" i am able to test some example from the lpc17xx user manual, but now i am stuck at the semaphores. I copied the source code provided in the manual but it seems some variables are not declared... The freertos example i downloaded was the lastest, 7.1 which version should i download to follow the manual?
0 项奖励
回复

962 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Polux rsv on Fri Mar 09 00:54:18 MST 2012
Have you succeed testing a simple Blinky or Hello world on your target ?

Freertos files could be downloaded from the.....Freertos website :D http://www.freertos.org/  there are two examples for LPC1768 for GCC and Redsuite.

And latest LPCXpresso suite have a wizard to create a project for Freertos. You only need to include the downloaded files.

Angelo
0 项奖励
回复