lazzarello / freemg

The engine for the Electromyographone project in collaboration with Torino::Margolis
http://www.torino-margolis.com/Torino_Margolis/FreEMG.html
3 stars 1 forks source link

get supercollider to run headless on pi #2

Closed lazzarello closed 6 years ago

lazzarello commented 6 years ago

sclang runs and I can get scide on another computer to send raw OSC messages / synthdefs but it's...sub-optimnal.

figure out how to get scsynth + sclang to work with uploaded patches.

lazzarello commented 6 years ago

sclang seems to require an X display

pi@bleh:~/src/freemg/ble2osc $ sclang -a testsynth.scd 
init_OSC
empty
compiling class library (debug build)...
initPassOne started
QXcbConnection: Could not connect to display 
Aborted
lazzarello commented 6 years ago

Okay, well I can send synthdefs and synths to the remote server but the OSCDef.new object fails, likely because it's not communicating with the server.

I figured out how to send raw OSC messages from Python but I need to set the type, for example this code fails silently when sent directly to the server.

                oscmsg = OSC.OSCMessage()
                oscmsg.setAddress("/n_set")
                oscmsg.append(data)
                oscmsg.append(1002)
                oscmsg.append("freq")
                oscmsg.append(data)
                osc.send(oscmsg)

Most likely because the nodeID and data is not an Integer type.