Jump to content
The simFlight Network Forums

Is it possible to adress a specified window with WideFS keys


Recommended Posts

Hi,

I'm flying with FS9 and Project Magenta Software and most time online with IVAO-network.

For the 'Push to Talk'-function (F12-key) I have successfully programmed a button on my CH FlightSimYoke using registered FSUIPC and WideFS.

There is only a small absence which I want to solve.

When I press my PTT button, the FS9-PC is sending this command over network to another PC where the IVAP software is running in combination with Teamspeak. So if on this PC the IVAP software is the current active window then everything works fine.

But on this PC I also run the PM CDU software and I often have to switch between these programs. So if the CDU software is in the moment of PTT-press the active window than it receives a command (F12-key) and switches to another page inside the CDU.

So is it possible to add to the FS-key-send over FSUIPC and WideFS a command that this key-send is only assigned for a specified window (the IVAP software)?

Or does exist a command in WideFS like i.e. 'make active window:..(name of the window)')?

Greetings

Norbert

Link to comment
Share on other sites

is it possible to add to the FS-key-send over FSUIPC and WideFS a command that this key-send is only assigned for a specified window (the IVAP software)?

Or does exist a command in WideFS like i.e. 'make active window:..(name of the window)')?

I am using a two PC setup, possibly the same way you are using. Some IVAP components are running on the 2nd PC with WideFS Client and TeamSpeak.

On the 1st (FS) PC I run FS9, WideServer and FSUIPC. I configure FSUIPC/Buttons+Switches as:

Joy# 0 Btn# 1

Select for FS control: check

COntrol sent when button pressed: KEYSEND 1-255 (WideFS)

Parameter: 1

COntrol sent when button released: KEYSEND 1-255 (WideFS)

Parameter: 2

I use the following settings in wideclient.ini:

[user]

Log=Errors+

Run1=D:\Progs\IVAO\TS\TeamSpeak.exe

UseSendInput=Yes

KeySend1=123,8

KeySend2=123,16

When WideClient starts, it also starts TeamSpeak. You might also "auto" start here IvAp Network Interface and IvAp User Interface with Run2 and Run3.

KeySend1 generates F12 keydown command and KeySend2 generates F12 keyup command. It is sent to the Windows main queue, thus all applications receives this. It controls TeamSpeak if PTT is set to F12.

So it is going to TeamSpeak, not to IvAp. In fact it works fine without IvAp running. IvAp is needed here as if you tune frequency in your cockpit or if you select ATC on IvAp User Interface, then it has to be located on the same PC where TeamSpeak is located to be able to switch channel. But IvAp has nothing to do with WideClient here.

The slight problem is that F12 is received by all running programs on the 2nd PC. It might or might not be a problem - depending on how the programs react on F12 (or the key you define). There is a second version of KeySned that direct the keystroke to the application that was started by the appropriate Runx command:

KeySend1=123,8,Run1

KeySend2=123,16,Run1

This is unfortunatelly does not work for me. With this setup TeamSpeak is not receiving the keys at all (and not any other apps running on the 2nd PC - I used to open notepad and configure letter 'A' instead of F12 when doing testing).

There is a more advanced form of KeySend, but i have never tried - though that might work:

KeySend1=123,8,,

WIndow name is only required in case there are multiple windows with the same class name - that is most probably not the case with TeamSpeak. One needs a "Spy" program to determine the internal Window name of a given program if it is not documented. I am too lasy to set up one and determine it for TeamSpeak - but i am interested.

You can find all this information in "WideFS Technical.pdf".

Gabor

Link to comment
Share on other sites

Well, I downloaded Spy++ from http://www.windows-spy.com/download/ and tested the solution with the following settings:

KeySend1=123,8,TMainForm

KeySend2=123,16,TMainForm

... TMainForm being the main window class name of TeamSpeak based on Spy++.

I also tried...

KeySend1=123,8,TMainForm,"TeamSpeak 2"

KeySend2=123,16,TMainForm,"TeamSpeak 2"

It still does not work for me. I just repeat, that

KeySend1=123,8

KeySend2=123,16

works fine.

TeamSpeak version: 2.2.0.32.60

Gabor

Link to comment
Share on other sites

There were errors in my examples. The keys should be as follows:

KeySend1=123,16 ;press F12

KeySend2=123,24 ;release F12

123,8 means the F12 key itself. +8 means press and +16 means release

So my working copy is as follows:

[user]

Log=Errors+

Run1=D:\Progs\IVAO\TS\TeamSpeak.exe

Run2=D:\Progs\IVAO\IvAp\ivapnetint.exe

Run3=D:\Progs\IVAO\IvAp\usrhost.exe

UseSendInput=Yes

KeySend1=123,16

KeySend2=123,24

Close1=Yes

Close2=Yes

Close3=Yes

Link to comment
Share on other sites

In fact I have not too muvh time to play with FS, so I had to re-configure quite a lot of staff to be able to answer you. Still yesterday I more refined the installation:

[user]

Log=Errors+

Run1=D:\Progs\IVAO\TS\TeamSpeak.exe

Run2=D:\Progs\IVAO\IvAp\usrhost.exe

UseSendInput=Yes

KeySend1=123,16

KeySend2=123,24

Close1=Yes

Close2=Yes

I.e. I moved the ivapnetint.exe from the 2nd PC and run it on the 1st (FS) PC. With the previous setup messages did not appear in the FS (only in IvAp) and also I had to manually connect the mutliplayer session to the 2nd PC. With the setup here it is all OK and automatic. Of course you have to run the IvApconfig utility on both PCs to set up IvAp correctly:

1st (FS) PC:

- IP of flight Simulator PC: 127.0.0.1

- IP of Network Interface PC: 127.0.0.1

- IP of User Interface PC:

2nd PC:

- IP of flight Simulator PC:

- IP of Network Interface PC:

- IP of User Interface PC: 127.0.0.1

Link to comment
Share on other sites

The slight problem is that F12 is received by all running programs on the 2nd PC. It might or might not be a problem - depending on how the programs react on F12 (or the key you define). There is a second version of KeySned that direct the keystroke to the application that was started by the appropriate Runx command:

Hi Gabor,

exactly the above was my problem.

Because the F12 key has disturbed the Project Magenta CDU software which is running on the same PC.

Now I found a way:

In Teamspeak I changed the key for Push-to-Talk to the TABULATOR-key and no more F12.

In the WideClient ini I changed the section also to the TAB-key:

[user]

UseSendInput=Yes

KeySend1=9,16 ; Press TAB-key

KeySend2=9,24 ; Release TAB-key

Log=Errors+

AllowShutDown=Yes

In a short test it worked fine.

Greetings

Norbert

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.