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.

TMS320F28377D: If write pin DAT is necessary when config CANTX to avoid a low pulse?

Part Number: TMS320F28377D

Tool/software:

I have 1+ machines which are hot-swappable and sharing the CAN bus.

When new machine plugs in and its MCU wake up, there was a very short low pulse occurred. It might affect the data which existing machines is transferring.

I try to fix it by writing pin DAT before config the CANTX pin as below:

Before:

GPIO_SetupPinOptions(MONITOR_CAN_GPIO_TX, GPIO_OUTPUT, GPIO_PUSHPULL);
GPIO_SetupPinMux(MONITOR_CAN_GPIO_TX, GPIO_MUX_CPU1, 3);

After:

GPIO_WritePin(MONITOR_CAN_GPIO_TX, true);
GPIO_SetupPinOptions(MONITOR_CAN_GPIO_TX, GPIO_OUTPUT, GPIO_PUSHPULL);
GPIO_SetupPinMux(MONITOR_CAN_GPIO_TX, GPIO_MUX_CPU1, 3);

Question:

  • Is the right way to fix the low pulse?
  • Is there a sequence shall be followed among WritePin, SetDirecetion, and SetMux?
  • Here are some typo:

    Before:

    GPIO_SetupPinOptions(MONITOR_CAN_GPIO_TX, GPIO_OUTPUT, GPIO_PUSHPULL);
    GPIO_SetupPinMux(MONITOR_CAN_GPIO_TX, GPIO_MUX_CPU1, 3);
    GPIO_WritePin(MONITOR_CAN_GPIO_TX, true);   --> I was missing in the question.

    After:

    GPIO_WritePin(MONITOR_CAN_GPIO_TX, true);
    GPIO_SetupPinOptions(MONITOR_CAN_GPIO_TX, GPIO_OUTPUT, GPIO_PUSHPULL);
    GPIO_SetupPinMux(MONITOR_CAN_GPIO_TX, GPIO_MUX_CPU1, 3);

    Question:

    • Is the right way to fix the low pulse?
    • Is there a sequence shall be followed among WritePin, SetDirecetion, and SetMux?
    • Is write DAT as high is necessary for CANTX?
  • HI Harley,

    From your snapshot, the pulse on RX line is still there. 

    Does the new machine issues software reset (set INIT bit, then set SWR bit) after the MCU wakes up? The SWR will generate a pulse on CAN TX line.