Posts with «lm358» label

Simple Circuit Keeps Process Control Loops in Tune

Spare a moment’s pity for the process engineer, whose job it is to keep industrial automation running no matter what. These poor souls seem to be forever on call, fielding panicked requests to come to the factory floor whenever the line goes down. Day or night, weekends, vacations, whatever — when it breaks, the process engineer jumps.

The pressures of such a gig can be enormous, and seem to have weighed on [Tom Goff] enough that he spent a weekend building a junk bin analog signal generator to replace a loop calibrator that he misplaced. Two process control signaling schemes were to be supported — the 0 to 10 VDC analog signal, and the venerable 4-20 mA current loop. All that’s needed for both outputs is an Arduino and an LM358 dual op-amp, plus a few support components. The 0-10 V signal starts as a PWM output from the Arduino, with its 0-5 V average amplified by one of the op-amps set up as a non-inverting amp with a gain of 2. With a little filtering, the voltage output is pretty stable, and swings nicely through the desired range — see the video below for that.

The current loop output is only slightly more complicated. An identical circuit on a separate Arduino output generates the same 10 V max output, but a code change limits the low end of the range to 1 V. This output of the op-amp is fed through a 500-Ω trimmer pot, and the magic of Ohm’s Law results in a 4-20 mA current. The circuit lives on a piece of perf board in a small enclosure and does the job it was built for — nothing fancy needed.

And spoiler alert: [Tom] found the missing loop calibrator — after he built this, of course. Isn’t that always the way?

Fail of the Week: The Arduino Walkie That Won’t Talkie

There’s something seriously wrong with the Arduino walkie-talkie that [GreatScott!] built.

The idea is simple: build a wireless intercom so a group of motor scooter riders can talk in real-time. Yes, such products exist commercially, but that’s no fun at all. With a little ingenuity and a well-stocked parts bin, such a device should be easy to build on the cheap, right?

Apparently not. [GreatScott!] went with an Arduino-based design, partly due to familiarity with the microcontroller but also because it made the RF part of the project seemingly easier due to cheap and easily available nRF24 2.4 GHz audio streaming modules. Everything seems straightforward enough on the breadboard – an op-amp to boost the signal from the condenser mic, a somewhat low but presumably usable 16 kHz sampling rate for the ADC. The radio modules linked up, but the audio quality was heavily distorted.

[GreatScott!] assumed that the rat’s nest of jumpers on the breadboard was to blame, so he jumped right to a PCB build. It’s a logical step, but it seems like it might be where he went wrong, because the PCB version was even worse. We’d perhaps have isolated the issue with the breadboard circuit first; did the distortion come from the audio stage? Or perhaps did the digitization inject some distortion? Or could the distortion be coming from the RF stage? We’d want to answer a few questions like that before jumping to a final design.

We love that [GreatScott!] has no issue with posting his failures – we’ve covered his suboptimal CPU handwarmer, and his 3D-printed BLDC motor stator was a flop too. It’s always nice to post mortem these things to avoid a similar fate.