Dhanushwaran A Junderstand · build · give back
dhanushwaran a j · menu
← journal2 min · 326 words
· technical

How machines talk: Modbus, explained for normal people

The forty-year-old language that factory machines still speak, and why a systems engineer finds it beautiful.

Most of my work at i45G is getting machines to talk. Not to people — to each other. A power meter on a factory wall, a gateway in a cabinet, a dashboard on someone's phone. The language the first two speak is called Modbus, and it's from 1979.

Here's the whole idea in one picture.

Imagine a row of students, each with a number. A teacher walks in and says: "Number 5 — what's in your notebook, page 12?" Student 5 answers. Nobody else speaks. The teacher moves on to number 6.

That's Modbus. One device asks (the master), the others only answer when their number is called (the slaves — the old term, still used on every datasheet). Each answer is just numbers from a numbered list, called registers. "Page 12" might be current voltage. "Page 40" might be total energy today.

The wires this runs on are usually RS-485: two copper wires, up to a kilometre long, tolerant of the electrical noise a factory throws at everything. Slow by internet standards — a few kilobytes a second — and that's fine. A meter has nothing new to say a thousand times a second.

Why do I find this beautiful?

Because it's honest. There's no magic in it. When it breaks, it breaks for physical reasons: a wire swapped, a missing terminating resistor, two devices given the same number. You debug it with a multimeter and patience, not with a stack trace. It's the closest thing in my job to understanding a system all the way down.

And because it's the seam where my two worlds meet. On one side, a device that only knows "page 12 is 231". On the other, a web dashboard someone reads over coffee. Everything I build lives in between, turning one into the other, reliably, without drama.

That's the job, mostly: make the boring, important connections work, and keep them working.

▸
Jump · Intro01
Jump · About02
Open · Writing03
Open · Work04
Open · Now05
Jump · Contact06
Open · Uses/uses
Read · How machines talk: Modbus, explained for normal peoplejournal
Read · First engineer on the teamjournal
Read · Why Kiospal existsjournal
Send mail · dhanushwaran.aj@gmail.com@
Open · github↗
Open · linkedin↗
Open · RSSfeed
Toggle · light / darktheme
↑↓ navigate↵ selectesc close⌘K toggle