Nodes/MKRShift_Nodes/OSC Message Plan
ComfyUI Node

OSC Message Plan

Where your OSC messages get designed, not sent

By criskb·Created 7 months ago·Updated 5 months ago· 0
OSC Message Plan
    • osc_plan_json
    • manifest_line
    • summary_json
    address/mkrshift/frame
    host127.0.0.1
    port7000
    payload_json{}

    MKROSCMessagePlan is the design half of the pack's OSC lane. It builds a reusable, inspectable description of an OSC message - address, host, port, payload - as JSON. It does not send anything. The sending is MKROSCSend's job, and that's a deliberate split: you construct and tweak the plan in your graph, verify it visually, then hand it to the runtime node that actually fires the UDP packet.

    If you've never met OSC (Open Sound Control): it's the network protocol from the music world - same neighborhood as MIDI, but over UDP and built for high-frequency, low-latency messages. It's how TouchDesigner, Resolume, QLab, Max/MSP and a hundred other live tools talk to each other. The address looks like a filesystem path (/mkrshift/frame), and the payload is a list of typed arguments. This node exists so your ComfyUI graph can say "every time I finish a frame, send that fact to the VJ software" without writing any networking code yourself.

    The inputs

    • address - the OSC address, default /mkrshift/frame. This is the "what are we talking about" part. Keep it descriptive; the receiving app filters on it.
    • host - where to send it, default 127.0.0.1. Same machine? Loopback. Another machine or a piece of hardware? That host's IP.
    • port - 1–65535, default 7000. Must match whatever the receiver is listening on. This is the number people get wrong constantly.
    • payload_json - the data to send. The pack reads it as JSON; the plan's payload becomes the OSC arguments (each key sorted, or an args list if you provide one).

    The outputs

    • osc_plan_json - the plan, schema mkrshift_osc_plan_v1. Wire this into MKROSCSend's osc_plan_json.
    • manifest_line - a compact host,port,address string for logs and manifests.
    • summary_json - host, port, address, warnings. The warnings matter: if your payload is an empty {}, the plan will note it.

    Installing and gotchas

    MKRShift Nodes, one install for the whole pack:

    cd ComfyUI/custom_nodes
    git clone https://github.com/criskb/MKRShift_Nodes
    

    restart, or use ComfyUI Manager and search "MKRShift". No requirements, no model files - and notably, the OSC runtime uses Python's stdlib socket with a hand-built OSC packet, so there's no python-osc dependency to fight.

    The traps are all network-side. A plan that looks perfect does nothing by itself - nothing is sent until MKROSCSend runs, and a plan node that "ran fine" proves zero connectivity. Also watch the port. The default 7000 is the author's choice, not a standard - if your receiver listens on 9000, a default plan sends to a black hole. And when payload keys come from a JSON object, the pack sends them sorted by key unless you give an explicit args list, so argument order is deterministic but maybe not the order you typed. Check summary_json before wiring up a whole live show.

    CategoryMKRShift Nodes/Addons/Network

    Inputs (4)

    NameTypeDefaultDescription
    addressSTRING/mkrshift/frame
    hostSTRING127.0.0.1
    portINT70001–65535
    payload_jsonSTRING{}

    Outputs (3)

    NameTypeDescription
    osc_plan_jsonSTRING
    manifest_lineSTRING
    summary_jsonSTRING