Teensy: Keyboard vs Joystick Decision
Teensy: Keyboard vs Joystick Decision
@Wermy
As I was testing the Teensy using my "chiz-built common ground dmg button", I came to realize that since the Teensy was programmed as USB keyboard rather than a USB controller/gamepad, it would only register one keypress at a time and will not allow more than two buttons held down at the same time. I noticed this immediately because as you know, I was testing my setup using a knock-off game pad until I fried it and I was trying a game and immediately I noticed that I can't get to move diagonally -- something that a USB game pad would allow.
I tried reprogramming the Teensy as a USB game pad and as I confirmed, it will now allow simultaneous key presses. See pics below.
I want to leave the Teensy programmed as a USB keyboard as diagonal movements is important for me, think arcade shoot-em up games. I wonder though if you have a specific reason why you chose to implement the Teensy as USB keyboard rather than a USB game pad. Perhaps I'm overlooking something.
This is my "chiz-built common ground dmg button" working as USB keyboard.
And here it is once again, working as USB game pad. Notice that I'm holding two buttons at once and the joystick properties showing two buttons being held.
As I was testing the Teensy using my "chiz-built common ground dmg button", I came to realize that since the Teensy was programmed as USB keyboard rather than a USB controller/gamepad, it would only register one keypress at a time and will not allow more than two buttons held down at the same time. I noticed this immediately because as you know, I was testing my setup using a knock-off game pad until I fried it and I was trying a game and immediately I noticed that I can't get to move diagonally -- something that a USB game pad would allow.
I tried reprogramming the Teensy as a USB game pad and as I confirmed, it will now allow simultaneous key presses. See pics below.
I want to leave the Teensy programmed as a USB keyboard as diagonal movements is important for me, think arcade shoot-em up games. I wonder though if you have a specific reason why you chose to implement the Teensy as USB keyboard rather than a USB game pad. Perhaps I'm overlooking something.
This is my "chiz-built common ground dmg button" working as USB keyboard.
And here it is once again, working as USB game pad. Notice that I'm holding two buttons at once and the joystick properties showing two buttons being held.
Last edited by chiz on Fri May 06, 2016 2:14 am, edited 1 time in total.
- Fleder
- Posts: 849
- Joined: Thu May 05, 2016 9:04 am
- Location: Germany
- Has thanked: 183 times
- Been thanked: 258 times
Re: Teensy: Keyboard vs Joystick Decision
Wow chiz, this is some sick soldering and tape work here!
Would you mind sharing what you've done, since i think everyone will be glad to use more than 1 button at the same time
Would you mind sharing what you've done, since i think everyone will be glad to use more than 1 button at the same time
Re: Teensy: Keyboard vs Joystick Decision
Nice ghetto pcb :3 Good job!
I think the idea of it beeing keyboard is that it can be used as input in for example Openelec if you choose to dual or tripleboot.
But i agree that simultaneaus keypresses are a must in alot of games.
I think the idea of it beeing keyboard is that it can be used as input in for example Openelec if you choose to dual or tripleboot.
But i agree that simultaneaus keypresses are a must in alot of games.
Re: Teensy: Keyboard vs Joystick Decision
@Fleder and @solder
That's my makeshift controller PCB until I get the GBZ controller PCB from Helder. I wanted to get a feel of the space and layout so I went one step further to Wermy's copper tape buttons
Anyways, regarding the USB game pad code... It's readily available and can be opened in the Arduino IDE under the menu, File -> Examples -> Teensy -> USB_Joystick -> Buttons
Once opened, flash the Teensy without any modifications and your game pad should be immediately detected under Windows.
That's my makeshift controller PCB until I get the GBZ controller PCB from Helder. I wanted to get a feel of the space and layout so I went one step further to Wermy's copper tape buttons
Anyways, regarding the USB game pad code... It's readily available and can be opened in the Arduino IDE under the menu, File -> Examples -> Teensy -> USB_Joystick -> Buttons
Once opened, flash the Teensy without any modifications and your game pad should be immediately detected under Windows.
- Robots86
- Posts: 268
- Joined: Thu May 05, 2016 1:18 am
- Location: Birmingham, UK
- Has thanked: 39 times
- Been thanked: 28 times
Re: Teensy: Keyboard vs Joystick Decision
I mentioned this on the last forum and think i will be going the joystick route. Its all about the gaming!
- crispy_tofu
- Posts: 340
- Joined: Thu May 05, 2016 1:51 am
- Location: Australia
- Been thanked: 5 times
- wermy
- Site Admin
- Posts: 1346
- Joined: Tue May 03, 2016 8:51 pm
- Has thanked: 620 times
- Been thanked: 1322 times
- Contact:
Re: Teensy: Keyboard vs Joystick Decision
That's really weird, mine definitely works with multiple button-presses at the same time (I just tried with Sonic Wings 3 and I was able to move diagonally and fire at the same time without issue).
I had done keyboard just to make it easier to configure some emulators. Plus I had planned on making it send arrow key presses, enter and escape, which would make it possible to do some things on the terminal (like scrolling through previous commands and executing them) but for whatever reason I couldn't get arrow keys to play nice.
Anyway, having said all that, USB joypad is of course fine too. I just wonder why yours is acting different than mine...
Edit: Also that hand-made PCB is awesome!
I had done keyboard just to make it easier to configure some emulators. Plus I had planned on making it send arrow key presses, enter and escape, which would make it possible to do some things on the terminal (like scrolling through previous commands and executing them) but for whatever reason I couldn't get arrow keys to play nice.
Anyway, having said all that, USB joypad is of course fine too. I just wonder why yours is acting different than mine...
Edit: Also that hand-made PCB is awesome!
-
- Posts: 279
- Joined: Fri May 06, 2016 5:36 pm
- Has thanked: 16 times
- Been thanked: 229 times
Re: Teensy: Keyboard vs Joystick Decision
I'm using the GPIO pins and the retro game c-code modified for my gpio pin choices. Works awesome and accepts more than one input at a time.
- Fleder
- Posts: 849
- Joined: Thu May 05, 2016 9:04 am
- Location: Germany
- Has thanked: 183 times
- Been thanked: 258 times
Re: Teensy: Keyboard vs Joystick Decision
@chiz
Have you ditched the idea of using the SNES controllers boards?
You were my hope to get this straight, as I am a newbie at electronics.
Is it that the SNES Board requires too much space?
Have you ditched the idea of using the SNES controllers boards?
You were my hope to get this straight, as I am a newbie at electronics.
Is it that the SNES Board requires too much space?
Who is online
Users browsing this forum: No registered users and 1 guest