Jump to content

FreeRTOS port


Recommended Posts

  • 2 months later...

I am currently running uGFX (git download from 2014/07/31) with FreeRTOS (v7.3.0) on an Altera NiosII target platform (gcc v4.5.3) with a framebuffer display driver.

My problems were:

  • freertos.h files in src\gos\gos module conflicted the original FreeRTOS.h file. I renamed them to freertos_gfx.h/c
  • Missing type definitions in freertos_gfx.h such as, int8_t, uint8_t, etc. This might work on other platforms without modifications?
  • freertos_gfx.c: renamed portTICK_PERIOD_MS to portTICK_RATE_MS. Again, this might be a platform/port/version issue.

Link to comment
Share on other sites

Thank you very much for your feedback.

We are aware of the conflicting file names on a case insensitive operating system since a short while. The changes have been made but not yet tested and pushed. We will push a fix to the repository this evening (GTM+01:00).

About the definitions: Which FreeRTOS version are you using? We have tested with FreeRTOS 8.x without any problems so far. Neither did any user report a conflict there.

~ Tectu

Link to comment
Share on other sites

Yes there is (defined in task.h)

Before FreeRTOS 8.x.x

#define tskKERNEL_VERSION_NUMBER "V7.3.0"

From FreeRTOS 8.x.x on


#define tskKERNEL_VERSION_NUMBER "V8.0.1"
#define tskKERNEL_VERSION_MAJOR 8
#define tskKERNEL_VERSION_MINOR 0
#define tskKERNEL_VERSION_BUILD 1

Link to comment
Share on other sites

Too bad that they don't have separate macros for each individual digit before 8.x.

I don't know FreeRTOS that well, what do you think about this?


#if tskKERNEL_VERSION_MAJOR == 8
/* Types for 8.x */
#else
/* Types for 7.x (and lower?) */

I assume taht this should work as the tskKERNEL_VERSION_MAJOR macro should not be implemented at all at any < 8.x release.

~ Tectu

Link to comment
Share on other sites

Too bad that they don't have separate macros for each individual digit before 8.x.


#if tskKERNEL_VERSION_MAJOR == 8
/* Types for 8.x */
#else
/* Types for 7.x (and lower?) */

I assume taht this should work as the tskKERNEL_VERSION_MAJOR macro should not be implemented at all at any < 8.x release.

~ Tectu

Are undefined preprocessor symbols handled consistently across compilers?

Defensive coding might suggest:


#ifdef tskKERNEL_VERSION_MAJOR
#if tskKERNEL_VERSION_MAJOR == 8
/* Types for 8.x */
#else
/* Types for 7.x (and lower?) */
#endif
#else
/* Types for 7.x (and lower?) */
#endif

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...