30.04.2023, 17:19
Hi!!
I am controlling an audio software with udp.
Follwoing is the python code working on the site.
I want to execute this from LM so I need to rewrite this in Lua.
I've tried follwoing code but I got an error "invalid value (table) at index 2 in table for 'concat'".
Could you help me write this code properly?
Thank you very much for your help
I am controlling an audio software with udp.
Follwoing is the python code working on the site.
Code:
from pythonosc.udp_client import SimpleUDPClient
ip = "172.28.11.110"
to_ableton = 11000
from_ableton = 11001
client = SimpleUDPClient(ip, to_ableton)
client.send_message("/topic/of/message", [a, b, c])
I want to execute this from LM so I need to rewrite this in Lua.
I've tried follwoing code but I got an error "invalid value (table) at index 2 in table for 'concat'".
Could you help me write this code properly?
Code:
local socket = require("socket")
local ip = "172.28.11.110"
local to_ableton = 11000
local from_ableton = 11001
local msg = {"/topic/of/message", {a, b, c}}
local udp = socket.udp()
udp:settimeout(1)
udp:setpeername(ip, to_ableton)
udp:send(table.concat(msg, " "))
Thank you very much for your help