Posted December 13, 20222 yr dear all i would like to send some specific data via OSC to MAX... i can send "something" to max (defparameter max '(127.0.0.1 7500)) ;; that works SEND data to MAX and i would like to send the following seq to MAX by OSC /player "12" 1.0 1.0 1.0 but how to do it / format it in OMPO? ;; data should be "113" 1 1. 25000 => but how to "format"? -> see the MAX form ;; ??? (send-osc-data (create-osc-thread "player" max) data) /player is sended but not the rest of teh sequence here is a screenshot from MAX, it worked with an external library (in CCL) but i would like to do it "directly" in OPMO. in MAX, that's what i'm sending - for example - as an internal test thanx for some help...!! andré
February 14, 20232 yr Author here is the solution to send any data by OSC! a big thanks to janusz who made it for me/us!! now a wide variety of externals can be controlled via OSC, in any format... (not only reaktor) (defun osc-send (&rest args) (let* ((host #(127 0 0 1)) ;; host (port 7500) ;; port (s (usocket:socket-connect host port :protocol :datagram :element-type '(unsigned-byte 8))) (b (apply' osc:encode-message args))) (format t "sending to ~a on port ~A~%~%" host port) (unwind-protect (usocket:socket-send s b (length b)) (when s (usocket:socket-close s))))) (osc-send "/player" "120" 1 1 1) (osc-send "/beat" "defer" 0 "duration" 1 "pattern" 12)
Create an account or sign in to comment