• Extended Joystick Controller

    Tutorial Presented By Wendy

    "extended joystick controller” for our “Simulators”

    Last week I have been testing this USB device that can be used as a joystick controller or a full featured USB interface card. It’s a special type of controller that is fully and easy configurable and it makes this device perfectly suitable for connecting different types of hardware. By that I mean, every port can be set as digital input/output or encoder, 5 ports are reserved for analog input or digital in/out. 1 port is reserved for analog out. In addition it also supports 6 high-speed fully configurable PWM (pulse width modulation) outputs. Users can freely set PWM period and PWM duties. The PWM module runs at 12 MHz and allows high-speed switching. Last but not the least interesting is the price setting, you only pay around 1 euro / port, isn’t that great news? What more could we desire than an interface card where we decide what the card should be used for? Shall it be inputs/outputs/analog in or analog out or a mixture of everything, it’s all in your hands!

    Do I have your attention… keep reading

    It is called PoKeys and it is a simple, easy-to-use real USB device that combines standard keyboard and joystick simulation. PoKeys enables user to design specially built robust computer interface, comprising only the mechanical keys and PoKeys device. The device is highly adjustable and as such requires no complex knowledge on device programming. Everything is done in a graphical user interface.

    If additional input and output capabilities are needed, this device provides 55 digital 5V tolerant inputs or outputs, 5 x 10-bit analog inputs and one 10-bit analog output. They are configured via included software, which enables you to either use the highly intuitive graphical user interface or advanced console type interface. There are 6 main pin functions available: inactive, digital input, triggered digital input, digital output, analog input and analog output. Chosen settings can be stored on the device, so no special software is needed on target system. For those of us (like me) that know how to write software programs it also has a nice addendum… all functions of the board can be programmed and
    accessed via external software (VB, C++, Delphi, C#...).

    This very nice device can be extended with 10 extention boards so that another 10 x 8 digital outputs, yes that’s right 80 extra digital outputs or 10 relay boards. When you have multiple boards connected to 1 computer, you can give every board a unique name and even assign the board an ID so that the boards could be easily identified in for instance ProSim737. I have been doing some interface tests with the ProSim737 software and it is recognized and can be configured in ProSim737. Because I have used it as a joystick controller only 32 inputs can be configured in ProSim737. That is because a game controller in windows has only 32 ports that are recognized. I have asked Marty from ProSim737 to support this card natively so that all 55 inputs/outputs could be used. I already received a version to test the use of digital inputs/outputs and analog input in Prosim.

    Showing the hardware device

    The USB device itself measure 63 mm x 47 mm with a height of 13 mm. Every port has a screw terminal to connect the wire, no it is not a push-button type connector. The manual itself has examples of different hardware attachments, leds, encoders, lcd, all this comes together with instructions on how to connect everything. Small schematics are provided even for connecting multi 7-segment displays.

    There is also an Ethernet version with the same technical specifications, only difference is that it is Ethernet and not USB.

    Showing the software side of things

    Below I will show you the most important screen. You will be amazed by how many parameters you can adjust, most of them require no knowledge at all. There are too many screens to show in this introduction, I’ll open a separate thread showing all screen images. Below the main screen and the matrix keyboard configuration screen.

    How to connect inputs…

    First of all you need to open the configuration tool of PoKeys. See the picture above. Select the portnumber that you wish to assign. Click on the digital input mark and check if the port needs to be inverted or not. Mine needed to be inverted so I checked the “Invert pin” box. If you do not want to assign a key mapping to this input, then you are done and ready to press “Send to device”. One more thing to do before the input is recognized by Windows. Open the screen “Joystick mappings” (see picture below) that is available under the menu “Peripherals” and on the right side of this windows you select the button first, click “Direct mapping” and select the pin that you want to use.

    Close this screen and don’t forget to use “Send to device” so that the settings are saved on PoKeys. Optional you can choose the “File” menu and “Save as…” to also save the configuration in a file on your computer.

    What about encoders…

    Yes but… testing with ProSim737 showed that values on the MCP could be changed. For the moment it is to slow to be useful. Maybe something will come up so that these also could be used, if something changes I will definitely let you all know. Below find the details on the encoders as in the manual.
    Rotational encoder switch can be used with PoKeys55 digital inputs. It is possible to connect up to 25 encoders to one PoKeys55 device. To enable encoder input, first select encoder index with numerical up-down selector, then select appropriate encoder channel. The last step is to check the box ‘Encoder’.

    Same as simple digital inputs, encoders can be assigned to direct key mapping or keyboard macro. This is possible for both directions (CW and CCW) separately. Simply set one mapping for channel A and another for channel B. To check for proper connection and settings, there is a special dialog that displays current encoder state. If needed, encoder inputs can be incremented or decremented 4x faster, therefore each complete step will produce increment or decrement of 4 sub-steps. Using this setting, higher precision can be obtained.

    And the outputs…

    Because this is a game controller you cannot currently connect outputs in ProSim737 directly. As I mentioned before I have asked Marty to support this card in ProSim737. Until then only 32 inputs could be used. However connecting with self written software is very easy and you can use all features of this card. It is actually very simple and examples are provided in different programming languages. A few lines of code… that’s it.

    For the programmers among us… I have setup 2 projects, one in Delphi 7 and one in Delphi 2010 and was able to switch an output on the card with only 5 lines of code including the connection method. All it takes is create the interface object, set the port to digital output and switch it on and off. Next I entered this code in my own ReadFSX program and followed the status of the aircraft brakes. Switched the brakes in FSX and the connected LED goes on and off, extremely fast. Besides this simple example of switching a port on and off, all the other options are also available via external programming. And that includes saving the configuration to the device.

    Time for some figures…

    - Compatible with USB 1.1/2.0 HID standard
    - Standard USB keyboard simulation (with triggering support for up/down keys)
    - Standard USB joystick simulation (6 axis, 32 buttons with triggering support)
    - 55 digital inputs with pull-up resistors, freely mappable to virtual USB keyboard’s keys
    - 55 software controlled digital outputs
    - 5 analog inputs (10-bit), mappable to any of virtual USB joystick axes (adjustable low-pass filtering support)
    - 1 software controlled 10-bit analog output, controlled via included software
    - Up to 25 encoder pair inputs (3 high-speed encoder inputs)
    - 3 high speed encoder inputs
    - Up to 64 256-character long keyboard macro sequences
    - Intuitive and user-friendly software
    - Up to 16x8 matrix keyboard with triggered keys/alternate function support
    - Two 8x8 matrix LED display support
    - Up to 6 high-speed fully configurable PWM outputs support
    - HD44780-based character LCD support (up to 4x20)
    - ExtBus support for adding up to 10 external shift registers
    - Support for Connection signal output
    - Support via communication DLL library and protocol specification that allows porting to other systems

    Finally, requirements, pricing, ordering

    -One available USB 1.1 or USB 2.0 port.
    -USB HID device driver enabled operating system (Windows 98 SE/ME/2000/XP/Vista/7, Linux, Mac OS).
    -Included software requires Windows 2000/XP/Vista with .NET framework 3.0 installed
    -The target pc does not need any special software, just plug it in and start using.

    One of the nicest things about this controller is the price, only 55 euro + VAT. Cards will be offered till 30 august 2011 at 45 euro + VAT . I became a distributor so you can order these boards directly by me and delivery will be handled through my company.

    I have setup a website to accept orders and you can pay via PayPal, please visit http://www.flightsimparts.eu:
    On receiving an order I’ll keep you informed on sending out this nice little gadget.
    If you need more info you can e-mail me “support (AT) telee (DOT) com” or contact me via MyCockpit.org:

    Hope you enjoyed this small introduction to an incredible USB interface card. If you have more questions, please don’t hesitate to ask and/or join the thread I just opened. I haven’t yet tested all the functions of this card but as always I’ll do my best to answer all your questions.

    Regards, Wendy