|
@@ -9,6 +9,7 @@
|
|
|
/**
|
|
/**
|
|
|
* Import the modules used in this configuration.
|
|
* Import the modules used in this configuration.
|
|
|
*/
|
|
*/
|
|
|
|
|
+const Board = scripting.addModule("/ti/driverlib/Board");
|
|
|
const GPIO = scripting.addModule("/ti/driverlib/GPIO", {}, false);
|
|
const GPIO = scripting.addModule("/ti/driverlib/GPIO", {}, false);
|
|
|
const GPIO1 = GPIO.addInstance();
|
|
const GPIO1 = GPIO.addInstance();
|
|
|
const GPIO2 = GPIO.addInstance();
|
|
const GPIO2 = GPIO.addInstance();
|
|
@@ -19,23 +20,27 @@ const I2C2 = I2C.addInstance();
|
|
|
const PWM = scripting.addModule("/ti/driverlib/PWM", {}, false);
|
|
const PWM = scripting.addModule("/ti/driverlib/PWM", {}, false);
|
|
|
const PWM1 = PWM.addInstance();
|
|
const PWM1 = PWM.addInstance();
|
|
|
const SYSCTL = scripting.addModule("/ti/driverlib/SYSCTL");
|
|
const SYSCTL = scripting.addModule("/ti/driverlib/SYSCTL");
|
|
|
|
|
+const WWDT = scripting.addModule("/ti/driverlib/WWDT", {}, false);
|
|
|
|
|
+const WWDT1 = WWDT.addInstance();
|
|
|
const ProjectConfig = scripting.addModule("/ti/project_config/ProjectConfig");
|
|
const ProjectConfig = scripting.addModule("/ti/project_config/ProjectConfig");
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* Write custom configuration values to the imported modules.
|
|
* Write custom configuration values to the imported modules.
|
|
|
*/
|
|
*/
|
|
|
-GPIO1.$name = "GPIO_Battery_Charging";
|
|
|
|
|
-GPIO1.port = "PORTB";
|
|
|
|
|
-GPIO1.associatedPins[0].$name = "PIN_PB6";
|
|
|
|
|
-
|
|
|
|
|
-const Board = scripting.addModule("/ti/driverlib/Board", {}, false);
|
|
|
|
|
|
|
+Board.configureUnused = true;
|
|
|
Board.peripheral.$assign = "DEBUGSS";
|
|
Board.peripheral.$assign = "DEBUGSS";
|
|
|
Board.peripheral.swclkPin.$assign = "PA20";
|
|
Board.peripheral.swclkPin.$assign = "PA20";
|
|
|
Board.peripheral.swdioPin.$assign = "PA19";
|
|
Board.peripheral.swdioPin.$assign = "PA19";
|
|
|
|
|
|
|
|
-GPIO2.$name = "GPIO_Battery_Discharging";
|
|
|
|
|
-GPIO2.port = "PORTB";
|
|
|
|
|
-GPIO2.associatedPins[0].$name = "PIN_PB7";
|
|
|
|
|
|
|
+GPIO1.$name = "GPIO_Battery_Charging";
|
|
|
|
|
+GPIO1.port = "PORTB";
|
|
|
|
|
+GPIO1.associatedPins[0].$name = "PIN_PB6";
|
|
|
|
|
+GPIO1.associatedPins[0].pin.$assign = "PB6";
|
|
|
|
|
+
|
|
|
|
|
+GPIO2.$name = "GPIO_Battery_Discharging";
|
|
|
|
|
+GPIO2.port = "PORTB";
|
|
|
|
|
+GPIO2.associatedPins[0].$name = "PIN_PB7";
|
|
|
|
|
+GPIO2.associatedPins[0].pin.$assign = "PB7";
|
|
|
|
|
|
|
|
GPIO3.port = "PORTA";
|
|
GPIO3.port = "PORTA";
|
|
|
GPIO3.$name = "GPIO_ADDR_PINS";
|
|
GPIO3.$name = "GPIO_ADDR_PINS";
|
|
@@ -85,6 +90,11 @@ PWM1.ccp0PinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric4";
|
|
|
|
|
|
|
|
SYSCTL.peripheral.$assign = "SYSCTL";
|
|
SYSCTL.peripheral.$assign = "SYSCTL";
|
|
|
|
|
|
|
|
|
|
+WWDT1.$name = "WWDT0";
|
|
|
|
|
+WWDT1.wwdtMode = "INTERVAL";
|
|
|
|
|
+WWDT1.sleepMode = true;
|
|
|
|
|
+WWDT1.enabledInterrupts = true;
|
|
|
|
|
+
|
|
|
ProjectConfig.migrationCondition = true;
|
|
ProjectConfig.migrationCondition = true;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -92,6 +102,5 @@ ProjectConfig.migrationCondition = true;
|
|
|
* version of the tool will not impact the pinmux you originally saw. These lines can be completely deleted in order to
|
|
* version of the tool will not impact the pinmux you originally saw. These lines can be completely deleted in order to
|
|
|
* re-solve from scratch.
|
|
* re-solve from scratch.
|
|
|
*/
|
|
*/
|
|
|
-GPIO1.associatedPins[0].pin.$suggestSolution = "PB3";
|
|
|
|
|
-GPIO2.associatedPins[0].pin.$suggestSolution = "PB2";
|
|
|
|
|
-PWM1.peripheral.$suggestSolution = "TIMG0";
|
|
|
|
|
|
|
+PWM1.peripheral.$suggestSolution = "TIMG0";
|
|
|
|
|
+WWDT1.peripheral.$suggestSolution = "WWDT0";
|