Hi,
When i added a "flexcan" component to free rtos, i noticed that configurations "PIT channel -------default " is not present. PF image below.
Whereas for project without freertos PF below image.
Can any one tell me what modifications should i do to tx/rx data on can as an freertos task? I have attached my project. PFA.
Thanks
Krishnaja.
Hi @PetrS ,
I referred mpc5746c example. I had created mpc5748g project and just modified the code in the task alone.
I had checked the code using breakpoints, I found that it is not going inside the task.(Toggle pin is not happening).
static void prvTransmitTask( void *pvParameters ){
TickType_t xNextWakeTime;
/* Cast to void because parameter isn't used */
(void)pvParameters;
PINS_DRV_TogglePins(PTA,(1<<0));
// xNextWakeTime = xTaskGetTickCount();
for ( ;; )
{
uint8_t ledRequested;
ledRequested = LED1_CHANGE_REQUESTED;
SendCANData(TX_MAILBOX, TX_MSG_ID, &ledRequested, 1UL);
PINS_DRV_WritePin(PTA,7,1);
vTaskDelayUntil( &xNextWakeTime, mainTRANSMIT_FREQUENCY_MS );
}
}
Please tell me why it is not going into "prvTransmitTask".
PFA
Krishnaja.
Hi,
try to have same preprocessor setting as it is in the demo example
BR, Petr
I checked preprocessor setting. Still I have same problem.
Please tell me what I have missed.
Hi,
please refer to example I posted at https://community.nxp.com/t5/MPC5xxx-Knowledge-Base/Example-MPC5748G-FlexCAN-TX-RX-FreeRTOS-S32DS2-1...
Hope it helps.
BR, Petr
Hi @PetrS
Any updates??
Hi,
please refer to flexcan_mpc5746c example which shows FlexCAN and FreeRTOS usage.
BR, Petr