Csound Csound-dev Csound-tekno Search About

[Csnd] controllers like gamepad or joystick?

Date2011-04-03 08:59
Fromfrancesco
Subject[Csnd] controllers like gamepad or joystick?
Hello All,
is there a way to use generic controllers in csound, like gamepad and
joystick?
If not, could be possible to have it?

thanks,
ciao,
francesco.

--
View this message in context: http://csound.1045644.n5.nabble.com/controllers-like-gamepad-or-joystick-tp4278574p4278574.html
Sent from the Csound - General mailing list archive at Nabble.com.


Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-04-03 09:11
FromIain McCurdy
SubjectRE: [Csnd] controllers like gamepad or joystick?
On Mac you can convert from HID (human interface device - joystick) to OSC or MIDI then send this data into Csound using Junxion from Steim. On Windows Rejoice will convert into MIDI then via MIDI Ox into Csound. I don't think Csound can handle HID joystick natively. Rejoice is free, Junxion isn't.
Iain

> Date: Sun, 3 Apr 2011 00:59:46 -0700
> From: ilterzouomo@fastwebnet.it
> To: csound@lists.bath.ac.uk
> Subject: [Csnd] controllers like gamepad or joystick?
>
> Hello All,
> is there a way to use generic controllers in csound, like gamepad and
> joystick?
> If not, could be possible to have it?
>
> thanks,
> ciao,
> francesco.
>
> --
> View this message in context: http://csound.1045644.n5.nabble.com/controllers-like-gamepad-or-joystick-tp4278574p4278574.html
> Sent from the Csound - General mailing list archive at Nabble.com.
>
>
> Send bugs reports to the Sourceforge bug tracker
> https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"
>

Date2011-04-03 11:46
Fromfrancesco
Subject[Csnd] RE: controllers like gamepad or joystick?
Thanks Mr. Iain,
i would know if possible directly in csound (something like p5glove).
I'm actually using Ubuntu, but dual boot with Windows, then
i will look at Rejoice although i would prefer working in Ubuntu.

Thank You,
ciao,
francesco.



--
View this message in context: http://csound.1045644.n5.nabble.com/controllers-like-gamepad-or-joystick-tp4278574p4278676.html
Sent from the Csound - General mailing list archive at Nabble.com.


Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-04-03 12:59
FromRory Walsh
SubjectRe: [Csnd] RE: controllers like gamepad or joystick?
AttachmentsCsJoystick.zip  
I wrote a little python script that will let you use a joystick with
Csound. It doesn't uses the Csound API rather than MIDI to send data
to Csound. I've attached it and a few examples. This is only tested on
window but should work on whatever platform pygame is supported on.
Instructions are in the readme file.

Rory.





On 3 April 2011 11:46, francesco  wrote:
> Thanks Mr. Iain,
> i would know if possible directly in csound (something like p5glove).
> I'm actually using Ubuntu, but dual boot with Windows, then
> i will look at Rejoice although i would prefer working in Ubuntu.
>
> Thank You,
> ciao,
> francesco.
>
>
>
> --
> View this message in context: http://csound.1045644.n5.nabble.com/controllers-like-gamepad-or-joystick-tp4278574p4278676.html
> Sent from the Csound - General mailing list archive at Nabble.com.
>
>
> Send bugs reports to the Sourceforge bug tracker
>            https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"
>
>

Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"


Date2011-04-03 16:04
FromJustin Glenn Smith
SubjectRe: [Csnd] RE: controllers like gamepad or joystick?
I made an opcode for this, that is linux specific. It grabs the full 16 bit resolution of the HID input (the values it reports range from -32768 to 32767, I wrote the opcode because I didn't want to settle for the coercion to 7 bit values you get with midi). Also it will automatically inform you of the number of axes / buttons available, and provide access to all of them (it is possible to write an instrument that will use this information to dynamically adapt to the number of inputs available).

http://code.google.com/p/noisesmith-linux-audio/source/browse/#svn%2Ftrunk%2Fcsound%2FOpcodes

There are some bugs when it comes to handling multiple joysticks, so only one joystick at a time for the timebeing. But it does successfully deal with having a joystick plugged in or unplugged any number of times while the orchestra is running (it will poll for the joystick instead of crashing if there is no joystick avalable, it will stop reading the device instead of crashing if you unplug the joystick, and it will open the joystick device again if you plug the joystick back in)

The abovementioned bugs are likely very shallow, and I should be getting to them soon. At the moment I am busy with an ocaml/gtk/gnomecanvas based frontend to csound. I know that there are bindings and frontends with many languages / graphics toolkits already but I find ocaml to be less brittle than most languages for refactoring and rapid development and much better performing CPU wise than any other high level language.

Rory Walsh wrote:
> I wrote a little python script that will let you use a joystick with
> Csound. It doesn't uses the Csound API rather than MIDI to send data
> to Csound. I've attached it and a few examples. This is only tested on
> window but should work on whatever platform pygame is supported on.
> Instructions are in the readme file.
> 
> Rory.
> 
> 
> 
> 
> 
> On 3 April 2011 11:46, francesco  wrote:
>> Thanks Mr. Iain,
>> i would know if possible directly in csound (something like p5glove).
>> I'm actually using Ubuntu, but dual boot with Windows, then
>> i will look at Rejoice although i would prefer working in Ubuntu.
>>
>> Thank You,
>> ciao,
>> francesco.
>>
>>
>>
>> --
>> View this message in context: http://csound.1045644.n5.nabble.com/controllers-like-gamepad-or-joystick-tp4278574p4278676.html
>> Sent from the Csound - General mailing list archive at Nabble.com.
>>
>>
>> Send bugs reports to the Sourceforge bug tracker
>>            https://sourceforge.net/tracker/?group_id=81968&atid=564599
>> Discussions of bugs and features can be posted here
>> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"
>>
>>
> 
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"
> 



Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"