export board-specific macro for stm32 pins based on board yaml #3298
This commit is contained in:
parent
6a4f514cdd
commit
46ebb1c18c
|
@ -62,7 +62,7 @@ pins:
|
|||
- pin: K15
|
||||
meta: H144_IN_D_AUX4
|
||||
function: 'Cam Sensor (2014: yellow)'
|
||||
class: [event_inputs]
|
||||
class: event_inputs
|
||||
ts_name: Cam - K15
|
||||
|
||||
- pin: K16
|
||||
|
@ -72,13 +72,13 @@ pins:
|
|||
- pin: K17b
|
||||
function: Crank Sensor
|
||||
meta: H144_IN_CRANK
|
||||
class: [event_inputs]
|
||||
class: event_inputs
|
||||
ts_name: Crank - K17 rev B
|
||||
|
||||
- pin: K17c
|
||||
function: "Crank Sensor (2014: pink)"
|
||||
meta: H144_IN_SENS2
|
||||
class: [event_inputs]
|
||||
class: event_inputs
|
||||
ts_name: Crank - K17 rev C
|
||||
|
||||
- pin: K21
|
||||
|
|
|
@ -185,6 +185,10 @@ public class PinoutLogic {
|
|||
if (pinIdString.length() == 0) {
|
||||
throw new IllegalStateException("Unexpected empty ID field");
|
||||
}
|
||||
if (!(pinTsName instanceof String))
|
||||
throw new IllegalStateException("Wrong type: " + pinTsName.getClass() + " while " + pinIdString);
|
||||
if (!(pinClass instanceof String))
|
||||
throw new IllegalStateException("Wrong type: " + pinClass.getClass() + " while " + pinIdString);
|
||||
addPinToList(pinIdString, (String) pinTsName, (String) pinClass);
|
||||
} else {
|
||||
throw new IllegalStateException("Unexpected type of ID field: " + pinId.getClass().getSimpleName());
|
||||
|
|
Loading…
Reference in New Issue