osc icon indicating copy to clipboard operation
osc copied to clipboard

UnixConn read

Open avlapp opened this issue 2 years ago • 1 comments

Note I'm new to Unix sockets in general.

This library seems to support OSC via Unix sockets. Sending and receiving seems to work fine, but how should the client get a reply from server? It should just read from the same socket isn't it? Does this library support this? @briansorahan

avlapp avatar Dec 01 '22 14:12 avlapp

Or should I make another socket file for the client? That seems to work, I'm able to receive a 'pong'.

 addr, err = net.ResolveUnixAddr("unixgram", mySocket) 
    if err != nil {
        log.Fatalln(err)
    }

    u.laddr, err = net.ResolveUnixAddr("unixgram", osc.TempSocket())
    if err != nil {
        log.Fatalln(err)
    }
    u.clientConn, err = osc.DialUnix("unixgram", u.laddr, addr)
    if err != nil {
        log.Fatalln(err)
    }

https://stackoverflow.com/questions/3324619/unix-domain-socket-using-datagram-communication-between-one-server-process-and

avlapp avatar Dec 01 '22 15:12 avlapp