The Virtue Of Wires In The Age Of Wireless

We ran an article this week about RS-485, a noise resistant differential serial multidrop bus architecture. (Tell me where else you’re going to read articles like that!) I’ve had my fun with RS-485 in the past, and reading this piece reminded me of those days.

You see, RS-485 lets you connect a whole slew of devices up to a single bundle of Cat5 cable, and if you combine it with the Modbus protocol, you can have them work together in a network. Dedicate a couple of those Cat5 lines to power, and it’s the perfect recipe for a home, or hackerspace, small-device network — the kind of things that you, and I, would do with WiFi and an ESP8266 today.

Wired is more reliable, has fewer moving parts, and can solve the “how do I get power to these things” problem. It’s intrinsically simpler: no radios, just serial data running as voltage over wires. But nobody likes running cable, and there’s just so much more demo code out there for an ESP solution. There’s an undeniable ease of development and cross-device compatibility with WiFi. Your devices can speak directly to a computer, or to the whole Internet. And that’s been the death of wired.

Still, some part of me admires the purpose-built simplicity and the bombproof nature of the wired bus. It feels somehow retro, but maybe I’ll break out some old Cat5 and run it around the office just for old times’ sake.

Hacker Dictionary: RS-485 Will Go The Distance

RS485 is a communication standard that should be part of the advanced hardware hacker’s arsenal; it’s not commonly encountered, but powerful exactly when you need it. It’s a physical layer interface for wired communications that uses a single differential pair for noise immunity, has good long-distance properties, and allows many connections to a single bus. Because of that, you will encounter it in security systems and even cameras, wired sensor networks, DMX512 lighting and all sorts of industrial electronics. For our hobbyist goals, you can absolutely use RS485 to build your home (or room) automation system, or a relatively large robot – without all those worries that wireless brings.

The name might remind you of RS232, and that’s because both RS232 and RS485 are standards that come from EIA (Electronics Industries Alliance). It also might remind you of RS422, if you’ve ever seen this name mentioned online – RS422 and RS485 are closely intertwined, sharing most of the physical layer, and I’ll show how exactly they relate. Continue reading “Hacker Dictionary: RS-485 Will Go The Distance”

A PoE adapter's RJ45 jack added inside an Acer laptop

Laptop Empty Space Filled With RS485 And PoE

Out of all the laptop upgrade options typically available, you wouldn’t expect this specific one. [controlmypad] decided to take a part of his RS485 device programming workflow and put it inside of a spare laptop he picked up for cheap. Typically, he’d occupy some desk space and lay out an unwieldy combination of a USB-RS485 dongle, a PoE power injector, a PSU for that injector, and a few cables to join it all – being extra weight in the tool bag, cluttering the workspace when laid out, and the RS485 adapter slowly wearing out the USB ports during the work-related motions. No reason that all of this couldn’t be packed inside a laptop, however.

What helps a lot is that, in many modern cheap laptops, the motherboard is fairly small, and the DVD drive plastic placeholder can be omitted without second thought. Cutting off the plastic molding from both of the adapters turns them into a nicely reusable circuit board and a small PoE module, respectively. After laborious yet careful cutting of the laptop case with a hobby knife, the PoE injector fits right in and, essentially, adds an extra RJ45 port to the laptop. From where the Hackaday.io write-up left off, it doesn’t seem like this mod got fully completed, but most of the important details are there for us to learn from. What got left out is connecting it to an internal USB port (should help that the motherboard’s schematics are available online), as well as creating 12V-24V from the laptop’s power rails. At this point, however, this mod is a big step forward usability-wise, even if it still requires an external PSU.

Laptop internal upgrade projects are rare but cherished – it’s a combination of “daring”, “inquisitive” and “meticulous” that results in people successfully hacking on a thing they certainly were not meant to hack, and have that thing serve their needs better. Apart from all the EEE PC upgrade options that set the bar for a generation of laptop modders, there’s a myriad of unconventional laptop modification vectors – you could do a thorough from-scratch Type-C charging port conversion, replace your webcam with an FSF-endorsed open firmware WiFi dongle, build in a “12-axis” sensor for auto-orientation and data-logging, or invent a remote self-destruct mechanism for your laptop. Those are, indeed, quite a few things you won’t typically find in the list of available options while customizing your laptop at the manufacturer website.

Learn DMX512 Basics

If you’ve done anything with modern lighting effects, you’ve probably heard of DMX, also known as DMX512. Ever wonder what’s really happening under the hood? If so, then you should have a look at [EEForEveryone’s] video on the topic, which you can see below.

At the core, the DMX512 uses RS485, but adds software layers and features. The video uses the OSI model to show how the system works.

Continue reading “Learn DMX512 Basics”

Meter All The Phases: Three Phase Energy Meter With OpenWrt

Keeping track your overall electricity usage is a good thing, and it’s even better if you know where all the kilowatt-hours are going. [Anurag Chugh’s] house has the three phases coming from the electrical distribution box tidily organized: One for the lighting and fans, one for household appliances, and one for the hot water supply. To monitor and analyze the electrical fingerprint of his house, [Anurag] installed a 3 phase energy meter and hooked it up to the internet.

Continue reading “Meter All The Phases: Three Phase Energy Meter With OpenWrt”

LED Strip Cape Drives Kilometers Worth Of LEDs

led-strip-cape

[Hudson] is looking to drive a lot of LEDs. A driver that effectively addresses kilometers worth of LED strips isn’t an easy thing to come by. So he’s in the process of designing his own BeagleBone Cape to do the work. Above you can see the board layout he’s working with. Notice the set of repeating red footprints in the center? Those are pads for 32 RS485 connectors!

Of course this is all in preparation for Burning Man where the mantra seems to be: he who has the most LEDs wins. Well, unless you’re the sort that likes to work with flames. But we digress. The scaling problem that [Hudson] is dealing with hinges around his desire not to include ridiculous numbers microcontrollers and the need to beef up the 3.3V logic levels of the BeagleBone to travel further on the data bus of the strips. By leveraging the RS485 protocol — which is designed to carry data over long distances — he can get away with a single processing unit by adding an RS485 translator at each remote strip connector. He plans to use the BeagleBone’s Programmable Realtime Units feature to address the eight drivers on the cape. But first he has to solve what looks like a doozy of a trace routing problem

RS-485 Node Control For Arduino

rs-485-arduino-nodes

Wanting to control a split flap display that was not near a computer [Tom] looked to a common solution for communicating over distances not practical for I2C or SPI. He developed his own hardware and packet format using the RS-485 protocol.

This is part of a larger project he has been working on to feed data to a split flap display that he plans to hang on the wall. RS-485 is designed to work over long distances and overcome noise issues. The core of the communications system is the board seen on the left. It uses a MAX1483 chip, a pair of RJ45 jacks for Ethernet cables, and two terminal blocks for power and communications. There are a few nice things about this. The board acts as a pass-through making it easy to chain nodes together, and the data structure is completely independent of the hardware itself. Because of this [Tom] developed his own packet format that will be a bit more resilient than the Arduino networking scheme we looked at the other day.