PDA

View Full Version : POV Hat to DX Mode issue



Fever
6th March 2009, 02:05 AM
I'm trying to have the POV hat on my ProThrottle trigger a CMS button by setting the POV hat left position to DX mode and selecting CM Device 2 (ProThrottle) and Button 17. When I write my script to activate the CMS button when JS2.B17 goes true nothing happens. I have tried several scripting paths to get the CMS button to go true using JS2.B17 but have not had any success. Any thoughts would be appreciated.

Sample scripts i've tried:

Script 1:
IF ( JS2.B17 ) THEN
B300 = TRUE;
ENDIF
SEQUENCE
WAIT (B300);
CMS.B6 = TRUE;
DELAY (10);
CMS.B6 = FALSE;
B300 = FALSE;
ENDSEQUENCE

IF ( JS2.B18 ) THEN
B301 = TRUE;
ENDIF
SEQUENCE
WAIT (B301);
CMS.B7 = TRUE;
DELAY (10);
CMS.B7 = FALSE;
B301 = FALSE;
ENDSEQUENCE

Script 2:
CMS.B6=JS2.B17;
CMS.B7=JS2.B18;


I have CMS.B6 and 7 setup to send simple keys.

Bob Church
6th March 2009, 03:18 AM
Hi Fever,

The POV shows up on B25 through B32, actually. It doesn't matter what it's doing in the map (POV, Buttons, Characters), the script sees it as those 8 Buttons. Also, B24 will be TRUE when the POV is centered.

I took a quick look at the little script itself, I don't see anything really wrong with it. The IF/THEN blocks don't really look like they're necessary, you can just WAIT( js2.b25 ) or the one for the right POV direction, but my guess is you just need to get the buttons up into the 25..32 range and you'll fix your main problem.

If that doesn't take care of it, let me know!

Best regards,

- Bob

The StickWorks
http://www.stickworks.com

Fever
7th March 2009, 03:41 AM
Problem solved. B25-32 was the way to go. Thanks Bob! :cheers:

Bob Church
7th March 2009, 05:37 AM
Hi Fever,

Great! I'm glad it was an easy fix. Have fun with it!

Best regards,

- Bob

The StickWorks
http://www.stickworks.com

splash
8th July 2009, 01:41 PM
Hi,

I have a stupid (probably) question but.... why do you have to use a DELAY you use a WAIT sentence?

Thanks!

Dace
8th July 2009, 03:18 PM
Its so that whatever sim he is playing has time to register the button press.

The CH controllers are apparently quite a bit quicker that most software is capable of reading them ;-).

The WAIT waits for you to push the button. then it pushes another button and after the DELAY lets it go again. The DELAY is how long the button will be held down for. How long that actually is will depend on you maps character rate setting and a couple of other things I don't understand either :-D

splash
9th July 2009, 12:44 PM
what are the buttons 17, 18, 19, 20, 21, 22 and 23 used for?

Bob Church
9th July 2009, 08:27 PM
Hi Splash,

>> what are the buttons 17, 18, 19, 20, 21, 22 and 23 used for? <<

It depends on the controller. On most, they aren't used at all. The controller doesn't have enough buttons to use them.

On the Eclipse yoke, buttons 15, 16, and 17 are the up, down, and center clicks for the left trim wheel in the yoke hub. Buttons 18, 19, and 20, work similarly for the top trim wheel. Button 21, 22, and 23, correspond to the three positions on the rotary switch.

None of the other yokes use those. On the FighterStick and CombatStick, button 21, 22, and 23, are "Hat Centered" for the 4-way hats, Hat 1, Hat 2, and Hat 3 respectively, though only the FighterStick and ProThrottle have Hat 2 or Hat 3. Button 24 is "Hat Centered" for the POV.

In the case of the hat-buttons, they're only available in the CMS script, you can't assign a character to Button 24 directly for example. You can assign 21, 22, and 23 in the Eclipse, but they aren't hat-related there.

Best regards,

- Bob

The StickWorks
http://www.stickworks.com