Board index FlightGear Support Hardware

Heli Kit. Pedals not recognised.

Joysticks, pedals, monitors.

Heli Kit. Pedals not recognised.

Postby StuartC » Fri Feb 02, 2018 12:41 pm

I have just bought a Helicopter set up from Heli Kit.
It all runs through a single USB to the PC. Windows configuration tool recognises all buttons and axes for everything.
However, Flight Gear does not find nor recognise the pedals. Out of the 7 available axis on the joystic configuration tool in FG, none react to the pedal input. How can I trace what axes it is to manually input it into the xml ???

Second issue.
I need to reverse the throttle input. There is no reverse option tick box in the FG Joystick configuration for that axis.

I have tried this:-
<axis n="2">
<desc type="string">Throttle (all)</desc>
<binding>
<command type="string">nasal</command>
<factor type="double">-1</factor>
<script type="string">controls.throttleAxis();</script>
</binding>
</axis>

using the factor -1, but it has no affect on it. Any ideas ????
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby AndersG » Fri Feb 02, 2018 4:34 pm

For the last part: IIRC you send -1 as argument to controls.throttleAxis(), i.e. controls.throttleAxis(-1);.

For the main question I think the old jsdemo.exe program might help in seeing how FlightGear sees the device. It might be available from the build server.
The main issue is if the device is a normal USB joystick device to the system or if it is something special.
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2433
Joined: Wed Nov 29, 2006 9:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Fri Feb 02, 2018 6:40 pm

Was it ever included in an old FlightGear install ?
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby AndersG » Fri Feb 02, 2018 8:15 pm

StuartC wrote in Fri Feb 02, 2018 6:40 pm:Was it ever included in an old FlightGear install ?


js_demo.exe? I don't know about Windows releases but on Linux I think it is built by default. At least it have always been built for me.
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2433
Joined: Wed Nov 29, 2006 9:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Sat Feb 03, 2018 12:10 pm

according to Windows, the Calibration tool the pedals are recognised as Y rotation.
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby Richard » Sun Feb 04, 2018 10:50 am

C:\Program Files\FlightGear (Version)\bin\js_demo.exe

Step 1 is to find out the axis. You can use js_demo.exe to do this; or look in /input/joysticks/js[#]/ to find the right axis and the controller ID.

I've just redone a few axis on my Logitech Extreme 3d (as it's very noisy around the centre position) to have a deadzone with the remaining range scaled; and the way to do it directly in Nasal is as follows. Replace all lines with multiple # characters with the appropriate names/values/etc.

You can simply set the property to tempv and remove the other lines if you don't need them.

Code: Select all
   <axis n="##">
    <desc type="string">### axis name ####</desc>
        <binding>
            <command type="string">nasal</command>
            <script type="string">
                <![CDATA[
                tempv = cmdarg().getNode("setting").getValue();
#                deadzone=0.01;
#                tempv = (math.max(0.0, math.abs(tempv) - deadzone) * (1.0/(1.0 - deadzone)));
#print("valueis ",tempv);
#                    tempv = math.sgn(tempv) * math.pow(tempv,1.5); # non linear curve

                setprop("####some property####",tempv);
            ]]>
            </script>
        </binding>
    </axis>
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Sun Feb 04, 2018 3:48 pm

C:\Program Files\FlightGear (Version)\bin\js_demo.exe
This is not in the bin folder of 2017.3.1 though, or any 2016-2017 versions.

I have already looking in the property tree at /input/joysticks/js# and the pedals are not registering at all.
The pedals do work as I have used them in FSX, X Plane and other games with choppers in them.
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby Richard » Sun Feb 04, 2018 4:34 pm

Download and install the nightly build[1][2]; it's definitely in there[3] (or at least it was in the one I downloaded last week).

I'm not exactly sure but I don't think the input devices will be in the property tree unless there is a valid config file; for this you need the device ID string, that js_demo gives you.

[1] http://download.flightgear.org/builds/nightly/
[2] you probably should install it in a different directory to the one which you usually use.
[2] http://download.flightgear.org/builds/n ... ightly.exe
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Sun Feb 04, 2018 5:43 pm

its not in the nightly, but I scanned my HD for that file and found it in the remains of an old version.

So, I run it and it produces a constantly updating dos box fill of zeros ?
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Sun Feb 04, 2018 6:37 pm

Ok, I have an output

Joystick test program.
~~~~~~~~~~~~~~~~~~~~~~
Joystick 0: "HELI-KIT"
Joystick 1 not detected
Joystick 2 not detected
Joystick 3 not detected
Joystick 4 not detected
Joystick 5 not detected
Joystick 6 not detected
Joystick 7 not detected
+--------------------JS.0----------------------+
| Btns Ax:0 Ax:1 Ax:2 Ax:3 Ax:4 Ax:5 Ax:6 Ax:7 |
+----------------------------------------------+
|
AX 0 and 1 are Cyclic and show figures when moved.
AX2 is collective and shows figures when moved
AX 3 and 4 are the Hat. - show figures when moved.
AX5 is Engine power on the twist grip - shows figures when moved.
AX 6 and 7 show nothing when the pedals are moved. nothing shows figures relating to pedal movement.
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby Richard » Sun Feb 04, 2018 6:43 pm

That's odd; there might be something that needs fixing in plib to recognise the axes properly; as it always seems to return 7 (and that's not the maximum either).

try this and post a screenshot; http://www.planetpointy.co.uk/joystick- ... plication/
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Sun Feb 04, 2018 6:54 pm

Ok, here it is

Image

z = collective
RX = engine powr/twist grip
RY = pedals
S0 + S1 = hat
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Re: Heli Kit. Pedals not recognised.

Postby geed » Sun Feb 04, 2018 7:00 pm

I am looking into jsWindows.cxx where the implementation lives.
Maybe we could write a Little test program out of that code.
geed
 
Posts: 83
Joined: Fri Apr 18, 2014 12:53 pm
Location: in between
Callsign: G-EED
Version: 2017.3.1
OS: OSX, Win8.1

Re: Heli Kit. Pedals not recognised.

Postby Richard » Wed Feb 07, 2018 2:32 am

From looking at the PLIB joystick code[1] it seems that it (i.e. FG) is pulling out all of the values that are defined; but it doesn't seem to have the separate "rudder" axis (Rx, Ry), just R (which is displayed as RX in the test application). As the test application you ran uses DirectInput I have a nasty feeling that the old Win32 way that PLIB uses isn't going to work because it doesn't have enough axes.

Probably the only solution would be to change the input methods in FG to support DirectInput (Windows) only. I'm not sure about this but it looks like it could be the case.
-------------------------------------------------
[1] https://github.com/congocongo/plib/blob ... indows.cxx
Last edited by Richard on Thu Feb 08, 2018 6:10 am, edited 1 time in total.
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Heli Kit. Pedals not recognised.

Postby StuartC » Wed Feb 07, 2018 8:03 am

Well if FG boast its able to support any hardware, which it now clearly doesn't, it needs to be tried.
Meanwhile I have invested over £400 on kit to use n FG, and I cant use it in FG, and its a generic USB device. I presume the more expensive options for Helicopters will also suffer from the safe fate.
StuartC
 
Posts: 2704
Joined: Fri Jun 18, 2010 8:18 pm
Location: Arse end of the Universe
Callsign: WF01
Version: 2018.3.2
OS: W10 64 bit

Next

Return to Hardware

Who is online

Users browsing this forum: BLEXBot [Bot] and 0 guests