Forums > MaxMSP

Can you emulate a joystick?

September 30, 2006 | 12:47 pm

I want to have Max/MSP outputting a movement on a joystick-axis.
So can you trick windows (XP) to thinking a joystick is plugged in (soit can be used with games or other pieces of software accepting joystick input).

It will need like a driver emulating a joystick right?


September 30, 2006 | 2:09 pm

Not sure if Max is able to output the information I think Hi is definatly a one way thing, I’m not sure if you could do that with Junxion from Steim (i’ve been looking into its possibilities this week) Other than that, I wouldnt know how you could do it- since computers dont have joystick ports any more- you couldnt do things that way.

Good luck with your search.
T


September 30, 2006 | 5:25 pm

I have found a way – though not tested it.

Max/MSP MIDI out –> MIDI Yoke –> PIE (Programmable Input Editor) –> PPJoy (and its joystick driver)

I dunno if there is much lag this way around, but I think I’m going to try it.


October 1, 2006 | 8:23 am

Max/MSP MIDI out –> MIDI Yoke –> PIE (Programmable Input Editor) –> PPJoy (and its joystick driver)

Sounds feasable, but complicates things. How about an "emulateJoystick" object sending messages (such as "MM_JOY1BUTTONDOWN") to the OS? I’ve written these for the mouse, keyboard and filesystem; seems pretty straightforward…


October 1, 2006 | 9:23 am

yeah that would probalby work a lot quicker. Also I’ve heard mixed results with MIDI Yoke on XP – I don’t know how to send those joystick messages.

Could you give me an example of how to, for instance, send a button on the joystick being pressed?

TIA


October 1, 2006 | 10:12 am

as Dayton wrote, Ppjoy is definitly the tool to use.
I did that joystick emulation once.
Ppjoy comes with a serial to joystick converter, so you don’t need to write an object with the C
library that also come with it. then send data with the [serial] object from another computer.
that’s how I did it.

//yac


October 1, 2006 | 2:15 pm

yeah leaving the midi out of this sounds like a good idea. Im currently looking into some serial cable loopback driver, so I won’t need to PCs for this.

Any other suggestions on how to do this are most welcome!


October 5, 2006 | 12:28 am

hmm PIE isnt accepting midi input.. I can get maxmsp to catch midiout from PIE with no problems.

I need another way, for getting the stuff into PIE – or directly send the joystick commands to windows.
I have only just started on C – so I’m no experienced programmer.

So any help would be great!


Viewing 8 posts - 1 through 8 (of 8 total)