English
Language : 

XC164-16 Datasheet, PDF (336/417 Pages) Infineon Technologies AG – 16-Bit Single-Chip Microcontroller with C166SV2 Core Volume 2 (of 2): Peripheral Units
XC164-16 Derivatives
Peripheral Units (Vol. 2 of 2)
TwinCAN Module
21.1.6.3 Shared Gateway Mode
In shared gateway mode, only one message object is required to implement a gateway
functionality. The shared gateway object can be considered as normal message object,
which is toggled between the source and destination CAN node as illustrated in
Figure 21-21.
Source CAN Bus
Destination CAN Bus
Source
Node
Destination
Node
Shared Gateway
Control Logic
Node = <s, d>
MMC = ‘101’
CANPTR = ‘n’
FSIZE = ‘00000’
DIR = ‘0’, ‘1’
DATA
ID
DLC
TXRQ
RMTPND
NEWDAT
INTPND
Pointer to
Message
Object
MCA05491
Figure 21-21 Principle of the Shared Gateway Mode
Each message object can be used as shared gateway by setting MMC in the
corresponding MSGFGCRn register to ‘101’. When the message configuration bit NODE
is cleared, CAN node A is used as source, transferring data frames to destination node
B. If NODE is set to ‘1’, CAN node B operates as data source. A bidirectional gateway is
achieved by using a second message object, configured to shared gateway mode with
a complementary NODE declaration. Bitfield CANPTR has to be initialized with the
shared gateway’s message object number, whereas FSIZE, IDC and DLCC have to be
cleared. Bit GDFS in control register MSGFGCRn determines, whether bit TXRQ will be
automatically set in case of an arriving data frame with matching identifier (GDFS = ‘1’).
User’s Manual
TwinCAN_X41, V2.1
21-36
V2.1, 2004-03