Csound Csound-dev Csound-tekno Search About

[Csnd] R: Re: Anyone using wiiosc?

Date2008-11-26 19:44
From"vallste@libero.it"
Subject[Csnd] R: Re: Anyone using wiiosc?
Great! It works
Thank you, I owe you a beer

>----Messaggio originale----
>Da: 
hcengar@gmail.com
>Data: 26/11/2008 20.03
>A: 
>Ogg: 
[Csnd] Re: Anyone using wiiosc?
>
>Hello Stefano,
>
>I've been succesfuly using 
Csound, wiiosc and a wiimote with nunchuck
>under Linux (also done it using 
PD). Probably your problem is due to a
>missing "i" in your OSClisten calls. 
There are always two values being
>transmitted, one is the wii ID number (you 
can have more than one
>wiimote connected at the same time) and the second 
value is the value
>of the parameter (button, accel. x, accel. y, etc.). Your 
OSClisten
>calls should then read something like this:
>
>k1  OSClisten 
gihandle, "/wii/keys/one", "ii", kwiiID, kkey1
>k2  OSClisten gihandle, 
"/wii/keys/two", "ii", kwiiID, kkey2
>
>ka  OSClisten gihandle, "/wii/keys/a", 
"ii", kwiiID, kkeya
>kb  OSClisten gihandle, "/wii/keys/b", "ii", kwiiID, kkeyb

>
>Where kwiiID is the k-rate variable that will get the ID number.
>
>Hope 
this helps,
>
>Cheers,
>
>Hector
>
>
>
>On Wed, Nov 26, 2008 at 12:49 PM, 
vallste@libero.it  wrote:
>> Hello List,
>> I'm trying to 
use wiiosc to connect a wiimote to OSC to control a
>> realtime orchestra but 
I'm not able to let csound (5.08 Ubuntu .deb packages)
>> read osc data passed 
on, if I use the wiimote as mouse it works so the cwiid
>> library is working 
correctly, wiiosc discover the wii.
>> This is the orchestra
>> I'm using to 
test the button but it doesn't show any "button event".
>> Anyone is
>> having 
this thing working under Linux? Any Idea?
>>
>> Thank you
>>
>> Stefano
>>
>>

>> 
>> 
>> -i adc:system:capture_ -o dac:system:
playback_ -
>> +rtaudio=jack
>> 
>> 
>> sr = 48000

>> kr = 3000
>> nchnls = 2
>>
>>
>> gihandle OSCinit 57120
>> kwhen init 0
>>

>> FLpanel "Wii OSC test", 800, 300
>>
>> gktast1,
>> gitast1 FLtext          
"1",    0,   1,  0,     1,     50,      20,    10,  00
>> gktast2,
>> gitast2 
FLtext          "2",    0,   1,  0,     1,     50,      20,    10,  50
>> 
gktasta,
>> gitasta FLtext          "A",    0,   1,  0,     1,     50,      
20,    10,  100
>> gktastb,
>> gitastb FLtext          "B",    0,   1,  0,     
1,     50,      20,    10,  150
>>
>> FLpanelEnd
>> FLrun
>>
>>
>> instr 1
>> 
kwhen = 1
>> OSCsend kwhen, "192.168.1.7", 57150,
>> "/wii/rumble", "s", "ii"

>> ;initialize
>> kkey1 init 0
>> kkey2 init 0
>> kkeya init 0
>>
>> kkeyb init 
0
>> kkeylh init 0
>> kkeyrh init 0
>> kkeyup init 0
>> kkeydo init 0
>> kkeyho

>> init 0
>> kkeypl init 0
>> kkeymi init 0
>> ;keys
>> k1  OSClisten gihandle,

>> "/wii/keys/one", "i", kkey1
>> k2  OSClisten gihandle, "/wii/keys/two", "i", 
kkey2
>>
>> ka  OSClisten gihandle, "/wii/keys/a", "i", kkeya
>> kb  OSClisten 
gihandle,
>> "/wii/keys/b", "i", kkeyb
>>
>> printk2 k1
>> printk2 k2
>> 
printk2 ka
>> printk2 kb
>> printk2
>> kkey1
>> printk2 kkey2
>> printk2 kkeya

>> printk2 kkeyb
>>
>> FLsetVal k1, kkey1, gitast1
>>
>> FLsetVal k2, kkey2, 
gitast2
>> FLsetVal ka, kkeya, gitasta
>> FLsetVal kb, kkeyb,
>> gitastb
>>
>> 
endin
>> 
>> 
>> i 1 0 300
>> e
>> 
>>
>> 

>>
>>
>> Send bugs reports to this list.
>> To 
unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

>>
>
>
>Send bugs reports to this list.
>To unsubscribe, send email sympa@lists.
bath.ac.uk with body "unsubscribe csound"
>