Osc bugs loops in command line

Hi, I’m trying to send Osc to Processing on raspberry.
With the Gui, there is no problem.
But when I use only the server to make a standalone application
running from command line,
the live loops stops on all Osc messages and don’t go further.
Strange ?

The server command line repeat this error 8 times :slight_smile:

Connection refused - send(2)
["/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/osc/udp_client.rb:30:in send'", "/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/osc/udp_client.rb:30:insend’", “/opt/sonic-pi/app/server/bin/sonic-pi-server.rb:465:in `block in '”]

Hi there, using Sonic Pi without the GUI is unsupported at this stage, sorry.

Still, could you let us know how to reproduce this error in case there’s a simple fix?

When the processing program is started before, I don’t have the error exception write here before but the osc line still stop the live_loop and never send osc message
here is the init.rb file :

use_osc ‘’, 5000
use_debug false
live_loop :can do
panSample = rrand(-1, 1)
with_fx :pan, pan: panSample do
sleep 1
sample “/home/pi/samples/elaGood.wav”, amp: 2
osc “/inst/panSample”, panSample
sleep 3

the processing code :

void setup(){
oscP5 = new OscP5(this, 5000);
myRemoteLocation = new NetAddress(“”, 4557);
oscP5.plug(this, “panSample”, “/inst/panSample”);

Working perfect twith the Gui

Ok, starting the gui with the init.rb file I’v got this output message :

Runtime Error: [buffer eval, line 21] - NoMethodError
Thread death ±-> :live_loop_can
undefined method send_ts' for nil:NilClass Did you mean? send /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:650:in__osc_send’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:689:in osc' eval:21:inblock (3 levels) in __spider_eval’
eval:15:in block (4 levels) in __spider_eval' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/sound.rb:2248:inblock in with_fx’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/sound.rb:2247:in times' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/sound.rb:2247:inwith_fx’
eval:12:in block (3 levels) in __spider_eval' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2115:inblock in live_loop’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2135:in block (2 levels) in live_loop' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2055:inblock (2 levels) in loop’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2276:in block_duration' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2313:inblock_slept?’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2054:in block in loop' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2052:inloop’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2052:in loop' /opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:2133:inblock in live_loop’
/opt/sonic-pi/app/server/sonicpi/lib/sonicpi/lang/core.rb:4390:in `block (2 levels) in in_thread’

Hi there, I’m still struggling to know how to re-create this. How are you starting Sonic Pi without the GUI?

I only start the server in command line then the file init.rb start alone

How are you starting the server on the command line?

cd /opt/sonic-pi/app/server/bin/

Looks like this might be the same, or at least related, problem as in this thread: Sonic Pi Headless Doesn't receive OSC cues?