hi
i am testing osc implementation in Chuck but i dont get incomming
messages. i manage to send from chuck to pd but not the other way around.
i attach the pd patch and the chuck file in case anyone want to have a
look. I am not sure what it could be the port should be ok as I tried
with python and pd with the same ports and everything worked perfectly.
So i guess i am missing something on the chuck side.
thanks
enrike
#N canvas 0 0 466 316 12;
#X obj 86 214 sendOSC;
#X floatatom 87 270 5 0 0 0 - - -;
#X msg 127 98 send /test 1;
#X obj 308 223 print;
#X obj 300 172 dumpOSC 9000;
#X msg 31 72 connect localhost 9001;
#X msg 125 157 send /test \$1;
#X floatatom 125 137 5 0 0 0 - - -;
#X obj 28 27 loadbang;
#X connect 0 0 1 0;
#X connect 2 0 0 0;
#X connect 4 0 3 0;
#X connect 5 0 0 0;
#X connect 6 0 0 0;
#X connect 7 0 6 0;
#X connect 8 0 5 0;
OscSend xmit;
xmit.setHost( "localhost", 9000);
// create our OSC receiver
OscRecv recv;
9001 => recv.port;
recv.listen();
recv.event( "/test, f" ) @=> OscEvent t;
// infinite event loop
while ( true ){
<<<"sending">>>;
xmit.startMsg( "/sndbuf/buf/rate", "f" );
0.5 => xmit.addFloat;
0.2::second => now; //send something
t => now; // wait for event to arrive
// grab the next message from the queue.
while ( t.nextMsg() != 0 ){
<<
hi Ge I already thought about that so I already tried that, however this time I tried with float numbers on the PD number box and it worked. Seems that pd changes the int into float when sending the message or something like that thanks!! enrike Ge Wang wrote:
HI Enrike!
#X msg 127 98 send /test 1;
Just a stab in the dark: try:
#X msg 127 98 send /test 1.0;
The chuck code is expecting a float and the 1 is possibly sending the message with int.
Best, Ge!
_______________________________________________ chuck-users mailing list chuck-users@lists.cs.princeton.edu https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
participants (2)
-
altern
-
Ge Wang