Skip to content

Commit 81dc8f8

Browse files
committed
STM32: correct __cplusplus brackets in ci2c_device.h
1 parent 073c82e commit 81dc8f8

File tree

15 files changed

+49
-11
lines changed

15 files changed

+49
-11
lines changed

targets/TARGET_STM/TARGET_STM32F0/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
5353
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
5454
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5555

56+
#endif // DEVICE_I2C
57+
5658
#ifdef __cplusplus
5759
}
5860
#endif
59-
#endif // DEVICE_I2C
61+
6062
#endif

targets/TARGET_STM/TARGET_STM32F1/i2c_device.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,8 @@ extern "C" {
4545

4646
#endif // DEVICE_I2C
4747

48+
#ifdef __cplusplus
49+
}
50+
#endif
51+
4852
#endif

targets/TARGET_STM/TARGET_STM32F2/i2c_device.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,8 @@ extern "C" {
4444

4545
#endif // DEVICE_I2C
4646

47+
#ifdef __cplusplus
48+
}
49+
#endif
50+
4751
#endif

targets/TARGET_STM/TARGET_STM32F3/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
6767
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
6868
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
6969

70+
#endif // DEVICE_I2C
71+
7072
#ifdef __cplusplus
7173
}
7274
#endif
73-
#endif // DEVICE_I2C
75+
7476
#endif

targets/TARGET_STM/TARGET_STM32F4/i2c_device.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,8 @@ extern "C" {
3131

3232
#endif // DEVICE_I2C
3333

34+
#ifdef __cplusplus
35+
}
36+
#endif
37+
3438
#endif

targets/TARGET_STM/TARGET_STM32F7/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
6262
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
6363
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
6464

65+
#endif // DEVICE_I2C
66+
6567
#ifdef __cplusplus
6668
}
6769
#endif
68-
#endif // DEVICE_I2C
70+
6971
#endif

targets/TARGET_STM/TARGET_STM32G0/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
5252
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
5353
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5454

55+
#endif // DEVICE_I2C
56+
5557
#ifdef __cplusplus
5658
}
5759
#endif
58-
#endif // DEVICE_I2C
60+
5961
#endif

targets/TARGET_STM/TARGET_STM32G4/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
4848
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
4949
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5050

51+
#endif // DEVICE_I2C
52+
5153
#ifdef __cplusplus
5254
}
5355
#endif
54-
#endif // DEVICE_I2C
56+
5557
#endif

targets/TARGET_STM/TARGET_STM32H7/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
4848
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
4949
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5050

51+
#endif // DEVICE_I2C
52+
5153
#ifdef __cplusplus
5254
}
5355
#endif
54-
#endif // DEVICE_I2C
56+
5557
#endif

targets/TARGET_STM/TARGET_STM32L0/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
5959
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
6060
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
6161

62+
#endif // DEVICE_I2C
63+
6264
#ifdef __cplusplus
6365
}
6466
#endif
65-
#endif // DEVICE_I2C
67+
6668
#endif

targets/TARGET_STM/TARGET_STM32L1/i2c_device.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,8 @@ extern "C" {
3131

3232
#endif // DEVICE_I2C
3333

34+
#ifdef __cplusplus
35+
}
36+
#endif
37+
3438
#endif

targets/TARGET_STM/TARGET_STM32L4/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
6262
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
6363
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
6464

65+
#endif // DEVICE_I2C
66+
6567
#ifdef __cplusplus
6668
}
6769
#endif
68-
#endif // DEVICE_I2C
70+
6971
#endif

targets/TARGET_STM/TARGET_STM32L5/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
4848
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
4949
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5050

51+
#endif // DEVICE_I2C
52+
5153
#ifdef __cplusplus
5254
}
5355
#endif
54-
#endif // DEVICE_I2C
56+
5557
#endif

targets/TARGET_STM/TARGET_STM32WB/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
5555
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
5656
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
5757

58+
#endif // DEVICE_I2C
59+
5860
#ifdef __cplusplus
5961
}
6062
#endif
61-
#endif // DEVICE_I2C
63+
6264
#endif

targets/TARGET_STM/TARGET_STM32WL/i2c_device.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,10 @@ uint32_t i2c_get_timing(I2CName i2c, int hz);
4747
void i2c_compute_presc_scldel_sdadel(uint32_t clock_src_freq, uint32_t I2C_speed);
4848
uint32_t i2c_compute_scll_sclh(uint32_t clock_src_freq, uint32_t I2C_speed);
4949

50+
#endif // DEVICE_I2C
51+
5052
#ifdef __cplusplus
5153
}
5254
#endif
53-
#endif // DEVICE_I2C
55+
5456
#endif

0 commit comments

Comments
 (0)