homepage

Control Manager - How Do I?

Posted By: 531 Ghost

Control Manager - How Do I? - 10/26/10 03:32 PM

This Thread will be used to illustrate the basic programming of Control Manager. I will show various ways to program your CH Products Controllers in this thread. As time permits, it will be added to. If you have questions along the way, please, feel free to ask...

Let's kick this off...







Posted By: 20mm

Re: Control Manager - How Do I? - 10/26/10 03:57 PM

Outstanding Ghost! Thanks, after all these years, I'm still a dummy!
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 10/26/10 04:53 PM

Thank you 20mm. Working on the Map Wizard...
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 10/26/10 06:00 PM

Use the Map Wizard...











Posted By: LukeFF

Re: Control Manager - How Do I? - 10/27/10 08:48 AM

Good to see you're doing this. Keep up the good work! yep
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 10/27/10 02:25 PM

Thank you Luke. cheers

Let's continue...

Okay, you've created a Map, now...






Posted By: 531 Ghost

Re: Control Manager - How Do I? - 10/31/10 04:27 AM

Program a button...








Posted By: 531 Ghost

Re: Control Manager - How Do I? - 12/29/10 06:54 PM

Originally Posted By: Joe
At its simplest, programming the CH Fighterstick and CH Pro Throttle through Control Manger involves defining commands in a command file,
which allows those commands to be referenced in descriptive text instead of actual keystrokes. The user then selects these commands from
a list and assigns one or more to each button, based on the mode and shift state. Additional programming control is available through a
text-based scripting language called CMS (Control Manager Scripting), allowing access to CH devices’ more powerful programming options.












Originally Posted By: Joe
A cycle switch on the joystick or throttle can cycle through three modes. An option also exists to use CMS and have four modes.
Programming for each mode is accessed via tabs in Control Manager for each joystick button, allowing the user to click through
these quickly to fully understand the overall HOTAS programming.









As you may, or may not have noticed, on either the FighterStick or the ProThrottle as you pressed either Button 3 (FS) or Button 1 (PT) the LEDs cycled each push of the button on either the FS or PT. If you've selected either the FighterStick or ProThrottle to select hardware modes, as Joe states, you'll have three hardware modes. Now, if you select CMS as your hardware mode selecter well, you'll have up to four hardware modes. This however requires some scripting.




For this example we'll assume we have a FighterStick and wish to use Hat 3 to control the four Modes. Hat 3 generates Buttons 13
through 16. The script itself is straightforward, just a series of nested IF/THEN/ELSE blocks that set the CURRENTMODE variable
based on which of the current position of Hat 3. It's useful to remember when using hats that they can only have one position active
at a time so we don't need to make any allowance for a situation where B13 and B14 were closed at the same time.

The script might look like this:

SCRIPT

IF( JS1.B13 ) THEN
CURRENTMODE = MODE1;
ELSE
IF( JS1.B14 ) THEN
CURRENTMODE = MODE2;
ELSE
IF( JS1.B15 ) THEN
CURRENTMODE = MODE3;
ELSE
IF( JS1.B16 ) THEN
CURRENTMODE = MODE4;
ENDIF
ENDIF
ENDIF
ENDIF

ENDSCRIPT



Assuming the above is true type the following in CM Editor...



And there ya have it. Using a Command File, and setting up Mode Control, explained.
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 02/12/11 04:04 PM

Here's a question that gets asked a time or two: How do I get my mini-joystick to press buttons in [ insert sim name that does not support DX axes for a TDC ]? Or, how do I get my mini-joystick (or any axis for that matter) to press a button? Okay, here is a simple solution for that...

First, you'll need CMS capabilities. Remember when you were creating a .map with Map Wizard and Control Manager asked if you wanted CMS capabilities?



Didn't click Yes? No worries. You can still add CMS capabilities. How? Follow along...






Next, you'll need a script to press the button you want on the axis...

Assuming the mini-joystick is joystick 2 (typically it is)...

You would use a script that looks something like this:


// CMS Script File
//
// Game Title:
// Written By:
// Date:
//

script
cms.b1 = [js2.a2 < 70 ]; // TDC UP (KBUP)
cms.b2 = [js2.a2 > 170 ]; // TDC Down (KBDOWN)
cms.b3 = [js2.a1 < 70 ]; // TDC Left (KBLEFT)
cms.b4 = [js2.a1 > 170 ]; // TDC Right (KBRIGHT)

endScript

Okay, you may, or may not be asking, where do I put this script? Well, in the CM Editor, like this...



Once you've written the script, then you'd go into the CMS Controls (Buttons) and assign each of the four buttons you'd like to assign. Like so...










And there you have it copter
Posted By: LukeFF

Re: Control Manager - How Do I? - 02/14/11 07:33 AM

Good tutorial there. I just recently dug through my old posts at CH Hangar where I asked that very question in relation to something for IL2.
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 02/19/11 03:55 PM

Okay, now let's put a delay between key presses. Some games may need this, or you may want this. Here's the K.I.S.S. method:

Posted By: RyGuy

Re: Control Manager - How Do I? - 03/05/11 10:04 AM

GHOST,

CAN YOU EXPLAIN "CHARDLY"?
Posted By: 531 Ghost

Re: Control Manager - How Do I? - 03/05/11 03:16 PM

Simply put: Character (CHAR) + Delay (DLY) = CHARDLY

Now for all the bells and whistles:

The CHARDLY Character

This character really causes nothing visible to happen. What it does do is to insert a 1 character-time delay between two other characters. Normally the Control Manager will close as many characters as it can on any particular scan. Likewise it will release as many as possible. This is generally the correct thing to do but there are situations that occur in some games where this doesn't give the expected result and it's necessary to force a brief delay to let the game respond.

One of the more common of examples of this is where you need to use a right-shifted character. You can't just use SHF because that's a left-shift. The normal solution is to use something like "HOLD RSHF a", but in some games that doesn't work either because the "RSHF" and the "a" are sent at exactly the same time. In this case you need to be able to control the timing a little to be sure that the RSHF closes before the "a" and that the "a" opens before the RSHF. Using the CHARDLY function, this can be accomplished with a KEYS macro:

KEYS +RSHF CHARDLY +a -a CHARDLY -RSHF

This would hold the RSHF across the entire press of the "a" with one character delays between the time that RSHF was pressed and the time that "a" was pressed, and then a second delay between the time that "a" was released and the time that RSHF was released.

If the game were a little less fussy about the ordering, you might get by with a standard macro (not KEYS) that looked like this:

HOLD RSHF CHARDLY a

This is not as controlled, though, as the "a" and the RSHF are still likely to be released at the same time and in some games that doesn't work correctly.



Posted By: 531 Ghost

Re: Control Manager - How Do I? - 06/17/11 07:23 PM

Let's calibrate the ProThrottle to get a full range of motion in the sim:

Calibration Video
Posted By: Dragon36

Re: Control Manager - How Do I? - 05/05/20 08:12 PM

9 years later I come along and find answers to my burning questions, thank you
© 2024 SimHQ Forums