Results 1 to 6 of 6

Thread: OSC and PD

  1. #1

    OSC and PD

    Hello, I'm currently trying to get better at using Osculator and pd in unison. I'd like to start working on PD tutorials, but I want to always have them running in and out of Osculator. Could anyone with experience in either PD and/or OSC let me know if I have done my code between them effectively and without redundancies...

    Osculator file:
    I start off in Osculator with creating a manual message "/ya/1" with an OSC Routing of localhost:9000.

    PD file:

    - receiving code

    (object) udpreceive 9000
    |
    |
    (object) unpackOSC
    |
    |
    (object) routeOSC /ya
    |
    |
    (object) routeOSC /1
    |
    |
    (number)
    |
    |
    (object) send hot

    - sending code (separated from my receiving code)

    (message) connect localhost 9000
    |
    |
    (object) udpsend

    (message) disconnect
    |
    |
    (object) udpsend

    (object) receive hot
    |
    |
    (message) send /ba/1 $1
    |
    |
    (object) packOSC
    |
    |
    (object) udpsend

    ...So when i test the /ya/1 message in Osculator with my mouse, I get the /ba/1 message added to Osculator. As I continue to click with my mouse, both of their activity boxes light up green in unison.

    I'd like to know if this coding between Oscualtor and PD is efficient enough to move on with practices and tutorials in PD?
    Is there a way to code udpreceive and udpsend interconnected rather than separated as seen in my PD file?
    Should Osculator have two messages that are OSC Routing rather than one?

    Let me know if anything is confusing or in need of clarification. Thanks!
    Attached Files Attached Files

  2. #2
    Hi Sam,

    All looks fine to me, exept the sending code. I don't understand why you ask PureData to connect on port 9000 since it is the one it is listening to. Maybe it is a typo and you meant 8000 to connect to OSCulator?

    I don't know if you've already seen this tutorials, but you should definitely check out Rafael Hernandez's PureData tutorials: http://www.osculator.net/2010/01/20/pure-data-and-osc/
    They cover a broad range of PureData, and you have also some of them dedicated to OSCulator.


    Best,
    Cam

  3. #3
    Well I would like the communication to be: Osc --> Puredata --> Osc. To do that, shouldI should use udpreceive 9000 to take information from Osc into Puredata, and use connect localhost 8000 to send information back to Osc?

  4. #4
    Yes, this is correct.

  5. #5
    Great, Thanks.

    One other thing. Yesterday this code was working fine, giving me activity on /ba/1 in Osc when I would click the activity box on /ya/1, but upon opening the files this morning and doing the same exact thing, I get the error "udpsend: not connected". I am confused as to how things could have changed like that over night. Do you have any ideas for why this is happening, or simple errors that I may be over looking?

  6. #6
    Probably because of the order in which you opened your OSC servers.
    It seems you had OSCulator running on port 9000 at some point since you received data from PD.

    I think "udpsend: not connected" means that it could not open the port because another application is already using it. Simply check the ports assigned to each application and you should sort that out. If you want simple explanations about IP networks and OSC ports, please check out the manual, the first chapter should help you see clearer : http://dl.osculator.net/doc/OSCulator+2.11+Manual.pdf

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •