STM32H743VI FDCAN didn't works as classical CAN
Hello, I have some trouble with FDCAN.
Please let me know what is wrong with my settings.
1. Current problem
: My STM32H7 transmit only error.
(Logic Analyzer)
(PCAN View)
Same error signal repeat endless and if I connect PCAN, many other error and stuff error occur and can bus status become BUSHEAVY.
I check where does HAL_FDCAN_AddMessageToTxFifoQ() return HAL_ERROR.
First transmission, HAL_FDCAN_AddMessageToTxFifoQ() return HAL_OK(but in Logic analyzer and PCAN, it is just error) and in Second transmission, TXFQS is 0x00 20 00 00 and enter a if state under and return HAL_ERROR.

I think it is become there was no ACK from PCAN. Therefore Tx Que in STM32 will not reset.
Maybe PCAN can't give ACK to STM32 because STM32 didn't transmit hole CAN frame as you can see upper logic analyzer screenshot.
2. How I test CAN communication.

This is what I setup for debugging.
* I didn't attach 120 Ohm terminal resistor because length of CAN bus is short. (it is shorter than 50cm.)
3. Current setting.
3.1 Bit timming and HW settings

I am using 12MHz for CANbus from HSE(12MHz TCXO) and SN65HVD231Q-Q1 CAN transceiver.

I follow this settings. Under code is in main.c -> static void MX_FDCAN2_Init(void)
hfdcan2.Init.NominalPrescaler = 1;
hfdcan2.Init.NominalSyncJumpWidth = 3;
hfdcan2.Init.NominalTimeSeg1 = 20;
hfdcan2.Init.NominalTimeSeg2 = 3;
hfdcan2.Init.DataPrescaler = 1;
hfdcan2.Init.DataSyncJumpWidth = 3;
hfdcan2.Init.DataTimeSeg1 = 20;
hfdcan2.Init.DataTimeSeg2 = 3;
3.2 other settings (Under code is in main.c -> static void MX_FDCAN2_Init(void))
hfdcan2.Instance = FDCAN2;
hfdcan2.Init.FrameFormat = FDCAN_FRAME_CLASSIC;
hfdcan2.Init.Mode = FDCAN_MODE_NORMAL;
hfdcan2.Init.AutoRetransmission = ENABLE;
hfdcan2.Init.TransmitPause = DISABLE;
hfdcan2.Init.ProtocolException = DISABLE;
hfdcan2.Init.MessageRAMOffset = 0;
hfdcan2.Init.StdFiltersNbr = 1;
hfdcan2.Init.ExtFiltersNbr = 1;
hfdcan2.Init.RxFifo0ElmtsNbr = 1;
hfdcan2.Init.RxFifo0ElmtSize = FDCAN_DATA_BYTES_8;
hfdcan2.Init.RxFifo1ElmtsNbr = 0;
hfdcan2.Init.RxFifo1ElmtSize = FDCAN_DATA_BYTES_8;
hfdcan2.Init.RxBuffersNbr = 0;
hfdcan2.Init.RxBufferSize = FDCAN_DATA_BYTES_8;
hfdcan2.Init.TxEventsNbr = 0;
hfdcan2.Init.TxBuffersNbr = 0;
hfdcan2.Init.TxFifoQueueElmtsNbr = 1;
hfdcan2.Init.TxFifoQueueMode = FDCAN_TX_FIFO_OPERATION;
hfdcan2.Init.TxElmtSize = FDCAN_DATA_BYTES_8;
--------------------------------------------------------------------------------------------------------
I already check example on github and AN5348 document but I can't find why it didn't work. (actually, I don't know lot about memory system in STM32.)
I attach my main.c file and ioc file.
If you know how to use classic CAN. please help me.
Thank you!
