No announcement yet.

SP command stops counting steps if motor is disabled

  • Filter
  • Time
  • Show
Clear All
new posts

  • SP command stops counting steps if motor is disabled

    I have a use case where the user needs to manually rotate the motor to a position, and then I need to be able to know what that position is. The only way I have found to do this is to disable the motor with the "MD" command, then have the user rotate the motor, but the "SP" command stops tracking the position during this time.

    Is there another mode I can use where the user can turn the motor and the position is tracked? I will be adding an encoder, so will I be able to track the position still with the "EP" command?

  • #2
    What drive are you using? since you mention SP and MD commands I'm guessing it is a SCL capable drive, but you also mention adding an encoder, so I'd guess you are using one of the integrated motor/drives?
    The only practical way to do what you want is to have an encoder, but you wrote "will be adding an encoder" (future tense) that implies you are not using an encoder now. One would hope that once an encoder is added the drive (supposing the dive is equipped to receive an encoder input) will keep track of position even when the drive is disabled.
    However, not knowing what drive you are using, I can't say for sure.


    • #3
      Instead of disabling the drive and spinning by hand, use an HMI button or panel button to send a jog command to have the motor jog where it needs to be. This keeps the drive/motor enabled and keeps the position.


      • #4
        I'll take a look at adding jog functionality, although right now I only have SCL to communicate, since I need to keep the encoder lines free for the encoder. If I can't control the jogging through SCL, I guess I can always mimic the behavior.

        I am using the STP-DRV-4850 driver with an STP-MTRL-14034E motor and an AMT112Q-0400 encoder from CUI Devices. I'm currently using SCL to communicate with the drive. The drive has encoder inputs.. I say "will be adding" because currently I can't get the encoder to work. I verified the output with an oscilloscope, but when I try ti use the "EP" command over SCL I get an unknown command response.
        Last edited by dsabol; 03-16-2020, 11:29 AM.


        • #5
          EP is not compatible with the STP-DRV-4850 (see page 10 of the SCL manual)
          EP is only compatible with:
          Any Drive with Encoder Feedback (E Models)
          As far as I can tell from the online catalog that is only some of the integrated motor/drive models


          • #6
            Thanks.. I didn't order the parts... just inherited them... missed that in the documentation. I suspect the person that ordered them saw the E appended on the motor label and thought that was all that was needed.


            • #7
              I haven't tried using step motors with encoders, so I'm not sure how well that works. According to the manual, the encoder is connected to STP-DRV-4850 as follows:
              A+ <-> STEP+
              A- <-> STEP-
              B+ <-> DIR+
              B- <-> DIR-

              Beyond that, I'm not sure if it's configurable to use encoder feedback using SCL commands. From what I see in the manual, the encoder connections allow it to follow a handwheel or master encoder in a slave function. The SCL manual shows that ED, EF, EP, IE commands do not work on STP-DRV-4850's; only on "Any Drive with Encoder Feedback (E Models)".

              I've used SCL with stepper motors in an open loop function, and that has worked fairly well, as long as the motor isn't disabled or gets overtorqued and the step position is lost (which requires re-homing).

              I've also used SCL's jogging commands which maintains step control/counts, and included the option to change jogging speeds through a C-More panel.

              Just my 2₵.