-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how make an osc response from the server #169
Comments
I found this solution : from pythonosc.udp_client import SimpleUDPClient
def xinfo(unused_addr, args):
client_infos = server.get_request()[1]
client_ip, client_port = client_infos[0], client_infos[1]
client_answer = SimpleUDPClient(client_ip, client_port) # Create client
client_answer.send_message('/xinfo', [client_ip, 'X32-04-A0-71', 'X32', '4.06']) Is there another solution less manual ? |
In fact, this solution doesn't work because client_answer sends message with a random source port but we need the source port of the response to be the server port. For instance : client sends an OSC message : (64302, 127.0.0.1) -> to the server (10023, 127.0.0.1) With SimpleUDPClient we just specify 127.0.0.1 and 64302. We have to fix is source_port as 10023. How to make a real response from the server ? Thanks a lot. |
@systemeFriche take a look at the changes merged in #173 which is in the 1.9.0 release. You can send responses to incoming messages on both the client and server side. |
I want to simulate a Beringher X32 mixing table with a python program. The idea is to command a max program with the X32 Edit software.
To initiate the communication between the X32 Edit software and my fake X32 program, I need the server to respond to the client with an OSC message, something like that :
Is it possible with python-osc module ? How ?
Thanks a lot.
The text was updated successfully, but these errors were encountered: