XIM Community

General Category => Tutorials => Topic started by: W11cE on 10:22 AM - 01/20/13

Title: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 10:22 AM - 01/20/13
The latest version here: 08012016 (https://drive.google.com/open?id=0B_0MQrj9_eGtZm1PTHRQdGpYWkk)

Install on the top of Arduino IDE 1.6.7 and Teensyduino 1.27


Short description:
This package adds 3 custom USB modes for teensy 3.0, 3.1, 3.2 and LC.
 - Joystick VER 1 is recommended for XIM 3 and EDGE. (Does not work with XIM 4).
 - Joystick VER 2 is for XIM 4.
 - Modified mouse USB mode with support for Aux buttons for XIM 3, 4 and EDGE.


Joystick VER 1
Code: [Select]
Joystick.X(val);
Joystick.Y(val);
Axis values between 0 and 1023.

Code: [Select]
Joystick.Button(button, val);
Joystick.button(button, val);
Button from 1 to 11. Val 1 = pressed, 0 = released.


Joystick VER 2
Code: [Select]
Joystick.X(val);
Joystick.Y(val);
Axis values between 0 and 1023.

Code: [Select]
Joystick.Button(button, val);
Joystick.button(button, val);
Button from 1 to 35. Val 1 = pressed, 0 = released.


Mouse
Code: [Select]
Mouse.X(val);
Mouse.Y(val);
Mouse axis relative movement.

Code: [Select]
Mouse.scroll(val);
Mouse.pan(val);
Use these for scroll direction(0 is centered):
Code: [Select]
SCROLL_UP
SCROLL_DOWN
PAN_LEFT
PAN_RIGHT


Code: [Select]
Mouse.Button(button, val);
Mouse.button(button, val);
Val 1 = pressed, 0 = released. Use these for button names:
Code: [Select]
XIM4_Left
XIM4_Right
XIM4_Middle
XIM4_Back
XIM4_Forward
XIM4_Aux1
XIM4_Aux2
XIM4_Aux3
XIM4_Aux4
XIM4_Aux5
XIM4_Aux6
XIM4_Aux7
XIM4_Aux8
XIM4_Aux9
XIM4_Aux10
XIM4_Aux11
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:42 AM - 01/20/13
Congratulations W11ce major breakthrough :D
Will build this right away!
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 10:56 AM - 01/20/13
Thanks! This has been a real challenge. Gave up few times, but i got it working :)
Is the tutorial enough clear to you? You are a good benchmark for tutorial difficulty  ;D
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:59 AM - 01/20/13
We need a picture of you W11ce you are officially the Ximmer of the decade this opens a lot of new possibilities. You are awesome! Take this, a bunch of keys, a Joystick and make your own input device!
Add a Joystick to any device no controller needed.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:01 AM - 01/20/13
First question, is the middle foot of the potentiometers of  joystick needed? Never saw one of these except in dualshock controllers. Dunno where to get such a joystick. Are these 5000 Ohm each direction?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 11:06 AM - 01/20/13
We need a picture of you W11ce you are officially the Ximmer of the decade this opens a lot of new possibilities. You are awesome! Take this, a bunch of keys, a Joystick and make your own input device!
Add a Joystick to any device no controller needed.
Lol. Thanks, but maybe only xim modder of the decade  ;)


First question, is the middle foot of the potentiometers of  joystick needed? Never saw one of these except in dualshock controllers. Dunno where to get such a joystick. Are these 5000 Ohm each direction?

Xbox 360 controller joysticks are all like these. If you mean that leg that connects to yellow wire, then yes it is needed. I think these are 5kOhm each direction. With 3 wire pots it doesnt matter.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:08 AM - 01/20/13
Oh long time I did not check then sorry sure three legs :D
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:09 AM - 01/20/13
Where do you connect the 11 buttons?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: OBsIV on 11:10 AM - 01/20/13
How many GPIOs does the board have? The reason I ask is because you have gotten pretty close to a device that would sell a lot to the Accessibility community. A device that has a bunch of stereo phone jacks (for connecting Accessibility foot/hand/etc petals) and converts to a USB hid for input into devices like XIM or PC etc.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:16 AM - 01/20/13
If you help him mimic the G13 he would have 21(?) buttons? To my understanding this talks as attack 3 Joystick.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 11:30 AM - 01/20/13
How many GPIOs does the board have? The reason I ask is because you have gotten pretty close to a device that would sell a lot to the Accessibility community. A device that has a bunch of stereo phone jacks (for connecting Accessibility foot/hand/etc petals) and converts to a USB hid for input into devices like XIM or PC etc.
34 total, 12 can be used as an analog input and 10 as a PWM output.
Yeap, this makes easy conversion from any arduino compatible device to HID. I have some ideas already, just need some time to make those.

Where do you connect the 11 buttons?
It depends on the code. Where do you want those?

If you help him mimic the G13 he would have 21(?) buttons? To my understanding this talks as attack 3 Joystick.
I might not need his help. I already know what to do ;)
And yes this talks like Attack 3. With G13 clone there would be 35 buttons.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: Od1n on 11:54 AM - 01/20/13
what exactly is a teensy 3.0? ._.

maybe include that into your tut for noobs like me ;)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:58 AM - 01/20/13
Quote
With G13 clone there would be 35 buttons.

Get to it man this is awesome.

Quote
It depends on the code. Where do you want those?

Dont care just code them somewhere so they work.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:04 PM - 01/20/13
Teensy is a programmable controller board Od1n. W11ce for complete noobs you need to draw the picture without the test board.

watch this Odini

http://www.arduino-tutorial.de/
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:05 PM - 01/20/13
If you code the buttons in I will make my own controller tomorrow W11ce. Have a Teensy 3.0 here already.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:20 PM - 01/20/13
(http://img228.imageshack.us/img228/9025/cimg1080y.jpg)

This is an arduino mini controlling a G400 also a W11ce project I was allowed to build.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: Boltman on 12:56 PM - 01/20/13
(http://img228.imageshack.us/img228/9025/cimg1080y.jpg)

This is an arduino mini controlling a G400 also a W11ce project I was allowed to build.

I've seen videos and I'm semi familiar (now) with what it's all about, sounds very promising indeed.

A few out there with very minimal views of people doing some pretty dubious things hehe.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:01 PM - 01/20/13
Itís a great step to get out of the badly designed input devices and make something much better.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:40 PM - 01/20/13
Ok, i will make this tutorial a little more noob friendly.

roads here is your code for 11 buttons:
Code: [Select]
#define BUTTONSREVERSED

void setup() {
  pinMode(0, INPUT_PULLUP);
  pinMode(1, INPUT_PULLUP);
  pinMode(2, INPUT_PULLUP);
  pinMode(3, INPUT_PULLUP);
  pinMode(4, INPUT_PULLUP);
  pinMode(5, INPUT_PULLUP);
  pinMode(6, INPUT_PULLUP);
  pinMode(7, INPUT_PULLUP);
  pinMode(8, INPUT_PULLUP);
  pinMode(9, INPUT_PULLUP);
  pinMode(10, INPUT_PULLUP);
}

void loop() {
 Joystick.X(analogRead(0));
 Joystick.Y(analogRead(1));
 Joystick.button(1, digitalRead(0));
 Joystick.button(2, digitalRead(1));
 Joystick.button(3, digitalRead(2));
 Joystick.button(4, digitalRead(3));
 Joystick.button(5, digitalRead(4));
 Joystick.button(6, digitalRead(5));
 Joystick.button(7, digitalRead(6));
 Joystick.button(8, digitalRead(7));
 Joystick.button(9, digitalRead(8));
 Joystick.button(10, digitalRead(9));
 Joystick.button(11, digitalRead(10));
}

Connect buttons between ground and digital pins. Pin 0 = button 1 and pin 10 = button 11. And others between those in order.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:58 PM - 01/20/13
Thanks Master W11ce I am good to go.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 05:00 AM - 01/21/13
Excuse me for sounding dumb but what does that thing do qyboshed into your mouse, or rather what does it do and how or where can i use it.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:30 AM - 01/21/13
Oh thatís an arduino mini and it lights up three Diodes LOL

Just kidding, its Skynet.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 05:52 AM - 01/21/13
Cheers Roads thanks for the heads up i will look into this a bit more.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 11:13 AM - 01/21/13
Roads how do you like the new wiring pic? And how is your wiring going? And does the code even work?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:26 AM - 01/21/13
Quote
For people that are scared of breadboards (like roads...)

This is not funny at all, not at all. :)
The new wiring pic is quite easy no you dont have to know much to solder those cables.

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:30 PM - 01/21/13
Here is a 10 minute solder of a Cherry Keyboard with analoge stick that is by definition already better than 90% of all left hand input devices out there as it has cherry keys and an analogue joystick :D.


Mac OSX be sure the files are in the right location. Open the Arduino app for this and look for the java folder. If you copied all files correctly you will see the example code in the arduino software and you will be able to choose the XIM Joystick instead of the standard Teensy joysticks.


(http://imageshack.us/a/img11/6013/cimg1081d.jpg)

(http://img21.imageshack.us/img21/4892/teensy1.png)

(http://img805.imageshack.us/img805/7017/teensy2.png)

(http://img255.imageshack.us/img255/5811/teensy3.png)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:19 AM - 01/22/13
Nice pics roads :) but the last one is a little wrong. The example should be in examples menu, not in scetchbook. And that code on the background is not exactly the example one.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 03:33 AM - 01/22/13
(http://img10.imageshack.us/img10/2597/teensy4.png)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:36 AM - 01/22/13
Ok, thanks. Ill add these to the tutorial. Is it ok ?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:20 AM - 01/22/13
That is why I made them, sorry its German.

I can confirm that all my 4 buttons (11 showing but only 4 attached) are working in Joy.cpl in windows7 as well as the analog Joystick. Someone else will have to test this on the Xbox as I sold mine.

Really simple to build.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:28 AM - 01/22/13
btw on the Mac the Teensy should be usable with Controllermate, it is showing up there. Not that I have much use for it there but who knows what Apple might do in the future concerning Gaming.

(http://img27.imageshack.us/img27/3324/teensy5.png)

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 04:43 AM - 01/22/13
Ok, good. Just realized that many pc games support xbox 360 controllers, but not regular joystick controllers. So this needs directinput to xinput app. Do you have a good one in your mind ?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:03 AM - 01/22/13
Cant it just mimic an Xbox controller as it mimics the Joystick?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 05:06 AM - 01/22/13
Dont think so. It has that extra chip for security, remember ?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:18 AM - 01/22/13
hmm yeah right. So for PC my N52te mod stays the way to go? Unbelievable but the games do not support other joysticks at all..
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 05:25 AM - 01/22/13
Found x360ce. It will make this step really easy. Dunno why games dont support Dinput. And 360 controller support is also barely there in some games. Just noticed that in borderlands 2 there are no settings menu for 360 controller, but it still works.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:32 AM - 01/22/13
Maybe the next gen Controllers will talk Dinput on that Win8 surface.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 05:36 AM - 01/22/13
Lol no. Xinput was made for xbox 360 controllers. Dinput is old and not good for gamepads.

"While DirectInput forms a part of the DirectX library, it has not been significantly revised since DirectX 8 (2001Ė2002). Microsoft recommends that new applications make use of the Windows message loop for keyboard and mouse input instead of DirectInput (as indicated in the Meltdown 2005 slideshow[1]), and to use XInput instead of DirectInput for Xbox 360 controllers."

That was in wikipedia. So yeah, old...
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:42 AM - 01/22/13
Ah ok so why is the Teensy talking Xinput? Maybe a feature request for the Dev?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:16 PM - 01/24/13
(http://img5.imageshack.us/img5/5949/unbenanntjgw.png)

(http://img255.imageshack.us/img255/8776/unbenannt2cn.png)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:29 AM - 01/25/13
OK so with the Teensy, a Joystick and a USB Hub you can now just attach a Joystick to just any device you like for movement as WASD replacement. For Windows games you use X360ce to translate the commands.

W11ce we still need an easy DIY small internal USB hub or a small and cheap one we can strip and use? You have any solution for this?

Joystick only is this, 6 wires to solder 6y old can do. Flash the Teensy with the software, analog stick on XIM.

(http://img201.imageshack.us/img201/8698/cimg1082q.jpg)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 06:39 AM - 01/26/13
Cool liking it guys.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 07:12 AM - 01/26/13
Cool liking it guys.
Thanks. Have you ordered your teensy ?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 05:03 AM - 01/27/13
Cool liking it guys.
Thanks. Have you ordered your teensy ?

Note yet I am watching and reading your posts obviously you guys are way more intelligent than i am i have no programing skills what so ever I come from the era of computers that was the ZX81.
So right now just watching and trying to learn what you are doing.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:48 AM - 01/27/13
Na Mara I cant program what W11ce does but building this is super easy. Its perfect for the XIM, you just buy a Teensy 3.0 an analoge Joystick, a small USB Hub you strip to the platina and you can remove the controller from my mod. Its perfect for XIM but not PC. PC you need that X360ce software that totally does not work for me, tried everything. It works for W11ce though. Also on PC you need to hope X360ce supports the game so its like on the XIM waiting for STs if you have bad luck. So for PC I sadly dont see this as replacement for my N52te mod. The Teensy would need to speak Xinput which it cant.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:23 PM - 01/27/13
Sorry that x360ce doesnt work for you roads. For me it works great.

I was supposed to update this tutorial this weekend, but forgot/ didnt have time for that. It is always a nightmare to edit that long post with that long links. I try to get it done next week.

Also ive started to prepare for analog kb mod. Still cant decide which kb to buy...
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:57 PM - 01/27/13
W11cE quick question I'm interested in this very much as i am playing Birds of Steel on ps3 at the moment and supported flight sticks are limited to only few officially liecensed ones as usual.
Looking here http://www.pjrc.com/teensy/td_joystick.html would this work for me to use a PC stick through the Teensy to enable me to buy a pc stick which is miles better than the ones for ps3.
Currently i am using the Thrustmaster Hotas x stick which is a good stick but it has this very anouying deadzone which just can't be eliminated and makes fine aiming frustrating to say the least.
I would be looking at getting the Wharthog stick with yaw peedles for a complete set up details found here http://www.simhq.com/_technology3/technology_174b.html
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:14 PM - 01/27/13
I had in my mind a "HID converter" device, which would read a device connected to it and then send input in wanted format to xim. Usb HID host shield does not work currently with teensy 3.0. That is a "little" problem.

But you are going to use it without xim? How many axes does those things have ?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 03:40 PM - 01/27/13
Yeah i was thinking not through the xim just the Teensy asuming that the ps reads it as a controller with the wharthog attached as for axis i'll do some more research.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:47 PM - 01/27/13
If it can work without drivers as a regular hid joystick it should be possible.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 03:49 PM - 01/27/13
Quote
Sorry that x360ce doesnt work for you roads. For me it works great.

Not your fault :) I will for sure try upcoming releases. As I said perfect for the XIM3.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 03:50 PM - 01/27/13
The push sensitive keyboard , why do you need a kb? Cant you attach this to the Teensy? What I mean is make it possible for every cherry user to make this.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 04:01 PM - 01/27/13
The push sensitive keyboard , why do you need a kb? Cant you attach this to the Teensy? What I mean is make it possible for every cherry user to make this.
Well, to do a keyboard mod i propably need a keyboard. What do you mean?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:08 PM - 01/27/13
Just the keys I mean independent of a keyboard on teensy over USB hub.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 04:12 PM - 01/27/13
Just the keys I mean independent of a keyboard on teensy over USB hub.
Nope. I will do it with keyboard. I was planning on glueing hall sensors on kb pcb. So you cant really do this mod with only few cherry switches.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:38 PM - 01/27/13
I am back in business the problem was the Teensy XIM HID was not set as preferred device in joy.cpl. Add this to your tutorial as this is a hard one to find. X360ce is working flawlessly now, no stall and Dishonored starts normally and the stick moves as intended. Man this cost me hours and hours and its stated nowhere with weird errors. Add it to your Tutorial by all means W11ce!
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:11 AM - 01/28/13
Another thing, to me it looks as in the Orbweaver the joystick will be a tight-fit or no-fit. Do you know about smaller form factor joysticks? I also thought about a sliding mechanism with the potentiometers flattened down. Could be nice to use with the Orbweavers D-pad button. We just need a slider button, I think they build them for the Iphones/Ipads.
Like this just not 145$ :)

http://www.broadenedhorizons.com/versatility-psp-style-fingertip-slider-joystick

Right now I really have a problem paying 130Ä for that Razer.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 06:23 AM - 01/28/13
Good to hear that it works for you now :)
Funny thing. I just got few of those. PSP joysticks. I was going to add these to mouse  ;D, Dunno how those would feel on N52te or orbweaver.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:03 AM - 01/28/13
I think they would feel quite nice as the motion you have to do with the ps3/xbox thumbsticks is quite huge. I got used to it quickly but I found it the motion too large. Where did you get those and for how much? Could you try the feel on the N52te? How do you wire those 4 pins?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 07:14 AM - 01/28/13
I think they would feel quite nice as the motion you have to do with the ps3/xbox thumbsticks is quite huge. I got used to it quickly but I found it the motion too large. Where did you get those and for how much? Could you try the feel on the N52te? How do you wire those 4 pins?
The same as always. Ebay: china/asia. And price few $
Dunno about wiring yet. Have to do some research ;)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:25 AM - 01/28/13
If you find out I have a spare N52te part for the Joystick so I could hotglue it up there. My feeling is it will be nice if those joysticks are not hard to move. Never touched one.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:01 AM - 01/29/13
This is awesome, I did an external Teensy mod and it works perfectly. Again a big thanks to our Chief Modder W11ce. This way I can connect the Controller as it was before or connect the Teensy. Of course internally with a switch also internal would be nicer but I would like to keep the controllerversion on PC possible if there are games not supporting X360ce. I will do the internal mod to the Orbweaver. I found an Extender is the best housing as it is big enough and it has an Ethernet and USB connection like I need it for my mod. Some pictures.

(http://img42.imageshack.us/img42/4498/cimg1088v.jpg)

(http://img198.imageshack.us/img198/1681/cimg1089s.jpg)

(http://img832.imageshack.us/img832/9843/cimg1090k.jpg)

(http://img4.imageshack.us/img4/4260/cimg1092z.jpg)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 10:19 PM - 01/29/13
Nice. Looking goo... well, better than that controller hanging there  ;D
You could have put also a usb hub inside that box.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:20 PM - 01/29/13
Yeah but then there are two cables running to the N52te from the box, ugly also + a dangling cable when connected to modded controller.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:59 AM - 01/30/13
Yeah but then there are two cables running to the N52te from the box, ugly also + a dangling cable when connected to modded controller.
No, i meant there would be usb connector in that box. Then you connect that usb cable coming from N52te to that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:15 AM - 01/30/13
I get you but then I have to either shorten the N52te USB cable or lengthen the CAT cable I am using for the joystick pots. The analogue signal wouldnít like it above 50cm there are problems with the resistance of the cable also that adds to the pots and the stick begins to move. The problem here is I want to keep my controller mod. Itís the best way imo with the Extender. The Orbweaver will look unchanged from the outside except the analogue stick as you suggested. I am just waiting for Amazon to sell it so I can give it back if I dont like it.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 12:47 PM - 02/01/13
Roads am i right in thinking that the teensy device you have in there is basically working as your old xbox controller or am i just being stupid lol
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:08 PM - 02/01/13
That is right You do not need a controller any more for the N52te mod thanks to W11ce. I mean you still need one for operating the XIM but now you can put it far far away. Its also not replacing a controller but mimics an attack3 joystick. Put the Teensy inside with a USB hub. I will do that with the Orbweaver soon.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 10:40 AM - 02/03/13
I had in my mind a "HID converter" device, which would read a device connected to it and then send input in wanted format to xim. Usb HID host shield does not work currently with teensy 3.0. That is a "little" problem.

But you are going to use it without xim? How many axes does those things have ?

W11cE heres some more info on the Warthog stick the video shows how many axis there are and their adjustments the funny thing the graph on the right some what resembles the ballistics graph for xim edge bizzare.
http://www.youtube.com/watch?v=rVyVlzVn4gU
And another
http://www.youtube.com/watch?v=-aheDJkfb-E

I think this is going to be a no no though as it does need software installed to work lokking at the vids i could be wrong.

Found this to a link to a complete set of scripting instructions and button mappings which you may understand but to me it looks painfull   http://ts.thrustmaster.com/download/accessories/pc/hotas/software/TARGET/TARGET_Script_Editor_Basics_v1.5_ENG.pdf
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:04 PM - 02/03/13
It looks like it would not work with teensy. Maybe could be done easily with XIM Bridge.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:18 PM - 02/03/13
Sorry, I was just using it as an example, never used a G13 and I thought it emulated both and could be used for keystrokes.

this 40 key version of the teensy code probably uses some keyboard matrix or similar right? do you think that we could create the switchable profiles and led indicators that the n52te has and completely sacrifice the n52te's circuitry? I don't mind if I have to manually code the profiles.

I'm thinking it could really open up the XIM for possibilitys.

Sorry if I seem over excited I just have no knowledge of ardiunos and the possibilitys seem awesome

One more question; can the XIM pass rumble to a joypad? we might be able to add that too!

You can use keyboard matrix or just "regular" wiring. 40 key max is just on the HID side, which is what is sent to XIM. How you define when and what button is pressed is up to you.

Profiles, led indicators: sure. We already have plans with roads for independent teensy circuit.

Nothing we can do with rumble. XIM3 or Edge does not pass rumble through.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 01:01 PM - 03/01/13
i come late to the party as usual...

i'm thinking of doing this, but not until orbweaver is a little more out there. i want red cherrys and a psp stick on the thing. (maybe new RGB LEDs if i can get the teensy to control them)

hey W11cE first off, fu*king congrats man, creation of the year.

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:35 PM - 03/01/13
i come late to the party as usual...

i'm thinking of doing this, but not until orbweaver is a little more out there. i want red cherrys and a psp stick on the thing. (maybe new RGB LEDs if i can get the teensy to control them)

hey W11cE first off, fu*king congrats man, creation of the year.
Thanks. RGB leds are not a problem to control. But the problem is to get those under cherry keykaps. 3mm leds barely fit there.

There are still few problems to solve. First, teensy freezes when rebooting host device without total power loss (regular pc reboot). This is not my "fault". I believe it is a bug or "feature" in teensys bootloader. I have posted about this to pjrc forums.

Second, Im working on G13 clone code now. Works now with pc and XIM3, but Edge freezes 2 seconds after connecting. Might be painfull to get working. With this code we get 35 buttons for XIM3 and Edge.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 09:41 PM - 03/01/13
tell me about it..

the orbweaver comes with G LEDs so it would be as "simple" as to replace them with RGB LEDs, but as a quick research on the market as taught me 3mm RGB LEDs are hard to find and their price is expensive as hell.

honestly i think i'm missing something because every android phone i see has a notification LED which in most cases is RGB and the thing is quite small..
never the less just thinking about the replacement procedures makes me throw up =X



about the mod, the most important part is done, which was analog. you should relax a bit and enjoy it now xD
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:26 AM - 04/04/13
Found this guys any good or not looks it to me but i am not technically minded http://www.leobodnar.com/shop/index.php?main_page=product_info&cPath=87&products_id=210
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:49 AM - 04/04/13
What do you need an 8-way for, you want analogue, no?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:20 AM - 04/04/13
Where do you want to use it? If you are asking will it work with teensy then yes, propably.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 08:14 PM - 04/04/13
Hold the bus i just stumbled across it and as it looked nice and small i thought it would fit nicely into the n52te without to much effort plus its already on a pcb making it even simpler you even get the wires plus a cheap price to.
I didn't read it properly as i was in a hurry an running late for work, so is the fact that its 8 way not very good and whats wrong with analouge is that not what the current controller sticks are.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:38 PM - 04/04/13
Mara 8 way is 8 directions only whereas analog is infinite directions. Thatís why we did the N52te mod in first place the N52 has a 4-way D-pad.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 11:35 AM - 04/05/13
Those pcbs are usually not good for tight places. Those are easy to connect and handle, which makes those good for prototyping. But for more permanent solution those are not usually good. And that stick doesnt look good imo anyways.

And analog is not infinite. In this case we have 65536 positions. Position can be defined with direction and distance, so from that we can get number of possible directions... and uuh.
Just wanted to point out that it is not infinite. My INTJ mind can not allow this comment just pass by without comment ;)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:44 AM - 04/05/13
Thank you W11ce LOL :)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 05:52 AM - 05/17/13
Hows this going guys found this site if its of interest to you http://www.piengineering.com/index.php

Is it all working now and does this work for PS the reason I ask is as Roads will remember the DS3 controller sticks have 4 x 4 x 4 pins on them not the 3 x 3 x 3 on the one you guys are using not sure if that makes a difference or not.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:03 AM - 05/17/13
Just get the same Stick as in the device.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:48 PM - 05/17/13
What 4 or 3 pin joysticks has to do with this?

About this project: I have a lot of new features in my mind. Im planning on buying this: http://www.adafruit.com/products/708

One wild idea that i have is to mimic easy transfer cable. Xim3 and edge are too stupid to tell the difference ;). In theory this should be possible. How hard can it be  ???

Also i pledged on this: http://www.kickstarter.com/projects/1650950769/rigidbot-3d-printer
So it is 3d printed parts on christmas :)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 09:35 PM - 05/17/13
What 4 or 3 pin joysticks has to do with this?

About this project: I have a lot of new features in my mind. Im planning on buying this: http://www.adafruit.com/products/708

One wild idea that i have is to mimic easy transfer cable. Xim3 and edge are too stupid to tell the difference ;). In theory this should be possible. How hard can it be  ???

Also i pledged on this: http://www.kickstarter.com/projects/1650950769/rigidbot-3d-printer
So it is 3d printed parts on christmas :)

$400 ?! ... well if you have the cash to burn then by all means do it please!

ahahah i bet it will be usefull for xmas.. those hollydays have a tendency for that kind of solutions.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 04:19 AM - 05/18/13
What 4 or 3 pin joysticks has to do with this?

Quite simple really the xbox pots use a 3 x 3 x 4 config for the connection to pcb and the DS3 sticks use a newer model with magnetic pots which have a connection config of 4 x 4 x 4 to the pcb.
So will I have any conflicts am I the first to do this for ps if so that's fine I have no quams with a leap of faith as long as its not a long way down lol.
The teensy is on its way.
I have plenty of spare sticks left from destroying controllers the last time.
I know for a fact that the pins 1 and 4 on each side of the pot are grounds along with 1 of the ones for click down state of stick.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: CharlieSears on 08:14 PM - 05/20/13
Did you make any changes to USB_Dev.h/c? I cant seem to compile the example sketches.

I'm not very clever, I installed it on Arduino 1.0.4, not 1.0.3 as you stated.

Everything works swimmingly now.

Thank you for this!
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:30 AM - 05/21/13
Did you make any changes to USB_Dev.h/c? I cant seem to compile the example sketches.

I'm not very clever, I installed it on Arduino 1.0.4, not 1.0.3 as you stated.

Everything works swimmingly now.

Thank you for this!
Np. Nice you got it working. Im doing a new version of this with new features. It will be compatible with newest arduino and teensy software versions.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:11 PM - 05/23/13
Ok got my Teensy and man that's a little tiny tiny board that came in a big big box full of polystyrene stuff.
I nearly had a fit when I opened the bag looking for it where is it then just these pieces of card and paper and a little pink plastic bag that's a bit hard whats in there lol there it is.

Ok so moving on got all the programs downloaded and the Teensy is configured seems to be working and recognising sketches.

Now onto the proto i'm not sure about these PS3 sticks as they have hall sensors look here http://forums.xbox-scene.com/index.php?showtopic=648322 and scroll down to picture 5.

So I have coming out of each side 1 ground 1 vcc and 2 poles so will these sticks work and how to wire them to the Teensy it must be achievable just not sure how at the moment.

Any ideas guys I do have some other 3rd party controllers which have the old pots style perhaps I should strip out one of those instead maybe.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 05:27 PM - 05/24/13
Why did you buy it in a big box :o I got TWO teensys in a letter with some bubble wrap.

I have no idea how to wire 4 pin hall sensors. Usually hall sensors have 3 pins: +, ground and signal. Maybe could measure how resistance changes in those pins when stick is turned. But easiest would be ofcourse using joystick with 3 pins.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 04:12 AM - 05/25/13
Why did you buy it in a big box :o I got TWO teensys in a letter with some bubble wrap.

I have no idea how to wire 4 pin hall sensors. Usually hall sensors have 3 pins: +, ground and signal. Maybe could measure how resistance changes in those pins when stick is turned. But easiest would be ofcourse using joystick with 3 pins.

I suppose mine had to come in a big box as I am the other side of the pond or maybe since yours a customer received a damaged one so now they ship in a box like 10 times the size of it.

Yeah I have gone for the strip a 3 x 3 from a third party controller seems the best way to go and I already know the stick works as it was a controller before I destroyed it lol.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:05 AM - 05/30/13
Just want to say that I am playing Tomb Raider with the "W11ce device" and its working great. The Controller plus mouse on the other hand and not the W11ce dont work side by side. I have no idea if its my system or not. I searched everywhere on it to find why I cant look around while moving. Oh and TR is patched up well now, worth a play.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:20 PM - 05/30/13
Just want to say that I am playing Tomb Raider with the "W11ce device" and its working great. The Controller plus mouse on the other hand and not the W11ce dont work side by side. I have no idea if its my system or not. I searched everywhere on it to find why I cant look around while moving. Oh and TR is patched up well now, worth a play.
Nice. Do you need to use x360ce with teensy?
TR was ~14Ä in greenmangaming few days ago. Should have bought it, but i have other games on my list too.

I have made some progress with analog kb. Found right magnets, so now it looks like this might work :) I will test tonight how gaming feels with this. If it works, i will propably get tutorial done in 1-2 weeks.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:32 PM - 05/30/13
Did not try without but I will.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 03:20 AM - 05/31/13
Doesnít work without 360ce and the startup bug is still present. You have to reconnect it so it works or connect it after boot. Anything new on that from the Teensy Dev?

Btw TR is really nice to play with the N52te+mouse much better than I thought after you learn the three quickmoves you need in the game. right-left, meelee and apply. These are the only three needed in the action cinematics. As Mist wrote some months ago its pretty tough, if you dont make it out with the keycombos you see Lara being headshot, pierced, suffocated etc. over and over and over. Pretty tough and its somehow wrong.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: mist4fun on 01:31 PM - 05/31/13
W11cE were you the one who made the teensy a ps3 to xbox converter? Did you plan to attempt this for next gen?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 05:34 PM - 06/01/13
Doesnít work without 360ce and the startup bug is still present. You have to reconnect it so it works or connect it after boot. Anything new on that from the Teensy Dev?

Btw TR is really nice to play with the N52te+mouse much better than I thought after you learn the three quickmoves you need in the game. right-left, meelee and apply. These are the only three needed in the action cinematics. As Mist wrote some months ago its pretty tough, if you dont make it out with the keycombos you see Lara being headshot, pierced, suffocated etc. over and over and over. Pretty tough and its somehow wrong.
Yeah ok, then it uses xinput only, just like most console ported games. I hope on the next gen we will get at least some level joystick support on pc games, xinput or dinput.

W11cE were you the one who made the teensy a ps3 to xbox converter? Did you plan to attempt this for next gen?
No i havent done that. I have had some plans, but i dont think i have talked about those on this forum. I have plans for next gen.

It depends on what security next gen controllers will have. Now:
PS3: No security check. Any device that says it is DS3 will be accepted.
XBOX 360: Security check when controller is connected. 2 reports are sent to controller. If those are answered wrong, xbox 360 will stop communicating with the controller.

If next gen consoles will have same security than this gen, PS4 adapter will be easy. If controller descriptors are leaked before release, it is possible to get this done before release.

Xbox 360 type security is trickier. Theoretically this is possible to do. Im just not sure if i have needed skills. We need to throw those security checks to a real xbox 360 controller. Just what PS3 to xbox 360 adapters are doing now.

Also there is one critical requirement: Host shield support for teensy 3.0. Currently it is unsupported, but i hope teensy dev will get it working during this summer.
This is the shield im talking about: http://www.circuitsathome.com/products-page/arduino-shields/usb-host-shield-for-arduino-pro-mini/

If this adapter is done it will work for all wired xbox 360 controllers and adapters (XIM2, XIM3, XIM Edge). And also all other devices that can be connected to teensy (joystick on a potato!!! :o)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 09:38 PM - 06/01/13
Reconnect bug?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 06:47 AM - 06/02/13
Reconnect bug?
I had almost forgotten this one. Sorry :( Nothing new has happened to this problem. I will need to dig into this myself. Then reopen the thread in pjrc forums.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:00 AM - 06/02/13
Would be great if you could hunt this one down, its an annoying one.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:26 PM - 06/03/13
You can put a pushbutton between ground and reset. When teensy freezes you can push this button to reset it. After this it will work again before next reboot. pinout: http://www.pjrc.com/teensy/pinout.html

I know we want this to work without pressing buttons, but this is at least a little better than wearing out usb ports.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:04 PM - 06/03/13
OK that would work even if ugly. Cant you execute a reset when it gets voltage automatically?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:39 PM - 06/06/13
PS3: No security check. Any device that says it is DS3 will be accepted.

They do have a security check not sure about the rest of the world but here in Europe Sony rolled out an update last year that blocked third party controllers and fakes the ones found on ebay from China.

I know this for sure as last year I downloaded a game from the store called Birds of Steel I like to fly sometimes, so using the default controller was ok but I wanted a little more realism so I checked the types of controllers that could be used in the options menu and listed were 8 flight sticks one of which was called the AV8R.

So I got it then used it for like a month then all of a sudden it would not work not even in the XMB yet its made for PS3, strange so I checked the calibration in windows yep all working but not on the PS.

So I called Sony and a nice lady there told me they rolled out an update patch due to security issues involving third party controllers, she then goes on to say send us the controller with your receipt and we will reimburse you for your purchase which they did hats off to them.

But she said unless it states on the box with a hologram that it has official Sony licensing it won't work as they are trying to eliminate the millions of fakes carrying their name and logo not to mention the money they are losing to.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:43 PM - 06/06/13
Roads are you using your mod on pc
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:54 PM - 06/06/13
Yes all games just completed Tomb Raider and it was great with mouse and N52te.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:55 PM - 06/06/13
PS3: No security check. Any device that says it is DS3 will be accepted.

They do have a security check not sure about the rest of the world but here in Europe Sony rolled out an update last year that blocked third party controllers and fakes the ones found on ebay from China.

I know this for sure as last year I downloaded a game from the store called Birds of Steel I like to fly sometimes, so using the default controller was ok but I wanted a little more realism so I checked the types of controllers that could be used in the options menu and listed were 8 flight sticks one of which was called the AV8R.

So I got it then used it for like a month then all of a sudden it would not work not even in the XMB yet its made for PS3, strange so I checked the calibration in windows yep all working but not on the PS.

So I called Sony and a nice lady there told me they rolled out an update patch due to security issues involving third party controllers, she then goes on to say send us the controller with your receipt and we will reimburse you for your purchase which they did hats off to them.

But she said unless it states on the box with a hologram that it has official Sony licensing it won't work as they are trying to eliminate the millions of fakes carrying their name and logo not to mention the money they are losing to.
What i said is still totally true. I dont remember what happened with this, but i think earlier PS3 accepted all "generic joystick" devices. This means that third party devices can use any kind of descriptors.

Those devices were not saying they are DS3 controllers. If a device says it is DS3 then it will be accepted.

Im not yet expert with usb stuff, but this is how i see it is.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 03:36 PM - 06/06/13
PS3: No security check. Any device that says it is DS3 will be accepted.

They do have a security check not sure about the rest of the world but here in Europe Sony rolled out an update last year that blocked third party controllers and fakes the ones found on ebay from China.

I know this for sure as last year I downloaded a game from the store called Birds of Steel I like to fly sometimes, so using the default controller was ok but I wanted a little more realism so I checked the types of controllers that could be used in the options menu and listed were 8 flight sticks one of which was called the AV8R.

So I got it then used it for like a month then all of a sudden it would not work not even in the XMB yet its made for PS3, strange so I checked the calibration in windows yep all working but not on the PS.

So I called Sony and a nice lady there told me they rolled out an update patch due to security issues involving third party controllers, she then goes on to say send us the controller with your receipt and we will reimburse you for your purchase which they did hats off to them.

But she said unless it states on the box with a hologram that it has official Sony licensing it won't work as they are trying to eliminate the millions of fakes carrying their name and logo not to mention the money they are losing to.
What i said is still totally true. I dont remember what happened with this, but i think earlier PS3 accepted all "generic joystick" devices. This means that third party devices can use any kind of descriptors.

Those devices were not saying they are DS3 controllers. If a device says it is DS3 then it will be accepted.

Im not yet expert with usb stuff, but this is how i see it is.

So you are saying any controller that says DS3 on it or on the packaging will work if that's the case why won't the one I purchased in Hong Kong work, it clearly states Sony PS3 and DS3 on the box and it is identical to Sony's packaging, comparing it to one of mine it looks identical until you open it up and theres the proof no sony markings on the pcb some rather dodgy looking soldering mine is better cough cough a battery that looks like its from an Ipod and some other stuff in there that I have no words to describe.
However when plugged into my pc its seen as a PS3 DS3 controller its just weird I am by no means saying you wrong I just wanted to give you a heads up on what Sony said to me.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 03:39 PM - 06/06/13
Yes all games just completed Tomb Raider and it was great with mouse and N52te.

Sweet so it works fine on PC then good that's what I like to here as my build is nearing its final fabrication ergonomically designed to fit my hand and only my hand.
How about console or are you not on there anymore.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:53 PM - 06/06/13
So you are saying any controller that says DS3 on it or on the packaging will work if that's the case why won't the one I purchased in Hong Kong work, it clearly states Sony PS3 and DS3 on the box and it is identical to Sony's packaging, comparing it to one of mine it looks identical until you open it up and theres the proof no sony markings on the pcb some rather dodgy looking soldering mine is better cough cough a battery that looks like its from an Ipod and some other stuff in there that I have no words to describe.
However when plugged into my pc its seen as a PS3 DS3 controller its just weird I am by no means saying you wrong I just wanted to give you a heads up on what Sony said to me.
Im not talking about what you see, im talking about what PS3 sees. PS3 sees only data. If that data is identical to what DS3 controller sends, it is recognized as a DS3 controller. Also what that text says is not always true. I could call teensy a toaster and it would be seen on pc as a "toaster". It could still work as a DS3 controller. btw i havent tried that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:34 PM - 06/06/13
Yes all games just completed Tomb Raider and it was great with mouse and N52te.

Sweet so it works fine on PC then good that's what I like to here as my build is nearing its final fabrication ergonomically designed to fit my hand and only my hand.
How about console or are you not on there anymore.

No console right now waiting what nextgens and XIM4 will be like.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 03:18 AM - 06/07/13
So you are saying any controller that says DS3 on it or on the packaging will work if that's the case why won't the one I purchased in Hong Kong work, it clearly states Sony PS3 and DS3 on the box and it is identical to Sony's packaging, comparing it to one of mine it looks identical until you open it up and theres the proof no sony markings on the pcb some rather dodgy looking soldering mine is better cough cough a battery that looks like its from an Ipod and some other stuff in there that I have no words to describe.
However when plugged into my pc its seen as a PS3 DS3 controller its just weird I am by no means saying you wrong I just wanted to give you a heads up on what Sony said to me.
Im not talking about what you see, im talking about what PS3 sees. PS3 sees only data. If that data is identical to what DS3 controller sends, it is recognized as a DS3 controller. Also what that text says is not always true. I could call teensy a toaster and it would be seen on pc as a "toaster". It could still work as a DS3 controller. btw i havent tried that.

I get ya now sorry if I aggravated you there a bit as sometimes things have to be explained to me in laymen's terms makes sense to me now. ;)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 06:31 AM - 06/07/13
mara, Sony made those patches to block the jailbreak devices, not the chinese fakes and whatnot.. those were just a bonus xD

there was a lot of racket online since many many people were left with all kinds of devices not working on their PS3's all of a sudden for "no good reason".... i honestly believe Sony actually quit with that war since it could not win and their resources had to go elsewhere. namely the maintenance and security of their crap and not pissing their clients even more after they got hacked ahahahaahhah
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:15 PM - 06/17/13
Ok so summit not wright for me am I supposed to write some code or something to get this to work I followed all the instructions to the letter atleast I think I did been back over them again and again to no avail.
The joystick moves on the xmb left right up down but oh so slowly like move pause then move thn pause then move.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:23 PM - 06/17/13
Ok so summit not wright for me am I supposed to write some code or something to get this to work I followed all the instructions to the letter atleast I think I did been back over them again and again to no avail.
The joystick moves on the xmb left right up down but oh so slowly like move pause then move thn pause then move.

How does it work ingame? Is moving there slow too?
Also test this: search program "joy.cpl", open it and teensy should be seen there.

How does that mark move on the X axis / Y axis box when you move joystick?
(http://www.pjrc.com/teensy/td_joystick_sc3.png)
It will look a little different from this, but that box is there.

This is ofcourse if you are using windows. Also if you have LGS installed, it might confuse drivers.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:34 PM - 06/17/13
Shows nothing in there at all daren't try a game i'll be destroyed before I can get buttons mapped to edge.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:36 PM - 06/17/13
I get nothing in joy.cpl not even buttons working.
Yet on the ps3 I can move and navigate around the xmb but very slowly at OAP speed.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:38 PM - 06/17/13
Is it even flashed? And you have to reconnect to make it work Mara. Unplug it plug it again and then start joy.cpl.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:42 PM - 06/17/13
Is it even flashed? And you have to reconnect to make it work Mara. Unplug it plug it again and then start joy.cpl.

Done that if by flashed you mean RE BOOT OK then yes its done that with the green light on auto what ever that does.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:43 PM - 06/17/13
Also do you have Logitech Gaming Software installed? That might be the reason why it is not seen in joy.cpl
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:53 PM - 06/17/13
I have the logitech thing installed and works fine just had to set the Teeny as standard. Mara I mean just pull the Teensy and plug it back in, not talking about flashing.
Flashing I had to reset it with the button on the Teensy before the flash to be able to flash it.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:53 PM - 06/17/13
Let me break it down.

Teensy is connected to a powered usb hub is this ok for configuring or should it be direct to pc no hub inbetween.

Also connected to hub is n52te or rather whats left of it after I striped it back to its brass tacks that all works fine no problems there. ( should I disconnect it from the hub whilst Teensy is doing its thing ).

No functions on Joy.cpl in windows but on ps3 I can move the xmb but it moves very slowly like one space at a time.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:53 PM - 06/17/13
W11ce you should add a led flash 3 times at startup or something like that to be sure the code is even on there.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:54 PM - 06/17/13
Quote
on ps3 I can move the xmb but it moves very slowly like one space at a time.

would that be so with an unflashed Teensy?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:58 PM - 06/17/13
Quote
on ps3 I can move the xmb but it moves very slowly like one space at a time.

would that be so with an unflashed Teensy?

Ok Roads you got me how do I even know if its been flashed or not....
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:59 PM - 06/17/13
Right, I had some flashes that showed OK but it didnít work.
HAve you replugged the Teensy and ran joy.cpl again if its there and working? What does it say in joy.cpl? XIM something?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:04 PM - 06/17/13
Right so theres the problem well done Roads my joy.cpl shows at the top 6 axis joystick with 24 buttons

The picture W11 posted says at the top Teensy Keyboard/mouse/joystick so how do I get to that then.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:09 PM - 06/17/13
Flash it :) maybe W11ce can make a version that definitively shows it has been flashed.  think he is one the moves so this may have to wait.
Press the reset button before you flash.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:10 PM - 06/17/13
Also remember the bug where after the window start you have to replug the Teensy. Makes it even harder to see if stuff is flashed right.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:12 PM - 06/17/13
I think he flashed teensy correctly.

The name in that pic is different than what it should say for you. I think you have not installed my custom pack correctly (step 2). Also make sure you pick in menu USB Type: XIM Joystick VER1 (+KB&M).
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:14 PM - 06/17/13
Quote
USB Type: XIM Joystick VER1 (+KB&M).

Thatís what it says for me yes.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:15 PM - 06/17/13
I think it should not say Teensy keyboard /mouse/joystick thatís what it says unflashed. I may be wrong though.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:19 PM - 06/17/13
I think he flashed teensy correctly.

The name in that pic is different than what it should say for you. I think you have not installed my custom pack correctly (step 2). Also make sure you pick in menu USB Type: XIM Joystick VER1 (+KB&M).

The above is done and all selected the little Teensy box with the press button to activate says at the bottom Simple.cpp.hex , 7% used then the Simple Ardinio says 1.0.3 done compiling
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:27 PM - 06/17/13
Does it say XIM Joystick VER1 (+KB&M) or Teensy keyboard /mouse/joystick in windows? Open Devices and Printers and check what it is seen there.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:32 PM - 06/17/13
He posted this check the windows title.

(http://www.pjrc.com/teensy/td_joystick_sc3.png)


Hmm no that was you why does yours have this title?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:33 PM - 06/17/13
Does it say XIM Joystick VER1 (+KB&M) or Teensy keyboard /mouse/joystick in windows? Open Devices and Printers and check what it is seen there.

Yep got that its under unspecified devices but its there exactly as you say under properties though it says its Logitech.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:34 PM - 06/17/13
He posted this check the windows title.

(http://www.pjrc.com/teensy/td_joystick_sc3.png)

Mine doesn't say that Roads.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:34 PM - 06/17/13
Yeah just saw that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:37 PM - 06/17/13
That is what it should look like with default settings. I was too lazy post what it should really look like, lol sorry  :o

Try different usb port.

FFS, let me reply before posting something new. Every time i press post button it throws that red warning text to me. lol
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:40 PM - 06/17/13
LOL i was born to make your life hard W11ce :D Thatís why you love me.
And flash again after pressing the reset knob on the Teensy.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:44 PM - 06/17/13
I have got to go to work now so have think guys really need to get this working.

I think it is working it appears on the ps3 xmb that when I move the stick left it bumps along slowly but faster than to the right I am wondering if the opening for my stick is may be to small so its restricting its full travel I know I got it slightly off centre when installing but its mere thousandths of a millimetre but that could be enough.
There is now way for me to take it out but I can open up the hole a bit more I will try this tomorrow.

Any other ideas you have would be greatly appreciated one question should I have updated Teensy and Ardinio I didn't I promise just curious incase that's the answer. 
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:46 PM - 06/17/13
Ill leave this to W11ce and you I also told the pitfalls I stepped into.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:55 PM - 06/17/13
Lol roads...

Ok, so the code might be working, so maybe it is the joystick then. I will make tomorrow a debug code that shows joystick values in serial monitor.

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:41 AM - 06/18/13
Heads up stick is all working it was my fault didn't make the hole big enough thank god I got it off centre slightly otherwise the penny would not have dropped.
Thanks for your help guys W11 don't need to write any bug program its all good fella well done like it.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:15 AM - 06/18/13
Come here for your slap :D
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 04:39 AM - 06/18/13
Come here for your slap :D

Lol yes I deserve one don't I.

All working good now fellas still won't function in Joy.cpl but I do have Logitech gaming software running on pc so I will look into that but on PS3 its working all good.

Now all I gotta do is decide which buttons to bind to.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 05:28 AM - 06/18/13
check the configuration pictures thread will give you lots of ideas. What I personally got used to ADS, duck, jump, melee on the left Hand from right to left. I use that in all games. The same four also have the D-pad shifted with a switcher.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 10:51 AM - 06/18/13
Good, i would not have wanted to make any debug code anyways, lol.

Heads up stick is all working it was my fault didn't make the hole big enough thank god I got it off centre slightly otherwise the penny would not have dropped.
Thanks for your help guys W11 don't need to write any bug program its all good fella well done like it.
Thats what i thought. There isnt usually almost never ever any bugs in my code  ;D Now pictures of the completed mod ?

Anything you would like to add, roads?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:57 AM - 06/18/13
Great not to have the controller around the N52te huh?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 03:50 AM - 06/20/13
Great not to have the controller around the N52te huh?

Indeed not having that attached is a bonus.

However I have some ghosting issues at the moment for example if I push key A in note pad I get AB this happens on 5 keys.

I used the guts from the Razor N52te I know Roads don't shoot me down for it as I know the Belkin version I have are like rocking horse poo they just don't exist anymore so rather than nerf that one up I thought I would try on the Razor first.

What I did was to make a keyboard in a U shape so my fingers slot inbetween the keys if that makes sense so my 4 fingers are poised over 12 keys with minimum movement to push flick or pull on a key now the concept seems to work apart from the ghosting not sure why that's happening.
I did the scrape of the contacts on the board and soldered wires to those contacts just like you did earlier on Roads for the Cherries.

So 1 question can I just use the Teensy for this without the need of either n52's personally I am not bothered about macro's never use them as I can never seem to make them work anyway.
So with that in mind can I do that and how many buttons will I be able to use I know the stick will obviously work.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:37 AM - 06/20/13
Of course you can use the Teensy without even plugging the N52te. Just wire the buttons to the cherry keys. Did W11ce release his G13 emulation already? You need those extra keys.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 09:51 AM - 06/20/13
I havent released G13 code yet. It currently works on XIM3, but not on edge. Edge freezes :( I will dig into it again later when i get usb protocol analyzer. I would estimate in about 2 weeks, but im kinda busy right now. So if you are waiting for some kind of tutorial, then that would take maybe 4 weeks.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 09:55 AM - 06/20/13
No Hurry man we are glad you are doing this for us. Mara just connect all wires to the teensy and use the buttons that are available for now. Later you just flash the Teensy with the new code.

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:21 AM - 06/20/13
http://deskthority.net/workshop-f7/my-diy-keyboard-collection-or-how-i-became-a-kb-geek-t2534.html

check this thread 4 pages, when you have your 3D printer we need something like this :)

(http://deskthority.net/resources/image/3116)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 10:25 AM - 06/20/13
i would love to dive into this but i just can't.. roads mods were challenging enough..

i wish you'd go retail with something.. make money off this man, you deserve it...
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:31 AM - 06/20/13
Someone here who could design an N52te like keyboard?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 12:55 PM - 06/20/13
Look what I just found off the back of your post Roads via a link check it out talk about making things easier for the novice https://www.sparkfun.com/products/9110
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:09 PM - 06/20/13
I saw that with the stick on it already mounted. Dunno if it fits though.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:15 PM - 06/20/13
I saw that with the stick on it already mounted. Dunno if it fits though.

Yeah I have found a few more now all around the 35mm x 35mm in size they even go upto a 10k pot but to make it fit surely we just use the trusty Dremel Roads that'll make it fit a little off here a little of there and voila.  :-\
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:18 PM - 06/20/13
Found this one too http://www.technobotsonline.com/mdfly-thumb-joystick-breakout-board.html says its 10k as the others are same as ps2 ones and they are listed as almost 10k with a lot of problems posted on get them working correctly.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 06:47 AM - 06/21/13
I would love a simple Key plastic crate like the above with 5 rows and 6 in a line wher you can just buy whatever keys you like at WASD keyboards. and a nice hull that is similar to the N53te and spaces for the joystick and the Teensy. That would be great. W11ce will you do that for us when you have your Printer?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 06:53 AM - 06/21/13
I would love a simple Key plastic crate like the above with 5 rows and 6 in a line wher you can just buy whatever keys you like at WASD keyboards. and a nice hull that is similar to the N53te and spaces for the joystick and the Teensy. That would be great. W11ce will you do that for us when you have your Printer?

we could basically even transfer all the internals from the N52te to it and pay you to send it to us no?
that would suffice..

w11ce didn't you make a custom PCB even? i mean.. printer+custom PCBs is pretty much the core of the device.. only thing lacking is the assembly process and the rest of the parts and you have yourself a retail product.

why won't throwing money at you work, how did we get OBsIV to sell XIM1 roads?



actually, why doesn't OBsIV just picks up W11CE's work and make a device for the XIM a la fragfx and aimon? he already has the lay of the china land, costumer base, store and w11ce work... only lacks will
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:02 AM - 06/21/13
I dunno he could easily do a device for the XIM but I guess it wont sell much. He would need to do a CAD design and ask the people.

Meanwhile... W11ce could do such a thing with his Teensy. Would be quite cool.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 07:09 AM - 06/21/13
why won't it sell? i don't mean for OB to make a mouse, leave the mouse up to the user.

but if OB sold a n52te-modded like device, we could even manage to do it with bluetooth, and i'm sure around 30% of the XIMers at least would buy.. did you see the amount of people that use the Nav and other nunchucks?
how many gave those up due to lack of keys? how many wanted a solution like the OP's but without the modding troubles?


sure most people will use the XIM with the KB they have at hand. but i see this actually gaining a lot of momentum with some publicity.. peolple outside the XIM world would be interested also since the only offerings at the market as we know very well are razer's and G13. both far from perfect unlike a W11CE solution..
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:12 AM - 06/21/13
I am not sure about the 30% that is why I would design, show the design and ask. Itís a very simple task for Obsiv after doing the XIM3 and Edge. He could even talk to us what that device would need to have. Like Cherry keys etc.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 07:17 AM - 06/21/13
I am not sure about the 30% that is why I would design, show the design and ask. Itís a very simple task for Obsiv after doing the XIM3 and Edge. He could even talk to us what that device would need to have. Like Cherry keys etc.

granted. but like you say very well we could just do a poll and build-to-order from that number.. like geekhack keys group orders, they seem to work fine there.. trolls may be a concern but i feel a pay first, get it later model would solve it.

kickstarter could be the way too, we have said it many times before but now the device is almost complete as far as core hardware is concerned W11CE achieved a very polished iteration already


and let's notice that with next gen around the corner and a possible XIM4 the timing for this should be simultaneous since that is when this store will see the peak
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:29 AM - 06/21/13
I see you have a nice long conversation going on here. I have thought about this too. Designing and actually making the device is just a part of the process. That is something i can do, it is "just" designing.

Other things that this includes are the ones im concerned about. If i want to make a "real" product, then laws, patents and other bs cant be ignored.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 08:33 AM - 06/21/13
I see you have a nice long conversation going on here. I have thought about this too. Designing and actually making the device is just a part of the process. That is something i can do, it is "just" designing.

Other things that this includes are the ones im concerned about. If i want to make a "real" product, then laws, patents and other bs cant be ignored.

this post is exactly what i imagined that you would post. man i have to play the Euro lottery !

and it is why i talked about OBsIV coming in on it. at least he has some experience already and my guess is that we can't just copy other's designs, but a PCB is something too simple to protect very harshly for instance.. the model could be quite original and the code is open source on teensy. do you see anything at first sight that might cause problems?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:49 AM - 06/21/13
Well, i have to come up with enough original design so that it doesnt violate any patets. But then i need to patent my design. I dont want that someone steals my design lol.

Dont need the help of obs. I have people at work that i can ask for advice.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 08:53 AM - 06/21/13
What does a 3D print cost you W11ce?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 09:01 AM - 06/21/13
What does a 3D print cost you W11ce?
You mean one printed part? Well it is about the price of plastic it takes. 1kg of PLA costs about $30. So if it weighs 200g, it costs $6.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 09:09 AM - 06/21/13
Well, i have to come up with enough original design so that it doesnt violate any patets. But then i need to patent my design. I dont want that someone steals my design lol.

Dont need the help of obs. I have people at work that i can ask for advice.

if i begged you to do it, would it matter to you?

and if you do it, can you scram bluetooth in ? doesn't matter to me if it still has to draw power from a cord, but then it will be much more flexible.. i can see that cause mass confusion though.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 09:11 AM - 06/21/13
So why involve the Chinese then for the first 50 pieces. Take 25-50$ for the thing people throw in the Teensy and the cherries they want.

AK can we first do the device BEFORE we add rockets?

I think this modular approach is funny.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 09:18 AM - 06/21/13
So why involve the Chinese then for the first 50 pieces. Take 25-50$ for the thing people throw in the Teensy and the cherries they want.

AK can we first do the device BEFORE we add rockets?

I think this modular approach is funny.

i agree the first models could just be home made.. that may also help testing..

roads i'm just asking to see if it would be easy to do, not actually asking him to do it right away.
from a design standpoint i'd find better to perfect the core devices before all the xmas lights.

a GUI is something retail customers would want but to us it wouldn't be important for instance. why bother
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 09:19 AM - 06/21/13
Yeah, i was thinking about modules too. We can throw there bluesmirf HID (costs $50 !!!) and lithium battery. It will work at least with pc. With XIM, not sure. It depends on how advanced bt support will next xim have. On edge maybe, probably not.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 09:26 AM - 06/21/13
i doubt it but if there is any way we can help just say the word

Yeah, i was thinking about modules too. We can throw there bluesmirf HID (costs $50 !!!) and lithium battery. It will work at least with pc. With XIM, not sure. It depends on how advanced bt support will next xim have. On edge maybe, probably not.
http://www.kickstarter.com/projects/kytelabs/bleduino-bluetooth-40-ble-made-easy-arduino-compat?ref=category

just as a reference
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 11:33 AM - 06/21/13
All we need is a design.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:13 PM - 06/21/13
i doubt it but if there is any way we can help just say the word

Yeah, i was thinking about modules too. We can throw there bluesmirf HID (costs $50 !!!) and lithium battery. It will work at least with pc. With XIM, not sure. It depends on how advanced bt support will next xim have. On edge maybe, probably not.
http://www.kickstarter.com/projects/kytelabs/bleduino-bluetooth-40-ble-made-easy-arduino-compat?ref=category

just as a reference

Backed. Not sure if that has HID support.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 12:22 PM - 06/21/13
i wish i had the money and patience to toy with a arduino match with that project.. seems really useful for so many things.. i can automate half the house with that thing and an android app to control all the boards would be a cheap awesome DIY..
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 05:06 AM - 06/22/13
I shouldn't worry to much about breaking any patent laws or copyrights the Chinese don't they just make it lol.

All I know is when it comes to patents and laws regarding copyrights is that providing there are 46 changes to the original design or the copied design it can then no longer be classed as a direct copyright infringement as its now a completely new device.

With that said those changes can be anything from colour to shape, keys ergonomics etc etc.
Keeping with the N52te shape is going to be the hard part but we could over come that by having squared corners key height change key position change key type change and so on and so on.

Although I would be curious at this stage as to who holds the rights currently to the N52te as it appears the early models of this device were BELKIN which has now passed to Razor.

So that tells me that maybe Razor are making it under the guise of Razor/Belkin perhaps this is open as perhaps Belkin hold the rights and Razor are making it and selling it under their name with Belkin still in there with a mention perhaps only collecting royalties for sales from Razor.

With that in mind we could approach them with the concept and design then let them make it and we collect royalties from the sales.
A bit like the man who invented the Black & Deckerworkmate, that guy invented that workmans tresel for clamping wood and what not for sawing and assembling for the diy and construction industry.
He then approached Black & Decker with his concept and working model they loved it and offered him a contract by means of royalties from sales of £1.00 for each one sold I can't remember what the retail price is of this but I now he became a millionaire over night and the last I heard about this was that global sales hit 40 million sold so that's £40,000,000 he has collected in royalties.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 07:21 AM - 06/22/13
Its not a device at all itís a hull you place your stuff in. You could sell it as a box.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 07:52 AM - 06/22/13
Its not a device at all itís a hull you place your stuff in. You could sell it as a box.

this could circumvent almost all patent dangers. and you could win the patent for modular, gaining royalties from every similar product that gets done this way if it is too similar i guess..

but it needs to be a "set it up yourself" and not a DIY thing.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 11:31 AM - 06/22/13
Its not a device at all itís a hull you place your stuff in. You could sell it as a box.

I thought that was the whole point you lack ambition to follow through your super ideas Roads come on with all of us involved we could and must surely be able to get this as a whole device and get it to market.

Seriously a BOX which means anyone could go out and buy a 3d printer and start making them cause its a BOX.
I to started looking into 3d printers how cool are they not cheap though but I could just go out and get one now even though I am saving for something else lol.
I'm going to contact Belkin and see if they would be happy for me to make a revised copy of their original shell for my own personal use and not for re-sale but should it invoke interest would they allow me to bring it to market without infringing upon their rights or laws, or for a share in sales.
I reckon its a Belkin and Razor paid them for the rights to make it and expand on the original.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:14 PM - 06/22/13
Why, I find this intruiging, imagine an empty N52te no electronics in it just some screws holding it together. You buy some cherries as you like, black ones blue red, combine them or not. Buy a Teensy, flash it with the W11ce code. Buy an analog stick or a digital one as you wish. Solder the cables and off you go. I would like that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 12:19 PM - 06/22/13
Why, I find this intruiging, imagine an empty N52te no electronics in it just some screws holding it together. You buy some cherries as you like, black ones blue red, combine them or not. Buy a Teensy, flash it with the W11ce code. Buy an analog stick or a digital one as you wish. Solder the cables and off you go. I would like that.

no no no! not at all.. i would ask that of W11cE out of his kindness..

but what i was proposing before was really a retail product you can build without any soldering or similar skills. something everyone can do like screws and cables to connect... you don't need to take the modular away for that..
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:45 PM - 06/22/13
I was thinking about fully assembled and kit versions. Kit would include maybe all components or just special ones.

Modular would mean that you can swap joystick with dpad and also you could open back plate and plug in bluetooth shield, wifi shield, usb host shield, xbee, potato...
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 12:49 PM - 06/22/13
I was thinking about fully assembled and kit versions. Kit would include maybe all components or just special ones.

Modular would mean that you can swap joystick with dpad and also you could open back plate and plug in bluetooth shield, wifi shield, usb host shield, xbee, potato...

so the question is do you want a gold diamond ring or a white gold diamond ring?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 12:25 PM - 06/23/13
Here's a little something that I use now for soldering these doughnuts as I call them make it so easy to do through hole soldering a child can do it even some one who has never used a soldering iron like for example my daughter it was her that drew my attention towards these as she used them in school once.

Here they are http://proto-pic.co.uk/schmartsolder-50-pieces/

And here's a video showing them in action http://www.youtube.com/watch?v=51duvSWqriw&feature=player_embedded
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 12:30 PM - 06/23/13
Here's a little something that I use now for soldering these doughnuts as I call them make it so easy to do through hole soldering a child can do it even some one who has never used a soldering iron like for example my daughter it was her that drew my attention towards these as she used them in school once.

Here they are http://proto-pic.co.uk/schmartsolder-50-pieces/

And here's a video showing them in action http://www.youtube.com/watch?v=51duvSWqriw&feature=player_embedded

Thank You very much!! this will be useful in the future.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:45 PM - 06/23/13
Honestly, i dont see how that makes soldering easier. You still have to handle soldering iron yourself so whats the point? Now on the top of all, you have to handle ridiculously small parts too (small parts belong to smd side!) . And through hole soldering is so easy anyways, so that if this is the only way you can solder, then you shouldnt solder anything real at all yet.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:47 PM - 06/23/13
Thatís what I thought.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 12:58 PM - 06/23/13
Honestly, i dont see how that makes soldering easier. You still have to handle soldering iron yourself so whats the point? Now on the top of all, you have to handle ridiculously small parts too (small parts belong to smd side!) . And through hole soldering is so easy anyways, so that if this is the only way you can solder, then you shouldnt solder anything real at all yet.

this is why i don't want to solder anything at all! LOL

my hands shake like leafs in the wind.. i can manage to fire a 1911 type of handgun fine but things like snipers are just not for me.. .22 small guns will limit my accuracy to 1m i guess xD (i'm saying this to give you an idea)
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 01:56 PM - 06/23/13
Well I can solder the normal way these are just perfect for exactly the right amount and perfect soldered joints all the time just like the ones the pros do.

And i'll just point out the pros don't even do it the way we do they use a paste from a syringe which is applied across all contacts and then heated by hot air that's not soldering the very same paste that's used in mass production soldering.

Not really fair to say I shouldn't be soldering if I have to use those its not a case of have to they are simple stick to ya finger slot in on touch done next its more a case of quicker cleaner and no cold spots nice and shinny every time and no waste or snots.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:45 PM - 06/26/13
This stuff I found intrigues me http://shop.pimoroni.com/collections/lifestyle/products/sugru

Seems durable and modable even seems it bounces maybe usefull.

Roads those stick breakout boards on the same site above work a treat got mine yesterday and I can confirm they work.
The foot print of the pcb is bigger than needed by us and most of it can cut away and reduced to fit.

Progressing to modular I went with pin headers and male and female jump wires so its all pluggable and inter changeable.
Pinheaders are the way to go especially for those that can't solder as we can solder in the pinheaders for them to just plug everything into plus its a lot less pain full if you get something wrong no need to de-solder just swap plugs around.

W11ce,
I have another project on the go at the moment which making a helicopter collective pitch control, I notice in joy.cpl that there are 2 more axis to use could I use these for that or is it not possible trying to cheap out and not by another board.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 02:54 PM - 06/26/13
Just out of curiosity can one of these http://proto-pic.co.uk/blackberry-trackballer-breakout/ be factored in to the mod or my mod as I like the idea of having this in for another game I play.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 03:25 PM - 06/26/13
It is possible to use at least 6 axes with teensy: http://www.pjrc.com/teensy/td_joystick.html
You can see there axes that are supported by unmodified original code.

I think that blackberry trackball should work with teensy.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 07:46 AM - 07/10/13
Ok so got it all working in serial and usb keyboard/mouse/joystick with all buttons confirmed as working in joy.cpl.

However when connected to the Edge 3 buttons will not work, I have pin modes input pull up 0 - 13, then joystick.button 1 - 14 on digitalread 0 -13 is there some code that needs to be added for these buttons to work in usb_xim1_joystick.h or am I missing something.
Title: Re: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:20 AM - 07/10/13
Ok so got it all working in serial and usb keyboard/mouse/joystick with all buttons confirmed as working in joy.cpl.

However when connected to the Edge 3 buttons will not work, I have pin modes input pull up 0 - 13, then joystick.button 1 - 14 on digitalread 0 -13 is there some code that needs to be added for these buttons to work in usb_xim1_joystick.h or am I missing something.

Current VER1 supports only 11 buttons. You cant expand it by modifying usb_xim1_joystick.h. I have tried to mimic G13, which would give us 36 buttons if I remember correctly. It works on xim3 and pc, but not on edge.

I have now usb protocol analyzer, which should help me figure out the reason why edge freezes when teensy is connected to it. I will try it this weekend, but can't say when I can release it.
Title: Re: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 10:51 AM - 07/10/13
Ok so got it all working in serial and usb keyboard/mouse/joystick with all buttons confirmed as working in joy.cpl.

However when connected to the Edge 3 buttons will not work, I have pin modes input pull up 0 - 13, then joystick.button 1 - 14 on digitalread 0 -13 is there some code that needs to be added for these buttons to work in usb_xim1_joystick.h or am I missing something.

Current VER1 supports only 11 buttons. You cant expand it by modifying usb_xim1_joystick.h. I have tried to mimic G13, which would give us 36 buttons if I remember correctly. It works on xim3 and pc, but not on edge.

I have now usb protocol analyzer, which should help me figure out the reason why edge freezes when teensy is connected to it. I will try it this weekend, but can't say when I can release it.

Well there's a relief then and for the last 4 hours I thought it was me lol cool ok I will work with what we have right now and awaite your new model.
Title: Re: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 11:18 AM - 07/10/13

 and for the last 4 hours I thought it was me lol

LOL this was pretty discussed man! how could you miss it xD
(it's actually easy to miss tbh i just thought i was funny. no offence i get those situations with myself a lot and i usually laugh at least a few days later if not right on the "Eureka!" moment ^^)
Title: Re: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: THE-MARAVINGY on 07:24 AM - 07/13/13

 and for the last 4 hours I thought it was me lol

LOL this was pretty discussed man! how could you miss it xD
(it's actually easy to miss tbh i just thought i was funny. no offence i get those situations with myself a lot and i usually laugh at least a few days later if not right on the "Eureka!" moment ^^)

Yes but after spending 4 hours tinkering to no avail I was not going to read through all the pages to find my answer sometimes its best to just put your hand up and ask. Those who don't ask will never know the answer to their question.
Title: Re: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 07:50 AM - 07/13/13
Yes but after spending 4 hours tinkering to no avail I was not going to read through all the pages to find my answer sometimes its best to just put your hand up and ask. Those who don't ask will never know the answer to their question.

ofc! sometimes i won't even matter if you read endless pages as the emotional state can deprive the brain of the concentration to actually process what we read. i learned that from a lot of experience and i'm usually above average good reading diagonally which is not a very easy thing for most. the more i look the less i find, especially if i can't just ctrl+f or google the keywords for some reason..

life is like darksouls, when you get stuck too many hours on the same place it often means you should get a break before going back to the fray xD
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 10:24 AM - 09/08/13
There is a new alternative for this:
http://www.xim3.com/community/index.php?topic=28650.0

That is more advanced way if using device only on XIM3 and Edge. I was going to include it in this thread, but it exploded a little and now it is in projects section. Also it is not really a tutorial, or even a HID device.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ak-xs on 10:44 AM - 09/08/13
There is a new alternative for this:
http://www.xim3.com/community/index.php?topic=28650.0

That is more advanced way if using device only on XIM3 and Edge. I was going to include it in this thread, but it exploded a little and now it is in projects section. Also it is not really a tutorial, or even a HID device.

o.0
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:10 AM - 11/17/13
2.2 mac

you cant overwrite examples, Arduino will not load if the folder is overwritten as it can load its example file.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 01:50 AM - 11/17/13
getting arduino.h not found compilation error for "simple". Seems like a common error searching on Google. Cant resolve it.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:48 AM - 11/17/13
It compiles fine under windows. Id remove the Mac part W11ce.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ManApe on 09:10 AM - 12/13/13
Found this if anyone needs one https://www.sparkfun.com/products/9032
and https://www.sparkfun.com/products/9426
and http://www.digikey.co.uk/product-search/en/potentiometers-variable-resistors/joystick-potentiometers/262970?k=surface%20mount%20resistors
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:46 PM - 02/08/14
Here (https://drive.google.com/file/d/0B_0MQrj9_eGtckRNVWltZG5aalk/edit?usp=sharing) is the new pack. Use 1.18 RC3 teensyduino (http://forum.pjrc.com/threads/25046-Teensyduino-1-18-Release-Candidate-3-Available) with this.
Ver2 works with XIM4E and supports 35 buttons.

Now all my custom usb types are in same package and its called "Wusb pack". The topics are not updated with these yet. If this martial law does not end soon i will need to mass disturb mods to get these updated.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 02:34 PM - 02/08/14
Thanks you Teensymaster W11ce!
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 02:30 PM - 03/06/14
I know XIM4E doesn't have attack drivers yet... but is the g13 stuff still problematic?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: mikael on 02:35 PM - 03/06/14
Hey guys what exactly does the new pack do for the WD? I use my xim3 and my xim4e and I'm getting stutter ( jitter) on ghosts , will this new pack fix that?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 02:35 PM - 03/06/14
This is unrelated as far as I know.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 02:58 PM - 03/06/14
Roads says it lags. Just tested it and it didnt lag for me. Soo, just test it.
One note: Use "Joystick.useManualSend(true);". Explained here: http://www.pjrc.com/teensy/td_joystick.html
Works with my custom joystick codes too. With this many buttons it adds really much lag if that is not used.

Hey guys what exactly does the new pack do for the WD? I use my xim3 and my xim4e and I'm getting stutter ( jitter) on ghosts , will this new pack fix that?
This pack has nothing to do with WD. This is just XIM compatible USB HID types for teensy 3. Have you tried other games or other translators?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 10:09 PM - 03/06/14
I have problems with the stick in BF4 menus, that I did not have before with the attack 3 code, thatís all. Stick down does not always work, takes seconds to activate. But it strangely is BF5 menu only.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: Wurstwasser on 04:36 AM - 03/10/14
Hm i tested my flightstick in the BF4 menus. Works fine with the new G13 code.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 04:44 AM - 03/10/14
Thatís strange. Will see how it behaves with the XIM4beta.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 08:36 AM - 03/20/14
So I take joystick version 1 is the attack 3 and version 2 is the g13?

Version 2 crashes my xim edge.  Doesn't crash the same edge when it's a xim4e.

Anybody else see this behavior?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 01:16 PM - 07/01/14
Here  (https://drive.google.com/file/d/0B_0MQrj9_eGtSkZCNEtRNTlHZEE/edit?usp=sharing)is new pack. Use with 1.19 (http://www.pjrc.com/teensy/td_download.html) version of teensyduino.

Nothing new really. Just made it compatible to 1.19 td and added VER2 joystick, because roads had problems finding it.

Also side note: I have problems with pictures on my tutorials because my imageshack premium ended. I will get rid of imageshack and fix this at some point. Dont worry.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 09:20 PM - 08/03/14
Thanks for new files

Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 08:41 PM - 08/10/14
Has anyone used the stick with teensy for WoW.   If so post a quick review
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: roads on 12:14 AM - 08/11/14
on PC?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 05:26 AM - 08/11/14
Yes,   World of Warcraft
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 06:31 PM - 09/14/14
Oh poop.  It no worky on Linux.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 07:50 PM - 09/16/14
Oh poop.  It no worky on Linux.
It should, you just need to put files to correct places. Im not sure where the files are located on linux.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 02:18 PM - 09/17/14
I replaced the files just like I did on windows 7 x64.  The Arduino app wouldn't even open after that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 12:34 PM - 09/18/14
Has happened to me before on win7 once or twice. Never figured out why it wont open.
Sorry, but i dont have linux machine. I cant test this on that.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: tuffrabit on 12:44 PM - 09/18/14
Gotcha.

Linux is easy my man.  VM's are your friend.  Go with Mint or Ubuntu if you get curious.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 07:11 PM - 10/19/14
Hey guys I am making another controller and I am not able to flash . it says serialevent was not declared. I am using the new updated files not the same as I used for my first one. I did go from xp to windows 7. Can anyone help me with this?
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 07:15 PM - 10/19/14
I'm using Arduino 1.0.6 as I can't get the teensyduino to see the 1.5.8  to install, I am also using T3_Wusb_pack_01072014
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 07:18 PM - 10/19/14
Teensyduino 1.18 rc#3
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 07:33 PM - 10/19/14
One more thing this is a 3.1 teensy
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: W11cE on 08:19 PM - 10/19/14
Looks like you are using both wrong arduino IDE and teensyduino versions. For 01072014 version you need:
 - Arduino IDE 1.0.5 (http://arduino.cc/en/Main/OldSoftwareReleases)
 - Teensyduino 1.19 (http://www.pjrc.com/teensy/td_119/teensyduino.exe)

Teensyduino 1.18 rc3 does not even support arduino IDE 1.0.6, which is probably why you get that error message.
Title: Re: Tut: Teensy 3.0 as a HID device on XIM3 and Edge (and PC)
Post by: ScopeLoc on 08:20 PM - 10/19/14
Thank you.   
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 05:35 PM - 11/21/14
Latest version 22112014 (https://drive.google.com/file/d/0B_0MQrj9_eGteGlfLUhvQ1N1ZVE/view?usp=sharing).
Install on the top of Arduino IDE 1.0.6 (http://arduino.cc/en/Main/Software) and Teensyduino 1.20 (http://www.pjrc.com/teensy/td_120/teensyduino.exe).
(And pololu a-star 1.0.1 drivers if you are using it.)

General changes:
 - The pack is now called "Wusb" pack, without T3. Also all my custom usb modes have "[Wusb]" as a prefix.

Changes Teensy 3.x:
 - Added custom mouse type to be used with ADNS-9800 sensor.

New supported boards:
 - Joystick VER2 support for Arduino Micro and Leonardo.
 - Joystick VER2 support for Pololu A-Star 32U4.
NOTE: With these 3 new boards you HAVE to press reset button on flashing. Pololu A-Star 32U4 board seems to have a weird timing on reset, but it works too (it doesnt have onboard reset button).

NOTE2: If you are unfamiliar with this pack and have not used Teensy 3 before with this pack: "USB Type" menu is added after "Board:" menu. From there you can choose either default arduino usb mode or my custom modes.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Panama on 02:50 AM - 12/05/14
Can someone help me out withe software segement of this mod. I know it says I would be able to to select XIM Joystick VER1 (+KB&M) after i select the board, but it doesn't show up
An option. I'm using the newest software from the post above this one and a teensy3.1. What do I need the teensyduino? And how exactly do I flash the board? I was able to open the sketch for xim hid simple, but how do I install that to the board?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 11:53 AM - 12/05/14
Did you copy in w11ce's teensyduino modification?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Panama on 01:16 PM - 12/05/14
not sure how too, the teensyduino I downloaded is an application or installer. Is there an application within the teensyduino I need to extract to the arduino 1.0.6? I did copy the Wusb_pack into the Arduino files.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 06:29 PM - 12/05/14
You dont copy the folder to arduino files. You merge it with arduino folder, so that few files will be overwritten.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Panama on 10:50 AM - 12/06/14
I found out what I was doing wrong, when launched teensyduino, I went ahead and just downloaded all of the programs. Don't know which one worked but , but my mod does now. Thanks for the help
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 11:01 PM - 12/06/14
Ok, nice you got it working :)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Panama on 12:58 PM - 12/17/14
mod works well with xim 4, but when i try it on edge on ps3 with usb hub it freezes  the xim edge and the controller is no longer responsive until i unplug the xim.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 01:02 PM - 12/17/14
The ver2 is not compatible with Edge.  You'd have to reflash with the same code but use ver1 for it to work on Edge.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Panama on 01:18 PM - 12/17/14
ok version 1 for edge and xim3  version 2 for xim 4   thanks. good to know ill give it a shot
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 11:07 AM - 04/09/15
I just got my orbweaver ps4 joystick and teensy 3.1 in the mail today. Not really sure what I'm doing but going to give it a shot. Not really worried about mounting the joystick or soldering just programing the teensy.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 01:15 PM - 04/09/15
The code is already written.  Look on the first page of this thread.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 04:51 PM - 04/10/15
What do you guys think is better, doing the vita or the ps4 stick? I bought the ps4 stick and my son broke his screen on his old vita so I have the parts to do that also. I think the vita might be a little nicer if it works good.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 04:02 PM - 04/11/15
I havent personally done any device with the vita stick, so cant comment on that. I think tuff is the only one here that has done a device with vita stick mod and actually played with that.

Are you doing only stick mod, or rewiring also all buttons through teensy?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 04:21 PM - 04/11/15
Just the stick mod. I decided to go with the vita stick.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 05:22 PM - 04/11/15
Got the orb all back together and tried to program it with no luck. really not sure what im doing. i downloaded the new stuff on page 16. not sure what the problem is but I dont see teensy 3.1 when I open Arduino.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 08:31 PM - 04/11/15
You need to download older version of arduino ide. You need version 1.0.6. Here: http://arduino.cc/en/Main/OldSoftwareReleases
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 11:40 PM - 04/11/15
Ok now teensy 3.1 is there and I can select joystick ver2. Trying to load Tuffs vita sketch on to teensy. Its not working, not sure of the exact process. Do you copy and paste in Arduino then plug in teensy and move joystick or is there something else you do before you plug in the teensy? When I plug in the teensy the  orange light is flashing, if I push the button it stops blinking. Is that correct?

Thanks for your help and sorry for all the questions.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 01:35 PM - 04/12/15
Assuming you have all the right versions of the Arduino IDE, Teensyduino, and W11cE's configs...

All you have to do is copy in the vita calibration sketch, click the Upload button (looks like a right pointing arrow), and then move the Vita stick in full circles for approx 10 seconds (count slow).
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 01:51 PM - 04/12/15
I had to revert back to the arduino on the front page to see teensy 3.1 and joystick very 2. When I try to run teensy duino I can't find where to install. When I click upload it says fatal error. I am going to Uninstall everything and start over. I really appreciate all your help.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 01:54 PM - 04/12/15
Oh yeah what about the flashing light. Is that normal.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 03:49 PM - 04/12/15
Flashing light on your teensy?  They come with a blink sketch pre loaded, so yes that's normal.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 04:09 PM - 04/12/15
I redid everything and  now if I open joy.cpl I see teensy duino in there. If I click on properties in the square the + is moving all over the place but the little circle in the bottom corner isn't there. Tuff on your directions for the vita stick the first sketch after loading you say to unplug teensy then on the second you just say load the sketch . Do I need to plug teensy back in and do something?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 04:13 PM - 04/12/15
In teensyduino for install destination you select the folder containing arduino app (should be something like arduino-1.0.6). For my Wusb pack you merge arduino folder with my pack folder. It will overwrite some files, thats how you know you have selected the right folders.

The first sketch checks the stick movement area and writes those values to EEPROM. The second real sketch uses those values to scale values correctly.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 04:39 PM - 04/12/15
If I use 1.0.5 I can select joystick in arduino. If I use 1.0.6 it isn't there. In both I can select teensy 3.1.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 05:02 PM - 04/12/15
Then you have installed 1.0.5 correctly and 1.0.6 incorrectly. It should not matter to use 1.0.5 if you can compile the sketch.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 05:15 PM - 04/12/15
In joy.cpl shouldn't the joystick show up in the circle in the  bottom corner and not be moving around in the square?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 06:59 PM - 04/12/15
No, thats the rotating hat. It should show up in the square box.
On the resting position it should be aprox on the middle and when you rotate it around it should go through all the edges. Its ok if it does not go completely to corners, most games still accept that as a max position.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 07:23 PM - 04/12/15
Ok I got 1.0.6 working but no matter what I do the + in the box jitters all around. If I plug it in my xim and in ps4 it keeps flipping around the screen
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 07:44 PM - 04/12/15
Do you have vita stick connected correctly?
http://xim4.com/community/index.php?topic=31390.0

Note that you have to connect those all 3 traces to +. Sounds like you might have one of those not connected.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 07:49 PM - 04/12/15
Yeah that's the problem. I just thought the center one was needed. Now that you pointed it out its pretty clear. Thanks I'll tear it apart and try again.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 07:41 AM - 04/13/15
Was gonna say... that sounds like a wiring issue, not a code issue.  You're going to have to recalibrate after you fix the wiring.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 12:50 PM - 04/13/15
Yeah thanks. I screwed up the board when I was trying to remove the hot glue. I bought a whole broken ps vita locally for $15. So I should be back in business tonight when I get home. Im 40 years old and you would think by now I could read directions.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 12:57 PM - 04/13/15
For the record... I don't recommend the Vita stick.  It's generally a PITA to get working compared to a regular stick.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 03:25 PM - 04/13/15
It just felt like the ps4 stick was going to be uncomfortable because it sticks way out unless I got rid of the side button board. If I don't like the vita stick I can always change to the ps4. In your video you said you liked the feel of the vita stick and the guy you did it for said he likes it so I figured I would give it a try.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 04:55 PM - 04/13/15
I also saw the video. It looked nice I am waiting for my parts then I will use vita also.   Once it is working is it durable?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 05:02 PM - 04/13/15
I redid everything and still can't get it to work.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 05:56 PM - 04/13/15
I give up. I know all the wires are soldered right and still jittery. My only  guess is it's the programming. I'm going to try and wire up a ps4 joystick to the teensy and see if I can get that to work.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 07:27 PM - 04/13/15
Ok here's my process tell me if you see something wrong before I give up. First I copy sketch to arduino click upload and rotate joystick, then arduino says to load on teensy push reset button on teensy,push the button then when it's done unplug and replug teensy . Copy second sketch in arduino click upload then it says press reset button on teensy, when it's done unplug and replug and test with no luck. This is for the vita stick.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 08:48 AM - 04/14/15
Did you change the pin #'s in the code to match whatever pins you have wired on your teensy for x and y signal?  Not power and ground, but x and y.

In the calibration code it's lines 27 and 28.  You actually need to use the teensy layout sheet that came with your teensy, because the analog pin #'s are different from the digital pin #'s.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 05:42 PM - 04/14/15
Thanks I switched the wires and ran the calibration sketch unplugged the teensy and now when I plug it in it doesn't turn on. Not sure what happened.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 07:49 PM - 04/14/15
When you plug it in does the chip get real hot after a few seconds?  If yes, you have a short in your wiring somewheres.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 10:32 PM - 04/15/15
Ok my teensy is ok. I had to use the left side joystick pcb. Its a little different than the right but im pretty sure its wired correctly but my y direction doesnt work at all. It doesnt jitter and x works good. Another question , when I open joy.cpl at the top it says teensyduino properties I thought I saw someone elses say joystick or something. Does that mean I have something istalled wrong?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 12:23 AM - 04/16/15
It does not say same for everyone. Dont know why.
It might be that your Y wire is not connected properly.

You can try this to eliminate the calibration from process:
Code: [Select]
void setup() {
}

void loop() {
 
 Joystick.X(analogRead(0));
 Joystick.Y(analogRead(1));

}
If this one works then you can use the real sketches and at least wiring is ok then.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 04:54 AM - 04/16/15
Thanks I will try this when I get home.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 03:31 PM - 04/17/15
Ok I got it working but up,down is reversed. Left right is good. Is there a way to change this or did I do something wrong ?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 03:43 PM - 04/17/15
up,down should be Y.  Just subtract the current analogRead value from 255.  I 'think' that will unreverse it.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 03:52 PM - 04/17/15
Where do I find that?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 04:35 PM - 04/17/15
In your code...

Code: [Select]
Joystick.Y(255 - analogRead(whatever analog pin # your Y wire is soldered to));
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 12:20 PM - 04/18/15
Cant get it to work. I have tried putting this in different places and it just stops y movement all together.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 12:21 PM - 04/18/15
I might try moving y wire on teensy to see if that does anything
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 12:33 PM - 04/18/15
Nope. No change.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 02:27 PM - 04/18/15
Ok thanks Tuff and W11cE for all the help I finally got it. I changed ymin and ymax around in the code and that fixed it. Also I didn't use the joystick pcb, I just split the wires on the joystick itself and soldered to them. I'm not sure if that is why my y was reversed but now it works . I am very sorry for all the questions. Again thank you guys very much for all the help.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 05:47 PM - 04/18/15
I have been following. Good work to all of you getting through it.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 09:03 PM - 04/18/15
Glad its working.

So you just soldered directly to the copper film coming out of the stick base?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 10:31 PM - 04/18/15
Yeah I think it was a lot easier than soldering to the pcb. Looking at the copper film with the joystick to the back I left the 3 wires to the right together then split the other three with an razer blade. I put a piece of double sided tape on the table so I could keep the wires apart. After I soldered the wires I hot glued them in place while still on the double sided tape. I played a couple games and it felt good. All I have ever used is the nav so it's going to take a little getting used to. I think I might check out the fps freeks mod you did Tuff.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 11:47 PM - 04/19/15
Nice. Never thought of soldering to that flexboard directly. So all we need now are some pics ? :)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 10:04 AM - 04/20/15
After all the problems I had once it worked I was so excited that I didn't think about pics until I had it all installed. I have another joystick I can do and take some pics.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 10:16 AM - 04/20/15
To be clear... you soldered directly to this:

(http://i.imgur.com/rO3lTn6.png)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 12:39 PM - 04/20/15
Yes. The three on right I kept together then split the rest.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 08:28 PM - 04/26/15
I am having a problem with my joystick on pc. When I back out of a lobby and join another game my joystick doesn't work but my orbweaver still does. The only way I have found to get it working again is to unplug the orbweaver and plug it back in. No issues when using with xim. Other than that I love the vita stick.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 05:08 PM - 04/27/15
Have you tried any "real" joystick device with that game to see if its a bug feature in that game? Joystick devices along with kb/m are a pita with some games on pc.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:08 PM - 05/12/15
Hi guys got my vita in ty for the guides. Stick works well calibration worked well. But left and right are backwards. Which ymin and ymax are you changing to fix that? Is it in the void loop or void setup?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:13 PM - 05/12/15
Looks like it will be loop. I see analog read 1 is y. If that is correct how do I change it? Would I just swap places with them
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:14 PM - 05/12/15
Can anyone post a pic of it
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 08:18 PM - 05/12/15
I really don't get why people keep doing the Vita mod.  It's much harder and more expensive.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:22 PM - 05/12/15
Well when guys posted that earlier I had already bought it.   So far I like it.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:25 PM - 05/12/15
Got it going.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 08:27 PM - 05/12/15
Could you post the current code you are using now?

Depends on the scale but for 10-bit it would go like this:
Code: [Select]
Joystick.X(1023 - analogRead(whatever analog pin # your X wire is soldered to));
I really don't get why people keep doing the Vita mod.  It's much harder and more expensive.
Its smaller than "regular" joysticks and better than PSP stick. So that is the only solution if you dont want to use the regular ones.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:27 PM - 05/12/15
Rabbit I seen you post the expense part after it was in the mail.  But to truthful the other stick was making my thumb sore.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:29 PM - 05/12/15
Thank you W11cE. And thank you Rabbit and Roads and everyone I love reading your guides.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 08:11 AM - 05/13/15
Don't get me wrong.  It's a legit joystick and has some pros over the other option.  It's just an expensive PITA to get working comparatively.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 10:20 AM - 05/13/15
Sorry I didn't see your question. Glad you got it working. I really like the size of the vita stick, I think the ps4 joystick would be uncomfortable. As far as price you can pick up a vita with a broken screen pretty cheap.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 12:23 PM - 05/14/15
Yes I like it also good movement. My worry was that it would not be durable but I used the PCB so easy plug in, and mounted it with screws so easy change now if it breaks.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 09:36 AM - 05/23/15
I have used the vita stick enough to say that it is a worthy upgrade over regular stick. Now my wife wants one lol.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 09:41 AM - 05/23/15
It works well in world of Warcraft. Frees up finger for casting, I use foot pedal mod for main rotation and fingers for cool downs. Stick to drive. Its the best controller I have used.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 06:30 AM - 06/01/15
I've been following the various Teensy threads and I'm about to try to add a joystick to an N52te.
I wont be doing the Teensy buttons (maybe later if I get this working)  .. I'm using the board from the N52 with Cherry reds and mounting it in a homemade enclosure.
 
So if I do joystick only with W11ce's version 2, and I get a Teensy 3.1 will I only need Arduino IDE 1.0.6... or will I need Teensyduino as well ?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 07:10 AM - 06/02/15
Hi from I can tell you will need both. Teensyduino is what makes it work with teensy chip
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 07:12 AM - 06/02/15
I would like to see a pic of your case for it if you would like to share. I also wanted to do my own but n52te is already perfect for me.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 07:17 AM - 06/02/15
I have disability leading me to mod controller. I also have a friend who had a stroke at 17 and now he can't use left arm at all. I am trying to make him a mouse using corsair m90 with vita stick on thumb. Fitting it together is hard with such tight space. A right hand n52te would be the answer to it, anyone have any ideals on a one hand control for the right hand. Please share if you do.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 08:08 AM - 06/02/15
My Narwhal pad will be ambidextrous.

http://xim4.com/community/index.php?topic=40201.0
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 08:28 AM - 06/02/15
Nice work I will follow up on it. The kid I am referring to wants to play COD, and he understands he will not be as mobile as everyone else, but he has nothing to do and he is gamer at heart. I think we can all imagine how we would feel.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 01:14 PM - 06/02/15
Hi from I can tell you will need both. Teensyduino is what makes it work with teensy chip

Thanks for the advice ... I need all the help I can get with software lol !
 
I'll post a pic if and when I get it all working, going to use wood and try to get the buttons laid out to suit my hand, and get away from the straight rows of keys.
 
I also have a gaming friend who recently had a stroke, his right hand has been badly affected  .. it would be nice to be able to come up with something that would help him keep gaming. He should still be able to hold a mouse ... so maybe some foot switches wired to the Teensy would help ... could it emulate a mouse click I wonder?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 01:17 PM - 06/02/15
Well left hand is easy n52te as is work. Add vita stick even better. But yes add foot pedals to buttons not used after putting in vita stick that's what I have.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 01:18 PM - 06/02/15
And yes would as mouse clicks.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 01:20 PM - 06/02/15
If my controller was for right hand it would be great for my friend. Drive with wasd and vita stick use pinky to fire, or foot pedals.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 10:25 AM - 06/05/15
First off I apologise to all the intelligent members for having to ask such a dumb question  :-[
 
I have my Teensy 3.1 and I'm ready to begin, but my 1st stumbling block is knowing exactly what to do to be able to install or "merge" the WUSB pack 22112014 over the Arduino folder.
 
I have the WUSB pack extracted into a new desktop folder on Windows Vista.
Arduino IDE 1.0.6 is installed on my PC along with Teensyduino 1.20
 
Do I go to (C:) Program files / Arduino and simply drag and drop the WUSB pack into the Arduino folder ?
 
Or do I have to name the folder containing the WUSB pack in a certain way to "merge" it with the Arduino folder?
 
Any help would be very much appreciated ... just imagine you are explaining it to a 6 year old  :)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 11:44 AM - 06/05/15
Copy over and say yes to overwrite
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 12:22 PM - 06/05/15
Yeah, you copy paste the contents of wusb pack to arduino folder. It will as you if you want to merge the folders and overwrite some files. If not you did not copypaste the right stuff.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 01:54 PM - 06/05/15
 :)  Thanks  :)  .... so when I copy paste the contents of the wusb pack to the Arduino folder, do I have to open the wusb pack and then copy your library / lib / hardware files etc. to the ones with the same names in the Arduino folder ... or do I just paste the entire contents  of the folder into the Arduino folder?
 
 
Apologies again for being a noob  ... I'm really looking forward to doing this. I understand the soldering, but I can't get past this little obstacle  ... man they didn't even have calculators when I went to school  :)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 03:32 PM - 06/05/15
I gotta own up and say that I'm well and truly stuck  :-[
 
I uninstalled everything and tried again, this time I saved the Arduino ide to a folder before opening it.
 
I then downloaded the wusb pack, saved it and then copied it over the Arduino folder ... this started up the arduino installation, but when I open it up there is no sign of xim joystick.
 
 
All I have done so far is download the software and plug the Teensy 3.1 into the PC  ... No wires soldered to the teensy yet, and I haven't connected it to the xim4 yet (this shouldn't make any difference to the wusb software showing up in Arduino ide ,should it?)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 10:42 AM - 06/06/15
copied it over the Arduino folder
You dont copy it over arduino folder, you copy the contents over arduino folder.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 02:52 PM - 06/06/15
WOO HOO  ;D ... I've just seen those magical words [Wusb] Xim Joystick Ver 2 .... Yes !!!
 
I don't know how many times I installed and uninstalled everything, but I got there eventually  .. man I'm so thick lol.
 
So I now have teensy 3.1 and Joystick Ver 2 highlighted  ...  do I just have to copy/paste the correct script onto the sketch page and that will be everything done apart from the wiring ?
 
I've seen a lot of posts in various threads with scripts   .. all I want to do is the G13 joystick and buttons, no mouse touch pads or anything .... can anyone point me at the one I need please ... in case I goof it up  :-[
 
I'm really stoked at the thought of making my own little wooden keypad, first I'm going to put a joystick on my Belkin that has the roads 360 controller stick/ cherry mod.
Then I'm going to make a wooden keypad with buttons all over the place  :)
 
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 03:14 PM - 06/06/15
How many buttons are you going to have and how are you going to wire those?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 03:45 PM - 06/06/15
Well at the moment I'm only using about 10 or 12 keys on my G13, so maybe 15 keys would do.
As for wiring  .. same as your diagram on page 1 with the ground running from switch to switch.
 
One more question if you don't mind W11cE  .. I have a SparkFun joystick + breakoutboard and it has a stick click function.
Could I just wire the stick click pins to the teensy 3.3v and ground connections in the same way as a cherry switch to perform a joystick button function?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 05:02 PM - 06/06/15
For 15 keys matrix wiring is a little more simple, but the code is a little more complicated. Either way teensy 3.1 got enough pins for simple wiring also.

Checked the breakout board schematic and the switch is wired to ground. So yes, you can wire it the same way as a simple cherry switch.

Just a note that the fist post is highly outdated. The info in there was written for the fist version and after that only links were renewed.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Au1d Yin on 05:35 PM - 06/06/15
Many thanks W11cE  :) 
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 05:45 PM - 06/06/15
np  ;)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 02:56 PM - 08/04/15
Could I use W11ce's package, teensy 3.1 and wii nunchuk to replace my NAV much like this post but for joystick instead of mouse?

http://www.instructables.com/id/USB-Mouse-Made-Out-Of-A-Wii-Nunchuck/?ALLSTEPS

Also seen this wiichuck that enables I2c use which appears supported by teensy

http://proto-pic.co.uk/wiichuck-adapter/
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 12:45 PM - 08/05/15
Yeah, Either way should be possible.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 04:24 PM - 08/05/15
Thanks, teensy 3.1 ordered, going to try the dismantle route
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 05:34 PM - 08/07/15
I'm nearly there with the nunchuck but my Y AXIS is inverted, could someone tell me exactly what to add to the Y axis line please;

// Pin 13 has the LED on Teensy 3.1
// 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);     
  pinMode(0, INPUT_PULLUP);
  pinMode(1, INPUT_PULLUP);
}

// the loop routine runs over and over again forever:
void loop() {
  Joystick.X(analogRead(0));
  Joystick.Y(analogRead(1));
  Joystick.button(1, !digitalRead(0));
  Joystick.button(2, !digitalRead(1));
  digitalWrite(led, HIGH);   // turn the LED on (HIGH is the voltage level)
}
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 07:21 AM - 08/08/15
Code: [Select]
Joystick.Y(1023 - analogRead(1));This inverts it.
And as always, some pics please.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 09:43 AM - 08/08/15
Super thankyou, that fixed my axis, now I'll try and work out how and why :)

(https://lh3.googleusercontent.com/eyx0_We3lNDRz-nhSmSo6qkeQhDSqwoKoqUl9ngzcA=w582-h775-no)

One last question : the Z and C buttons on the nunchuck are on a single pcb - very left in pic, with a shared ground. My Z button works with the code as expected but the C button is always on and can't be changed, any ideas?

Dom
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 10:50 AM - 08/09/15
Dow did you wire it? Looking from the picture looks like you did not wire the button pcb directly to teensy.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 11:46 AM - 08/09/15
Yeah, the button PCB was wired to the main PCB so took it from there, I'll cut those and go back directly to the button PCB.

However, I've been thinking about the use of the INPUT_PULLUP voltage would that cause a problem if the ground is shared?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 12:52 PM - 08/09/15
No, thats how buttons are usually wired. Just separate the button pcb from the main board and wire the ground and pins to teensy.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 02:55 PM - 08/11/15
Thanks again, all done and working fine now, will assemble it all soon. I'm just waiting for some momentary buttons to arrive, going to put 2 on the side for 3rd and 4th fingers and then I'll be done.

(https://lh3.googleusercontent.com/_MxC5Die7cMHfjGIqN30N4kV5m7KR_d-764JJPTL724=w1034-h775-no)
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 02:38 PM - 08/17/15
Well I've wired it all up, just went for the single side button in the end which i'm using in place of the missing joystick down button.

One thing I have noticed is that joystick up and down doesn't work in the in-game menu for BF-HL. It works fine in game and on the Playstation home screen so I've just mapped a couple of the mouse buttons to take care of this.

(https://lh3.googleusercontent.com/AwrFvdPxQ_SM9QIx_Aplr--Qd9s8MiKsMw8oVoYGSgs=w582-h775-no)

Thanks again W11ce, Dom.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 02:56 PM - 08/29/15
Well done :)
The menus not working might be because the joystick value does not go to the max or min at all. You can fix it by scaling the axes. Here is an example on how to do it:
Code: [Select]
#define STICK_X 0
#define STICK_Y 1

#define OVERVAL 256
int Xstick;
int Ystick;



void setup() {
  pinMode(0, INPUT_PULLUP);
  pinMode(1, INPUT_PULLUP);
}

void loop() {
 
  Xstick = map(analogRead(STICK_X), OVERVAL, 1024-OVERVAL, 0, 1024);
  Xstick = constrain(Xstick, 0 , 1023);
  Joystick.X(Xstick);
  Ystick = map(analogRead(STICK_Y), OVERVAL, 1024-OVERVAL, 1024, 0);
  Ystick = constrain(Ystick, 0 , 1023);
  Joystick.Y(Ystick);

  Joystick.button(1, !digitalRead(0));
  Joystick.button(2, !digitalRead(1));
 
}
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 01:36 PM - 09/19/15
I made the changes and unfortunately it still doesn't work in the menus. Also noticed that it won't let me move to a vehicle when on the spawn map.

// Pin 13 has the LED on Teensy 3.1 give it a name
int led = 13;
//define STICK_X 0
//define STICK_Y 1
//define OVERVAL 256
int Xstick;
int Ystick;
int OVERVAL;
int STICK_X = 0;
int STICK_Y = 1;

// the setup routine runs once when you press reset:
void setup() {               
  // initialize the digital pin as an output.
  // initialize the digital pins as inputs.
  pinMode(led, OUTPUT);     
  pinMode(0, INPUT_PULLUP);
  pinMode(1, INPUT_PULLUP);
  pinMode(2, INPUT_PULLUP);
}

// the loop routine runs over and over again forever:
void loop() {
//  Joystick.X(analogRead(0));
//  Joystick.Y(1023 - analogRead(1));
  Xstick = map(analogRead(STICK_X), OVERVAL, 1024-OVERVAL, 0, 1024);
  Xstick = constrain(Xstick, 0 , 1023);
  Joystick.X(Xstick);
  Ystick = map(analogRead(STICK_Y), OVERVAL, 1024-OVERVAL, 1024, 0);
  Ystick = constrain(Ystick, 0 , 1023);
  Joystick.Y(Ystick);
  Joystick.button(1, !digitalRead(0));
  Joystick.button(2, !digitalRead(1));
  Joystick.button(3, !digitalRead(2));
  digitalWrite(led, HIGH);   // turn the LED on (HIGH is the voltage level)
}


Should I change the overval line to int OVERVAL=256; ?
Thanks
Dom
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 11:36 AM - 09/28/15
Sorry, forgot to answer. Why have you exluded #defines?

It should be like this:

Code: [Select]
// Pin 13 has the LED on Teensy 3.1 give it a name
int led = 13;
#define STICK_X 0
#define STICK_Y 1
#define OVERVAL 256
int Xstick;
int Ystick;

// the setup routine runs once when you press reset:
void setup() {               
  // initialize the digital pin as an output.
  // initialize the digital pins as inputs.
  pinMode(led, OUTPUT);     
  pinMode(0, INPUT_PULLUP);
  pinMode(1, INPUT_PULLUP);
  pinMode(2, INPUT_PULLUP);
}

// the loop routine runs over and over again forever:
void loop() {
  Xstick = map(analogRead(STICK_X), OVERVAL, 1024-OVERVAL, 0, 1024);
  Xstick = constrain(Xstick, 0 , 1023);
  Joystick.X(Xstick);
  Ystick = map(analogRead(STICK_Y), OVERVAL, 1024-OVERVAL, 1024, 0);
  Ystick = constrain(Ystick, 0 , 1023);
  Joystick.Y(Ystick);
  Joystick.button(1, !digitalRead(0));
  Joystick.button(2, !digitalRead(1));
  Joystick.button(3, !digitalRead(2));
  digitalWrite(led, HIGH);   // turn the LED on (HIGH is the voltage level)
}

Sure you can change those to int also if you want, but previously the OVERVAL was 0. That means nothing was changed in behaviour.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 01:21 PM - 09/28/15
The #defines didn't seem to build for me last time but will try it again. I'll cut n paste your code and give it a try, thanks.
Dom
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: DomA on 05:02 PM - 10/01/15
W11CE that works perfectly, all menu navigation is fine, thanks very much.

I really like using the chuk but really miss the lack of J3 stick button so am going to take a look at retro fitting the nav joystick into the chuck.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 01:10 AM - 01/08/16
New version out. Added support for latest teensy versions and removed some stuff. If someone misses those, they can use older versions.

Please report if you get any errors.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 08:12 AM - 01/08/16
What stuff did you remove?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: SE4N on 03:03 AM - 01/10/16
Hey thanks for updating this W11cE. I got it to work, yay. Appreciate your help.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 02:22 PM - 01/10/16
Nice you got it working :)

What stuff did you remove?
XIMCommanduino for example. Does not work with XIM4, so no reason to keep it.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tails72 on 04:50 AM - 02/26/16
hey guys, so far your code works great W11cE,

Is this better for buttons then say using a bounce library?

Also does anyone know how to wire up the joystick from a nav controller to the teensy 3.2? or even what the wires are then i can just wire them up myself.
Also for multiple butttons do you daisy chain the ground? or put it in series?

cheers

i will post a tutorial when i get out of the testing phase.

I'm going to redesign my nav controller a little

tails
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tuffrabit on 11:18 AM - 02/26/16
I may have missed the announcement... but does this work on teensy 3.2?
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: W11cE on 03:27 PM - 02/26/16
I may have missed the announcement... but does this work on teensy 3.2?
Yes.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tails72 on 04:44 AM - 03/22/16
Hey W11ce, is it normal that when i test the joystick on windows in the joy.cpl that its eractic, i mean it looks like its never going to stay center.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: chad20 on 08:26 PM - 03/22/16
It depends how bad. You can adjust you dead zone in the manager. Mine moved a little but don't notice it at all while playing.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 06:20 AM - 03/23/16
I had that on my first one. You guy told me I was using wrong software version, I got the right one and it worked perfect.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: tails72 on 06:31 AM - 03/23/16
thanks, well will have to wait because now the teensy is not working at all,
ordered another an will see how i go
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: ScopeLoc on 07:42 AM - 03/23/16
When I did mine and it was doing that I re worked  the wires 3 times. Then asked on site for help. I was using a completely wrong version. I got the right one and it is smooth as butter. I have since updated my hard drive and can't remember the version of it, but it was over a year ago. And they have updated since
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: gduck24 on 09:18 PM - 07/20/17
anybody have the pictures that roads posted from the beginning?  I am a picture guy and I am redoing the wiring on this mod and need pictures.
Title: Re: Tut: Microcontrollers as a HID device(s) on XIM adapters.
Post by: Pallo420 on 06:38 PM - 11/03/19
The latest version here: 08012016 (https://drive.google.com/open?id=0B_0MQrj9_eGtZm1PTHRQdGpYWkk)

Install on the top of Arduino IDE 1.6.7 and Teensyduino 1.27


Short description:
This package adds 3 custom USB modes for teensy 3.0, 3.1, 3.2 and LC.
 - Joystick VER 1 is recommended for XIM 3 and EDGE. (Does not work with XIM 4).
 - Joystick VER 2 is for XIM 4.
 - Modified mouse USB mode with support for Aux buttons for XIM 3, 4 and EDGE.


Joystick VER 1
Code: [Select]
Joystick.X(val);
Joystick.Y(val);
Axis values between 0 and 1023.

Code: [Select]
Joystick.Button(button, val);
Joystick.button(button, val);
Button from 1 to 11. Val 1 = pressed, 0 = released.


Joystick VER 2
Code: [Select]
Joystick.X(val);
Joystick.Y(val);
Axis values between 0 and 1023.

Code: [Select]
Joystick.Button(button, val);
Joystick.button(button, val);
Button from 1 to 35. Val 1 = pressed, 0 = released.


Mouse
Code: [Select]
Mouse.X(val);
Mouse.Y(val);
Mouse axis relative movement.

Code: [Select]
Mouse.scroll(val);
Mouse.pan(val);
Use these for scroll direction(0 is centered):
Code: [Select]
SCROLL_UP
SCROLL_DOWN
PAN_LEFT
PAN_RIGHT


Code: [Select]
Mouse.Button(button, val);
Mouse.button(button, val);
Val 1 = pressed, 0 = released. Use these for button names:
Code: [Select]
XIM4_Left
XIM4_Right
XIM4_Middle
XIM4_Back
XIM4_Forward
XIM4_Aux1
XIM4_Aux2
XIM4_Aux3
XIM4_Aux4
XIM4_Aux5
XIM4_Aux6
XIM4_Aux7
XIM4_Aux8
XIM4_Aux9
XIM4_Aux10
XIM4_Aux11

Has this been tried with the XIM Apex?