TJA1043TK Initialization in M4

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

TJA1043TK Initialization in M4

Jump to solution
719 Views
vinothkumars
Senior Contributor IV

Hi,

 

I am working on TJA1043TK CAN initialization. Currently don't have GPIO expander and CAN_EN and CAN_STBY connected directly to the processor.

 

vinothkumars_0-1624167366018.png

 

FCAN0_EN connected with GPT0_CAPTURE

FCAN_STB connected with GPT0_COMPARE.

I have to initialize the TJA1043TK . But, IRQ is not triggering to receive the message.

 

Please check my configuration and let me know what I am missing

 

pin_mux.h

/* GPT0_CAPTURE, FCAN0_EN */
#define BOARD_INITPINS_FCAN0_EN_GPIO LSIO__GPIO0 /*!< GPIO device name: LSIO__GPIO0 */
#define BOARD_INITPINS_FCAN0_EN_GPIO_PIN 15U /*!< LSIO__GPIO1 pin index: 15 */
#define BOARD_INITPINS_FCAN0_EN_PIN_NAME GPT0_CAPTURE /*!< Pin name */
#define BOARD_INITPINS_FCAN0_EN_PIN_FUNCTION_ID SC_P_GPT0_CAPTURE /*!< Pin function id */
#define BOARD_INITPINS_FCAN0_EN_LABEL "FCAN0_EN" /*!< Label */
#define BOARD_INITPINS_FCAN0_EN_NAME "FCAN0_EN" /*!< Identifier name */
#define BOARD_INITPINS_FCAN0_EN_DIRECTION kGPIO_DigitalOutput /*!< Direction */

/* GPT0_COMPARE, FCAN0_STB */
#define BOARD_INITPINS_FCAN0_STB_GPIO LSIO__GPIO0 /*!< GPIO device name: LSIO__GPIO0 */
#define BOARD_INITPINS_FCAN0_STB_GPIO_PIN 16U /*!< LSIO__GPIO1 pin index: 16 */
#define BOARD_INITPINS_FCAN0_STB_PIN_NAME GPT0_COMPARE /*!< Pin name */
#define BOARD_INITPINS_FCAN0_STB_PIN_FUNCTION_ID SC_P_GPT0_COMPARE /*!< Pin function id */
#define BOARD_INITPINS_FCAN0_STB_LABEL "FCAN0_STB" /*!< Label */
#define BOARD_INITPINS_FCAN0_STB_NAME "FCAN0_STB" /*!< Identifier name */
#define BOARD_INITPINS_FCAN0_STB_DIRECTION kGPIO_DigitalOutput /*!< Direction */



pin_mux.c

err = sc_pad_set_all(ipc, BOARD_INITPINS_FCAN0_EN_PIN_FUNCTION_ID, 3U, SC_PAD_CONFIG_OUT_IN, SC_PAD_ISO_OFF, 0x61 ,SC_PAD_WAKEUP_OFF);
if (SC_ERR_NONE != err)
{
assert(false);
}

err = sc_pad_set_all(ipc, BOARD_INITPINS_FCAN0_STB_PIN_FUNCTION_ID, 3U, SC_PAD_CONFIG_OUT_IN, SC_PAD_ISO_OFF, 0x61 ,SC_PAD_WAKEUP_OFF);
if (SC_ERR_NONE != err)
{
assert(false);
}

 

Regards,
Vinothkumar Sekar
0 Kudos
1 Solution
706 Views
vinothkumars
Senior Contributor IV

Software wise this is proper only. There is hardware problem. 

Regards,
Vinothkumar Sekar

View solution in original post

0 Kudos
1 Reply
707 Views
vinothkumars
Senior Contributor IV

Software wise this is proper only. There is hardware problem. 

Regards,
Vinothkumar Sekar
0 Kudos