Forum Rule: Always post complete source code & details to reproduce any issue!
-
Teensy 3.2 Joystick and serial interface compatibility
Hi, I kindly ask for help or guidance with the following problem.
best regards, Christian
Problem description
I am using the Teensy 3.2 board https://www.pjrc.com/store/teensy32.html as USB gamecontroller for a PC running Windows 10 home.
I am using the Arduino IDE 1.8.5 with Teensyduino 1.44
When compiling with USB Type "Keyboard + Mouse + Joystick" everything works fine: On the PC, I am using "USB gamecontroller einrichten" - "Eigenschaften" and can see the full Joystick with its pushbuttons and axis (Screenshot 1)
However, when compiling with USB Type "Serial+ Keyboard + Mouse + Joystick", on the PC, only the Pushbuttons are shown, no axis (Screenshot 2)
Screenshot 1:

Screenshot 2:

Source Code
After several test with my own code I found out, that the application seems to be irrelevant. I verified the problem with the "blink" example from Arduino, which is of course not able to make use of the Joystick but shows the same behaviour regarding the initialisation as described above.
For completeness, I posted the code of the blink example here, but as I said, the code seems to be irrelevant.
/*
Blink
Turns on an LED on for one second, then off for one second, repeatedly.
This example code is in the public domain.
*/
// Pin 13 has an LED connected on most Arduino boards.
// Pin 11 has the LED on Teensy 2.0
// Pin 6 has the LED on Teensy++ 2.0
// Pin 13 has the LED on Teensy 3.0
// give it a name:
int led = 13;
// the setup routine runs once when you press reset:
void setup() {
// initialize the digital pin as an output.
pinMode(led, OUTPUT);
}
// the loop routine runs over and over again forever:
void loop() {
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
-
Is anybody able to reproduce this problem?
Dear community,
it would be great to know, if I am the only one having this problem. Could anybody give it a try and reproduce it?
I am also thankful for any hints, what I could try further.
Thank you, Christian
-
I see no problem with Win 10, IDE 1.8.7, Teensyduino 1.44, Teensy LC, Joystick example Complete.
-
Thank you
gdsports!
I tested on two different PCs and had the problem on both of them.
I just studied your postings in this threat here https://forum.pjrc.com/threads/54227...implementation which is somehow related.
I am still not sure, if this is a bug on teensy side or on the PC.
I guess, I will try the following:
- try this joystick test application instead of using the windows properties: http://www.planetpointy.co.uk/joysti...t-application/
- test with more PCs I can get access to
- try your Teensyduino patch https://forum.pjrc.com/attachment.ph...3&d=1543740882 from the threat mentioned above
I am aware, this sounds more like trial and error instead of analyzing the problem at its roots, but I guess I'd need lots of time to learn how to trace and debug HID messages. Currently, I'd have no idea how to do that.
-
I tried the same TeensyLC from yesterday on an up to date Win 10 PC and it shows the same problem you are seeing. The first test was before a large number of Windows updates were installed.
-
Tested TeensyLC with Joystick and Joystick + Serial on an up to date Win10 computer. Both options work. I updated the zip file on the other thread to enable Joystick + Serial on all Teensy 3.x and LC.
-
Thank you, gdsports, you made my day!
I will try this evening / tomorrow morning with the new zip file.
-

Originally Posted by
gdsports
Tested TeensyLC with Joystick and Joystick + Serial on an up to date Win10 computer. Both options work. I updated the zip file on the
https://besttechexpert.guide thread to enable Joystick + Serial on all Teensy 3.x and LC.
Got it! Thanks.
-

Originally Posted by
gdsports
Tested TeensyLC with Joystick and Joystick + Serial on an up to date Win10 computer. Both options work. I updated the zip file on the other thread to enable Joystick + Serial on all Teensy 3.x and LC.
Just tested with Joystick + Serial and it works. @gdsports: thank you again for your help!
I built a special gamepad based on Teensy and want to use the serial connection for downloading different configurations.
Now, I can continue working on the configuration interface.
-
Joystick patch updated to Teensyduino 1.45.
joystick_teensy_1.45_20181212.zip
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules