FreeRTOS port for MPLAB/PIC18F452

joconnor37 wrote on Wednesday, January 02, 2008:

I have FreeRTOS demo project building successfully for 18F452 in MPLAB, programming successfully into an 18F452 development board from Forest Electronics Development(FED), but getting “little action” on the board. The FreeRTOS demo project should flash LEDs on PORTD but doesn’t. In starting to dig deeper into the code, something immediately confuses me - partest.h defines:-

#define partstDEFAULT_PORT_ADDRESS ( ( unsigned portSHORT ) 0x378 )   - I presume this is

PORTD, PORTD<7:4> drive the 4 LEDs on the FED development board. But the Microchip datasheets
give the address of PORTD as F83h. I cannot complete the reference chain between the #define statement above, and actual PORTD - so maybe the demo project is not asking PORTD to do anything at present…?

Has anyone else worked with this particular port of FreeRTOS? Any advice gratefully accepted as I am probably missing something simple here.


John O’Connor

rtel wrote on Wednesday, January 02, 2008:

The name partest.c is a left over from the original “PARallel port TEST”, and the 0x378 is the default address used to access the parallel port on a PC compatible system.  I didn’t realise the definition was in the partest.h file, it should be moved to the FreeRTOS/Demo/PC/Partest/Partest.c file as this is the only file to which it is relevant, sorry for any confusion caused.  It will not be used in the PIC code.

Look at the file FreeRTOS/Demo/PIC18_MPLAB/Partest/partest.c to see how the LEDs are accessed on the FED hardware.

Its been quite I while since I fired up the FED board.  My first suggestion would be to double check that all the fuse settings are correct.


joconnor37 wrote on Wednesday, January 02, 2008:

Thanks Richard.