News:

  • June 20, 2026, 02:09:22 PM

Login with username, password and session length

Author Topic: Variable velocity jogging with AXJOG?  (Read 150 times)

JasonO

  • Jr. Member
  • **
  • Posts: 13
Variable velocity jogging with AXJOG?
« on: June 11, 2026, 12:45:35 PM »
I'm retrofitting a control that includes 2 servo axes, which I will control with step and direction outputs from a BRX. I need to be able to move the axes to preset positions, which is easy enough. I also need to be able to jog them manually with analog joystick, with the target velocity scaled from the analog input. In other words, the axis velocity needs to be dynamically updated based on the analog input signal, while the jog is in process. I don't think I've ever done this particular sort of thing before, so I wanted to see if someone can verify that this can work, and how.

Thanks!

JasonO

  • Jr. Member
  • **
  • Posts: 13
Re: Variable velocity jogging with AXJOG?
« Reply #1 on: June 11, 2026, 12:52:39 PM »
Looks like maybe I need to use AXVEL to achieve this, with the .TargetVelocity dynamically update from the scaled analog value, as log as the instruction is active?

BobO

  • Host Moderator
  • Hero Member
  • *****
  • Posts: 6161
  • Yes Pinky, Do-more will control the world!
Re: Variable velocity jogging with AXJOG?
« Reply #2 on: June 13, 2026, 12:58:29 PM »
Looks like maybe I need to use AXVEL to achieve this, with the .TargetVelocity dynamically update from the scaled analog value, as log as the instruction is active?

Yes, AXVEL will do what you want.
"It has recently come to our attention that users spend 95% of their time using 5% of the available features. That might be relevant." -BobO

JasonO

  • Jr. Member
  • **
  • Posts: 13
Re: Variable velocity jogging with AXJOG?
« Reply #3 on: June 19, 2026, 02:43:51 PM »
Another question on this: Along with the dynamic axis velocity while jogging, I also need to implement soft limits to keep the axes from crashing. I think I need to either a: use AXVEL to jog, and every scan calculate at what point I need to stop the jog and ramp to a stop, based on the current velocity, and considering the current acceleration, or b: Use an AXSCRIPT, with a While loop repeating a Ramp to Vel command, until reaching the point where we need to stop, and then transitioning to a Move to Position command, to bring the axis to a stop at exactly the limit of its stroke, or c: use AXVEL and just simply trim the TargetVelocity as I approach the limit, so that it ramps the TargetVelocity to zero by the time the limit is reached.

Not sure I'm thinking through this all correctly. I would prefer to use S-curve accel/decel ramps, so the math gets a bit dense for me. Maybe I'm overcomplicating this too. Just curious if there's any insight from anyone.

Thanks!