Help me to make this link error “vApplicationStackOverflowHook

Hi, I am a beginner in freertos. Please Help me When I compile this small below program it has compiled but it is not make.i am getting Link Error. Link Error: Undefined: “vApplicationStackOverflowHook” Referenced from “vTaskSwitchContext” in. (and i am using Coldfire MCF52259 Microcontroller)

include “FreeRTOS.h”

include “task.h”

include “queue.h”

include “timers.h”

void mytask(void *pvParameters) { while(1) { MCF_GPIO_DDRTC=0x0F; MCF_GPIO_SETTC=0x0F; vTaskDelay( 500 / portTICK_RATE_MS); MCF_GPIO_CLRTC=0x0F; } } int main(void) {
xTaskCreate(mytask,(signed char*) "mytask", configMINIMAL_STACK_SIZE, NULL, 1, NULL);
return 0;
}
This is FreeRTOSConfig.h file which i have used for this above program

ifndef FREERTOSCONFIGH

define FREERTOSCONFIGH

/* Library includes. */

include “common.h”

/———————————————————– * Application specific definitions. * * These definitions should be adjusted for your particular hardware and * application requirements. * * THESE PARAMETERS ARE DESCRIBED WITHIN THE ‘CONFIGURATION’ SECTION OF THE * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE. * * See http://www.freertos.org/a00110.html. *———————————————————-/

define configUSE_PREEMPTION 1

define configUSEIDLEHOOK 0

define configUSETICKHOOK 0

define configCPUCLOCKHZ ( ( unsigned long ) 80000000 )

define configTICKRATEHZ ( ( portTickType ) 100 )

define configMINIMALSTACKSIZE ( ( unsigned short ) 160 )

define configTOTALHEAPSIZE ( ( size_t ) (30* 1024 ) )

define configMAXTASKNAME_LEN ( 12 )

define configUSETRACEFACILITY 1

define configUSE16BIT_TICKS 0

define configIDLESHOULDYIELD 0

define configUSECOROUTINES 0

define configUSE_MUTEXES 1

define configCHECKFORSTACK_OVERFLOW 2

define configUSERECURSIVEMUTEXES 1

define configQUEUEREGISTRYSIZE 0

define configUSECOUNTINGSEMAPHORES 0

define configUSEMALLOCFAILED_HOOK 0

define configMAXPRIORITIES ( ( unsigned portBASETYPE ) 6 )

define configMAXCOROUTINE_PRIORITIES ( 2 )

/* Set the following definitions to 1 to include the API function, or zero to exclude the API function. */

define INCLUDE_vTaskPrioritySet 1

define INCLUDE_uxTaskPriorityGet 1

define INCLUDE_vTaskDelete 1

define INCLUDE_vTaskCleanUpResources 0

define INCLUDE_vTaskSuspend 1

define INCLUDE_vTaskDelayUntil 1

define INCLUDE_vTaskDelay 1

define INCLUDE_uxTaskGetStackHighWaterMark 1

define configYIELDINTERRUPTVECTOR 16UL

define configKERNELINTERRUPTPRIORITY 1

define configMAXSYSCALLINTERRUPT_PRIORITY 4

/* This demo makes use of one or more example stats formatting functions. These format the raw data provided by the uxTaskGetSystemState() function in to human readable ASCII form. See the notes in the implementation of vTaskList() within FreeRTOS/Source/tasks.c for limitations. */

define configUSESTATSFORMATTING_FUNCTIONS 1

void vApplicationSetupInterrupts( void ); /* Ethernet configuration. */

define configMAC_0 0x00

define configMAC_1 0x04

define configMAC_2 0x9F

define configMAC_3 0x00

define configMAC_4 0xAB

define configMAC_5 0x2B

define configIP_ADDR0 192

define configIP_ADDR1 168

define configIP_ADDR2 0

define configIP_ADDR3 11

define configGW_ADDR0 172

define configGW_ADDR1 25

define configGW_ADDR2 218

define configGW_ADDR3 3

define configNET_MASK0 255

define configNET_MASK1 255

define configNET_MASK2 255

define configNET_MASK3 0

define configNUMFECTX_BUFFERS 2

define configNUMFECRX_BUFFERS 4

define configFECBUFFERSIZE 1520

define configUSEPROMISCUOUSMODE 0

define configETHERNETINPUTTASKSTACKSIZE ( 320 )

define configETHERNETINPUTTASKPRIORITY ( configMAXPRIORITIES – 1 )

define configPHY_ADDRESS 1

if ( configFECBUFFERSIZE & 0x0F ) != 0

#error configFEC_BUFFER_SIZE must be a multiple of 16.

endif

endif /* FREERTOSCONFIGH */

Help me to make this link error “vApplicationStackOverflowHook

Hello, it is because you have asked to check for stack overflow in your FreeRTOSConfig.h: configCHECKFORSTACK_OVERFLOW Set it to 0 if you want Stack overflow disabled. Altough I recommend to have it enabled. Simply add something like this to your application: void FRTOS1vApplicationStackOverflowHook(xTaskHandle pxTask, signed portCHAR *pcTaskName) { /* This will get called if a stack overflow is detected during the context switch. Set configCHECKFORSTACKOVERFLOWS to 2 to also check for stack problems within nested interrupts, but only do this for debug purposes as it will increase the context switch time. / (void)pxTask; (void)pcTaskName; taskDISABLE_INTERRUPTS(); / Write your code here … */ for(;;) {} } If you are using ColdFire V2 (MCF52259) with CodeWarrior, then you might have a look at my Processor Expert component for FreeRTOS: it supports many cores, including ColdFire: Tutorial: FreeRTOS on DEMOJM http://mcuoneclipse.com/tag/freertos/ I hope this helps.