I am doing some OSC stuff to control track devices, and what I want to do is have my Renoise handle an OSC message that is some sort of “current status” request and send an OSC message back with some device info.
Can anyone point me in the right direction for getting the IP address of an OSC client? (That is, the address of whatever just sent that “current status” request.)
Thanks, but I don’t see how this allows Renoise Lua code to determine the IP address of the sender of an OSC message in order to send a reply back to that address.
The example in the Socket docs is essentially correct but it needs updating because it says you can use socket.address but that throws an error. What worked for me is socket.peer_address (which I found further up on the same page.).
My tools that use OSC already had socket_message(socket, message) implemented in order to have an OSC server other than the default Renoise OSC server, so grabbing the peer_address is easy.
Next step is for the code to create an OSC client with that address (or re-use an existing one if has already been created).
Yeah, I already know the addresses of all the devices but I want a tool to be able to detect it so that it can send back data to whatever client requests it. The Socket API docs offered a solution. But thanks, though.