Hello, for the mechinum wheel drive our team has set up, I have designed a control system using the joystick buttons. Unfortunately the design is clunky, and unwieldy. Because of this I have been looking at the “inrange and coerce” function. I was hoping to be able to use the joystick axises to replace the buttons (say moving a joystick to the left to make the mech drive go to the left.). Im confused with these things, has anyone used this idea to control the robot?
You’ll find a premade holonomic drive system in Labview that will perform the drive functions you need without you programming them all from scratch. Take a look.
First, I’d recommend trying the canned Labview holonomic code. It may work better than what you’re attempting right now.
However, if you’re just trying to decide if the joystick is, say, 50% to the right or 50% to the left, in range and coerce is a bit excessive. You should just be able to use the “greater than” and “less than” comparators from the Boolean palette.
If you’re trying to get a series of locations like, say “100%-75% Left”, “75%-50% Left”, “50%-75% Right”, and “75%-100% Right”, then a series of in range and coerce functions may be the simplest way to get that done.