# portable.h:140:Error: syntax error

**URL:** <https://forums.freertos.org/t/portable-herror-syntax-error/333>\
**Category:** Kernel\
**Created:** [March 17, 2006, 12:50am UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333 "2006-03-17T00:50:05Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 12:50am UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/1 "2006-03-17T00:50:05Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7):

Hi, I’ve downloaded FreeRTOS and I am trying to compile the rtosdemo1 example using the MPLAB v 6.30 IDE. I get this error "portable.h:140:Error: syntax error " - any ideas ? I am using the student version of Microchip C18 Compiler.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 7:13am UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/2 "2006-03-17T07:13:30Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7/8144):

This line is the first place that portSTACK\_TYPE is used so it is almost definite that your problem is that MPLAB\_PIC18F\_PORT is not defined in your project.&nbsp; Have you changed the project setting at all since downloading?

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 11:24am UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/3 "2006-03-17T11:24:51Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7/f82f):

Thanks for the reply, can you point me in the direction to where this should be defined ? It is possible that I may have inadvertantly changed something in the project as I had to edit the path location externally.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 11:56am UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/4 "2006-03-17T11:56:44Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7/73e4):

Hi,  
I defined the portSTACK\_TYPE in the C18 macro definitioin area of the project build options and this seems to have sorted the original problem…however I now get some warnings about some locations being redundant in the interrupt save of the serial.c ?. I also have 1 error which is :-  
Error - could not find definition of symbol ‘vStartPolledQueueTasks’ in file …FreeRTOS\Demo\PIC18\_MPLAB\main1.o’.  
any ideas&nbsp; ?

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 3:53pm UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/5 "2006-03-17T15:53:08Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7/f82f/7b69):

Right click on the project in the and select "build options" (or access build options through the menu).

In the pop up window select the MPLAB C18 tab.&nbsp;&nbsp; Under macro definitions you should see MPLAB\_PIC18F\_PORT.&nbsp; If this is not defined the build will not be correct.&nbsp; This definition tells the file portable.h which port file to include.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [March 17, 2006, 4:51pm UTC](https://forums.freertos.org/t/portable-herror-syntax-error/333/6 "2006-03-17T16:51:11Z")

</div>

**nobody** wrote on [Friday, March 17, 2006](https://sourceforge.net/p/freertos/discussion/382005/thread/0b717f63/#77c7/6ebe):

Hi, I had tried this as suggested ( see reply above 3:56 ) - I dont’t know why the later post got in ahead of the one 3:24, it solved the original problem but as has thrown up some other issues as I have outlined above - anay ideas ?, thanks in advance.
