source: rtems/c/src/lib/libbsp/arm/tms570/include/ti_herc/reg_dcan.h @ bea49c9

4.11
Last change on this file since bea49c9 was bea49c9, checked in by Premysl Houdek <kom541000@…>, on Jul 16, 2015 at 2:26:09 PM

bsp/tms570: New/generated header files for TMS570 SoC peripherals registers.

The header files are generated by script make_header.py.
Current script's version can be found at:

https://github.com/AoLaD/rtems-tms570-utils/tree/headers/headers/python

Registers offsets and fields have been extracted from reference manual.

Signed-off-by: Premysl Houdek <kom541000@…>

  • Property mode set to 100644
File size: 41.2 KB
Line 
1/* The header file is generated by make_header.py from DCAN.json */
2/* Current script's version can be found at: */
3/* https://github.com/AoLaD/rtems-tms570-utils/tree/headers/headers/python */
4
5/*
6 * Copyright (c) 2014-2015, Premysl Houdek <kom541000@gmail.com>
7 *
8 * Czech Technical University in Prague
9 * Zikova 1903/4
10 * 166 36 Praha 6
11 * Czech Republic
12 *
13 * All rights reserved.
14 *
15 * Redistribution and use in source and binary forms, with or without
16 * modification, are permitted provided that the following conditions are met:
17 *
18 * 1. Redistributions of source code must retain the above copyright notice, this
19 *    list of conditions and the following disclaimer.
20 * 2. Redistributions in binary form must reproduce the above copyright notice,
21 *    this list of conditions and the following disclaimer in the documentation
22 *    and/or other materials provided with the distribution.
23 *
24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
25 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
26 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
28 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
29 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
30 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
31 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
32 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
33 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
34 *
35 * The views and conclusions contained in the software and documentation are those
36 * of the authors and should not be interpreted as representing official policies,
37 * either expressed or implied, of the FreeBSD Project.
38*/
39#ifndef LIBBSP_ARM_tms570_DCAN
40#define LIBBSP_ARM_tms570_DCAN
41
42#include <bsp/utility.h>
43
44typedef struct{
45  uint32_t CTL;               /*CAN Control Register*/
46  uint32_t ES;                /*Error and Status Register*/
47  uint32_t ERRC;              /*Error Counter Register*/
48  uint32_t BTR;               /*Bit Timing Register*/
49  uint32_t INT;               /*Interrupt Register*/
50  uint32_t TEST;              /*Test Register*/
51  uint8_t reserved1 [4];
52  uint32_t PERR;              /*Parity Error Code Register*/
53  uint8_t reserved2 [96];
54  uint32_t ABOTR;             /*Auto-Bus-On Time Register*/
55  uint32_t TXRQX;             /*Transmission Request X Register*/
56  uint32_t TXRQx[4];          /*Transmission Request Register*/
57  uint32_t NWDATX;            /*New Data X Register*/
58  uint32_t NWDATx[4];         /*New Data  Register*/
59  uint32_t INTPNDX;           /*Interrupt Pending X Register*/
60  uint32_t INTPNDx[4];        /*Interrupt Pending Register*/
61  uint32_t MSGVALX;           /*Message Valid X Register*/
62  uint32_t MSGVALx[4];        /*Message Valid Register*/
63  uint8_t reserved3 [4];
64  uint32_t INTMUXx[4];        /*Interrupt Multiplexer Register*/
65  uint8_t reserved4 [24];
66  uint32_t IF1CMD;            /*IF1 Command Register*/
67  uint32_t IF1MSK;            /*IF1 Mask Register*/
68  uint32_t IF1ARB;            /*IF1 Arbitration Register*/
69  uint32_t IF1MCTL;           /*IF1 Message Control Register*/
70  uint32_t IF1DATA;           /*IF1 Data A Register*/
71  uint32_t IF1DATB;           /*IF1 Data B Register*/
72  uint8_t reserved5 [8];
73  uint32_t IF2CMD;            /*IF2 Command Register*/
74  uint32_t IF2MSK;            /*IF2 Mask Register*/
75  uint32_t IF2ARB;            /*IF2 Arbitration Register*/
76  uint32_t IF2MCTL;           /*IF2 Message Control Register*/
77  uint32_t IF2DATA;           /*IF2 Data A Register*/
78  uint32_t IF2DATB;           /*IF2 Data B Register*/
79  uint8_t reserved6 [8];
80  uint32_t IF3OBS;            /*IF3 Observation Register*/
81  uint32_t IF3MSK;            /*IF3 Mask Register*/
82  uint32_t IF3ARB;            /*IF3 Arbitration Register*/
83  uint32_t IF3MCTL;           /*IF3 Message Control Register*/
84  uint32_t IF3DATA;           /*IF3 Data A Register*/
85  uint32_t IF3DATB;           /*IF3 Data B Register*/
86  uint8_t reserved7 [8];
87  uint32_t IF3UEy[4];         /*IF3 Update Enable Register*/
88  uint8_t reserved8 [112];
89  uint32_t TIOC;              /*CAN TX IO Control Register*/
90  uint32_t RIOC;              /*CAN RX IO Control Register*/
91} tms570_dcan_t;
92
93
94/*-----------------------TMS570_DCANCTL-----------------------*/
95/* field: WUBA - Automatic wake up on bus activity when in local power down mode */
96#define TMS570_DCAN_CTL_WUBA BSP_FLD32(25)
97
98/* field: PDR - Request for local low power down mode */
99#define TMS570_DCAN_CTL_PDR BSP_FLD32(24)
100
101/* field: DE3 - Enable DMA request line for IF3 */
102#define TMS570_DCAN_CTL_DE3 BSP_FLD32(20)
103
104/* field: DE2 - Enable DMA request line for IF2 */
105#define TMS570_DCAN_CTL_DE2 BSP_FLD32(19)
106
107/* field: DE1 - Enable DMA request line for IF1 */
108#define TMS570_DCAN_CTL_DE1 BSP_FLD32(18)
109
110/* field: IE1 - Interrupt line 1 Enable */
111#define TMS570_DCAN_CTL_IE1 BSP_FLD32(17)
112
113/* field: InitDbg - Internal Init state while debug access */
114#define TMS570_DCAN_CTL_InitDbg BSP_FLD32(16)
115
116/* field: SWR - SW Reset Enable */
117#define TMS570_DCAN_CTL_SWR BSP_FLD32(15)
118
119/* field: PMD - Parity on/off */
120#define TMS570_DCAN_CTL_PMD(val) BSP_FLD32(val,10, 13)
121#define TMS570_DCAN_CTL_PMD_GET(reg) BSP_FLD32GET(reg,10, 13)
122#define TMS570_DCAN_CTL_PMD_SET(reg,val) BSP_FLD32SET(reg, val,10, 13)
123
124/* field: ABO - Auto-Bus-On Enable */
125#define TMS570_DCAN_CTL_ABO BSP_FLD32(9)
126
127/* field: IDS - Interruption Debug Support Enable */
128#define TMS570_DCAN_CTL_IDS BSP_FLD32(8)
129
130/* field: Test - Test Mode Enable */
131#define TMS570_DCAN_CTL_Test BSP_FLD32(7)
132
133/* field: CCE - Configuration Change Enable */
134#define TMS570_DCAN_CTL_CCE BSP_FLD32(6)
135
136/* field: DAR - Disable Automatic Retransmission */
137#define TMS570_DCAN_CTL_DAR BSP_FLD32(5)
138
139/* field: EIE - Error Interrupt Enable */
140#define TMS570_DCAN_CTL_EIE BSP_FLD32(3)
141
142/* field: SIE - Status Change Interrupt Enable */
143#define TMS570_DCAN_CTL_SIE BSP_FLD32(2)
144
145/* field: IE0 - Interrupt line 0 Enable */
146#define TMS570_DCAN_CTL_IE0 BSP_FLD32(1)
147
148/* field: Init - Initialization */
149#define TMS570_DCAN_CTL_Init BSP_FLD32(0)
150
151
152/*-----------------------TMS570_DCANES-----------------------*/
153/* field: PDA - Local power down mode acknowledge */
154#define TMS570_DCAN_ES_PDA BSP_FLD32(10)
155
156/* field: WakeUp_Pnd - Wake Up Pending */
157#define TMS570_DCAN_ES_WakeUp_Pnd BSP_FLD32(9)
158
159/* field: PER - Parity Error Detected */
160#define TMS570_DCAN_ES_PER BSP_FLD32(8)
161
162/* field: BOff - Bus-Off State */
163#define TMS570_DCAN_ES_BOff BSP_FLD32(7)
164
165/* field: EWarn - Warning State */
166#define TMS570_DCAN_ES_EWarn BSP_FLD32(6)
167
168/* field: EPass - Error Passive State */
169#define TMS570_DCAN_ES_EPass BSP_FLD32(5)
170
171/* field: RxOK - Received a message successfully */
172#define TMS570_DCAN_ES_RxOK BSP_FLD32(4)
173
174/* field: TxOK - Transmitted a message successfully */
175#define TMS570_DCAN_ES_TxOK BSP_FLD32(3)
176
177/* field: LEC - Last Error Code */
178#define TMS570_DCAN_ES_LEC(val) BSP_FLD32(val,0, 2)
179#define TMS570_DCAN_ES_LEC_GET(reg) BSP_FLD32GET(reg,0, 2)
180#define TMS570_DCAN_ES_LEC_SET(reg,val) BSP_FLD32SET(reg, val,0, 2)
181
182
183/*----------------------TMS570_DCANERRC----------------------*/
184/* field: RP - Receive Error Passive */
185#define TMS570_DCAN_ERRC_RP BSP_FLD32(15)
186
187/* field: REC - Receive Error Counter. Actual state of the Receive Error Counter. (values from 0 to 255). */
188#define TMS570_DCAN_ERRC_REC(val) BSP_FLD32(val,8, 14)
189#define TMS570_DCAN_ERRC_REC_GET(reg) BSP_FLD32GET(reg,8, 14)
190#define TMS570_DCAN_ERRC_REC_SET(reg,val) BSP_FLD32SET(reg, val,8, 14)
191
192/* field: TEC - Transmit Error Counter. Actual state of the Transmit Error Counter. (values from 0 to 255). */
193#define TMS570_DCAN_ERRC_TEC(val) BSP_FLD32(val,0, 7)
194#define TMS570_DCAN_ERRC_TEC_GET(reg) BSP_FLD32GET(reg,0, 7)
195#define TMS570_DCAN_ERRC_TEC_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
196
197
198/*-----------------------TMS570_DCANBTR-----------------------*/
199/* field: BRPE - Baud Rate Prescaler Extension. */
200#define TMS570_DCAN_BTR_BRPE(val) BSP_FLD32(val,16, 19)
201#define TMS570_DCAN_BTR_BRPE_GET(reg) BSP_FLD32GET(reg,16, 19)
202#define TMS570_DCAN_BTR_BRPE_SET(reg,val) BSP_FLD32SET(reg, val,16, 19)
203
204/* field: TSeg2 - Time segment after the sample point */
205#define TMS570_DCAN_BTR_TSeg2(val) BSP_FLD32(val,12, 14)
206#define TMS570_DCAN_BTR_TSeg2_GET(reg) BSP_FLD32GET(reg,12, 14)
207#define TMS570_DCAN_BTR_TSeg2_SET(reg,val) BSP_FLD32SET(reg, val,12, 14)
208
209/* field: TSeg1 - Time segment before the sample point */
210#define TMS570_DCAN_BTR_TSeg1(val) BSP_FLD32(val,8, 11)
211#define TMS570_DCAN_BTR_TSeg1_GET(reg) BSP_FLD32GET(reg,8, 11)
212#define TMS570_DCAN_BTR_TSeg1_SET(reg,val) BSP_FLD32SET(reg, val,8, 11)
213
214/* field: SJW - Synchronization Jump Width */
215#define TMS570_DCAN_BTR_SJW(val) BSP_FLD32(val,6, 7)
216#define TMS570_DCAN_BTR_SJW_GET(reg) BSP_FLD32GET(reg,6, 7)
217#define TMS570_DCAN_BTR_SJW_SET(reg,val) BSP_FLD32SET(reg, val,6, 7)
218
219/* field: BRP - Baud Rate Prescaler */
220#define TMS570_DCAN_BTR_BRP(val) BSP_FLD32(val,0, 5)
221#define TMS570_DCAN_BTR_BRP_GET(reg) BSP_FLD32GET(reg,0, 5)
222#define TMS570_DCAN_BTR_BRP_SET(reg,val) BSP_FLD32SET(reg, val,0, 5)
223
224
225/*-----------------------TMS570_DCANINT-----------------------*/
226/* field: Int1ID - Interrupt 1 Identifier (indicates the message object with the highest pending interrupt) */
227#define TMS570_DCAN_INT_Int1ID(val) BSP_FLD32(val,16, 23)
228#define TMS570_DCAN_INT_Int1ID_GET(reg) BSP_FLD32GET(reg,16, 23)
229#define TMS570_DCAN_INT_Int1ID_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
230
231/* field: Int0ID - Interrupt Identifier (the number here indicates the source of the interrupt) */
232#define TMS570_DCAN_INT_Int0ID(val) BSP_FLD32(val,0, 15)
233#define TMS570_DCAN_INT_Int0ID_GET(reg) BSP_FLD32GET(reg,0, 15)
234#define TMS570_DCAN_INT_Int0ID_SET(reg,val) BSP_FLD32SET(reg, val,0, 15)
235
236
237/*----------------------TMS570_DCANTEST----------------------*/
238/* field: RDA - RAM Direct Access Enable */
239#define TMS570_DCAN_TEST_RDA BSP_FLD32(9)
240
241/* field: EXL - External Loop Back Mode */
242#define TMS570_DCAN_TEST_EXL BSP_FLD32(8)
243
244/* field: Rx - Receive Pin. Monitors the actual value of the CAN_RX pin. */
245#define TMS570_DCAN_TEST_Rx BSP_FLD32(7)
246
247/* field: Tx - Control of CAN_TX pin */
248#define TMS570_DCAN_TEST_Tx(val) BSP_FLD32(val,5, 6)
249#define TMS570_DCAN_TEST_Tx_GET(reg) BSP_FLD32GET(reg,5, 6)
250#define TMS570_DCAN_TEST_Tx_SET(reg,val) BSP_FLD32SET(reg, val,5, 6)
251
252/* field: LBack - Loop Back Mode */
253#define TMS570_DCAN_TEST_LBack BSP_FLD32(4)
254
255/* field: Silent - Silent Mode */
256#define TMS570_DCAN_TEST_Silent BSP_FLD32(3)
257
258
259/*----------------------TMS570_DCANPERR----------------------*/
260/* field: Word_Number - Word number where parity error has been detected */
261#define TMS570_DCAN_PERR_Word_Number(val) BSP_FLD32(val,8, 10)
262#define TMS570_DCAN_PERR_Word_Number_GET(reg) BSP_FLD32GET(reg,8, 10)
263#define TMS570_DCAN_PERR_Word_Number_SET(reg,val) BSP_FLD32SET(reg, val,8, 10)
264
265/* field: Message_Number -  */
266#define TMS570_DCAN_PERR_Message_Number(val) BSP_FLD32(val,0, 7)
267#define TMS570_DCAN_PERR_Message_Number_GET(reg) BSP_FLD32GET(reg,0, 7)
268#define TMS570_DCAN_PERR_Message_Number_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
269
270
271/*----------------------TMS570_DCANABOTR----------------------*/
272/* field: ABO_Time - Number of VBUS clock cycles before a Bus-Off recovery sequence is */
273#define TMS570_DCAN_ABOTR_ABO_Time(val) BSP_FLD32(val,0, 31)
274#define TMS570_DCAN_ABOTR_ABO_Time_GET(reg) BSP_FLD32GET(reg,0, 31)
275#define TMS570_DCAN_ABOTR_ABO_Time_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
276
277
278/*----------------------TMS570_DCANTXRQX----------------------*/
279/* field: TxRqstReg8 - TxRqstReg8 */
280#define TMS570_DCAN_TXRQX_TxRqstReg8(val) BSP_FLD32(val,14, 15)
281#define TMS570_DCAN_TXRQX_TxRqstReg8_GET(reg) BSP_FLD32GET(reg,14, 15)
282#define TMS570_DCAN_TXRQX_TxRqstReg8_SET(reg,val) BSP_FLD32SET(reg, val,14, 15)
283
284/* field: TxRqstReg7 - TxRqstReg8 */
285#define TMS570_DCAN_TXRQX_TxRqstReg7(val) BSP_FLD32(val,12, 13)
286#define TMS570_DCAN_TXRQX_TxRqstReg7_GET(reg) BSP_FLD32GET(reg,12, 13)
287#define TMS570_DCAN_TXRQX_TxRqstReg7_SET(reg,val) BSP_FLD32SET(reg, val,12, 13)
288
289/* field: TxRqstReg6 - TxRqstReg8 */
290#define TMS570_DCAN_TXRQX_TxRqstReg6(val) BSP_FLD32(val,10, 11)
291#define TMS570_DCAN_TXRQX_TxRqstReg6_GET(reg) BSP_FLD32GET(reg,10, 11)
292#define TMS570_DCAN_TXRQX_TxRqstReg6_SET(reg,val) BSP_FLD32SET(reg, val,10, 11)
293
294/* field: TxRqstReg5 - TxRqstReg8 */
295#define TMS570_DCAN_TXRQX_TxRqstReg5(val) BSP_FLD32(val,8, 9)
296#define TMS570_DCAN_TXRQX_TxRqstReg5_GET(reg) BSP_FLD32GET(reg,8, 9)
297#define TMS570_DCAN_TXRQX_TxRqstReg5_SET(reg,val) BSP_FLD32SET(reg, val,8, 9)
298
299/* field: TxRqstReg4 - TxRqstReg8 */
300#define TMS570_DCAN_TXRQX_TxRqstReg4(val) BSP_FLD32(val,6, 7)
301#define TMS570_DCAN_TXRQX_TxRqstReg4_GET(reg) BSP_FLD32GET(reg,6, 7)
302#define TMS570_DCAN_TXRQX_TxRqstReg4_SET(reg,val) BSP_FLD32SET(reg, val,6, 7)
303
304/* field: TxRqstReg3 - TxRqstReg8 */
305#define TMS570_DCAN_TXRQX_TxRqstReg3(val) BSP_FLD32(val,4, 5)
306#define TMS570_DCAN_TXRQX_TxRqstReg3_GET(reg) BSP_FLD32GET(reg,4, 5)
307#define TMS570_DCAN_TXRQX_TxRqstReg3_SET(reg,val) BSP_FLD32SET(reg, val,4, 5)
308
309/* field: TxRqstReg2 - TxRqstReg8 */
310#define TMS570_DCAN_TXRQX_TxRqstReg2(val) BSP_FLD32(val,2, 3)
311#define TMS570_DCAN_TXRQX_TxRqstReg2_GET(reg) BSP_FLD32GET(reg,2, 3)
312#define TMS570_DCAN_TXRQX_TxRqstReg2_SET(reg,val) BSP_FLD32SET(reg, val,2, 3)
313
314/* field: TxRqstReg1 - TxRqstReg8 */
315#define TMS570_DCAN_TXRQX_TxRqstReg1(val) BSP_FLD32(val,0, 1)
316#define TMS570_DCAN_TXRQX_TxRqstReg1_GET(reg) BSP_FLD32GET(reg,0, 1)
317#define TMS570_DCAN_TXRQX_TxRqstReg1_SET(reg,val) BSP_FLD32SET(reg, val,0, 1)
318
319
320/*----------------------TMS570_DCANTXRQx----------------------*/
321/* field: TxRqsX - Transmission Request Bits (for all message objects) */
322#define TMS570_DCAN_TXRQx_TxRqsX(val) BSP_FLD32(val,0, 31)
323#define TMS570_DCAN_TXRQx_TxRqsX_GET(reg) BSP_FLD32GET(reg,0, 31)
324#define TMS570_DCAN_TXRQx_TxRqsX_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
325
326
327/*---------------------TMS570_DCANNWDATX---------------------*/
328/* field: NewDatReg8 - TxRqstReg8 */
329#define TMS570_DCAN_NWDATX_NewDatReg8(val) BSP_FLD32(val,14, 15)
330#define TMS570_DCAN_NWDATX_NewDatReg8_GET(reg) BSP_FLD32GET(reg,14, 15)
331#define TMS570_DCAN_NWDATX_NewDatReg8_SET(reg,val) BSP_FLD32SET(reg, val,14, 15)
332
333/* field: NewDatReg7 - TxRqstReg8 */
334#define TMS570_DCAN_NWDATX_NewDatReg7(val) BSP_FLD32(val,12, 13)
335#define TMS570_DCAN_NWDATX_NewDatReg7_GET(reg) BSP_FLD32GET(reg,12, 13)
336#define TMS570_DCAN_NWDATX_NewDatReg7_SET(reg,val) BSP_FLD32SET(reg, val,12, 13)
337
338/* field: NewDatReg6 - TxRqstReg8 */
339#define TMS570_DCAN_NWDATX_NewDatReg6(val) BSP_FLD32(val,10, 11)
340#define TMS570_DCAN_NWDATX_NewDatReg6_GET(reg) BSP_FLD32GET(reg,10, 11)
341#define TMS570_DCAN_NWDATX_NewDatReg6_SET(reg,val) BSP_FLD32SET(reg, val,10, 11)
342
343/* field: NewDatReg5 - TxRqstReg8 */
344#define TMS570_DCAN_NWDATX_NewDatReg5(val) BSP_FLD32(val,8, 9)
345#define TMS570_DCAN_NWDATX_NewDatReg5_GET(reg) BSP_FLD32GET(reg,8, 9)
346#define TMS570_DCAN_NWDATX_NewDatReg5_SET(reg,val) BSP_FLD32SET(reg, val,8, 9)
347
348/* field: NewDatReg4 - TxRqstReg8 */
349#define TMS570_DCAN_NWDATX_NewDatReg4(val) BSP_FLD32(val,6, 7)
350#define TMS570_DCAN_NWDATX_NewDatReg4_GET(reg) BSP_FLD32GET(reg,6, 7)
351#define TMS570_DCAN_NWDATX_NewDatReg4_SET(reg,val) BSP_FLD32SET(reg, val,6, 7)
352
353/* field: NewDatReg3 - TxRqstReg8 */
354#define TMS570_DCAN_NWDATX_NewDatReg3(val) BSP_FLD32(val,4, 5)
355#define TMS570_DCAN_NWDATX_NewDatReg3_GET(reg) BSP_FLD32GET(reg,4, 5)
356#define TMS570_DCAN_NWDATX_NewDatReg3_SET(reg,val) BSP_FLD32SET(reg, val,4, 5)
357
358/* field: NewDatReg2 - TxRqstReg8 */
359#define TMS570_DCAN_NWDATX_NewDatReg2(val) BSP_FLD32(val,2, 3)
360#define TMS570_DCAN_NWDATX_NewDatReg2_GET(reg) BSP_FLD32GET(reg,2, 3)
361#define TMS570_DCAN_NWDATX_NewDatReg2_SET(reg,val) BSP_FLD32SET(reg, val,2, 3)
362
363/* field: NewDatReg1 - TxRqstReg8 */
364#define TMS570_DCAN_NWDATX_NewDatReg1(val) BSP_FLD32(val,0, 1)
365#define TMS570_DCAN_NWDATX_NewDatReg1_GET(reg) BSP_FLD32GET(reg,0, 1)
366#define TMS570_DCAN_NWDATX_NewDatReg1_SET(reg,val) BSP_FLD32SET(reg, val,0, 1)
367
368
369/*---------------------TMS570_DCANNWDATx---------------------*/
370/* field: NewDatX - New Data Bits (for all message objects) */
371#define TMS570_DCAN_NWDATx_NewDatX(val) BSP_FLD32(val,0, 31)
372#define TMS570_DCAN_NWDATx_NewDatX_GET(reg) BSP_FLD32GET(reg,0, 31)
373#define TMS570_DCAN_NWDATx_NewDatX_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
374
375
376/*---------------------TMS570_DCANINTPNDX---------------------*/
377/* field: IntPndReg8 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
378#define TMS570_DCAN_INTPNDX_IntPndReg8(val) BSP_FLD32(val,14, 15)
379#define TMS570_DCAN_INTPNDX_IntPndReg8_GET(reg) BSP_FLD32GET(reg,14, 15)
380#define TMS570_DCAN_INTPNDX_IntPndReg8_SET(reg,val) BSP_FLD32SET(reg, val,14, 15)
381
382/* field: IntPndReg7 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
383#define TMS570_DCAN_INTPNDX_IntPndReg7(val) BSP_FLD32(val,12, 13)
384#define TMS570_DCAN_INTPNDX_IntPndReg7_GET(reg) BSP_FLD32GET(reg,12, 13)
385#define TMS570_DCAN_INTPNDX_IntPndReg7_SET(reg,val) BSP_FLD32SET(reg, val,12, 13)
386
387/* field: IntPndReg6 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
388#define TMS570_DCAN_INTPNDX_IntPndReg6(val) BSP_FLD32(val,10, 11)
389#define TMS570_DCAN_INTPNDX_IntPndReg6_GET(reg) BSP_FLD32GET(reg,10, 11)
390#define TMS570_DCAN_INTPNDX_IntPndReg6_SET(reg,val) BSP_FLD32SET(reg, val,10, 11)
391
392/* field: IntPndReg5 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
393#define TMS570_DCAN_INTPNDX_IntPndReg5(val) BSP_FLD32(val,8, 9)
394#define TMS570_DCAN_INTPNDX_IntPndReg5_GET(reg) BSP_FLD32GET(reg,8, 9)
395#define TMS570_DCAN_INTPNDX_IntPndReg5_SET(reg,val) BSP_FLD32SET(reg, val,8, 9)
396
397/* field: IntPndReg4 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
398#define TMS570_DCAN_INTPNDX_IntPndReg4(val) BSP_FLD32(val,6, 7)
399#define TMS570_DCAN_INTPNDX_IntPndReg4_GET(reg) BSP_FLD32GET(reg,6, 7)
400#define TMS570_DCAN_INTPNDX_IntPndReg4_SET(reg,val) BSP_FLD32SET(reg, val,6, 7)
401
402/* field: IntPndReg3 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
403#define TMS570_DCAN_INTPNDX_IntPndReg3(val) BSP_FLD32(val,4, 5)
404#define TMS570_DCAN_INTPNDX_IntPndReg3_GET(reg) BSP_FLD32GET(reg,4, 5)
405#define TMS570_DCAN_INTPNDX_IntPndReg3_SET(reg,val) BSP_FLD32SET(reg, val,4, 5)
406
407/* field: IntPndReg2 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
408#define TMS570_DCAN_INTPNDX_IntPndReg2(val) BSP_FLD32(val,2, 3)
409#define TMS570_DCAN_INTPNDX_IntPndReg2_GET(reg) BSP_FLD32GET(reg,2, 3)
410#define TMS570_DCAN_INTPNDX_IntPndReg2_SET(reg,val) BSP_FLD32SET(reg, val,2, 3)
411
412/* field: IntPndReg1 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Interrupt Pending X Register will be set. */
413#define TMS570_DCAN_INTPNDX_IntPndReg1(val) BSP_FLD32(val,0, 1)
414#define TMS570_DCAN_INTPNDX_IntPndReg1_GET(reg) BSP_FLD32GET(reg,0, 1)
415#define TMS570_DCAN_INTPNDX_IntPndReg1_SET(reg,val) BSP_FLD32SET(reg, val,0, 1)
416
417
418/*---------------------TMS570_DCANINTPNDx---------------------*/
419/* field: IntPndX - Interrupt Pending Bits (for all message objects) */
420#define TMS570_DCAN_INTPNDx_IntPndX(val) BSP_FLD32(val,0, 31)
421#define TMS570_DCAN_INTPNDx_IntPndX_GET(reg) BSP_FLD32GET(reg,0, 31)
422#define TMS570_DCAN_INTPNDx_IntPndX_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
423
424
425/*---------------------TMS570_DCANMSGVALX---------------------*/
426/* field: MsgValReg8 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
427#define TMS570_DCAN_MSGVALX_MsgValReg8(val) BSP_FLD32(val,14, 15)
428#define TMS570_DCAN_MSGVALX_MsgValReg8_GET(reg) BSP_FLD32GET(reg,14, 15)
429#define TMS570_DCAN_MSGVALX_MsgValReg8_SET(reg,val) BSP_FLD32SET(reg, val,14, 15)
430
431/* field: MsgValReg7 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
432#define TMS570_DCAN_MSGVALX_MsgValReg7(val) BSP_FLD32(val,12, 13)
433#define TMS570_DCAN_MSGVALX_MsgValReg7_GET(reg) BSP_FLD32GET(reg,12, 13)
434#define TMS570_DCAN_MSGVALX_MsgValReg7_SET(reg,val) BSP_FLD32SET(reg, val,12, 13)
435
436/* field: MsgValReg6 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
437#define TMS570_DCAN_MSGVALX_MsgValReg6(val) BSP_FLD32(val,10, 11)
438#define TMS570_DCAN_MSGVALX_MsgValReg6_GET(reg) BSP_FLD32GET(reg,10, 11)
439#define TMS570_DCAN_MSGVALX_MsgValReg6_SET(reg,val) BSP_FLD32SET(reg, val,10, 11)
440
441/* field: MsgValReg5 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
442#define TMS570_DCAN_MSGVALX_MsgValReg5(val) BSP_FLD32(val,8, 9)
443#define TMS570_DCAN_MSGVALX_MsgValReg5_GET(reg) BSP_FLD32GET(reg,8, 9)
444#define TMS570_DCAN_MSGVALX_MsgValReg5_SET(reg,val) BSP_FLD32SET(reg, val,8, 9)
445
446/* field: MsgValReg4 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
447#define TMS570_DCAN_MSGVALX_MsgValReg4(val) BSP_FLD32(val,6, 7)
448#define TMS570_DCAN_MSGVALX_MsgValReg4_GET(reg) BSP_FLD32GET(reg,6, 7)
449#define TMS570_DCAN_MSGVALX_MsgValReg4_SET(reg,val) BSP_FLD32SET(reg, val,6, 7)
450
451/* field: MsgValReg3 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
452#define TMS570_DCAN_MSGVALX_MsgValReg3(val) BSP_FLD32(val,4, 5)
453#define TMS570_DCAN_MSGVALX_MsgValReg3_GET(reg) BSP_FLD32GET(reg,4, 5)
454#define TMS570_DCAN_MSGVALX_MsgValReg3_SET(reg,val) BSP_FLD32SET(reg, val,4, 5)
455
456/* field: MsgValReg2 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
457#define TMS570_DCAN_MSGVALX_MsgValReg2(val) BSP_FLD32(val,2, 3)
458#define TMS570_DCAN_MSGVALX_MsgValReg2_GET(reg) BSP_FLD32GET(reg,2, 3)
459#define TMS570_DCAN_MSGVALX_MsgValReg2_SET(reg,val) BSP_FLD32SET(reg, val,2, 3)
460
461/* field: MsgValReg1 - If at least one of the IntPnd bits of these message objects are set, the corresponding bit in the Message Valid X Register will be set. */
462#define TMS570_DCAN_MSGVALX_MsgValReg1(val) BSP_FLD32(val,0, 1)
463#define TMS570_DCAN_MSGVALX_MsgValReg1_GET(reg) BSP_FLD32GET(reg,0, 1)
464#define TMS570_DCAN_MSGVALX_MsgValReg1_SET(reg,val) BSP_FLD32SET(reg, val,0, 1)
465
466
467/*---------------------TMS570_DCANMSGVALx---------------------*/
468/* field: MsgVal1To32 - Message Valid Bits (for all message objects) */
469#define TMS570_DCAN_MSGVALx_MsgVal1To32(val) BSP_FLD32(val,0, 31)
470#define TMS570_DCAN_MSGVALx_MsgVal1To32_GET(reg) BSP_FLD32GET(reg,0, 31)
471#define TMS570_DCAN_MSGVALx_MsgVal1To32_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
472
473
474/*---------------------TMS570_DCANINTMUXx---------------------*/
475/* field: IntMux1To32 - Multiplexes IntPnd value to either DCAN0INT or DCAN1INT interrupt lines. */
476#define TMS570_DCAN_INTMUXx_IntMux1To32(val) BSP_FLD32(val,0, 31)
477#define TMS570_DCAN_INTMUXx_IntMux1To32_GET(reg) BSP_FLD32GET(reg,0, 31)
478#define TMS570_DCAN_INTMUXx_IntMux1To32_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
479
480
481/*---------------------TMS570_DCANIF1CMD---------------------*/
482/* field: WR_RD - Write/Read */
483#define TMS570_DCAN_IF1CMD_WR_RD BSP_FLD32(23)
484
485/* field: Mask - Access Mask bits */
486#define TMS570_DCAN_IF1CMD_Mask BSP_FLD32(22)
487
488/* field: Arb - Access Arbitration bits */
489#define TMS570_DCAN_IF1CMD_Arb BSP_FLD32(21)
490
491/* field: Control - Access Control bits */
492#define TMS570_DCAN_IF1CMD_Control BSP_FLD32(20)
493
494/* field: ClrIntPnd - Clear Interrupt Pending bit */
495#define TMS570_DCAN_IF1CMD_ClrIntPnd BSP_FLD32(19)
496
497/* field: TxRqst_NewDat - Access Transmission Request bit */
498#define TMS570_DCAN_IF1CMD_TxRqst_NewDat BSP_FLD32(18)
499
500/* field: Data_A - Access Data Bytes 0-3 */
501#define TMS570_DCAN_IF1CMD_Data_A BSP_FLD32(17)
502
503/* field: Data_B - Access Data Bytes 4-7 */
504#define TMS570_DCAN_IF1CMD_Data_B BSP_FLD32(16)
505
506/* field: Busy - Busy flag */
507#define TMS570_DCAN_IF1CMD_Busy BSP_FLD32(15)
508
509/* field: DMA_Active - Activation of DMA feature for subsequent internal IF1/IF2 update */
510#define TMS570_DCAN_IF1CMD_DMA_Active BSP_FLD32(14)
511
512/* field: Message_Number - Number of message object in Message RAM that is used for data transfer */
513#define TMS570_DCAN_IF1CMD_Message_Number(val) BSP_FLD32(val,0, 7)
514#define TMS570_DCAN_IF1CMD_Message_Number_GET(reg) BSP_FLD32GET(reg,0, 7)
515#define TMS570_DCAN_IF1CMD_Message_Number_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
516
517
518/*---------------------TMS570_DCANIF1MSK---------------------*/
519/* field: MXtd - Mask Extended Identifier */
520#define TMS570_DCAN_IF1MSK_MXtd BSP_FLD32(31)
521
522/* field: MDir - Mask Message Direction */
523#define TMS570_DCAN_IF1MSK_MDir BSP_FLD32(30)
524
525/* field: Msk - Identifier Mask */
526#define TMS570_DCAN_IF1MSK_Msk(val) BSP_FLD32(val,0, 28)
527#define TMS570_DCAN_IF1MSK_Msk_GET(reg) BSP_FLD32GET(reg,0, 28)
528#define TMS570_DCAN_IF1MSK_Msk_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
529
530
531/*---------------------TMS570_DCANIF1ARB---------------------*/
532/* field: MsgVal - Message Valid */
533#define TMS570_DCAN_IF1ARB_MsgVal BSP_FLD32(31)
534
535/* field: Xtd - Extended Identifier */
536#define TMS570_DCAN_IF1ARB_Xtd BSP_FLD32(30)
537
538/* field: Dir - Message direction */
539#define TMS570_DCAN_IF1ARB_Dir BSP_FLD32(29)
540
541/* field: ID - Message Identifier */
542#define TMS570_DCAN_IF1ARB_ID(val) BSP_FLD32(val,0, 28)
543#define TMS570_DCAN_IF1ARB_ID_GET(reg) BSP_FLD32GET(reg,0, 28)
544#define TMS570_DCAN_IF1ARB_ID_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
545
546
547/*---------------------TMS570_DCANIF1MCTL---------------------*/
548/* field: NewDat - New Data */
549#define TMS570_DCAN_IF1MCTL_NewDat BSP_FLD32(15)
550
551/* field: MsgLst - Message Lost (only valid for message objects with direction = receive) */
552#define TMS570_DCAN_IF1MCTL_MsgLst BSP_FLD32(14)
553
554/* field: IntPnd - Interrupt Pending */
555#define TMS570_DCAN_IF1MCTL_IntPnd BSP_FLD32(13)
556
557/* field: UMask - Use Acceptance Mask */
558#define TMS570_DCAN_IF1MCTL_UMask BSP_FLD32(12)
559
560/* field: TxIE - Transmit Interrupt Enable */
561#define TMS570_DCAN_IF1MCTL_TxIE BSP_FLD32(11)
562
563/* field: RxIE - Receive Interrupt Enable */
564#define TMS570_DCAN_IF1MCTL_RxIE BSP_FLD32(10)
565
566/* field: RmtEn - Remote Enable */
567#define TMS570_DCAN_IF1MCTL_RmtEn BSP_FLD32(9)
568
569/* field: TxRqst - Transmit Request */
570#define TMS570_DCAN_IF1MCTL_TxRqst BSP_FLD32(8)
571
572/* field: EoB - Data Frame has 0-8 data bits */
573#define TMS570_DCAN_IF1MCTL_EoB BSP_FLD32(7)
574
575/* field: DLC - Data Length Code */
576#define TMS570_DCAN_IF1MCTL_DLC(val) BSP_FLD32(val,0, 3)
577#define TMS570_DCAN_IF1MCTL_DLC_GET(reg) BSP_FLD32GET(reg,0, 3)
578#define TMS570_DCAN_IF1MCTL_DLC_SET(reg,val) BSP_FLD32SET(reg, val,0, 3)
579
580
581/*---------------------TMS570_DCANIF1DATA---------------------*/
582/* field: Data0 - Data 0 */
583#define TMS570_DCAN_IF1DATA_Data0(val) BSP_FLD32(val,0, 7)
584#define TMS570_DCAN_IF1DATA_Data0_GET(reg) BSP_FLD32GET(reg,0, 7)
585#define TMS570_DCAN_IF1DATA_Data0_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
586
587/* field: Data1 - Data 1 */
588#define TMS570_DCAN_IF1DATA_Data1(val) BSP_FLD32(val,8, 15)
589#define TMS570_DCAN_IF1DATA_Data1_GET(reg) BSP_FLD32GET(reg,8, 15)
590#define TMS570_DCAN_IF1DATA_Data1_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
591
592/* field: Data2 - Data 2 */
593#define TMS570_DCAN_IF1DATA_Data2(val) BSP_FLD32(val,16, 23)
594#define TMS570_DCAN_IF1DATA_Data2_GET(reg) BSP_FLD32GET(reg,16, 23)
595#define TMS570_DCAN_IF1DATA_Data2_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
596
597/* field: Data3 - Data 3 */
598#define TMS570_DCAN_IF1DATA_Data3(val) BSP_FLD32(val,24, 31)
599#define TMS570_DCAN_IF1DATA_Data3_GET(reg) BSP_FLD32GET(reg,24, 31)
600#define TMS570_DCAN_IF1DATA_Data3_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
601
602
603/*---------------------TMS570_DCANIF1DATB---------------------*/
604/* field: Data4 - Data 4 */
605#define TMS570_DCAN_IF1DATB_Data4(val) BSP_FLD32(val,0, 7)
606#define TMS570_DCAN_IF1DATB_Data4_GET(reg) BSP_FLD32GET(reg,0, 7)
607#define TMS570_DCAN_IF1DATB_Data4_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
608
609/* field: Data5 - Data 5 */
610#define TMS570_DCAN_IF1DATB_Data5(val) BSP_FLD32(val,8, 15)
611#define TMS570_DCAN_IF1DATB_Data5_GET(reg) BSP_FLD32GET(reg,8, 15)
612#define TMS570_DCAN_IF1DATB_Data5_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
613
614/* field: Data6 - Data 6 */
615#define TMS570_DCAN_IF1DATB_Data6(val) BSP_FLD32(val,16, 23)
616#define TMS570_DCAN_IF1DATB_Data6_GET(reg) BSP_FLD32GET(reg,16, 23)
617#define TMS570_DCAN_IF1DATB_Data6_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
618
619/* field: Data7 - Data 7 */
620#define TMS570_DCAN_IF1DATB_Data7(val) BSP_FLD32(val,24, 31)
621#define TMS570_DCAN_IF1DATB_Data7_GET(reg) BSP_FLD32GET(reg,24, 31)
622#define TMS570_DCAN_IF1DATB_Data7_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
623
624
625/*---------------------TMS570_DCANIF2CMD---------------------*/
626/* field: WR_RD - Write/Read */
627#define TMS570_DCAN_IF2CMD_WR_RD BSP_FLD32(23)
628
629/* field: Mask - Access Mask bits */
630#define TMS570_DCAN_IF2CMD_Mask BSP_FLD32(22)
631
632/* field: Arb - Access Arbitration bits */
633#define TMS570_DCAN_IF2CMD_Arb BSP_FLD32(21)
634
635/* field: Control - Access Control bits */
636#define TMS570_DCAN_IF2CMD_Control BSP_FLD32(20)
637
638/* field: ClrIntPnd - Clear Interrupt Pending bit */
639#define TMS570_DCAN_IF2CMD_ClrIntPnd BSP_FLD32(19)
640
641/* field: TxRqst_NewDat - Access Transmission Request bit */
642#define TMS570_DCAN_IF2CMD_TxRqst_NewDat BSP_FLD32(18)
643
644/* field: Data_A - Access Data Bytes 0-3 */
645#define TMS570_DCAN_IF2CMD_Data_A BSP_FLD32(17)
646
647/* field: Data_B - Access Data Bytes 4-7 */
648#define TMS570_DCAN_IF2CMD_Data_B BSP_FLD32(16)
649
650/* field: Busy - Busy flag */
651#define TMS570_DCAN_IF2CMD_Busy BSP_FLD32(15)
652
653/* field: DMA_Active - Activation of DMA feature for subsequent internal IF1/IF2 update */
654#define TMS570_DCAN_IF2CMD_DMA_Active BSP_FLD32(14)
655
656/* field: Message_Number - Number of message object in Message RAM that is used for data transfer */
657#define TMS570_DCAN_IF2CMD_Message_Number(val) BSP_FLD32(val,0, 7)
658#define TMS570_DCAN_IF2CMD_Message_Number_GET(reg) BSP_FLD32GET(reg,0, 7)
659#define TMS570_DCAN_IF2CMD_Message_Number_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
660
661
662/*---------------------TMS570_DCANIF2MSK---------------------*/
663/* field: MXtd - Mask Extended Identifier */
664#define TMS570_DCAN_IF2MSK_MXtd BSP_FLD32(31)
665
666/* field: MDir - Mask Message Direction */
667#define TMS570_DCAN_IF2MSK_MDir BSP_FLD32(30)
668
669/* field: Msk - Identifier Mask */
670#define TMS570_DCAN_IF2MSK_Msk(val) BSP_FLD32(val,0, 28)
671#define TMS570_DCAN_IF2MSK_Msk_GET(reg) BSP_FLD32GET(reg,0, 28)
672#define TMS570_DCAN_IF2MSK_Msk_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
673
674
675/*---------------------TMS570_DCANIF2ARB---------------------*/
676/* field: MsgVal - Message Valid */
677#define TMS570_DCAN_IF2ARB_MsgVal BSP_FLD32(31)
678
679/* field: Xtd - Extended Identifier */
680#define TMS570_DCAN_IF2ARB_Xtd BSP_FLD32(30)
681
682/* field: Dir - Message direction */
683#define TMS570_DCAN_IF2ARB_Dir BSP_FLD32(29)
684
685/* field: ID - Message Identifier */
686#define TMS570_DCAN_IF2ARB_ID(val) BSP_FLD32(val,0, 28)
687#define TMS570_DCAN_IF2ARB_ID_GET(reg) BSP_FLD32GET(reg,0, 28)
688#define TMS570_DCAN_IF2ARB_ID_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
689
690
691/*---------------------TMS570_DCANIF2MCTL---------------------*/
692/* field: NewDat - New Data */
693#define TMS570_DCAN_IF2MCTL_NewDat BSP_FLD32(15)
694
695/* field: MsgLst - Message Lost (only valid for message objects with direction = receive) */
696#define TMS570_DCAN_IF2MCTL_MsgLst BSP_FLD32(14)
697
698/* field: IntPnd - Interrupt Pending */
699#define TMS570_DCAN_IF2MCTL_IntPnd BSP_FLD32(13)
700
701/* field: UMask - Use Acceptance Mask */
702#define TMS570_DCAN_IF2MCTL_UMask BSP_FLD32(12)
703
704/* field: TxIE - Transmit Interrupt Enable */
705#define TMS570_DCAN_IF2MCTL_TxIE BSP_FLD32(11)
706
707/* field: RxIE - Receive Interrupt Enable */
708#define TMS570_DCAN_IF2MCTL_RxIE BSP_FLD32(10)
709
710/* field: RmtEn - Remote Enable */
711#define TMS570_DCAN_IF2MCTL_RmtEn BSP_FLD32(9)
712
713/* field: TxRqst - Transmit Request */
714#define TMS570_DCAN_IF2MCTL_TxRqst BSP_FLD32(8)
715
716/* field: EoB - Data Frame has 0-8 data bits */
717#define TMS570_DCAN_IF2MCTL_EoB BSP_FLD32(7)
718
719/* field: DLC - Data Length Code */
720#define TMS570_DCAN_IF2MCTL_DLC(val) BSP_FLD32(val,0, 3)
721#define TMS570_DCAN_IF2MCTL_DLC_GET(reg) BSP_FLD32GET(reg,0, 3)
722#define TMS570_DCAN_IF2MCTL_DLC_SET(reg,val) BSP_FLD32SET(reg, val,0, 3)
723
724
725/*---------------------TMS570_DCANIF2DATA---------------------*/
726/* field: Data0 - Data 0 */
727#define TMS570_DCAN_IF2DATA_Data0(val) BSP_FLD32(val,0, 7)
728#define TMS570_DCAN_IF2DATA_Data0_GET(reg) BSP_FLD32GET(reg,0, 7)
729#define TMS570_DCAN_IF2DATA_Data0_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
730
731/* field: Data1 - Data 1 */
732#define TMS570_DCAN_IF2DATA_Data1(val) BSP_FLD32(val,8, 15)
733#define TMS570_DCAN_IF2DATA_Data1_GET(reg) BSP_FLD32GET(reg,8, 15)
734#define TMS570_DCAN_IF2DATA_Data1_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
735
736/* field: Data2 - Data 2 */
737#define TMS570_DCAN_IF2DATA_Data2(val) BSP_FLD32(val,16, 23)
738#define TMS570_DCAN_IF2DATA_Data2_GET(reg) BSP_FLD32GET(reg,16, 23)
739#define TMS570_DCAN_IF2DATA_Data2_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
740
741/* field: Data3 - Data 3 */
742#define TMS570_DCAN_IF2DATA_Data3(val) BSP_FLD32(val,24, 31)
743#define TMS570_DCAN_IF2DATA_Data3_GET(reg) BSP_FLD32GET(reg,24, 31)
744#define TMS570_DCAN_IF2DATA_Data3_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
745
746
747/*---------------------TMS570_DCANIF2DATB---------------------*/
748/* field: Data4 - Data 4 */
749#define TMS570_DCAN_IF2DATB_Data4(val) BSP_FLD32(val,0, 7)
750#define TMS570_DCAN_IF2DATB_Data4_GET(reg) BSP_FLD32GET(reg,0, 7)
751#define TMS570_DCAN_IF2DATB_Data4_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
752
753/* field: Data5 - Data 5 */
754#define TMS570_DCAN_IF2DATB_Data5(val) BSP_FLD32(val,8, 15)
755#define TMS570_DCAN_IF2DATB_Data5_GET(reg) BSP_FLD32GET(reg,8, 15)
756#define TMS570_DCAN_IF2DATB_Data5_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
757
758/* field: Data6 - Data 6 */
759#define TMS570_DCAN_IF2DATB_Data6(val) BSP_FLD32(val,16, 23)
760#define TMS570_DCAN_IF2DATB_Data6_GET(reg) BSP_FLD32GET(reg,16, 23)
761#define TMS570_DCAN_IF2DATB_Data6_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
762
763/* field: Data7 - Data 7 */
764#define TMS570_DCAN_IF2DATB_Data7(val) BSP_FLD32(val,24, 31)
765#define TMS570_DCAN_IF2DATB_Data7_GET(reg) BSP_FLD32GET(reg,24, 31)
766#define TMS570_DCAN_IF2DATB_Data7_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
767
768
769/*---------------------TMS570_DCANIF3OBS---------------------*/
770/* field: IF3_Upd - IF3 Update Data */
771#define TMS570_DCAN_IF3OBS_IF3_Upd BSP_FLD32(15)
772
773/* field: IF3_SDB - IF3 Status of Data B read access */
774#define TMS570_DCAN_IF3OBS_IF3_SDB BSP_FLD32(12)
775
776/* field: IF3_SDA - IF3 Status of Data A read access */
777#define TMS570_DCAN_IF3OBS_IF3_SDA BSP_FLD32(11)
778
779/* field: IF3_SC - IF3 Status of Control bits read access */
780#define TMS570_DCAN_IF3OBS_IF3_SC BSP_FLD32(10)
781
782/* field: IF3_SA - IF3 Status of Arbitration data read access */
783#define TMS570_DCAN_IF3OBS_IF3_SA BSP_FLD32(9)
784
785/* field: IF3_SM - IF3 Status of Mask data read access */
786#define TMS570_DCAN_IF3OBS_IF3_SM BSP_FLD32(8)
787
788/* field: Data_B - Data B read observation */
789#define TMS570_DCAN_IF3OBS_Data_B BSP_FLD32(4)
790
791/* field: Data_A - Data A read observation */
792#define TMS570_DCAN_IF3OBS_Data_A BSP_FLD32(3)
793
794/* field: Ctrl - Ctrl read observation */
795#define TMS570_DCAN_IF3OBS_Ctrl BSP_FLD32(2)
796
797/* field: Arb - Arbitration data read observation */
798#define TMS570_DCAN_IF3OBS_Arb BSP_FLD32(1)
799
800/* field: Mask - Mask data read observation */
801#define TMS570_DCAN_IF3OBS_Mask BSP_FLD32(0)
802
803
804/*---------------------TMS570_DCANIF3MSK---------------------*/
805/* field: MXtd - Mask Extended Identifier */
806#define TMS570_DCAN_IF3MSK_MXtd BSP_FLD32(31)
807
808/* field: MDir - Mask Message Direction */
809#define TMS570_DCAN_IF3MSK_MDir BSP_FLD32(30)
810
811/* field: Msk - Identifier Mask */
812#define TMS570_DCAN_IF3MSK_Msk(val) BSP_FLD32(val,0, 28)
813#define TMS570_DCAN_IF3MSK_Msk_GET(reg) BSP_FLD32GET(reg,0, 28)
814#define TMS570_DCAN_IF3MSK_Msk_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
815
816
817/*---------------------TMS570_DCANIF3ARB---------------------*/
818/* field: MsgVal - Message Valid */
819#define TMS570_DCAN_IF3ARB_MsgVal BSP_FLD32(31)
820
821/* field: Xtd - Extended Identifier */
822#define TMS570_DCAN_IF3ARB_Xtd BSP_FLD32(30)
823
824/* field: Dir - Message direction */
825#define TMS570_DCAN_IF3ARB_Dir BSP_FLD32(29)
826
827/* field: ID - Message Identifier */
828#define TMS570_DCAN_IF3ARB_ID(val) BSP_FLD32(val,0, 28)
829#define TMS570_DCAN_IF3ARB_ID_GET(reg) BSP_FLD32GET(reg,0, 28)
830#define TMS570_DCAN_IF3ARB_ID_SET(reg,val) BSP_FLD32SET(reg, val,0, 28)
831
832
833/*---------------------TMS570_DCANIF3MCTL---------------------*/
834/* field: NewDat - New Data */
835#define TMS570_DCAN_IF3MCTL_NewDat BSP_FLD32(15)
836
837/* field: MsgLst - Message Lost (only valid for message objects with direction = receive) */
838#define TMS570_DCAN_IF3MCTL_MsgLst BSP_FLD32(14)
839
840/* field: IntPnd - Interrupt Pending */
841#define TMS570_DCAN_IF3MCTL_IntPnd BSP_FLD32(13)
842
843/* field: UMask - Use Acceptance Mask */
844#define TMS570_DCAN_IF3MCTL_UMask BSP_FLD32(12)
845
846/* field: TxIE - Transmit Interrupt Enable */
847#define TMS570_DCAN_IF3MCTL_TxIE BSP_FLD32(11)
848
849/* field: RxIE - Receive Interrupt Enable */
850#define TMS570_DCAN_IF3MCTL_RxIE BSP_FLD32(10)
851
852/* field: RmtEn - Remote Enable */
853#define TMS570_DCAN_IF3MCTL_RmtEn BSP_FLD32(9)
854
855/* field: TxRqst - TxRqst */
856#define TMS570_DCAN_IF3MCTL_TxRqst BSP_FLD32(8)
857
858/* field: EoB - End of Block */
859#define TMS570_DCAN_IF3MCTL_EoB BSP_FLD32(7)
860
861/* field: DLC - Data Length Code */
862#define TMS570_DCAN_IF3MCTL_DLC(val) BSP_FLD32(val,0, 3)
863#define TMS570_DCAN_IF3MCTL_DLC_GET(reg) BSP_FLD32GET(reg,0, 3)
864#define TMS570_DCAN_IF3MCTL_DLC_SET(reg,val) BSP_FLD32SET(reg, val,0, 3)
865
866
867/*---------------------TMS570_DCANIF3DATA---------------------*/
868/* field: Data0 - Data 0 */
869#define TMS570_DCAN_IF3DATA_Data0(val) BSP_FLD32(val,0, 7)
870#define TMS570_DCAN_IF3DATA_Data0_GET(reg) BSP_FLD32GET(reg,0, 7)
871#define TMS570_DCAN_IF3DATA_Data0_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
872
873/* field: Data1 - Data 1 */
874#define TMS570_DCAN_IF3DATA_Data1(val) BSP_FLD32(val,8, 15)
875#define TMS570_DCAN_IF3DATA_Data1_GET(reg) BSP_FLD32GET(reg,8, 15)
876#define TMS570_DCAN_IF3DATA_Data1_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
877
878/* field: Data2 - Data 2 */
879#define TMS570_DCAN_IF3DATA_Data2(val) BSP_FLD32(val,16, 23)
880#define TMS570_DCAN_IF3DATA_Data2_GET(reg) BSP_FLD32GET(reg,16, 23)
881#define TMS570_DCAN_IF3DATA_Data2_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
882
883/* field: Data3 - Data 3 */
884#define TMS570_DCAN_IF3DATA_Data3(val) BSP_FLD32(val,24, 31)
885#define TMS570_DCAN_IF3DATA_Data3_GET(reg) BSP_FLD32GET(reg,24, 31)
886#define TMS570_DCAN_IF3DATA_Data3_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
887
888
889/*---------------------TMS570_DCANIF3DATB---------------------*/
890/* field: Data4 - Data 4 */
891#define TMS570_DCAN_IF3DATB_Data4(val) BSP_FLD32(val,0, 7)
892#define TMS570_DCAN_IF3DATB_Data4_GET(reg) BSP_FLD32GET(reg,0, 7)
893#define TMS570_DCAN_IF3DATB_Data4_SET(reg,val) BSP_FLD32SET(reg, val,0, 7)
894
895/* field: Data5 - Data 5 */
896#define TMS570_DCAN_IF3DATB_Data5(val) BSP_FLD32(val,8, 15)
897#define TMS570_DCAN_IF3DATB_Data5_GET(reg) BSP_FLD32GET(reg,8, 15)
898#define TMS570_DCAN_IF3DATB_Data5_SET(reg,val) BSP_FLD32SET(reg, val,8, 15)
899
900/* field: Data6 - Data 6 */
901#define TMS570_DCAN_IF3DATB_Data6(val) BSP_FLD32(val,16, 23)
902#define TMS570_DCAN_IF3DATB_Data6_GET(reg) BSP_FLD32GET(reg,16, 23)
903#define TMS570_DCAN_IF3DATB_Data6_SET(reg,val) BSP_FLD32SET(reg, val,16, 23)
904
905/* field: Data7 - Data 7 */
906#define TMS570_DCAN_IF3DATB_Data7(val) BSP_FLD32(val,24, 31)
907#define TMS570_DCAN_IF3DATB_Data7_GET(reg) BSP_FLD32GET(reg,24, 31)
908#define TMS570_DCAN_IF3DATB_Data7_SET(reg,val) BSP_FLD32SET(reg, val,24, 31)
909
910
911/*---------------------TMS570_DCANIF3UEy---------------------*/
912/* field: IF3UpdEn - IF3 Update Enabled (for all message objects) */
913#define TMS570_DCAN_IF3UEy_IF3UpdEn(val) BSP_FLD32(val,0, 31)
914#define TMS570_DCAN_IF3UEy_IF3UpdEn_GET(reg) BSP_FLD32GET(reg,0, 31)
915#define TMS570_DCAN_IF3UEy_IF3UpdEn_SET(reg,val) BSP_FLD32SET(reg, val,0, 31)
916
917
918/*----------------------TMS570_DCANTIOC----------------------*/
919/* field: PU - CAN_TX Pullup/Pulldown select. This bit is only active when CAN_TX is configured to be an input. */
920#define TMS570_DCAN_TIOC_PU BSP_FLD32(18)
921
922/* field: PD - CAN_TX pull disable. This bit is only active when CAN_TX is configured to be an input. */
923#define TMS570_DCAN_TIOC_PD BSP_FLD32(17)
924
925/* field: OD - CAN_TX open drain enable. */
926#define TMS570_DCAN_TIOC_OD BSP_FLD32(16)
927
928/* field: Func - CAN_TX function. This bit changes the function of the CAN_TX pin. */
929#define TMS570_DCAN_TIOC_Func BSP_FLD32(3)
930
931/* field: Dir - CAN_TX data direction. */
932#define TMS570_DCAN_TIOC_Dir BSP_FLD32(2)
933
934/* field: Out - CAN_TX data out write. */
935#define TMS570_DCAN_TIOC_Out BSP_FLD32(1)
936
937
938/*----------------------TMS570_DCANRIOC----------------------*/
939/* field: PU - CAN_RX Pullup/Pulldown select. This bit is only active when CAN_RX is configured to be an input. */
940#define TMS570_DCAN_RIOC_PU BSP_FLD32(18)
941
942/* field: PD - CAN_RX pull disable. This bit is only active when CAN_RX is configured to be an input. */
943#define TMS570_DCAN_RIOC_PD BSP_FLD32(17)
944
945/* field: OD - CAN_RX open drain enable. */
946#define TMS570_DCAN_RIOC_OD BSP_FLD32(16)
947
948/* field: Func - CAN_RX function. This bit changes the function of the CAN_RX pin. */
949#define TMS570_DCAN_RIOC_Func BSP_FLD32(3)
950
951/* field: Dir - CAN_RX data direction. */
952#define TMS570_DCAN_RIOC_Dir BSP_FLD32(2)
953
954/* field: Out - CAN_RX data out write. */
955#define TMS570_DCAN_RIOC_Out BSP_FLD32(1)
956
957/* field: In - CAN_RX data in. */
958#define TMS570_DCAN_RIOC_In BSP_FLD32(0)
959
960
961
962#endif /* LIBBSP_ARM_tms570_DCAN */
Note: See TracBrowser for help on using the repository browser.