T3.6 USB Host - Joysticks

KurtE

Senior Member+
I have been playing around with some (hopefully) enhancements for the support of some of the USB hosted joysticks. I was trying to decide if I should post it on the other USB Host Mouse thread, but thought maybe it would be good thing to have some separate threads for some of the different USB types...

Currently we only have support for the joysticks that are connected using USB (no wireless support yet)

The current released joystick code (part of the Teensyduino release) has had some testing done, using: Sony PS4 controllers (DS4), Sony PS3 controllers (DS3), Microsoft XBox One controller, and I have done some testing with a Teensy configured as a Joystick. Currently most of the test code is contained in the USBHost_t36 example program mouse. I am wondering if we should rename mouse to something else, like usb_host_test and only have very top level testing there and then break out all of the mouse specific code into a new mouse.ino test program and likewise serial.ino and joystick.ino, ...

The current public portion of the JoystickController class is:
Code:
class JoystickController : public USBDriver, public USBHIDInput {
public:
	JoystickController(USBHost &host) { init(); }

	uint16_t idVendor();
	uint16_t idProduct();

	const uint8_t *manufacturer();
	const uint8_t *product();
	const uint8_t *serialNumber();
	operator bool() { return ((device != nullptr) || (mydevice != nullptr)); }	// override as in both USBDriver and in USBHIDInput

	bool    available() { return joystickEvent; }
	void    joystickDataClear();
	uint32_t getButtons() { return buttons; }
	int	getAxis(uint32_t index) { return (index < (sizeof(axis)/sizeof(axis[0]))) ? axis[index] : 0; }
	uint32_t axisMask() {return axis_mask_;}
	enum { AXIS_COUNT = 10 };
protected:
...

This class is derived both from USBHIDInput class which is used to support the standard joysticks that have HID definitions (like Teensy, DS3, DS4, ...) as well as the USBDriver (like Keyboard, Serial adapter...) which is needed to suport the XBox One controller.

Most of the USB Host objects support the ability to query for: the identification numbers for the vendor and product as well as the manufacture, product and Serial# strings. Note: Not all products have all three of these strings, in those cases the calls may return nullptr.

Likewise most of the objects in this library, have a bool operator defined, such that you can test if you have a device attached or not. That is if you have a variable joystick1 defined, you can do something like: if (joystick1) { you have a joystick }

Some information on some of the Joystick specific methods:

available: We have received a new message from the device

joystickDataClear: Usually called after you processed the data for the new data

getButtons: returns the mask of which buttons are pressed. Which bit corresponds to which button is joystick specific.

getAxis: returns the value for the different axis - Currently sort of constrained to standard ones in the standard range. Again some of the order varies depending on joystick.

axisMask: returns a mask that lets us know which axis, we have actually received data on.

To use this class your code probably needs to include a few other objects as well. Example:
Code:
#include "USBHost_t36.h"

USBHost myusb;
USBHub hub1(myusb);
USBHIDParser hid1(myusb);
USBHIDParser hid2(myusb);
JoystickController joystick1(myusb);

All USB Host programs need to include the top level USBHost class, which controls most of the support. In addition you may want to include at least one HUB object, in case you decide to plug a USB Hub into your USB connector and then connect the Joystick through the hub.

As most joysticks are HID based, you need to include at least one of the USBHIDParser objects, which will be used by the Joystick object to support those Joysticks which are HID based, like the Teensy, DS3, DS4...

The next message will contain some of the newer stuff, that I hope to get into the build... Decided that might be nice to keep some form of summary posting at the top of the thread.
 
Note: This has been merged into build 1.41 - Will migrate some of this text up to first post soon.

As I mentioned in the previous posting, I have been playing around with some of the Joystick code to hopefully enable a few more things, that hopefully can make it's way into the released code. The code is currently up in the fork/branch: https://github.com/KurtE/USBHost_t36/tree/Joystick_More_Axis_Rumble I issued a Pull request so Paul could take a look and either take or make suggestions/modifications.

One of the things I noticed was that the current code only returns a subset of the data that some of these joysticks produce and which is actually sent to us as part of the USB message.

For example: The Playstation 4 controller (DS4) only returned the standard Axis (Left and right dual axis thumb joysticks and Left and right Trigger). It did not return the values for Accel/Gyro touch pad... Likewise the PS3 only returned the main axis as well and did not give you the left and right trigger values (only show up in button mask).

So I added code to understand which Joystick which is currently attached and if appropriate try to extract the additional information: As part of this I wanted the ability to know which Joystick is attached. So the class now contains:
Code:
typedef enum { UNKNOWN=0, PS3, PS4, XBOXONE} joytype_t;
	joytype_t joystickType = UNKNOWN;

So your code can do something like:
Code:
if (joystick1.joystickType == JoystickController::PS3)

The getAxis method was updated to allow these values to be returned, starting by default at index 10 (STANDARD_AXIS_COUNT).

For the PS4 - There are an additional 54 bytes of data. You can see the breakdown of most of this up at: http://www.psdevwiki.com/ps4/DS4-USB

For the PS3 - There is something like 39 additional bytes of data. TODO: Provide Link

To support all of the additional axis, I updated the axisMask to return an uint64_t field.

I also was finding that would like to only display those axis that changed, so I updated the code to be able to return this:

uint64_t axisChangedMask() - Returns a mask of which axis changed.

I was also finding that maybe I don't want to be notified all of the time when some non-used field changes. So I added the ability to set a mask for which axis I wish to notified on. I added both a set and query: axisChangeNotifyMask


Rumble and LEDS

I have had at least one request for rumble support, so I did a first pass adding some support. Currently at least part of it is working for the DS3 and DS4 controllers. As one who does not do much with these I don't know if the support is sufficient, but added the method:
Code:
bool setRumble(uint8_t lValue, uint8_t rValue, uint8_t timeout=0xff);
Which at least does something on those two joysticks. I have been trying to get it to work with XBox One controller as well, but so far no luck. I have seen conflicting information on how to do this on the web. Example: https://github.com/quantus/xbox-one-controller-protocol

I also added a method to update the LEDS on these controllers.
Code:
   // setLEDs on PS4(RGB), PS3 simple LED setting (only uses lr)
    bool setLEDs(uint8_t lr, uint8_t lg=0, uint8_t lb=0);  // sets Leds,
On the DS4, I have three values for RGB to set the color... For DS3, it only uses the first value LR and I think only works for values maybe 0-15...

Test Program

The mouse test program was updated to show the additional Axis. I also hacked it up, to take some serial input. So if you just hit enter, it will toggle from showing all axis to only showing changed axis...

Also put test code in to read the Left trigger and right Trigger and try to turn on the rumble motors. Also had it use some of the X, o, sq, Tri buttons to control LEDs.

That is all for now. Obviously it would be great if someone could try it out and make sure things work and or maybe new test program...
 
Last edited:
For the fun of it, I purchased one of the Microsoft XBox 360 wireless adapters (https://smile.amazon.com/gp/product/B00FAS1WDG/) as I already have an XBox360...

It arrived today. Now to see how hard it will be to make it work. as a Joystick.

First issue: Config data length = 321
Which is > MAX defined 256... I bumped up to 512... And now it reads that in.

My assumption is that this Joystick controller like the XBoxOne is not HID based, which I confirmed. So will work to interface in as top level USB device like the XBoxOne.

Next Observation/Question to self and maybe others:
The device has 8 Interfaces defined. Should I assume that each of these interfaces are associated with one logical device that may be connected as the wireless controller supports 4 joysticks and 4 wireless headphones?
Also each of these Interfaces appear to have two end points plus an unknown (by Ubuntu) data item. The lsusb -v of this device is shown below.
Code:
Bus 001 Device 003: ID 045e:0719 Microsoft Corp. Xbox 360 Wireless Adapter
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass          255 Vendor Specific Class
  bDeviceSubClass       255 Vendor Specific Subclass
  bDeviceProtocol       255 Vendor Specific Protocol
  bMaxPacketSize0         8
  idVendor           0x045e Microsoft Corp.
  idProduct          0x0719 Xbox 360 Wireless Adapter
  bcdDevice            1.00
  iManufacturer           1 
  iProduct                2 
  iSerial                 3 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength          321
    bNumInterfaces          8
    bConfigurationValue     1
    iConfiguration          0 
    bmAttributes         0xa0
      (Bus Powered)
      Remote Wakeup
    MaxPower              260mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    129 
      iInterface              0 
      ** UNRECOGNIZED:  14 22 00 01 13 81 1d 00 17 01 02 08 13 01 0c 00 0c 01 02 08
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               8
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    130 
      iInterface              0 
      ** UNRECOGNIZED:  0c 22 00 01 01 82 00 40 01 02 20 00
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               2
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x02  EP 2 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               4
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        2
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    129 
      iInterface              0 
      ** UNRECOGNIZED:  14 22 00 01 13 83 1d 00 17 01 02 08 13 03 0c 00 0c 01 02 08
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x03  EP 3 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               8
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        3
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    130 
      iInterface              0 
      ** UNRECOGNIZED:  0c 22 00 01 01 84 00 40 01 04 20 00
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x84  EP 4 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               2
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x04  EP 4 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               4
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        4
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    129 
      iInterface              0 
      ** UNRECOGNIZED:  14 22 00 01 13 85 1d 00 17 01 02 08 13 05 0c 00 0c 01 02 08
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x85  EP 5 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x05  EP 5 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               8
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        5
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    130 
      iInterface              0 
      ** UNRECOGNIZED:  0c 22 00 01 01 86 00 40 01 06 20 00
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x86  EP 6 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               2
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x06  EP 6 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               4
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        6
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    129 
      iInterface              0 
      ** UNRECOGNIZED:  14 22 00 01 13 87 1d 00 17 01 02 08 13 07 0c 00 0c 01 02 08
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x87  EP 7 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x07  EP 7 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               8
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        7
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass     93 
      bInterfaceProtocol    130 
      iInterface              0 
      ** UNRECOGNIZED:  0c 22 00 01 01 88 00 40 01 08 20 00
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x88  EP 8 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               2
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x08  EP 8 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0020  1x 32 bytes
        bInterval               4

The data read in to the by our code base shows the following bytes: It was all one stream, but I broke it up here per interface/object
Code:
09 04 00 00 02 FF 5D 81 00 
14 22 00 01 13 81 1D 00 17 01 02 08 13 01 0C 00 0C 01 02 08 
07 05 81 03 20 00 01 
07 05 01 03 20 00 08 

09 04 01 00 02 FF 5D 82 00 
0C 22 00 01 01 82 00 40 01 02 20 00 
07 05 82 03 20 00 02 
07 05 02 03 20 00 04 

09 04 02 00 02 FF 5D 81 00 
14 22 00 01 13 83 1D 00 17 01 02 08 13 03 0C 00 0C 01 02 08 
07 05 83 03 20 00 01 
07 05 03 03 20 00 08 

09 04 03 00 02 FF 5D 82 00 
0C 22 00 01 01 84 00 40 01 04 20 00 
07 05 84 03 20 00 02 
07 05 04 03 20 00 04 

09 04 04 00 02 FF 5D 81 00 
14 22 00 01 13 85 1D 00 17 01 02 08 13 05 0C 00 0C 01 02 08 
07 05 85 03 20 00 01 
07 05 05 03 20 00 08 

09 04 05 00 02 FF 5D 82 00 
0C 22 00 01 01 86 00 40 01 06 20 00 
07 05 86 03 20 00 02 
07 05 06 03 20 00 04 

09 04 06 00 02 FF 5D 81 00 
14 22 00 01 13 87 1D 00 17 01 02 08 13 07 0C 00 0C 01 02 08 
07 05 87 03 20 00 01 
07 05 07 03 20 00 08 

09 04 07 00 02 FF 5D 82 00 
0C 22 00 01 01 88 00 40 01 08 20 00 
07 05 88 03 20 00 02 
07 05 08 03 20 00 04

Probably try to interface at the interface level...
 
Yesterday I was able to make get my Microsoft XBox 360 wireless adapter (https://smile.amazon.com/gp/product/B00FAS1WDG/) to talk through the USB Host code and work with one Microsoft XBox controller :D

Currently the code is hard coded to only handle one controller, whereas it can support up to 4 joysticks. I pushed the current stuff up to a new branch on github: https://github.com/KurtE/USBHost_t36/tree/XBOX-360-Wireless
If anyone wishes to give it a try. The rumble appears to work. Also when the joystick is connected to the USB adapter, the code sets the LED (currently hard coded to the first controller value).

I will next convert it to attach at the Interface level (where I need to only process Interfaces 1, 3, 5, 7), Not sure who uses 2, 4, 6, 8, but the Linux kernel does not appear to setup these ones either... It would be great at that time if anyone else has a wireless controller and hopefully multiple XBox360 controllers could try it out, as I only have one controller (I think... Will search around to see if I had any others)...

Edit: As part of this, When should a device object return true for being there. That is when should: if (joystick1) ... should it return true? When a wireless adapter is detected that claims the device or when the connection actually has a wireless device that has connected to this object and is ready to send data?

Again it would be great if anyone else has some of xbox 360 wireless adapters and controllers, if they can try it out. Probably need to add stuff to vendor/product id mapping at top of code.

Update: Support is now in at the interface level should be able to handle multiple XBox360 controllers. Added new Joystick test program that should support up to 4 joysticks.

---------------------------------

questions:

a) Currently this code is setup that all joysticks setup with the same class, such that you can hopefully just say I want to use a joystick and the code should work for any of them supported. This is different than the Arduino USB Host Shield 2 code that has different classes for each type of joystick and setup. So there is a PS3 class (actually maybe a few. One for USB vs one for Bluetooth), PS4 (dito), XBox360, XBox One (BT and USB), ... Some of these classes have some additional calls/support. Xbox 360 wireless I believe has methods where the user code can query the wireless state and the like. I wonder if I should add some support to our main joystick class?

b) There is no real standard here, between joysticks on which button maps to which value in button mask and likewise which axis is which... Was wondering if there should be some mapping of some of these major joystick types to some specific order. Like the USB HID generic desktop usage page where usages (30-39) sort of map to a standard (x, y, z, rx, ry, rz, slider, ...), but then again there does not appear to be standard on what X, Y, Z are...
Example: PS3, the axis order is something like (Left horizontal, left vertical, right horizontal, right vertical), the left and right trigger are now showing up in extended axis area. The PS4 is something like (LH, LV, RH, left trigger, right trigger, LV), which I never liked. Right now I think I have XBoxs (one and 360) setup like:(LH, LV, RH, RV, Left trigger, right trigger) Again maybe nice to have them all be similar.

The buttons may be completely random ordering. Could try to make some order of them... Or could maybe add some methods or the like to underlying code, that could maybe have a set of set of masks for the standard buttons that the user could use something like: if (joystick1.buttons() & joystick.buttons_mask(JoystickController::BUTTON_X)) ... This probably would only work for those joysticks we know, may not work fully in the generic way, but would be start...

Question is, is this level of mapping wanted?

--------------------------------

Side notes:

Not sure if anyone else has played around with using Saleae logic analyzer to work on USB decoding (USB LS and FS analyzer). But I found out about a few more tricks with this yesterday, which helps. That is once you capture the USB stuff, you can use the analyzer to save away the data in text files in a couple of different formats. First of if you wish to see the top level communications configuring devices. Set the protocol analyzers setting, to control transfers. Then
click on the menu item for the analyzer and do a save as text file... You will end up with data like:
Code:
USB RESET Time: 0.

USB RESET Time: 1.194624064

SETUP address: 0x00 time: 1.282552666
	bmRequestType=0x80 Data direction=Device to host, Type=Standard, Recipient=Device
	bRequest=0x06 GET_DESCRIPTOR
	wValue=0x0100 Descriptor=DEVICE, Index=0x00
	wIndex=0x0000
	wLength=0x0040
DATA time: 1.282573902
	<data IN packet NAKed by device. Time: 1.282577114>
	<data IN packet NAKed by device. Time: 1.282621864>
Descriptor time: 1.28266853
	bLength=0x12
	bDescriptorType=0x01 DEVICE
	bcdUSB=0x0200 2.00
	bDeviceClass=0xFF Vendor Specific
	bDeviceSubClass=0xFF
	bDeviceProtocol=0xFF
	bMaxPacketSize0=0x08
STATUS time: 1.282690102
	<status OUT data packet NAKed by device. Time: 1.282696614>
	ACK

USB RESET Time: 1.282809344

SETUP address: 0x00 time: 1.370468304
	bmRequestType=0x00 Data direction=No data, Type=Standard, Recipient=Device
	bRequest=0x05 SET_ADDRESS
	wValue=0x000E Address=0x0E
	wIndex=0x0000
	wLength=0x0000
STATUS time: 1.370487522
	<status IN packet NAKed by device. Time: 1.370490802>
	ACK

SETUP address: 0x0E time: 1.386488256
	bmRequestType=0x80 Data direction=Device to host, Type=Standard, Recipient=Device
	bRequest=0x06 GET_DESCRIPTOR
	wValue=0x0100 Descriptor=DEVICE, Index=0x00
	wIndex=0x0000
	wLength=0x0012
DATA time: 1.386516656
	<data IN packet NAKed by device. Time: 1.386519926>
Descriptor time: 1.386565176
	bLength=0x12
	bDescriptorType=0x01 DEVICE
	bcdUSB=0x0200 2.00
	bDeviceClass=0xFF Vendor Specific
	bDeviceSubClass=0xFF
	bDeviceProtocol=0xFF
	bMaxPacketSize0=0x08
	<data IN packet NAKed by device. Time: 1.38658876>
	idVendor=0x045E Vendor=Microsoft Corp.
	idProduct=0x0719
	bcdDevice=0x0100 1.00
	iManufacturer=0x01 ©Microsoft
	iProduct=0x02 Xbox 360 Wireless Receiver for Windows
	<data IN packet NAKed by device. Time: 1.386663678>
	iSerialNumber=0x03 E1A771D0
	bNumConfigurations=0x01
STATUS time: 1.386729458
	<status OUT data packet NAKed by device. Time: 1.386735926>
	ACK
...

However in this view you don't see the data that is sent and received on the End points. So to see more of this data, go back to the protocol analyzer and change the settings to packets. And then again do the save to text file.
With this you can see the data that is being sent and received...

I then edit this file and start to look for specific things like data being sent to my device/end point... Example: I searched for OUT,0x0e,0x01
Code:
1.406886360000000,IN,0x0E,0x01,,,0x0A
1.406889626000000,NAK,,,,,
1.406891824000000,IN,0x0E,0x03,,,0x0F
1.406895042000000,NAK,,,,,
1.406897240000000,IN,0x0E,0x05,,,0x00
1.406900458000000,NAK,,,,,
1.406902656000000,IN,0x0E,0x07,,,0x05
1.406905876000000,NAK,,,,,
[COLOR="#FF0000"]1.406908120000000,OUT,0x0E,0x01,,,0x0A
1.406911354000000,DATA0,,,,0x08 0x00 0x0F 0xC0 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00,0x171A[/COLOR]
1.406922626000000,ACK,,,,,
1.407008060000000,OUT,0x0E,0x03,,,0x0F
1.407011292000000,DATA0,,,,0x08 0x00 0x0F 0xC0 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00,0x171A
1.407022542000000,ACK,,,,,
1.407133076000000,OUT,0x0E,0x05,,,0x00
1.407136306000000,DATA0,,,,0x08 0x00 0x0F 0xC0 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00,0x171A
1.407147542000000,ACK,,,,,
1.407258074000000,OUT,0x0E,0x07,,,0x05
1.407261306000000,DATA0,,,,0x08 0x00 0x0F 0xC0 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00,0x171A
1.407272542000000,ACK,,,,,
1.407882816000000,SOF,,,0x5A9,,0x05
[COLOR="#FF0000"]1.407886298000000,IN,0x0E,0x01,,,0x0A
1.407889540000000,DATA0,,,,0x08 0x00,0x8FF9
1.407894194000000,ACK,,,,,[/COLOR]
...
Here is where I found what data I needed to send to wireless controller to enable it to start sending data... Note the last number is the checksum...
Also at the end of the above is the first response from the controller...
The 0x08 is a status indicator about either controller attach/detach. The 0 says that no controller attached...

Again just thought I would mention the above, in case others have not found the usage of the reports...
 
Last edited:
Yes - The Teensy 3.6 has a second USB port on it, that can be configured as either a host or client... We are working on adding some software support to allow us to plug in USB devices into the T3.6 and be able to use them. Yes this is currently only for T3.6.

Currently we have support for (Mouse, Keyboard, Joystick, Midi, Serial, RawHid, and maybe a few more). Hopefully in the not so distant future will have additional support for things like Bluetooth, Thumb drives...

As for your other thread... Will talk some there.
 
The Teensy 3.6 has a second USB port on it, that can be configured as either a host or client...
Thanks, I see it now thanks: https://www.pjrc.com/store/cable_usb_host_t36.html
So far I've only been using Teensy 3.2.

Support for Bluetooth and Wifi over that USB port would be awesome.
Does it mean T3.6 can also act as a USB Hub between a PC and other devices?

I guess it also means you could do things like plugin a couple of Joysticks on your T3.6 and have it remap their inputs as a single game controller for the PC.
Most interesting stuff.
 
Yes - The Teensy 3.6 has a second USB port on it, that can be configured as either a host or client... We are working on adding some software support to allow us to plug in USB devices into the T3.6 and be able to use them. Yes this is currently only for T3.6.

Currently we have support for (Mouse, Keyboard, Joystick, Midi, Serial, RawHid, and maybe a few more). Hopefully in the not so distant future will have additional support for things like Bluetooth, Thumb drives...

As for your other thread... Will talk some there.

How do you connect the wireless reciever to the teensy? Directly through the micro USB on the board? A sheild?
 
Thought I would mention, I tried out the non-bt branch on a T3.6 on a MAC, with the Logitech driving force and get lots of data.
Code:
port change: 10001803
    connect
  begin reset
port change: 10001005
  port enabled
  end recovery
new_Device: 12 Mbit/sec
new_Pipe
enumeration:
enumeration:
enumeration:
Device Descriptor:
  12 01 00 02 00 00 00 10 6D 04 94 C2 22 13 00 02 00 01 
    VendorID = 046D, ProductID = C294, Version = 1322
    Class/Subclass/Protocol = 0 / 0 / 0
    Number of Configurations = 1
enumeration:
enumeration:
Product: Driving Force GT
enumeration:
Config data length = 41
enumeration:
Configuration Descriptor:
  09 02 29 00 01 01 00 80 28 
    NumInterfaces = 1
    ConfigurationValue = 1
  09 04 00 00 02 03 00 00 00 
    Interface = 0
    Number of endpoints = 2
    Class/Subclass/Protocol = 3(HID) / 0 / 0
  09 21 00 01 21 01 22 82 00 
    HID, 1 report descriptor
  07 05 81 03 08 00 0A 
    Endpoint = 1 IN
    Type = Interrupt
    Max Size = 8
    Polling Interval = 10
  07 05 01 03 08 00 0A 
    Endpoint = 1 OUT
    Type = Interrupt
    Max Size = 8
    Polling Interval = 10
enumeration:
HIDParser claim this=1FFF2520
USBHub memory usage = 960
USBHub claim_device this=1FFF3460
HIDParser claim this=1FFF2A20
HIDParser claim this=1FFF2F40
HIDParser claim this=1FFF2020
JoystickController claim this=1FFF3840
JoystickController claim this=1FFF3D60
JoystickController claim this=1FFF4280
JoystickController claim this=1FFF47A0
Descriptor 4 = INTERFACE
HIDParser claim this=1FFF2520
 bInterfaceClass =    3
 bInterfaceSubClass = 0
 bInterfaceProtocol = 0
HID Parser Claim: 09 04 00 00 02 03 00 00 00 09 21 00 01 21 01 22 82 00 07 05 81 03 08 00 0A 07 05 01 03 08 00 0A 
report descriptor size = 130
Two endpoint HID:
  endpoint = 81
   size = 8
   interval = 10
  endpoint = 1
   size = 8
   interval = 10
new_Pipe
allocate_interrupt_pipe_bandwidth
 best_bandwidth = 3, at offset = 0, shift= 0
new_Pipe
allocate_interrupt_pipe_bandwidth
 best_bandwidth = 4, at offset = 1, shift= 0
Descriptor 33 = HID
Descriptor 5 = ENDPOINT
Descriptor 5 = ENDPOINT
*** Device HID1 46d:c294 - connected ***
  product: Driving Force GT
control callback (hid)
05 01 09 04 A1 01 A1 02 95 01 75 0A 15 00 26 FF 03 35 00 46 FF 03 09 30 81 02 95 0C 75 01 25 01 45 01 05 09 19 01 29 0C 81 02 95 02 06 00 FF 09 01 81 02 05 01 09 31 26 FF 00 46 FF 00 95 01 75 08 81 02 25 07 46 3B 01 75 04 65 14 09 39 81 42 75 01 95 04 65 00 06 00 FF 09 01 25 01 45 01 81 02 95 02 75 08 26 FF 00 46 FF 00 09 02 81 02 C0 A1 02 26 FF 00 46 FF 00 95 07 75 08 09 03 91 02 C0 C0 
  mesg = 22000681
  got report descriptor
Found top level collection 10004
find_driver
  driver 1FFF384C
Claim Additional axis: 0 0 0
*** HID Device joystick[0H] 46d:c294 - connected ***
  product: Driving Force GT
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:512 1:127 9:8
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - FE 01 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 510
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:510 1:127 9:8
HID: 0 - 54 01 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 340
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:340 1:127 9:8
HID: 0 - AA 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 170
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:170 1:127 9:8
HID: 0 - 00 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:0 1:127 9:8
HID: 0 - 00 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 00 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - AA 00 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 170
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:170 1:127 9:8
HID: 0 - 54 01 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 340
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:340 1:127 9:8
HID: 0 - FE 01 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 510
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:510 1:127 9:8
HID: 0 - A8 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 680
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:680 1:127 9:8
HID: 0 - 52 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 850
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:850 1:127 9:8
HID: 0 - FF 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 1023
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:1023 1:127 9:8
HID: 0 - FF 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 1023
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - FF 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 1023
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - FF 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 1023
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - FF 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 1023
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
HID: 0 - 52 03 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 850
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:850 1:127 9:8
HID: 0 - A8 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 680
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:680 1:127 9:8
HID: 0 - 00 02 80 7F 88 FF FF 00 
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 1
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 127
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 255
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 255
UP: usage_page=ff00 usage=201 add: 0 0 0
Joystick(0): buttons = 0 0:512 1:127 9:8
port change: 1C00100A
    disconnect
disconnect_Device:
USBDriver (available_drivers) list: 1FFF3460 -> 1FFF2A20 -> 1FFF2F40 -> 1FFF2020 -> 1FFF3840 -> 1FFF3D60 -> 1FFF4280 -> 1FFF47A0
USBDriver (dev->drivers) list: 1FFF2520
disconnect driver 1FFF2520
USBDriver (available_drivers) list: 1FFF2520 -> 1FFF3460 -> 1FFF2A20 -> 1FFF2F40 -> 1FFF2020 -> 1FFF3840 -> 1FFF3D60 -> 1FFF4280 -> 1FFF47A0
delete_Pipe 1FFF4960
  Free transfers
    * 536827136 * remove * free
  Free transfers attached to QH
    * 536824672
* Delete Pipe completed
delete_Pipe 1FFF49C0
  Free transfers
  Free transfers attached to QH
    * 536824736
* Delete Pipe completed
delete_Pipe 1FFF5400
  shut down async schedule
  Free transfers
  Free transfers attached to QH
    * 536824608
* Delete Pipe completed
removed Device_t from devlist
  disable
*** Device HID1 - disconnected ***
*** HID Device joystick[0H] - disconnected ***
With debug turned off:
Code:
oystick(0): buttons = 0 0:509 1:131 9:8
Joystick(0): buttons = 0 0:509 1:132 9:8
Joystick(0): buttons = 0 0:509 1:131 9:8
Joystick(0): buttons = 0 0:509 1:132 9:8
Joystick(0): buttons = 0 0:509 1:131 9:8
Joystick(0): buttons = 0 0:509 1:132 9:8
Joystick(0): buttons = 0 0:509 1:131 9:8
*** Device HID1 - disconnected ***
*** HID Device joystick[0H] - disconnected ***
Where Axis 0 is the wheel, Axis 1 is the break and gas pedals
9 is the sort hat and lot of the others are buttons,
There are some pages with data that we are not processing...
 
Nice looking beast! I saw it, but could not think of anything to use it for... I am too old to .... ;)

I was thinking of hacking up a Teensy joystick... Actually wonder if I already did? May have to look through notes and sketches.

That is, I have a few of these controllers by Trossen

ASS-ARBX-CMD-V2-a.jpg
, which is a simple shield that plugged into an Arduino clone... With two thumb controllers and six buttons... Normally use XBee to control, but maybe try with Teensy as Joystick..

Likewise awhile ago was playing with building my own remote control (had one earlier built by Jim Frye of what was Lynxmotion). The first version by Jim was RC based, later I adapted to XBee, my version,

AR-DIY-5.jpg
It has been awhile since I tried the Teensy (3.2 I think) in it now, but could be interesting, as both Joysticks are three Axis (the know twists) and 3 sliders, plus something like 22 buttons, if you could the keypad...
 
@KurtE

Ok-I know I lost focus on the Bluetooth but I needed to see what the HID input was in the WIP branch. So I set up a T3.5 as a joystick, changed it joysticksize to 64 and got several compile errors: "joystick class has no member named sliderleft, sliderright etc. So what am I doing wrong here - did I forget to change something else?

If I leave it as 12 it compiles and runs. As a test I linked it to the T3.6 and while I got axis and button data on the 3.6 didn't see any HID output on the T3.2 side- all debugs set on.
 
@KurtE

Ok-I know I lost focus on the Bluetooth but I needed to see what the HID input was in the WIP branch. So I set up a T3.5 as a joystick, changed it joysticksize to 64 and got several compile errors: "joystick class has no member named sliderleft, sliderright etc. So what am I doing wrong here - did I forget to change something else?

If I leave it as 12 it compiles and runs. As a test I linked it to the T3.6 and while I got axis and button data on the 3.6 didn't see any HID output on the T3.2 side- all debugs set on.

Actually a "diversion" like this is probably good as it does help to understand how different parts work (or don't work) and maybe get a good unified setup.

First off why you are not seeing any HID? Not sure, may need to see what broke! The hid stuff I showed in previous post was done using the non bt branch. I will take a look trying it on BT branch again. Maybe some define not being picked up or the like.

Now to sliderLeft - I am for sure no expert in this part, I only did a little hacking to try it out awhile ago. But if you look at usb_joystick.h you will see:
Code:
#if JOYSTICK_SIZE == 12
	void button(uint8_t button, bool val) {
		if (--button >= 32) return;
		if (val) usb_joystick_data[0] |= (1 << button);
		else usb_joystick_data[0] &= ~(1 << button);
		if (!manual_mode) usb_joystick_send();
	}
	void X(unsigned int val) {
		if (val > 1023) val = 1023;
		usb_joystick_data[1] = (usb_joystick_data[1] & 0xFFFFC00F) | (val << 4);
		if (!manual_mode) usb_joystick_send();
	}
	...
	void sliderLeft(unsigned int val) {
		if (val > 1023) val = 1023;
		usb_joystick_data[2] = (usb_joystick_data[2] & 0xFFC00FFF) | (val << 12);
		if (!manual_mode) usb_joystick_send();
	}
	void sliderRight(unsigned int val) {
		if (val > 1023) val = 1023;
		usb_joystick_data[2] = (usb_joystick_data[2] & 0x003FFFFF) | (val << 22);
		if (!manual_mode) usb_joystick_send();
	}
	void slider(unsigned int val) {
		if (val > 1023) val = 1023;
		usb_joystick_data[2] = (usb_joystick_data[2] & 0x00000FFF)
			| (val << 12) | (val << 22);
		if (!manual_mode) usb_joystick_send();
	}
And in the else area:
Code:
#elif JOYSTICK_SIZE == 64
	void button(unsigned int num, bool val) {
		if (--num >= 128) return;
		uint32_t *p = usb_joystick_data + (num >> 5);
		num &= 0x1F;
		if (val) *p |= (1 << num);
		else *p &= ~(1 << num);
		if (!manual_mode) usb_joystick_send();
	}
	void X(unsigned int position) { analog16(0, position); }
	void Y(unsigned int position) { analog16(1, position); }
	void Z(unsigned int position) { analog16(2, position); }
	void Xrotate(unsigned int position) { analog16(3, position); }
	void Yrotate(unsigned int position) { analog16(4, position); }
	void Zrotate(unsigned int position) { analog16(5, position); }
	void slider(unsigned int num, unsigned int position) {
		if (--num >= 17) return;
		analog16(num + 6, position);
	}
They don't have it. I guess they did not want to hard code which analog value it was?
 
@KurtE

Thanks Kurt - I saw the problem after I posted.

What I am really looking for is how the buttons and the second joystick is presented in the HID usage reports. Reading the pdf I have an idea but what to verify it. You know what they say about assumptions.

Jeez, I am actually its actually sinking in how this works. Argh - now I know why I am getting a headache. :)
 
@mjs513 - I hooked up the Wheel again to the T4 using our branch using the Mouse.ino...

I was seeing nothing as this program did not initialize Serial1...

Welcome to the headache:
The HID Input report drives everything: Example from Wheel, which is probably subset of PS3 controller:
Code:
HID: 0 - 00 02 40 84 88 E7 DD 00
begin, usage=10000
       type= 2
       min=  0
       max=  1023
       reportcount=1
       usage count=1
Input, total bits=10
  usage = 10030  data = 512
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=12
       usage count=255
Input, total bits=12
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=2
       usage count=0
Input, total bits=2
  usage = FF000100  data = 1
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=1
       usage count=1
Input, total bits=8
  usage = 10031  data = 132
begin, usage=10000
       type= 42
       min=  0
       max=  7
       reportcount=1
       usage count=1
Input, total bits=4
  usage = 10039  data = 8
begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=4
       usage count=0
Input, total bits=4
  usage = FF000100  data = 0
UP: usage_page=ff00 usage=100 add: 0 0 0
  usage = FF000101  data = 0
UP: usage_page=ff00 usage=101 add: 0 0 0
  usage = FF000102  data = 0
UP: usage_page=ff00 usage=102 add: 0 0 0
  usage = FF000103  data = 1
UP: usage_page=ff00 usage=103 add: 0 0 0
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=2
       usage count=0
Input, total bits=16
  usage = FF000200  data = 231
UP: usage_page=ff00 usage=200 add: 0 0 0
  usage = FF000201  data = 221

Now as for PS3:
Code:
HID: 1 - 01 00 00 00 00 00 81 7E 7A 7D 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 02 EE 12 00 00 00 00 33 AE 77 01 DE 01 D6 02 59 01 89 00 05 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[COLOR="#006400"]begin, usage=10000
       type= 2
       min=  0
       max=  1
       reportcount=19
       usage count=255
Input, total bits=19
  usage = 90001  data = 0
  usage = 90002  data = 0
  usage = 90003  data = 0
  usage = 90004  data = 0
  usage = 90005  data = 0
  usage = 90006  data = 0
  usage = 90007  data = 0
  usage = 90008  data = 0
  usage = 90009  data = 0
  usage = 9000A  data = 0
  usage = 9000B  data = 0
  usage = 9000C  data = 0
  usage = 9000D  data = 0
  usage = 9000E  data = 0
  usage = 9000F  data = 0
  usage = 90010  data = 0
  usage = 90011  data = 0
  usage = 90012  data = 0
  usage = 90013  data = 0[/COLOR]
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=4
       usage count=4
Input, total bits=32
 [COLOR="#FF0000"] usage = 10030  data = 129
  usage = 10031  data = 126
  usage = 10032  data = 122
  usage = 10035  data = 125[/COLOR]
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=39
       usage count=0
Input, total bits=312
  usage = 10100  data = 0
  usage = 10101  data = 0
  usage = 10102  data = 0
  usage = 10103  data = 0
  usage = 10104  data = 0
  usage = 10105  data = 0
  usage = 10106  data = 0
  usage = 10107  data = 0
  usage = 10108  data = 0
  usage = 10109  data = 0
  usage = 1010A  data = 0
  usage = 1010B  data = 0
  usage = 1010C  data = 0
  usage = 1010D  data = 0
  usage = 1010E  data = 0
  usage = 1010F  data = 0
  usage = 10110  data = 0
  usage = 10111  data = 0
  usage = 10112  data = 0
  usage = 10113  data = 2
  usage = 10114  data = 238
  usage = 10115  data = 18
  usage = 10116  data = 0
  usage = 10117  data = 0
  usage = 10118  data = 0
  usage = 10119  data = 0
  usage = 1011A  data = 51
  usage = 1011B  data = 174
  usage = 1011C  data = 119
  usage = 1011D  data = 1
  usage = 1011E  data = 222
  usage = 1011F  data = 1
  usage = 10120  data = 214
  usage = 10121  data = 2
  usage = 10122  data = 89
  usage = 10123  data = 1
  usage = 10124  data = 137
  usage = 10125  data = 0
  usage = 10126  data = 5
The above is the processing for one set of data coming:

The Part in RED is the two main axis Remember the main page, 0x30->X, 31->Y 32->Z 35->Rz this is where the data for those are
The part in GREEN is the different buttons, which we build up into one 32 bit value.

Then there are those 39 values that we really don't know much about except they are 8 bit values unsigned and un mapped...

Again welcome to the headache!
 
@KurtE
Kurt - thanks for pulling the data for me. Based on looking at usb_desc.c and the hut pdf the challenge is that right now the HID report only one joystick (6 axes - x,y,z, rx, ry, rz), technically it probably should be 12 axes (6 for each stick), then buttons, sliders, hats, dials etc. For instance, using the PS3 data:
Code:
begin, usage=10000
       type= 2
       min=  0
       max=  255
       reportcount=4
       usage count=4
Input, total bits=32
  usage = 10030  data = 129     <==== X
  usage = 10031  data = 126     <==== Y
  usage = 10032  data = 122     <==== Z
  usage = 10035  data = 125     <==== RZ (remember RZ is rotation
Why RZ and not RX, right now the report only supports X,Y,Z, RZ, I think, have to double check me on this. Think they really should be mapped differently so the second joystick data goes into a second set or Rx,Ry.

As for the other 39 they are probably gyro, accel, status, etc. For the PS4 I could translate those. Havent done that for the PS3.

You see what happens when I start reading stuff - learning just enough to be dangerous.

Any chance on you getting that Lynxmotion box of yours operational - would like to see how the sliders present themselves.
 
Hi Mike, the actual axis values appear to be a sudo standard for most units out there... Example linux dump of the PS3 info:
Code:
pi@raspberrypi:~ $ sudo usbhid-dump  -i0 | grep -v : | xxd -r -p | hidrd-convert -o spec
Usage Page (Desktop),               ; Generic desktop controls (01h)
Usage (Joystik),                    ; Joystik (04h, application collection)
Collection (Application),
    Collection (Logical),
        Report ID (1),
        Report Size (8),
        Report Count (1),
        Logical Minimum (0),
        Logical Maximum (255),
        Input (Constant, Variable),
        Report Size (1),
        Report Count (19),
        Logical Minimum (0),
        Logical Maximum (1),
        Physical Minimum (0),
        Physical Maximum (1),
        Usage Page (Button),        ; Button (09h)
        Usage Minimum (01h),
        Usage Maximum (13h),
        Input (Variable),
        Report Size (1),
        Report Count (13),
        Usage Page (FF00h),         ; FF00h, vendor-defined
        Input (Constant, Variable),
        Logical Minimum (0),
        Logical Maximum (255),
        Usage Page (Desktop),       ; Generic desktop controls (01h)
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Collection (Physical),
            Report Size (8),
            Report Count (4),
            Physical Minimum (0),
            Physical Maximum (255),
            Usage (X),              ; X (30h, dynamic value)
            Usage (Y),              ; Y (31h, dynamic value)
            Usage (Z),              ; Z (32h, dynamic value)
            Usage (Rz),             ; Rz (35h, dynamic value)
            Input (Variable),
        End Collection,
        Usage Page (Desktop),       ; Generic desktop controls (01h)
        Report Size (8),
        Report Count (39),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Input (Variable),
        Report Size (8),
        Report Count (48),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Output (Variable),
        Report Size (8),
        Report Count (48),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Feature (Variable),
    End Collection,
    Collection (Logical),
        Report ID (2),
        Report Size (8),
        Report Count (48),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Feature (Variable),
    End Collection,
    Collection (Logical),
        Report ID (238),
        Report Size (8),
        Report Count (48),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Feature (Variable),
    End Collection,
    Collection (Logical),
        Report ID (239),
        Report Size (8),
        Report Count (48),
        Usage (Pointer),            ; Pointer (01h, physical collection)
        Feature (Variable),
    End Collection,
End Collection
Again notice X, Y, Z, Rz

Likewise for PS4:
Code:
pi@raspberrypi:~ $ sudo usbhid-dump   | grep -v : | xxd -r -p | hidrd-convert -o spec
Usage Page (Desktop),               ; Generic desktop controls (01h)
Usage (Gamepad),                    ; Gamepad (05h, application collection)
Collection (Application),
    Report ID (1),
    Usage (X),                      ; X (30h, dynamic value)
    Usage (Y),                      ; Y (31h, dynamic value)
    Usage (Z),                      ; Z (32h, dynamic value)
    Usage (Rz),                     ; Rz (35h, dynamic value)
    Logical Minimum (0),
    Logical Maximum (255),
    Report Size (8),
    Report Count (4),
    Input (Variable),
    Usage (Hat Switch),             ; Hat switch (39h, dynamic value)
    Logical Minimum (0),
    Logical Maximum (7),
    Physical Minimum (0),
    Physical Maximum (315),
    Unit (Degrees),
    Report Size (4),
    Report Count (1),
    Input (Variable, Null State),
    Unit,
    Usage Page (Button),            ; Button (09h)
    Usage Minimum (01h),
    Usage Maximum (0Eh),
    Logical Minimum (0),
    Logical Maximum (1),
    Report Size (1),
    Report Count (14),
    Input (Variable),
    Usage Page (FF00h),             ; FF00h, vendor-defined
    Usage (20h),
    Report Size (6),
    Report Count (1),
    Logical Minimum (0),
    Logical Maximum (127),
    Input (Variable),
    Usage Page (Desktop),           ; Generic desktop controls (01h)
    Usage (Rx),                     ; Rx (33h, dynamic value)
    Usage (Ry),                     ; Ry (34h, dynamic value)
    Logical Minimum (0),
    Logical Maximum (255),
    Report Size (8),
    Report Count (2),
    Input (Variable),
    Usage Page (FF00h),             ; FF00h, vendor-defined
    Usage (21h),
    Report Count (54),
    Input (Variable),
    Report ID (5),
    Usage (22h),
    Report Count (31),
    Output (Variable),
    Report ID (4),
    Usage (23h),
    Report Count (36),
    Feature (Variable),
    Report ID (2),
    Usage (24h),
    Report Count (36),
    Feature (Variable),
    Report ID (8),
    Usage (25h),
    Report Count (3),
    Feature (Variable),
    Report ID (16),
    Usage (26h),
    Report Count (4),
    Feature (Variable),
    Report ID (17),
    Usage (27h),
    Report Count (2),
    Feature (Variable),
    Report ID (18),
    Usage Page (FF02h),             ; FF02h, vendor-defined
    Usage (21h),
    Report Count (15),
    Feature (Variable),
    Report ID (19),
    Usage (22h),
    Report Count (22),
    Feature (Variable),
    Report ID (20),
    Usage Page (FF05h),             ; FF05h, vendor-defined
    Usage (20h),
    Report Count (16),
    Feature (Variable),
    Report ID (21),
    Usage (21h),
    Report Count (44),
    Feature (Variable),
    Usage Page (FF80h),             ; FF80h, vendor-defined
    Report ID (128),
    Usage (20h),
    Report Count (6),
    Feature (Variable),
    Report ID (129),
    Usage (21h),
    Report Count (6),
    Feature (Variable),
    Report ID (130),
    Usage (22h),
    Report Count (5),
    Feature (Variable),
    Report ID (131),
    Usage (23h),
    Report Count (1),
    Feature (Variable),
    Report ID (132),
    Usage (24h),
    Report Count (4),
    Feature (Variable),
    Report ID (133),
    Usage (25h),
    Report Count (6),
    Feature (Variable),
    Report ID (134),
    Usage (26h),
    Report Count (6),
    Feature (Variable),
    Report ID (135),
    Usage (27h),
    Report Count (35),
    Feature (Variable),
    Report ID (136),
    Usage (28h),
    Report Count (63),
    Feature (Variable),
    Report ID (137),
    Usage (29h),
    Report Count (2),
    Feature (Variable),
    Report ID (144),
    Usage (30h),
    Report Count (5),
    Feature (Variable),
    Report ID (145),
    Usage (31h),
    Report Count (3),
    Feature (Variable),
    Report ID (146),
    Usage (32h),
    Report Count (3),
    Feature (Variable),
    Report ID (147),
    Usage (33h),
    Report Count (12),
    Feature (Variable),
    Report ID (148),
    Usage (34h),
    Report Count (63),
    Feature (Variable),
    Report ID (160),
    Usage (40h),
    Report Count (6),
    Feature (Variable),
    Report ID (161),
    Usage (41h),
    Report Count (1),
    Feature (Variable),
    Report ID (162),
    Usage (42h),
    Report Count (1),
    Feature (Variable),
    Report ID (163),
    Usage (43h),
    Report Count (48),
    Feature (Variable),
    Report ID (164),
    Usage (44h),
    Report Count (13),
    Feature (Variable),
    Report ID (240),
    Usage (47h),
    Report Count (63),
    Feature (Variable),
    Report ID (241),
    Usage (48h),
    Report Count (63),
    Feature (Variable),
    Report ID (242),
    Usage (49h),
    Report Count (15),
    Feature (Variable),
    Report ID (167),
    Usage (4Ah),
    Report Count (1),
    Feature (Variable),
    Report ID (168),
    Usage (4Bh),
    Report Count (1),
    Feature (Variable),
    Report ID (169),
    Usage (4Ch),
    Report Count (8),
    Feature (Variable),
    Report ID (170),
    Usage (4Eh),
    Report Count (1),
    Feature (Variable),
    Report ID (171),
    Usage (4Fh),
    Report Count (57),
    Feature (Variable),
    Report ID (172),
    Usage (50h),
    Report Count (57),
    Feature (Variable),
    Report ID (173),
    Usage (51h),
    Report Count (11),
    Feature (Variable),
    Report ID (174),
    Usage (52h),
    Report Count (1),
    Feature (Variable),
    Report ID (175),
    Usage (53h),
    Report Count (2),
    Feature (Variable),
    Report ID (176),
    Usage (54h),
    Report Count (63),
    Feature (Variable),
    Report ID (224),
    Usage (57h),
    Report Count (2),
    Feature (Variable),
    Report ID (179),
    Usage (55h),
    Report Count (63),
    Feature (Variable),
    Report ID (180),
    Usage (55h),
    Report Count (63),
    Feature (Variable),
    Report ID (181),
    Usage (56h),
    Report Count (63),
    Feature (Variable),
    Report ID (208),
    Usage (58h),
    Report Count (63),
    Feature (Variable),
    Report ID (212),
    Usage (59h),
    Report Count (63),
    Feature (Variable),
End Collection

And if you look at the Teensy USB Joystick complete example code you see:
Code:
void loop() {
  // read 6 analog inputs and use them for the joystick axis
  Joystick.X(analogRead(0));
  Joystick.Y(analogRead(1));
  Joystick.Z(analogRead(2));
  Joystick.Zrotate(analogRead(3));
  Joystick.sliderLeft(analogRead(4));
  Joystick.sliderRight(analogRead(5));
Again notice the Zrotate...
and likewise our descriptor for it>
Code:
static uint8_t joystick_report_desc[] = {
        0x05, 0x01,                     // Usage Page (Generic Desktop)
        0x09, 0x04,                     // Usage (Joystick)
        0xA1, 0x01,                     // Collection (Application)
        0x15, 0x00,                     //   Logical Minimum (0)
        0x25, 0x01,                     //   Logical Maximum (1)
        0x75, 0x01,                     //   Report Size (1)
        0x95, 0x20,                     //   Report Count (32)
        0x05, 0x09,                     //   Usage Page (Button)
        0x19, 0x01,                     //   Usage Minimum (Button #1)
        0x29, 0x20,                     //   Usage Maximum (Button #32)
        0x81, 0x02,                     //   Input (variable,absolute)
        0x15, 0x00,                     //   Logical Minimum (0)
        0x25, 0x07,                     //   Logical Maximum (7)
        0x35, 0x00,                     //   Physical Minimum (0)
        0x46, 0x3B, 0x01,               //   Physical Maximum (315)
        0x75, 0x04,                     //   Report Size (4)
        0x95, 0x01,                     //   Report Count (1)
        0x65, 0x14,                     //   Unit (20)
        0x05, 0x01,                     //   Usage Page (Generic Desktop)
        0x09, 0x39,                     //   Usage (Hat switch)
        0x81, 0x42,                     //   Input (variable,absolute,null_state)
        0x05, 0x01,                     //   Usage Page (Generic Desktop)
        0x09, 0x01,                     //   Usage (Pointer)
        0xA1, 0x00,                     //   Collection ()
        0x15, 0x00,                     //     Logical Minimum (0)
        0x26, 0xFF, 0x03,               //     Logical Maximum (1023)
        0x75, 0x0A,                     //     Report Size (10)
        0x95, 0x04,                     //     Report Count (4)
        0x09, 0x30,                     //     Usage (X)
        0x09, 0x31,                     //     Usage (Y)
        0x09, 0x32,                     //     Usage (Z)
        0x09, 0x35,                     //     Usage (Rz)
        0x81, 0x02,                     //     Input (variable,absolute)
        0xC0,                           //   End Collection
        0x15, 0x00,                     //   Logical Minimum (0)
        0x26, 0xFF, 0x03,               //   Logical Maximum (1023)
        0x75, 0x0A,                     //   Report Size (10)
        0x95, 0x02,                     //   Report Count (2)
        0x09, 0x36,                     //   Usage (Slider)
        0x09, 0x36,                     //   Usage (Slider)
        0x81, 0x02,                     //   Input (variable,absolute)
        0xC0                            // End Collection
};
 
Hey Kurt

Interesting. So essentially the standard is to support single joysticks but if have cases like PS3/PS4/XBOX its going to redefine the standard and put the data into what we are seeing. So now that I understand that one I think I have a better idea what we can do for standard structure - I hope. Have a few more data points to work with though. Curious about HATs now in terms of joysticks or everything goes into buttons.
 
Hi Mike a couple more data points,

As for HID stuff, I like the quote by Paul in the thread post: https://forum.pjrc.com/threads/45740-USB-Host-Mouse-Driver?p=151897&viewfull=1#post151897

I know Paul has done a joystick setup with lots of axis... https://forum.pjrc.com/threads/23681-Many-axis-joystick?highlight=rabbit+hole

And PJRC has a write up about some of it: https://www.pjrc.com/teensy/td_joystick.html

But as for standards for which button is which... Does not appear like any real standard on that one.

HAT: again there is a standard HAT, but as for the area on PS3 and PS4, they are handled/implemented very different on PS3 and PS4

Got to run Annie is restless!
 
Hi Kurt

Make sure you take of Annie. My little one is not feeling too well today. So have to pay attention to her.

Anyway, This link is rather informative, https://forum.pjrc.com/threads/23681-Many-axis-joystick?p=40193&viewfull=1#post40193 (he actually redefines the hid report for up to 8 axes (https://github.com/harlequin-tech/a.../firmwares/arduino-big-joystick/Descriptors.c). Don't think we really want to do that but just make sure we keep track of it for mapping the axes.

This tutorial I found in one of those links is rather informative as well: https://eleccelerator.com/tutorial-about-usb-hid-report-descriptors/
 
Kurt - have you ever looked at the Linux CmdLine on Windows - would it run things like that HID dump tool?
 
Kurt
Here is a problem. If you look at the Logitech Joystick that I have there is actually a slider - on a tool that Paul reference its identified as a axes 6 (slider according to Hid table) but on the non-Bluetooth its showing up as multiple buttons being pressed? Havent tried it with the Bluetooth version but it will probably be the same.

EDIT:
Looks like 1033 is rumble left and 1034 is rumble right on the ps4

EDIT:
Found this which you probably already know:
Code:
 FF00-FFFF | Vendor-defined usage page id
 
Last edited:
Kurt - have you ever looked at the Linux CmdLine on Windows - would it run things like that HID dump tool?
A long time ago, I have also installed the Ubuntu Windows app...

and for example: usbhid-dump
does run, but: it does not find any hid devices... Currently I have a PS3 plugged in and it did not see it.

But first before I say it does not work, I thought I would update the Ubuntu on it.
(sudo apt-get update.... upgrade .... dist-upgrade...
 
Back
Top