Multican

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
UNknown_12
Level 1
Level 1
10 sign-ins 5 sign-ins First reply posted

Hi Guys,

In TC297, by default Can Receive interrupt is service in CPU0 ,  How to change that into CPU1. If any example code is there ,

Please share me

0 Likes
1 Solution
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

 

void IfxMultican_Can_initModuleConfig(IfxMultican_Can_Config *config, Ifx_CAN *mcan)
{
    IfxMultican_SrcId srcId;
    /** - take over module pointer */
    config->module = mcan;

    /** - Selected input clock is from CLC */
    config->clockSelect = IfxMultican_ClockSelect_fclc;

    /** - Module frequency is fSPB */
    config->moduleFreq = IfxScuCcu_getSpbFrequency();
    uint16 numSrcs = (mcan == &MODULE_CANR) ? IFXMULTICAN_R_NUM_SRC : IFXMULTICAN_NUM_SRC;

    for (srcId = IfxMultican_SrcId_0; srcId < numSrcs; srcId++)
    {
        config->nodePointer[srcId].priority      = 0;
        config->nodePointer[srcId].typeOfService = IfxSrc_Tos_cpu0;
    }
}

 

 

 

 

 

Dear Users,

In MULTICAN_1_KIT_TC297_TFT demo code, you could searched IfxSrc_Tos_cpu0 and changed to others, the ISR is accordingly need to be changed.

https://github.com/Infineon/AURIX_code_examples/tree/master/code_examples/MULTICAN_1_KIT_TC297_TFT

 

View solution in original post

0 Likes
1 Reply
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

 

void IfxMultican_Can_initModuleConfig(IfxMultican_Can_Config *config, Ifx_CAN *mcan)
{
    IfxMultican_SrcId srcId;
    /** - take over module pointer */
    config->module = mcan;

    /** - Selected input clock is from CLC */
    config->clockSelect = IfxMultican_ClockSelect_fclc;

    /** - Module frequency is fSPB */
    config->moduleFreq = IfxScuCcu_getSpbFrequency();
    uint16 numSrcs = (mcan == &MODULE_CANR) ? IFXMULTICAN_R_NUM_SRC : IFXMULTICAN_NUM_SRC;

    for (srcId = IfxMultican_SrcId_0; srcId < numSrcs; srcId++)
    {
        config->nodePointer[srcId].priority      = 0;
        config->nodePointer[srcId].typeOfService = IfxSrc_Tos_cpu0;
    }
}

 

 

 

 

 

Dear Users,

In MULTICAN_1_KIT_TC297_TFT demo code, you could searched IfxSrc_Tos_cpu0 and changed to others, the ISR is accordingly need to be changed.

https://github.com/Infineon/AURIX_code_examples/tree/master/code_examples/MULTICAN_1_KIT_TC297_TFT

 

0 Likes