NXP SBC Fs23 CAN transceiver debugging, MCU CAN remains in a busy state

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

NXP SBC Fs23 CAN transceiver debugging, MCU CAN remains in a busy state

1,199 Views
txp_camel
Contributor I

Using s32k312 chip to control sbc fs23.

I want to use the built-in CAN transceiver in NXP's SBC FS23 to send CAN messages. Use SPI communication to initialize the registers of fs23, and then set the registers related to the CAN transceiver.

txp_camel_0-1715061042536.pngThe value of this register is 0x3f08(can enable)

txp_camel_1-1715061186244.pngThe value of this register is 0x02a0(

CAN Transceiver active mode)

txp_camel_2-1715061294167.pngThe value of this register is 0x308f(Strangely, SBC is in both normal and init states)

txp_camel_3-1715061430404.pngThe value of this register is 0x061f(Can state machine in normal mode)

For debugging convenience, I connected the debug pin of sbc fs23 to a voltage of 3.8V.

M_SYS1_CFG reg is 0x8(sbc in debug mode)

Above is my register settings,But when sending can messages, can remains in a busy state.

The following is the code for sending CAN messages.

    status = FlexCAN_Ip_GetTransferStatus(INST_FLEXCAN_1, TX_MAILBOX_ID);
    if(FLEXCAN_STATUS_SUCCESS == status)
    {
            FlexCAN_Ip_Send(INST_FLEXCAN_1, TX_MAILBOX_ID, &tTXCANMsgConfig, txMsg.msgId, txMsg.data);
        }
    }

 

 

 

 

 

)

 

 

0 Kudos
Reply
3 Replies

688 Views
vinaychitturi
Contributor III

@txp_camel @TomasVaverka 

Hello,

I am facing the same issue on my board. I am also using s32k312 board,fs23 chip. CAN ports and SPI ports are same like as you guys mentioned above.

I am seeing same register values for all the registers you mentioned.in the above email. 

I contacted one nxp support, They suggested to add the pullup resistor for the reset pin after that hardware change SBC is in normal mode. But the SBC CAN communication is still not working.

If you find the solution for this issue, Please let me know i will try those changes from my end too.

Thanks in advance

Regards,

Vinay Chitturi.

0 Kudos
Reply

1,150 Views
TomasVaverka
NXP TechSupport
NXP TechSupport

Hi,

When the FS23 is in Debug mode, the CAN transceiver is set to Active mode by default, there is no need to set CAN_MODE = 0b1x.

Are you using an NXP EVB or your own board? Could you please share your schematic to double check your HW setup?

If you have a logic analyzer or an oscilloscope, could you share a snapshot with the following signals captured:

- CANTXD, CANRXD, CANH and CANL?

BR, Tomas

0 Kudos
Reply

1,145 Views
txp_camel
Contributor I

Thank you for your reply.

I am using my own board.

S32k312 uses spi2 to connect to fs23, while s32k312 uses can1 to connect to fs23.

The following is a schematic diagram of connecting pins.

txp_camel_0-1715134480868.png

Here are the collected signals of CANH and CANL
Ch0 connects to CANL, ch1 connects to CANH.

txp_camel_1-1715134621728.png

 

 

0 Kudos
Reply