Asked — Edited

Joystick

Hello, When programing the joystick the first column says Btn Down Cmd and this works great. The second column says Btn Up Cmd. I can't seem to get this to work. Any help would be appreciated.


ARC Pro

Upgrade to ARC Pro

Synthiam ARC Pro is a new tool that will help unleash your creativity with programming robots in just seconds!

PRO
Canada
#1  

Hello Bookmaker,

I don't know if anyone has said it yet but Welcome to the forums!

So the way the Button Cmd systems works is that on button press the script that you have in the Btn Down Cmd box will activate and as soon as you let go of the button the Btn Up Cmd box will activate.

On my robot I call ServoUp(d17, 2) on button activation Then as soon as I release it I then call Servo(d17, 31)

This action will put my servo up a couple of positions Up when I press the Joystick button down and then when I release it, it will always return to the 31 position.

Hope this helps.

#2  

Greetings!

I'm still kind of new to all of this and I have an addition joystick question.

Using the ARC Application can you assign scripts to run after a joysticks Btn Down Cmd' action?

And if so can you post an example?

Thanks!

PRO
Synthiam
#3  

if you'd like to have a servo on port D0 move to position 5 when the button is pressed, enter this in the Btn Down cmd


servo(d0, 5)

and to have the servo return to position 10 when the button is released, enter this in Btn Up


servo(d0, 10)

if you have a script control, and the control is called "MyScript", and you'd like to execute that script on Btn Down, enter this:


ControlCommand("MyScript", scriptStart)

there is a tutorial video on how to use the joystick. Look under the Tutorial tab on this website :)

#4  

Thanks DJ,

The Script Control example helped.
I did watch the Tutorial video but it kind of glosses over the scripting control part at the end. It does help to see an example. Thanks again, this is a great product! :)