Part Number:LAUNCHXL-F2800137Other Parts Discussed in Thread: C2000WARE
软件采用C:\ti\c2000\C2000Ware_MotorControl_SDK_4_02_01_00\solutions\universal_motorcontrol_lab\f280013x工程,硬件采用LAUNCHXL-F2800137+DRV5353公版电机转不起来,根据TI开发文档spruj26-Universal Motor Control Project and Lab User’s Guide,设置DMC_BUILDLEVEL DMC_LEVEL_1,编译烧录debug->resume,systemVars.flagEnableSystem符合开发文档自动变成1,然后修改motorVars_M1.flagEnableRunAndIdentify为1,motorVars_M1.faultMtrPrev.bit.overvoltage变成了1,查找代码,initMotor1CtrlParameters()初始化时设置的objSets->overVoltageFault_V = USER_M1_OVER_VOLTAGE_FAULT_V;为40V,runMotorMonitor()中判断条件中if(obj->adcData.VdcBus_V > objSets->overVoltageFault_V)确是成立的,导致motorVars_M1.faultMtrPrev.bit.overvoltage被设置成了1. 实际上我的电源是24V,bj->adcData.VdcBus_V采样值是23点几V,objSets->overVoltageFault_V在判断条件这里变成了0. 请问这个问题怎么解啊?
Ben Qin:
你好,user guide 中推荐的电压是多少?请按照user guide推荐的电压来。
,
Ben Qin:
你好,user guide 中推荐的电压是多少?请按照user guide推荐的电压来。
,
liang zuxing:
从user guide 中截图看,dcData.VdcBus_V采样值是23点几V可以确定推荐值是24V。代码默认的电压设置如下:
//! \brief DC bus over voltage threshold#define USER_M1_OVER_VOLTAGE_FAULT_V (40.0f)
//! \brief DC bus over voltage threshold#define USER_M1_OVER_VOLTAGE_NORM_V (36.0f)
//! \brief DC bus under voltage threshold#define USER_M1_UNDER_VOLTAGE_FAULT_V (10.0f)
//! \brief DC bus under voltage threshold#define USER_M1_UNDER_VOLTAGE_NORM_V (12.0f)
电机初始化里按照上面的值设置:
objSets->overVoltageFault_V = USER_M1_OVER_VOLTAGE_FAULT_V; objSets->overVoltageNorm_V = USER_M1_OVER_VOLTAGE_NORM_V; objSets->underVoltageFault_V = USER_M1_UNDER_VOLTAGE_FAULT_V; objSets->underVoltageNorm_V = USER_M1_UNDER_VOLTAGE_NORM_V;
问题焦点是runMotorMonitor()为什么会判断出obj->faultMtrNow.bit.overVoltage = 1?
// Check if DC bus voltage is over threshold if(obj->adcData.VdcBus_V > objSets->overVoltageFault_V) { if(obj->overVoltageTimeCnt > objSets->voltageFaultTimeSet) { obj->faultMtrNow.bit.overVoltage = 1; } else { obj->overVoltageTimeCnt++; } }
,
Ben Qin:
我咨询下相关资深工程师后回复您。
,
liang zuxing:
感谢Ben Qin支持,错误原因找到了,去掉DAC128S模块预定义,错误就没有了。但是新的问题出现了,电机设置motorVars_M1.speedRef_Hz = 60.0f,实际转速motorVars_M1.speed_Hz不到3,请Ben Qin帮忙分析原因
,
liang zuxing:
再补充一点,电机启动瞬间转速快,噪音小,但是稳定之后电机转起来噪声大转速慢
,
Ben Qin:
电机的电压电流有问题吗?
,
liang zuxing:
电压和电流检测都在正确范围
,
Ben Qin:
您发一个新帖子吧,详细描述下,这样方便看一点。这个帖子我先关闭了。
,
liang zuxing:
好的,我重新提了问题。这个电机不转动问题解决了,请关闭吧