AEK-MOT-TK200G1 Test Application Lock/Unlock motor PWM speed control incorrect
In the AutoDevKit's AEK-MOT-TK200G1 SPC582Bxx_RLA_AEK-MOT-TK200G1_MotorControl_via_CAN - Test Application, the operation of the functions controlling the trunk lock and trunk unlock motor appears to be incorrect in that the PWM duty cycle has the opposite effect on the motor speed from what is expected. For example, when the PWM duty cycle is set to 80% the trunk lock/unlock motor appears to run at a slower 20% speed. Likewise, when the PWM duty cycle is set to 20% the trunk lock/unlock motor appears to run at a faster 80% speed.
This appears to be due to an incorrect configuration of the L99DZ200G's H-Bridge configuration in the AEK_MOT_TK200G1_TrunkConfiguration() function in file "AEK_MOT_TK200G1_for_TrunkLift.c".
That is:
case TRUNK_LOCK:
DataSend = 0x00049000;
break;
case TRUNK_UNLOCK:
DataSend = 0x00061000;probably should be:
case TRUNK_LOCK:
DataSend = 0x00041000;
break;
case TRUNK_UNLOCK:
DataSend = 0x00041000;With those values, the trunk lock/unlock motor appears to operate as expected.
