SimHQ
Previous Thread
Next Thread
Print Thread
Rate Thread
Hop To
Joined: Mar 2009
Posts: 227
C
Member
Member
C Offline
Joined: Mar 2009
Posts: 227
I wist to replicate the DCS:A-10 S1 sequence where each press cycles a weapon station and a 'long press' selects A-A mode. Here is the basic sequence code so far.

MapKey(&Joystick, S1, SEQ
(
PULSE+Weapon_selection_inward_stations,
PULSE+Weapon_selection_outward_stations,
PULSE+Weapon_selection_all_stations,
PULSE+Weapon_selection_A-A_mode
)
);

I wish to insert a TEMPO statement for the final selection, "Weapon_selection_A-A_mode", but am unsure about nesting commands.

Can anyone shed some light please?


i7 6700k | 16gb DDR4|Geforce GTX980|M2 SSD |27� & 2 x 24� | TrackIR 5| HOTAS WARTHOG (SERIAL 0273)| CH PRO Pedals USB |2 x Cougar MFD�s and a partridge in a pear tree
Inline advert (2nd and 3rd post)

Joined: Nov 2010
Posts: 37
H
Junior Member
Junior Member
H Offline
Joined: Nov 2010
Posts: 37
Hi,

Maybe because I don't have DCS:A-10C myself I might not understand your question.
The TEMPO command is about two keys, but you are referring to just one namely Weapon_selection_A-A_mode?
Otherwise your code would look like:
....
PULSE+Weapon_selection_all_stations,
TEMPO(PULSE+Weapon_selection_A-A_mode,key2,press_delay)
)
);
Short key press would sequence stations and A-A mode, long key press would generate key2. The press delay defines how long you have to hold the key before key2 is generated.

Joined: Mar 2009
Posts: 227
C
Member
Member
C Offline
Joined: Mar 2009
Posts: 227
I will give that a go later. The manual states,

"A short press will generate the first output; a long press will generate the
other output. This is a feature used on modern fighters.
Syntax:

TEMPO(key1, key2, delay) delay is optional (500 milliseconds is a good value)."

If it expects two comma separated commands, i may be able to wrap a sequence up in the first and then the long hold function second.
Something like;

MapKey(&Joystick, S1, TEMPO(

(SEQ(PULSE+Weapon_selection_inward_stations, PULSE+Weapon_selection_outward_stations, PULSE+Weapon_selection_all_stations)), //short presses cycle

PULSE+Weapon_selection_A-A_mode) //Long press
);

Last edited by coolts; 12/06/10 08:35 AM.

i7 6700k | 16gb DDR4|Geforce GTX980|M2 SSD |27� & 2 x 24� | TrackIR 5| HOTAS WARTHOG (SERIAL 0273)| CH PRO Pedals USB |2 x Cougar MFD�s and a partridge in a pear tree
Joined: Nov 2010
Posts: 37
H
Junior Member
Junior Member
H Offline
Joined: Nov 2010
Posts: 37
Hi,

I cannot test your solution at the moment but it would certainly be good to let us know how it worked out. Something to learn again Smile2

Joined: Mar 2009
Posts: 227
C
Member
Member
C Offline
Joined: Mar 2009
Posts: 227
Yep, I wlll have a go tonight. We need a proper comamnd syntax reference manual for this from TM really to determins which commands can be nested and which, if any, can't.


i7 6700k | 16gb DDR4|Geforce GTX980|M2 SSD |27� & 2 x 24� | TrackIR 5| HOTAS WARTHOG (SERIAL 0273)| CH PRO Pedals USB |2 x Cougar MFD�s and a partridge in a pear tree
Joined: Sep 2010
Posts: 104
D
Member
Member
D Offline
Joined: Sep 2010
Posts: 104
here is the answer, just replace the 'letter' with you macro...

MapKey(&Joystick, S1, TEMPO(SEQ('a','b','c'), 'v', 500));

so

MapKey(&Joystick, S1, TEMPO(SEQ(PULSE+Weapon_selection_inward_stations, PULSE+Weapon_selection_outward_stations,PULSE+Weapon_selection_all_stations), PULSE+Weapon_selection_A-A_mode , 500));

you can mix tempo, chain, seq, exec... put a sequence inside another sequence...

Last edited by Dimebug; 12/06/10 06:45 PM.

Guillaume "Dimebug" Leleve
Joined: Mar 2009
Posts: 227
C
Member
Member
C Offline
Joined: Mar 2009
Posts: 227
I thought it would be something like that. That opens up a lot of possibilities.

Thanks for your help.


i7 6700k | 16gb DDR4|Geforce GTX980|M2 SSD |27� & 2 x 24� | TrackIR 5| HOTAS WARTHOG (SERIAL 0273)| CH PRO Pedals USB |2 x Cougar MFD�s and a partridge in a pear tree

Moderated by  RacerGT 

Link Copied to Clipboard
Quick Search
Recent Articles
Support SimHQ

If you shop on Amazon use this Amazon link to support SimHQ
.
Social


Recent Topics
God Forbid they want to have a bit of fun at work
by NoFlyBoy - 09/22/26 08:50 PM
How a 5" 38 Caliber US Naval Gun Works
by F4UDash4 - 09/19/26 01:20 AM
100% commission based sales
by PanzerMeyer - 09/18/26 04:47 PM
Relativity
by Terl9999 - 09/18/26 04:34 AM
HOA's
by Terl9999 - 09/18/26 04:12 AM
Football
by Terl9999 - 09/18/26 02:42 AM
Flags
by Terl9999 - 09/15/26 10:03 PM
September 15th Battle of Britain Day.
by RedToo - 09/15/26 08:06 PM
Population Patterns
by PanzerMeyer - 09/15/26 03:43 PM
"Problem occurred in connection"
by F4UDash4 - 09/14/26 01:41 PM
Popular Topics(Views)
7,068,764 SAM Simulator
Copyright 1997-2016, SimHQ Inc. All Rights Reserved.

Powered by UBB.threads™ PHP Forum Software 8.0.1