Skip to content

Commit 66162c6

Browse files
committed
STM32: move can_s definition to common_objects.h
This will ease up further changes to the structure.
1 parent 5bddd88 commit 66162c6

File tree

31 files changed

+42
-127
lines changed

31 files changed

+42
-127
lines changed

targets/TARGET_STM/TARGET_STM32F0/TARGET_NUCLEO_F042K6/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F0/TARGET_NUCLEO_F072RB/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F0/TARGET_NUCLEO_F091RC/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F0/common_objects.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,13 @@ struct dac_s {
128128
};
129129
#endif
130130

131+
#if DEVICE_CAN
132+
struct can_s {
133+
CANName can;
134+
int index;
135+
};
136+
#endif
137+
131138
#ifdef __cplusplus
132139
}
133140
#endif

targets/TARGET_STM/TARGET_STM32F1/TARGET_BLUEPILL_F103C8/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F1/TARGET_NUCLEO_F103RB/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F1/common_objects.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,13 @@ struct analogin_s {
116116
uint8_t channel;
117117
};
118118

119+
#if DEVICE_CAN
120+
struct can_s {
121+
CANName can;
122+
int index;
123+
};
124+
#endif
125+
119126
#include "gpio_object.h"
120127

121128
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F3/TARGET_STM32F302x8/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F3/TARGET_STM32F303x8/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

targets/TARGET_STM/TARGET_STM32F3/TARGET_STM32F303xC/objects.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ struct port_s {
5454
__IO uint32_t *reg_out;
5555
};
5656

57-
struct can_s {
58-
CANName can;
59-
int index;
60-
};
61-
6257
#include "common_objects.h"
6358

6459
#ifdef __cplusplus

0 commit comments

Comments
 (0)