Menu

Topic-icon !MS stop and clear last command

More
4 years 3 months ago #29531103 by ied168
Currently running SDC2130, firmware 1.4a SDC2XXX 11/21/2014. I have two motors hooked up with encoders for each. Operating in closed loop position count. Issuing command !PR 1 -500000 will cause motor1 to move (good). Do the same for motor2. Issued command !MS 1 causes motor1 AND motor2 to stop, but motor2 immediately starts up again. Next command !PR 1 3000. Problem is 1) issuing MS 1 should affect motor1 only, and not even cause motor2 to pause. why? 2) The next command !PR 1 3000 is not moving relative to where motor1 stopped. Instead, motor1 continues with its prior command and ultimately stops at (-500000+3000). !MS is not truly a STOP command, but a PAUSE. I need a STOP command that will clear out the prior command of -500000, and move PR+3000 from the point where it stopped on !MS.

Please Log in or Create an account to join the conversation.

More
4 years 3 months ago #29531104 by TechSupport
MS is motor stop. It maybe a buggy function.

Please Log in or Create an account to join the conversation.

More
4 years 3 months ago #29531105 by ied168
This was a two part question. I'm not so concerned about part1 right now. The 2nd part is what's important. Due to the limited number of IOs on the SDC2130 (I'm using the available IOs for joystick control), I'm using a separate microcontroller that will take the input from a limit sensor and then issue the MS command to the SDC2130 to stop the motor. MS works fine by stopping the motor, but it's not clearing the last command. The whole purpose here is to create a "rehoming" sequence with the limit sensor. Therefore, I cannot have the SDC2130 continue to run a prior !PR command; I need the prior command cleared from memory.

Please Log in or Create an account to join the conversation.

More
4 years 3 months ago #29531106 by TechSupport
Putting controller in open loop mode and sending the !G cc 0 (Where cc is motor channel)command will stop motor for sure.

^mmod cc nn where cc is motor channel and nn is mode. 0 is open loop, 3 is position count.

^mmod 1 0
^mmod 2 0
!G 1 0 for motor 1 to stop
!G 2 0 for motor 2 to stop

^mmod 1 3
^mmod 2 3

Please Log in or Create an account to join the conversation.

More
4 years 3 months ago #29531107 by ied168
Tested and works. Even stops the motor more gently. Great! Thanks. I'll use this instead of the !MS command.

Please Log in or Create an account to join the conversation.

Moderators: tonysantoni
Time to create page: 0.102 seconds
Go to top