Hi.
How can i configure a xmc1400 as can gateway with DAVE4?
FIrst i try to use two CAN_NODE app's,
configure each CAN-Node Message object's as TX object and send a frame, to test the physical connection.
That works on both CAN-Nodes :-)
Than i configure:
CAN-Node1 Message-Object LMO_01 as RX object (Ext_29bit, Accept Std_Ext, Mask:0 to receive all frames)
CAN-Node0 Message-Object LMO_01 as TX object ( (Ext_29bit, Accept Std_Ext)
To activate the gateway function, i place in main.c after DAVE_Init() two API calls:
XMC_CAN_GATEWAY_InitSourceObject( CAN_NODE_1.lmobj_ptr[0] , can_gatewaySource);
XMC_CAN_GATEWAY_InitDesObject( CAN_NODE_0.lmobj_ptr[0] );
But the Gateway doesn't work.....
I try the gateway config with:
XMC_CAN_GATEWAY_CONFIG_t can_gatewaySource =
{
0, //bot
0, //top
0, //base
true,
true,
true,
true
} ;
Also i try as bot,top,base: 1,1,1 / 19,19,19 / 17,17,17 without a working gateway.
What is missed?
The second try is to use the multican_config app.
In this
i configure LMO_0 to List2 (Node1) as RX and Gateway source object; Copy all to destination; Mask 0.....
i configure LMO_1 to List1 (Node0) as TX and Gateway destination object (MMC: Standard message object)
Because NO MANUAL PIN Allocator is available for the CAN-RX/TX-Pin's (is this a bug or feature?)
i change the PIN config in multican_config_conf.c to XMC_CAN_NODE_RECEIVE_INPUT_RXDCG for NODE0 and XMC_CAN_NODE_RECEIVE_INPUT_RXDCC for NODE1
and the gateway isn't working!
In this config, no acknowledge is possible on the RX-Node1.
So i try to configure the Port Pins manualy to Output after Dave_Init() :
XMC_GPIO_Init(XMC_GPIO_PORT1, 1,&config_out); // G
XMC_GPIO_Init(XMC_GPIO_PORT4, 9,&config_out); // C
but the Gateway isn't working....
What is wrong?