|
12 | 12 | #define gpio_led gpioc |
13 | 13 | #define pin_led 13 |
14 | 14 |
|
15 | | -const static struct pin_mapping _msel_pins_std[] = { |
16 | | - { 10, _B, 11 }, |
17 | | - { 14, _B, 10 }, |
18 | | - { 0, 0, 0 } |
19 | | -}; |
20 | | - |
21 | | -const static struct pin_mapping _msel_pins_f1_plus[] = { |
22 | | - { 10, _B, 11 }, |
23 | | - { 12, _B, 0 }, |
24 | | - { 14, _B, 10 }, |
25 | | - { 16, _B, 1 }, |
26 | | - { 0, 0, 0 } |
27 | | -}; |
28 | | - |
29 | 15 | const static struct pin_mapping _user_pins_std[] = { |
30 | | - { 2, _B, 9, _OD }, |
31 | | - { 0, 0, 0, _OD } }; |
| 16 | + { 2, _B, 9, _OD }, |
| 17 | + { 10, _B, 11, _OD }, |
| 18 | + { 14, _B, 10, _OD }, |
| 19 | + { 0, 0, 0, _OD } }; |
| 20 | + |
32 | 21 | const static struct pin_mapping _user_pins_f1_plus[] = { |
33 | | - { 2, _B, 9, _PP }, |
34 | | - { 4, _A, 3, _PP }, |
35 | | - { 6, _A, 1, _PP }, |
36 | | - { 0, 0, 0, _PP } }; |
| 22 | + { 2, _B, 9, _PP }, |
| 23 | + { 4, _A, 3, _PP }, |
| 24 | + { 6, _A, 1, _PP }, |
| 25 | + { 10, _B, 11, _PP }, |
| 26 | + { 12, _B, 0, _PP }, |
| 27 | + { 14, _B, 10, _PP }, |
| 28 | + { 16, _B, 1, _PP }, |
| 29 | + { 0, 0, 0, _PP } }; |
| 30 | + |
37 | 31 | const static struct pin_mapping _user_pins_f1_plus_unbuffered[] = { |
38 | | - { 2, _B, 9, _OD }, |
39 | | - { 4, _A, 3, _OD }, |
40 | | - { 6, _A, 1, _OD }, |
41 | | - { 0, 0, 0, _OD } }; |
| 32 | + { 2, _B, 9, _OD }, |
| 33 | + { 4, _A, 3, _OD }, |
| 34 | + { 6, _A, 1, _OD }, |
| 35 | + { 10, _B, 11, _OD }, |
| 36 | + { 12, _B, 0, _OD }, |
| 37 | + { 14, _B, 10, _OD }, |
| 38 | + { 16, _B, 1, _OD }, |
| 39 | + { 0, 0, 0, _OD } }; |
42 | 40 |
|
43 | 41 | const static struct board_config _board_config[] = { |
44 | 42 | [F1SM_basic] = { |
45 | 43 | .flippy = FALSE, |
46 | | - .user_pins = _user_pins_std, |
47 | | - .msel_pins = _msel_pins_std }, |
| 44 | + .user_pins = _user_pins_std }, |
48 | 45 | [F1SM_plus] = { |
49 | 46 | .flippy = TRUE, |
50 | | - .user_pins = _user_pins_f1_plus, |
51 | | - .msel_pins = _msel_pins_f1_plus }, |
| 47 | + .user_pins = _user_pins_f1_plus }, |
52 | 48 | [F1SM_plus_unbuffered] = { |
53 | 49 | .flippy = TRUE, |
54 | | - .user_pins = _user_pins_f1_plus_unbuffered, |
55 | | - .msel_pins = _msel_pins_f1_plus } |
| 50 | + .user_pins = _user_pins_f1_plus_unbuffered } |
56 | 51 | }; |
57 | 52 |
|
58 | 53 | /* Blink the activity LED to indicate fatal error. */ |
@@ -121,15 +116,10 @@ static void mcu_board_init(void) |
121 | 116 | [_B] = 0x0e27, /* PB0-2,5,9-11 */ |
122 | 117 | [_C] = 0xffff, /* PC0-15 */ |
123 | 118 | }; |
124 | | - const struct pin_mapping *mpin; |
125 | 119 | const struct pin_mapping *upin; |
126 | 120 |
|
127 | 121 | identify_board_config(); |
128 | 122 |
|
129 | | - /* MSEL pins: do not default these pins to pull-up mode. */ |
130 | | - for (mpin = board_config->msel_pins; mpin->pin_id != 0; mpin++) |
131 | | - pu[mpin->gpio_bank] &= ~(1u << mpin->gpio_pin); |
132 | | - |
133 | 123 | /* User pins: do not default these pins to pull-up mode. */ |
134 | 124 | for (upin = board_config->user_pins; upin->pin_id != 0; upin++) |
135 | 125 | pu[upin->gpio_bank] &= ~(1u << upin->gpio_pin); |
|
0 commit comments