Integration Flow
Build integrations with your line in a browser, without writing code.
The Integration Flow is where you connect your Captic system to your line. It is based on Node-RED 4.0 and runs on every Captic device. You build integrations in your browser by wiring nodes together into flows; no application code is needed.
The Integration Flow comes with Captic's own nodes for vision, robots and digital I/O, plus pre-installed nodes for the common industrial protocols. See Integrations for an overview of everything you can connect to.
Open it on a computer on the same network as the device:
http://[serial-number].local:1880How a flow works
A flow is a chain of nodes connected by wires. Each node does one thing, such as reading a PLC value, running a vision pipeline or moving a robot, and passes a message (msg) on to the next node. Most data travels in msg.payload.
Drag nodes from the palette on the left onto the canvas, double-click a node to configure it, wire nodes together, and click Deploy to make your changes live.
A typical flow looks like this:
A trigger starts the flow: a PLC value changes, a digital input goes high, or an HTTP request arrives.
Run Pipeline asks the vision system for a result.
A function or change node picks the values you need from the result.
An output node sends them on: it writes to the PLC, moves the robot or sets a digital output.
The palette
The palette is organised by what you connect to:
The digital I/O nodes are described in Digital I/O.
Vision nodes
The vision nodes connect your flow to the vision system on the same device, through the Product API.
Vision Connection
A configuration node shared by the other vision nodes.
Host
localhost
Port
5004
Timeout
30 s
If a vision node has no connection set, it uses localhost:5004. That's usually right, but set the connection explicitly so a misconfiguration doesn't go unnoticed.
Run Pipeline
Starts a vision pipeline run, waits for it to finish, and outputs the result.
Settings: pipeline ID (required), timeout (default 120 s), connection.
Per message: override the pipeline with
msg.pipelineIdand the timeout withmsg.timeout. Ifmsg.payloadis an object, its fields are passed to the pipeline as extra parameters.Output:
msg.resultholds the result, alongsidemsg.runId,msg.pipelineId,msg.statusandmsg.metadata.msg.payloadholds the full run overview.
Save Image
Saves the current frame from a camera, for example to collect images for retraining.
Settings: camera ID (required), timeout (default 30 s), connection.
Per message: override with
msg.cameraIdandmsg.timeout.Output: the API response in
msg.payload.
Pipeline Run Listener
Receives a notification each time a pipeline run happens, so a flow can react to runs started elsewhere, for example from the Product UI.
Endpoint:
POST http://[serial-number].local:1880/api/vision/pipeline-runby default.Filter: optionally set a pipeline ID; notifications for other pipelines are ignored.
Output: the notification in
msg.payload, plusmsg.event,msg.runId,msg.pipelineIdandmsg.status.
Endpoints your flow can offer
Flows can expose HTTP endpoints on port 1880. They are always served under /api: a path you enter as /robot/pose in a node is reached at http://[serial-number].local:1880/api/robot/pose. See also HTTP.
Robot pose service
The Pose Request and Pose Response nodes turn a flow into a service that answers one question: where is the robot right now? The robot calibration wizard uses it to fetch the robot's pose instead of you typing it in.
Add a Pose Request node. It listens on
GET /api/robot/pose.Wire it to a node that reads the robot pose, such as a robot node or a PLC read.
Wire that to a Pose Response node, which sends the pose back.
The pose can be an object with x, y, z and a, b, c (or rx, ry, rz), or an array of six numbers in that order, in millimetres and degrees. A successful answer looks like {"ok": true, "pose": {"x": …, "y": …, "z": …, "a": …, "b": …, "c": …}}.
Only one Pose Request node can be active; a second one disables itself. If no pose arrives within the timeout (default 2 s), the service answers with an error that the robot is unreachable.
Good to know
Units. Positions are in millimetres and angles in degrees throughout the Integration Flow, including for robots that use other units internally.
Per-message overrides. Most node settings, including the timeout (
msg.timeout), can be set per message, so flows can drive nodes dynamically. Bothsnake_caseandcamelCasenames are accepted.Status indicators. Nodes show a blue dot while working, green on success and a red ring with the error message on failure.
Updates keep your flows. When the device software is updated, the Captic nodes and settings are refreshed, but your flows and credentials are kept.