This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

F28M35 CAN API bug

Other Parts Discussed in Thread: CONTROLSUITE

Hi

There is a bug in F28M35 internal CAN API function: "CANIntNumberGet" (Driver Library from  TI's controlSUITE).
"break" instruction is missing in the "CAN1_BASE" case.
The result of this function "CANIntNumberGet" always returns the default value (-1) for CAN1 interrupts.
It would be nice if the bug has been fixed in "driverlib" library.

Best regards,

  • Dmitry,

    I just checked our internal sources and it looks like this has been fixed.  Which version of the device support package for this device are you using?

    BR,

  • Trey German said:

     Which version of the device support package for this device are you using?

    The version of controlSUITE is 3.2.4. 

    And I just looked through the following source file
    ..\controlSUITE\device_support\f28m35x\v140\MWare\driverlib\can.c
    ..\controlSUITE\device_support\f28m35x\v201\MWare\driverlib\can.c
    and both of them have described above bug.

    For clarity, here is a piece of source code (function "CANIntNumberGet").

        // Return the interrupt number for CAN 1
        case CAN1_BASE:
        {
            switch(ucNumber)
            {
            case 0:
            {
                lIntNumber = INT_CAN1INT0;
                break;
            }
            case 1:
            {
                lIntNumber = INT_CAN1INT1;
                break;
    
            }
            default:
            {
                lIntNumber = -1;
                break;
            }
            }
    	break; //  <- this instruction is missing in original source 
        }

  • Ahhh...You're right.  The nested switch statement was throwing me off.  I'll file a bug and get this fixed.

    Thanks for reporting this!