HORUS/blog

Sep 5, 2026 · robot-nodes · ros-2 · robotics-middleware · beginners

What Is a Robot Node, and Why Does Everything Use That Word?

A robot node is one program doing one job and swapping named messages with the rest, and here is when splitting a robot that way helps and when it hurts.

A robot node is one small program doing one job, and in ROS 2, HORUS and nearly every rival, nodes talk by publishing named messages. The word spread because splitting a robot into replaceable pieces is how almost everyone builds one, and because the tooling assumes it. That flips only if your whole robot is a single loop on a microcontroller, where nodes are vocabulary you do not need. The rest of this post is for someone who keeps meeting the word in tutorials and wants to know what it changes about the robot they are building.

You opened what was supposed to be a beginner tutorial and by the third paragraph everything was a node. The camera node publishes to a topic. The navigation node subscribes. Launch the nodes. Check that your nodes are running. Nobody stopped to say what a node is, because the word arrived so early in this field that the people writing tutorials have stopped seeing it.

So you did the reasonable thing and looked it up, and got a definition made of four more words you did not have: process, topic, publisher, executor. You came away with the impression that a node is something ceremonial — a thing you must declare, register and configure before your robot is allowed to move — and that impression is quietly discouraging, because it makes the simplest robot sound like paperwork.

Meanwhile you have a motor, a camera and a script that works, and you cannot tell whether you are doing it wrong. Is the script a node? Should it be three of them? Does the word describe something your robot needs, or something a particular toolkit needs you to write? That is the confusion worth clearing, and it clears faster than you would guess.

Should I build my robot as several nodes or as one program?

Several separate programs, once your robot has more than one sensor and something that moves; one program until then. The reason is not elegance. A robot fails in pieces: the camera driver hangs, the wheels keep spinning, and if everything lives in one program the hang takes the whole machine down with it. Split into separate programs, the part that hangs is the part that stops, and the rest can notice and react — cut the motors, hold position, write something in a log you can read afterwards.

The second reason is that you will replace things. The camera you bought will be discontinued. When each job is its own program talking through named messages, you swap one and leave the others untouched. When it is all one file, every change touches everything, and you stop making changes.

The honest exception is the beginning. A first robot that drives forward and stops when it sees a wall is fine as one script, and pretending otherwise is how beginners stall before anything ever moves.

What is a robot node in plain terms?

A node is one running program on a robot that does one job and hands its results to other programs by name instead of calling them directly. The camera node's job is to take pictures and announce them. The wheels node's job is to listen for speed instructions and drive the motors. Neither knows the other exists. They agree on a name — something like camera images, or wheel commands — and everything else is arranged by the layer sitting underneath them.

Two things follow from that, and both matter more than the definition itself. First, you can stop a node, fix it, and start it again while the rest of the robot keeps running, which is what makes debugging a machine bearable. Second, you can attach a new listener to any name without touching the program that produces it — which is how a recording tool, a screen display or a safety watchdog gets added later without a rewrite.

The name comes from graph drawings: circles with lines between them, and publish and subscribe explained without jargon draws the picture properly.

What actually uses the word node, and what are my options?

Four families use it, and they mean slightly different things by it. ROS 2 means it most strictly: a node is an object you construct, register with the system, and hang publishers and subscribers off, and the tooling can then list every node on a running robot and draw the graph. HORUS uses the same shape with a leaner interior — an open-source Apache-2.0 middleware for Rust, Python and C++ where the three languages share the same shared-memory ring buffers, so two nodes on one computer hand data over without packing it up for a network first — and the word still means one program doing one job. Vendor SDKs for arms and humanoids have nodes in all but name: one process per subsystem, with the vendor's own messaging between them. And plenty of working robots use no framework at all: separate programs, a pipe or a socket between them, the same idea assembled by hand.

That last family is the reminder worth keeping: nodes are a pattern, not a product, and what middleware actually does in a robot is what spares you assembling the pattern by hand.

How do the ways of organising robot code compare?

Read the last column first. Every row here works for somebody, and the mistake beginners make is not picking a weak option, it is picking one whose disqualifier applies to them and failing to notice for months. Two notes before the rows. These mix freely — a robot full of framework nodes can still have a hand-written program off to the side — and the choice is cheap to reverse early and expensive late.

OptionWho it is forWhat it assumes you knowWhen to pick itWhen not to
One program, no nodesFirst-time builders with one sensorBasic programmingYour robot does one thing and you want it moving this weekA second sensor or a safety stop has appeared
ROS 2 nodesAlmost every learner and most teamsLinux and patience with build toolsYou want drivers, navigation and tutorials that already existYour robot is a bare microcontroller with no operating system
HORUSBuilders whose machine hesitates and who own all of itWhich of your programs must never be lateSeveral languages share one computer and messages must not be repackedYou need a ready-made driver and package for every sensor
Vendor SDK nodesPeople with a bought arm or humanoidThe vendor's documentationThe robot came with it and you are building on topYou expect to move to different hardware later
Hand-rolled processes and pipesEngineers with a narrow, fixed robotOperating system basics and message formatsThe robot has few parts and outside dependencies are unwelcomeYour part count grows every month
Threads inside one programPython builders bolting on a cameraWhat happens when two threads touch one variableYou need two things at once without a second processA fault in one part must not stop the others
Microcontroller firmwareMotor and sensor boardsEmbedded C or RustThe job is one tight loop close to the hardwareThe job involves cameras, maps or models

I am building my first robot alone — how many nodes should I start with?

Three, and add a fourth only when something forces you. One node for the thing that senses, one for the thing that decides, one for the thing that moves. That split matches how you will think about the machine anyway, it survives contact with almost any project, and it hands you the single most useful debugging move available: stop the deciding part, drive the wheels by hand, and find out immediately which half is lying to you.

Resist the urge to split further at the start. A common beginner failure is arriving at a dozen tiny programs, each too small to justify itself, with the actual logic scattered across the gaps between them. Your evenings then go on chasing which of twelve things failed to start.

Split when you feel one of three pressures: a part that must keep running when another dies, a part written in a different language, or a part that runs on different hardware. Those are real reasons to add a node. "It felt tidier" is not one.

What if my whole robot runs on one small computer?

One small computer changes nothing about the pattern and quite a lot about the cost. Nodes still earn their place on a Raspberry Pi or a Jetson, because the separation still saves you when the camera driver hangs. But each extra program brings its own memory, its own startup time, and its own copy of whatever libraries it loads, and small boards fill up sooner than people expect.

The part worth understanding is what happens between two nodes on the same board. In the general case a message gets packed into a transportable form, handed to the operating system's networking machinery, and unpacked on the other side, even though both programs sit inches apart in the same memory. That work stays invisible until you add a camera, and then it is why a board that felt fine starts stuttering once a fourth node appears.

Middlewares differ on whether they avoid that repacking on a single machine, and on a small board it is the question worth asking, as middleware choices for Raspberry Pi and Jetson robots goes into.

I have a demo in three weeks — does any of this matter yet?

Not much, and the honest advice is to pick whatever arrangement gets the robot moving. Three weeks is enough time to build one thing imperfectly and have it work, and not enough to redesign how your programs talk to each other. Take whatever the tutorial for your hardware assumes, follow it exactly, and spend the remaining evenings on the behaviour you are actually demonstrating.

The one piece of structure worth having even under deadline is a separate program for anything that touches motors. Keep the part that commands movement in its own process, with a way to stop it that does not depend on the rest of the system being healthy. That costs an hour and it is the difference between a demo that ends with the robot stopping and a demo that ends with a repair.

Structure is worth paying for once a robot has to keep working while somebody else changes it, and that situation arrives immediately after a demo goes well, as why robot demos work and robot products do not describes.

I have never written two programs that run at once — is this too advanced?

No, and nodes are a gentler introduction to concurrency than the alternatives. Two programs exchanging messages is much easier to reason about than two threads sharing a variable, because there is nothing shared to corrupt: one program announces, another receives its own copy, and getting the order wrong produces stale data rather than a crash you cannot reproduce.

What actually trips people up is not the concept but the operational side. Programs that fail to start and say nothing about why. A misspelled name, so two nodes talk past each other in complete silence. A node that runs perfectly and receives nothing, because it began listening after the announcement was made. All of that is the first week, and every item on the list is a lookup rather than a skill.

The genuinely hard part arrives later and it is about time rather than concurrency: what should happen when the sensing part falls behind the deciding part, and which of the two is allowed to wait for the other.

What does a badly split robot look like when it goes wrong?

It looks like a machine that works, then stops working for no reason you can name. The usual first symptom is hesitation: the robot drives smoothly for a minute, pauses, then continues, and nothing in your code changed between those moments. Underneath, one node is producing faster than another can consume, a queue is filling, and older messages are either piling up or being discarded according to settings nobody has read.

The second symptom is order. The arm reaches for where the object used to be rather than where it is, because the picture the decision was based on had aged in transit. Everything is technically working. The robot is simply acting on the past.

The third is startup. The machine behaves differently depending on which node happened to start first, so half your mornings begin with turning it off and on again. None of these are bugs in the ordinary sense — no single line is wrong — which is exactly why they eat weeks, and why a robot that behaves differently every run is such a common complaint.

What do I give up by splitting my robot into nodes?

You give up simplicity, a little of the machine's capacity, and the ability to follow your own program by reading it from top to bottom. The last one is the real loss. In a single script you trace what happens by scrolling. Across seven nodes the flow lives in the connections between them, and you need a tool to see it at all — which is why every framework in this space ships a graph viewer, and why reading logs becomes a skill you have to develop.

You also give up directness. A function call either happens or raises an error; a message is announced into a name and may arrive late, arrive twice, or arrive at nobody. That is an honest tax, and the answer to it is not to avoid nodes but to be explicit about which streams your robot cannot survive missing.

And you pay in setup: more processes to launch, more things to supervise, more ways for a machine to end up half-alive. Frameworks exist largely to make that tolerable.

When is ROS 2 the better choice?

ROS 2 is the better choice for nearly everyone learning what a node is, and for most teams building a robot that has to still exist next year. The reason is that the word node is a small part of what you are actually buying. What you need is the camera driver you did not write, the navigation stack you did not write, the coordinate-frame bookkeeping you did not want to learn, the recorder, the visualiser, and the answer somebody already posted to the exact error you will hit at eleven at night. ROS 2 supplies all of that, and job adverts name it.

ROS 2 also wins when a robot spans several computers, when a team needs people it can hire without retraining them, and when the biggest risk to the project is simply not finishing. HORUS is not the answer to any of those problems: it replaces the layer that moves messages rather than the ecosystem around it, so choosing it while you are still learning what a topic is means writing the drivers, the tooling and the navigation yourself, alone.

Are nodes just a complicated way to call functions?

No, and here is why: a function call assumes both halves are alive, in the same program, and willing to wait for each other. A robot violates all three constantly. The camera is a separate device that sometimes stalls. The planner sometimes takes longer than the wheels can afford to wait. The moment you want the wheels to keep obeying their last instruction while the planner thinks, you have left function-call territory, and every workaround you invent to stay in it is a worse version of what nodes already do.

There is a real version of the complaint, though. Inside one node, people sometimes push work through the messaging layer when a plain function call would do, because the framework's vocabulary is right there in front of them. That is genuine over-engineering. If two pieces of code always run together, always in the same program, and neither needs to survive the other's failure, call the function.

The dividing line is survivability. Messages are for things that must outlive each other's failures, and functions are for everything else.

Do nodes make a robot slower?

Partly, but not the way you think. Handing a message from one program to another is genuinely more work than a function call, because the message has to be packaged and delivered rather than simply pointed at, and on a small board with a camera in the mix you will feel that eventually. So the worry is real in outline.

Where the intuition misleads is on what actually slows robots down in practice. The pauses people blame on nodes usually come from elsewhere: a queue configured to hold on to old messages long after they stopped being useful, a node doing heavy work in the same place it receives messages so incoming data stacks up behind it, or one sensor driver stalling and dragging its neighbours' timing along with it. Every one of those is fixable without abandoning the structure, and each gets diagnosed only because the structure let you examine one part at a time.

The genuine cost is copying, and it is a solved problem on a single computer — some middlewares avoid repacking altogether, which zero-copy messaging covers.

How do I decide how to split my own robot up?

Draw the robot as boxes and lines before you write anything. One box for each physical thing that produces data, one for each thing that moves, one for each decision that has to be made, and a line wherever information passes between them. That drawing is your node list, and making it takes about fifteen minutes.

Then apply three tests to every line you drew. Does the receiver need to keep working if the sender dies? Are the two written in different languages, or running on different computers? Does one need to run on a strict rhythm while the other is allowed to be leisurely? A yes to any of those means the two belong in separate nodes. Three noes means they can share one program, and probably should.

Finally, count the boxes you invented for tidiness rather than necessity, and delete them. The right number of nodes is the smallest number that passes those three tests, and beginners are punished far more often for having too many than for having too few.

Take the line that matches you:

The HORUS Fit Framework is that same judgement applied to the layer underneath, and not one of its five axes is a number: ecosystem size, setup effort, team size fit, deployment target and licence. Score whatever you are weighing on all five, and the axis you cannot compromise on decides it.

Once you have a robot that moves and a hesitation you can reproduce, the layer underneath is worth a second look. HORUS is open source under Apache-2.0 at github.com/softmata/horus — star it so it is in your list when you start building.

Found this useful? Share it:Discuss on HNShare on X