Bluetooth hid game controller with Teensy 3.1

Status
Not open for further replies.

bigshaq10

Member
Hi, i would like to build a bluetooth gamepad with bluefruit ez-key and teensy 3.1(because the bluefruit doesn't have analog pin). I think everything is ok for the connections between the boards but I have no knowledge for coding the teensy in order to make it communicate with the bluefruit
Can you help me?
 
Yes I know but the problem is that i would like to add 2 joystick to my gamepad and the bluefruit doesn't provide analog pins. That's why i need to connect an additional microcontroller.
 
Yes I know but the problem is that i would like to add 2 joystick to my gamepad and the bluefruit doesn't provide analog pins. That's why i need to connect an additional microcontroller.

Adafruit has some example code that shows how to send keyboard and mouse messages via Bluefruit EZ-Key. I have asked in their forum if it is possible to act like a joystick device, which is what I will need to do for things like the Android-based OUYA.

Here is their page on sending commands serially to the EZ-Key so they are transmitted via Bluetooth:

http://learn.adafruit.com/introducing-bluefruit-ez-key-diy-bluetooth-hid-keyboard/sending-keys-via-serial

There is sample code there that could be easily used on the Teensy.
 
First, sorry for reviving a few month old thread.

I am too also looking at doing something similar. I was planning to purchasing a teensy and using a bluetooth module to make a Bluetooth Gamepad/Joystick. So far what I figured is that the teensy would communicate with the Bluetooth Module via the TX & RX lines along with a power and ground. The main issue is trying to get the teensy to initialize the bluetooth packets as a joystick/gamepad. After that we would just need to figure out how to pass the joystick data over bluetooth instead of USB.

So does anyone know how to do the following:
1) Initialize a bluetooth module as a Joystick/Gamepad
2) Convert the Joystick commands to Bluetooth instead of USB.
 
Unless you get the dev package for those Bluetooth devices (and even then) it will be difficult to convert those serial modules to Joystick Bluetooth devices. I have some of those 8 dollar BT serial devices and am on the email list for the dev environment for them. However, they are a completely different animal. You have to connect a custom programming device to the ones I have to even change the firmware. I have not done this as I am using mine as serial devices.

One thing you could do is use 2 micros and 2 bluetooth serial devices. Have one micro collect the analog data and send over a bluetooth master device, then have a bluetooth slave device grab the serial from it and send to a micro connected to the computer (the one on the computer would be set as a joystick USB device). Even this might require the dev environment for those BT devices. I don't know.

Another possibility is use the bluetooth serial device and write custom software on the PC to emulate a joystick from inputs from the serial device.
 
Status
Not open for further replies.
Back
Top