use of net.sourceforge.usbdm.deviceEditor.information.PcrInitialiser in project usbdm-eclipse-plugins by podonoghue.
the class WriteFamilyCpp method writePinMappingFunction.
private void writePinMappingFunction(DocumentUtilities writer) throws Exception {
PcrInitialiser pcrInitialiser = new PcrInitialiser();
for (String pinName : fDeviceInfo.getPins().keySet()) {
Pin pin = fDeviceInfo.getPins().get(pinName);
pcrInitialiser.addPin(pin);
}
writer.write("/**\n" + " * Used to configure pin-mapping before 1st use of peripherals\n" + " */\n" + "void " + DO_PIN_MAPPING_FUNCTION + "() {\n");
writer.write(pcrInitialiser.getInitPortClocksStatement(""));
writer.write(pcrInitialiser.getPcrInitStatements(""));
writer.write("}\n");
}
Aggregations