init:全链路闭环控制调通
This commit is contained in:
@@ -5,16 +5,25 @@
|
||||
* @v2CliArgs --device "MSPM0G3507" --package "LQFP-64(PM)" --product "mspm0_sdk@2.04.00.06"
|
||||
* @versions {"tool":"1.23.1+4034"}
|
||||
*/
|
||||
scripting.excludeFromBuild("device_linker.cmd");
|
||||
scripting.excludeFromBuild("device_linker.lds");
|
||||
scripting.excludeFromBuild("device.opt");
|
||||
scripting.excludeFromBuild("device.cmd.genlibs");
|
||||
scripting.excludeFromBuild("device.lds.genlibs");
|
||||
scripting.excludeFromBuild("Event.dot");
|
||||
|
||||
/**
|
||||
* Import the modules used in this configuration.
|
||||
*/
|
||||
const GPIO = scripting.addModule("/ti/driverlib/GPIO", {}, false);
|
||||
const GPIO1 = GPIO.addInstance();
|
||||
const GPIO2 = GPIO.addInstance();
|
||||
const SYSCTL = scripting.addModule("/ti/driverlib/SYSCTL");
|
||||
const SYSTICK = scripting.addModule("/ti/driverlib/SYSTICK");
|
||||
const VREF = scripting.addModule("/ti/driverlib/VREF");
|
||||
const GPIO = scripting.addModule("/ti/driverlib/GPIO", {}, false);
|
||||
const GPIO1 = GPIO.addInstance();
|
||||
const GPIO2 = GPIO.addInstance();
|
||||
const QEI = scripting.addModule("/ti/driverlib/QEI", {}, false);
|
||||
const QEI1 = QEI.addInstance();
|
||||
const SYSCTL = scripting.addModule("/ti/driverlib/SYSCTL");
|
||||
const SYSTICK = scripting.addModule("/ti/driverlib/SYSTICK");
|
||||
const VREF = scripting.addModule("/ti/driverlib/VREF");
|
||||
const ProjectConfig = scripting.addModule("/ti/project_config/ProjectConfig");
|
||||
|
||||
/**
|
||||
* Write custom configuration values to the imported modules.
|
||||
@@ -79,6 +88,13 @@ GPIO2.associatedPins[0].interruptEn = true;
|
||||
GPIO2.associatedPins[0].polarity = "RISE";
|
||||
GPIO2.associatedPins[0].pin.$assign = "PA18";
|
||||
|
||||
QEI1.$name = "QEI_0";
|
||||
QEI1.peripheral.$assign = "TIMG8";
|
||||
QEI1.peripheral.ccp0Pin.$assign = "PB6";
|
||||
QEI1.peripheral.ccp1Pin.$assign = "PB7";
|
||||
QEI1.ccp0PinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric0";
|
||||
QEI1.ccp1PinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric1";
|
||||
|
||||
SYSCTL.forceDefaultClkConfig = true;
|
||||
SYSCTL.clockTreeEn = true;
|
||||
scripting.suppress("For best practices when the CPUCLK is running at 32MHz and above, clear the flash status bit using DL_FlashCTL_executeClearStatus\\(\\) before executing any flash operation\\. Otherwise there may be false positives\\.", SYSCTL);
|
||||
@@ -98,6 +114,8 @@ VREF.peripheral.vrefPosPin.$assign = "PA23";
|
||||
VREF.peripheral.vrefNegPin.$assign = "PA21";
|
||||
VREF.vrefNegPinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric30";
|
||||
|
||||
ProjectConfig.genLibIQVersion = "MATHACL";
|
||||
|
||||
/**
|
||||
* Pinmux solution for unlocked pins/peripherals. This ensures that minor changes to the automatic solver in a future
|
||||
* version of the tool will not impact the pinmux you originally saw. These lines can be completely deleted in order to
|
||||
|
||||
Reference in New Issue
Block a user