store synched motor info always (#187)

This commit is contained in:
Peli de Halleux
2018-01-05 08:40:49 -08:00
committed by GitHub
parent dc6ce0efc7
commit aa06fd344a
2 changed files with 5 additions and 4 deletions

View File

@ -70,7 +70,7 @@ namespace pxsim {
for (const motor of motors) {
const otherMotor = motors.filter(m => m.port != motor.port)[0];
motor.setSyncCmd(
motor.port < otherMotor.port ? otherMotor : undefined,
otherMotor,
cmd, [speed, turnRatio, stepsOrTime, brake]);
}
return 2;