Skip to content

Commit ab43896

Browse files
mnkpcarlescufi
authored andcommitted
patch: same70, same70b: Align naming of TcChannel in TC
Change naming of TC_CHANNEL to TcChannel in Tc struct to align with a new convention used by samv71, samv71b series. Signed-off-by: Piotr Mienkowski <[email protected]>
1 parent 02a0d4f commit ab43896

File tree

6 files changed

+9
-24
lines changed
  • asf/sam/include

6 files changed

+9
-24
lines changed

asf/sam/include/sam3x/component/tc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ typedef struct {
5656
/** \brief Tc hardware registers */
5757
#define TCCHANNEL_NUMBER 3
5858
typedef struct {
59-
TcChannel TC_CHANNEL[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
59+
TcChannel TcChannel[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
6060
__O uint32_t TC_BCR; /**< \brief (Tc Offset: 0xC0) Block Control Register */
6161
__IO uint32_t TC_BMR; /**< \brief (Tc Offset: 0xC4) Block Mode Register */
6262
__O uint32_t TC_QIER; /**< \brief (Tc Offset: 0xC8) QDEC Interrupt Enable Register */

asf/sam/include/sam4e/component/tc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ typedef struct {
7070
#define TCCHANNEL_NUMBER 3
7171
#define TCPDC_NUMBER 3
7272
typedef struct {
73-
TcChannel TC_CHANNEL[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
73+
TcChannel TcChannel[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
7474
WoReg TC_BCR; /**< \brief (Tc Offset: 0xC0) Block Control Register */
7575
RwReg TC_BMR; /**< \brief (Tc Offset: 0xC4) Block Mode Register */
7676
WoReg TC_QIER; /**< \brief (Tc Offset: 0xC8) QDEC Interrupt Enable Register */

asf/sam/include/sam4l/component/tc.h

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1202,23 +1202,7 @@ typedef union {
12021202

12031203
/** \brief TcChannel hardware registers */
12041204
#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))
1205-
typedef union {
1206-
struct {
1207-
__O TC_CCR_Type CCR; /**< \brief Offset: 0x00 ( /W 32) Channel Control Register Channel */
1208-
__IO TC_CMR_Type CMR; /**< \brief Offset: 0x04 (R/W 32) Channel Mode Register Channel */
1209-
__IO TC_SMMR_Type SMMR; /**< \brief Offset: 0x08 (R/W 32) Stepper Motor Mode Register */
1210-
RoReg8 Reserved1[0x4];
1211-
__I TC_CV_Type CV; /**< \brief Offset: 0x10 (R/ 32) Counter Value Channel */
1212-
__IO TC_RA_Type RA; /**< \brief Offset: 0x14 (R/W 32) Register A Channel */
1213-
__IO TC_RB_Type RB; /**< \brief Offset: 0x18 (R/W 32) Register B Channel */
1214-
__IO TC_RC_Type RC; /**< \brief Offset: 0x1C (R/W 32) Register C Channel */
1215-
__I TC_SR_Type SR; /**< \brief Offset: 0x20 (R/ 32) Status Register Channel */
1216-
__O TC_IER_Type IER; /**< \brief Offset: 0x24 ( /W 32) Interrupt Enable Register Channel */
1217-
__O TC_IDR_Type IDR; /**< \brief Offset: 0x28 ( /W 32) Interrupt Disable Register Channel */
1218-
__I TC_IMR_Type IMR; /**< \brief Offset: 0x2C (R/ 32) Interrupt Mask Register Channel */
1219-
RoReg8 Reserved2[0x10];
1220-
} bf;
1221-
struct {
1205+
typedef struct {
12221206
WoReg TC_CCR; /**< \brief (TC Offset: 0x00) Channel Control Register Channel */
12231207
RwReg TC_CMR; /**< \brief (TC Offset: 0x04) Channel Mode Register Channel */
12241208
RwReg TC_SMMR; /**< \brief (TC Offset: 0x08) Stepper Motor Mode Register */
@@ -1232,14 +1216,15 @@ typedef union {
12321216
WoReg TC_IDR; /**< \brief (TC Offset: 0x28) Interrupt Disable Register Channel */
12331217
RoReg TC_IMR; /**< \brief (TC Offset: 0x2C) Interrupt Mask Register Channel */
12341218
RoReg8 Reserved4[0x10];
1235-
} reg;
12361219
} TcChannel;
12371220
#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */
12381221

1222+
#define TCCHANNEL_NUMBER 3
1223+
12391224
/** \brief TC hardware registers */
12401225
#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))
12411226
typedef struct {
1242-
__IO uint32_t Channel[3]; /**< \brief Offset: 0x00 TcChannel groups */
1227+
TcChannel TcChannel[3];/**< \brief Offset: 0x00 TcChannel groups */
12431228
__O uint32_t BCR; /**< \brief Offset: 0xC0 ( /W 32) TC Block Control Register */
12441229
__IO uint32_t BMR; /**< \brief Offset: 0xC4 (R/W 32) TC Block Mode Register */
12451230
RoReg8 Reserved1[0x1C];

asf/sam/include/sam4s/component/tc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ typedef struct {
5656
/** \brief Tc hardware registers */
5757
#define TCCHANNEL_NUMBER 3
5858
typedef struct {
59-
TcChannel TC_CHANNEL[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
59+
TcChannel TcChannel[TCCHANNEL_NUMBER]; /**< \brief (Tc Offset: 0x0) channel = 0 .. 2 */
6060
__O uint32_t TC_BCR; /**< \brief (Tc Offset: 0xC0) Block Control Register */
6161
__IO uint32_t TC_BMR; /**< \brief (Tc Offset: 0xC4) Block Mode Register */
6262
__O uint32_t TC_QIER; /**< \brief (Tc Offset: 0xC8) QDEC Interrupt Enable Register */

asf/sam/include/same70/component/tc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1104,7 +1104,7 @@ typedef struct {
11041104
#define TCCHANNEL_NUMBER 3
11051105
/** \brief TC hardware registers */
11061106
typedef struct {
1107-
TcChannel TC_CHANNEL[TCCHANNEL_NUMBER]; /**< Offset: 0x00 Channel Control Register (channel = 0) */
1107+
TcChannel TcChannel[TCCHANNEL_NUMBER]; /**< Offset: 0x00 Channel Control Register (channel = 0) */
11081108
__O uint32_t TC_BCR; /**< (TC Offset: 0xC0) Block Control Register */
11091109
__IO uint32_t TC_BMR; /**< (TC Offset: 0xC4) Block Mode Register */
11101110
__O uint32_t TC_QIER; /**< (TC Offset: 0xC8) QDEC Interrupt Enable Register */

asf/sam/include/same70b/component/tc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1095,7 +1095,7 @@ typedef struct {
10951095
#define TCCHANNEL_NUMBER 3
10961096
/** \brief TC hardware registers */
10971097
typedef struct {
1098-
TcChannel TC_CHANNEL[TCCHANNEL_NUMBER]; /**< Offset: 0x00 Channel Control Register (channel = 0) */
1098+
TcChannel TcChannel[TCCHANNEL_NUMBER]; /**< Offset: 0x00 Channel Control Register (channel = 0) */
10991099
__O uint32_t TC_BCR; /**< (TC Offset: 0xC0) Block Control Register */
11001100
__IO uint32_t TC_BMR; /**< (TC Offset: 0xC4) Block Mode Register */
11011101
__O uint32_t TC_QIER; /**< (TC Offset: 0xC8) QDEC Interrupt Enable Register */

0 commit comments

Comments
 (0)