The Linux X86 Journey To Main()

Have you ever had a program crash before your main function executes? it is rare, but it can happen. When it does, you need to understand what happens behind the scenes between the time the operating system starts your program and your first line of code in main executes. Luckily [Patrick Horgan] has a tutorial about the subject that’s very detailed. It doesn’t cover statically linked libraries but, as he points out, if you understand what he does cover, that’s easy to figure out on your own.

The operating system, it turns out, knows nothing about main. It does, however, know about a symbol called _start. Your runtime library provides this. That code contains some stack manipulation and eventually calls __libc_start_main which is also provided by the library. Continue reading “The Linux X86 Journey To Main()”

Photo of an automated plant watering system attached to four potted plants.

Automation Allows You To Leaf Your Plants Alone

The greatest threat to a potted plant stems from its owner’s forgetfulness, but [Sasa Karanovic] has created an automation system that will keep his plants from getting too thirsty. Over the past year [Sasa] has been documenting an elegant system for monitoring and watering plants which has now blossomed into a fully automated solution.

If you haven’t seen the earlier stages of the project, they’re definitely worth checking out. The short version is that [Sasa] has developed a watering system that uses I2C to communicate with soil moisture, temperature, and light sensors as well as to control solenoids that allow for individual plants to be watered as needed. An ESP32 serves as a bridge, allowing for the sensors to be read and the water to be dispensed via an HTTP interface.

In this final part, [Sasa] integrates his watering system into a home automation system. He uses a MySQL database to store logs of sensor data and watering activity, and n8n to automate measurement and watering. If something isn’t quite right, the system will even send him a Telegram notification that something is amiss.

If you think automation might be the best way to save your plants from a slow death, [Sasa] has kindly shared his excellent work on GitHub. Even if you don’t have a green thumb, this is still a great example of how to develop a home automation solution from scratch. If you’re more interested in television than gardening, check out [Sasa]’s approach to replacing a remote control with a web interface!

Continue reading “Automation Allows You To Leaf Your Plants Alone”

Pulp-Molding: A Use For Cardboard Confetti

We’re pretty sure that we don’t have to tell you how great cardboard is. You probably sing the praises yourself and use it for everything from a work surface protective layer to a prototype of your next amazing build. But if you still find yourself flush with cardboard even after all that, here’s one thing you can do with all those pieces that are too small to use for anything else– chuck them in an old blender, whip up some cardboard pulp, and press that gunk into some 3D-printed molds.

In addition to a step-by-step of the process, [flowalistik] offers a mold set of STL files for various useful items like a pencil holder, a box with a lid, a tray, and a coaster, as well as the Fusion 360 files in case you want to change them around. You might want to seal the coaster with something protective so that it doesn’t mold/disintegrate/bloom from condensation.

Each part consists of the walls, the wall clip that keeps them closed, but allows for de-molding and reuse, the bottom lid, and the top lid. All these prints need to be pretty high-res so that they can withstand the pressure of the clamp holding it all together. [flowalistik] recommends a layer height no larger than .03mm and a 20% infill.

The process of making the pulp itself is fairly simple, and the recipe only calls for water and some kind of binder. To start, remove all tape, coatings, staples, and anything else non-soluble from the cardboard. Cut it into bite-sized pieces your blender will enjoy, and add water and PVA glue or rice paste. Mix it up, remove the excess water by squeezing your pulp inside of a piece of cloth, and then use it to fill up your mold. You’ll want to press out the water as you go and fill it further, then finally apply the clamp. You can start de-molding parts on a schedule, starting with the clamp after about six hours. Once it’s fully dried in about two days, you can treat it like MDF and sand, cut, or even drill it. We think some of these would look pretty good with a coat of paint.

Need your objects to be more sturdy? Keep that printer warmed up — you can use prints to cast concrete, too.

DIY CNC Uses Lots Of 3D-Printed Parts

There are probably almost as many DIY CNC designs as there are DIY CNCs. And there’s nothing wrong with that! We really liked [maxvfischer’s] documentation on GitHub for a machine he made based on a design by [Ivan Miranada].

In addition to a complete bill of materials, there are Fusion 360 files and very good instructions. There are several tips that seemed like they would help even if you were building similar machines.

The machine uses HTD5M belts instead of the more prevalent lead screw design. Everything slides on MGN12H slides. There are detailed photographs covering not just the tricky parts but even how to extend the stepper motor wires.

The original design used a Makita RT0700C for the spindle, but [max] couldn’t find one of those, but found a similar version with the same dimensions.

The only tip we would add is to be careful using taps in a handheld drill. (Don’t ask us how we know that.) A drill press is safer, or you can even use a tap handle and do it the old-fashioned way.

The firmware is grbl on an Arduino, and there are complete instructions for setting that up, too. We were amazed at the number of pictures included along with the detailed description. If you were ever afraid you couldn’t duplicate a CNC project, this might be the one to tackle.

There are, of course, cheaper and simpler options with fewer capabilities. Some are even almost free courtesy of the local dumpster.

ETH0 Autumn 2021: Tiny Camp Manages COVID Precautions Indoors

It’s tempting despite news of stubbornly higher-than-ideal COVID infection figures, to imagine that just maybe the world might be returning to some semblance of pre-pandemic normality. Where this is being written we’re a largely vaccinated population long out of lockdown, and though perhaps some of the pandemic pronouncements of our politicians are a bit suspect we’re cautiously able to enjoy most of life’s essentials. Visiting the supermarket and having a beer might be one thing, but the effect of the pandemic is still being felt in our community’s gatherings. BornHack went ahead this summer, but the headline MCH hacker camp was put off until 2022 and the upcoming CCC Congress in Germany is once more to be a virtual event.

But some events manage to put together the right mix of precaution and size. Such was the case with ETH0, a hacker camp which I was happy to attend last weekend.

Continue reading “ETH0 Autumn 2021: Tiny Camp Manages COVID Precautions Indoors”

Hackaday Podcast 143: More Magnesium Please, Robot Bicep Curls, Malamud’s General Index, And Are You Down With EMC?

Hackaday editors Mike Szczys and Elliot Williams catch up on a week’s worth of hacks. Get a grip on robot hands: there’s an eerily human one on offer this week. If you’re doing buck/boost converter design, the real learning is in high-frequency design patterns that avoid turning your circuits into unintentional radiators. Those looking for new hobbies might want to take up autonomous boat racing. We saw a design that’s easy enough to print on the average 3D printer — and who doesn’t want to build their own jet boat? We’ll wrap up the episode by digging into magnesium sources, and by admiring the number of outfits who are rolling their own silicon these days.

Take a look at the links below if you want to follow along, and as always, tell us what you think about this episode in the comments!

Direct download (50 MB)

Continue reading “Hackaday Podcast 143: More Magnesium Please, Robot Bicep Curls, Malamud’s General Index, And Are You Down With EMC?”

Homebrewed Voice Assistant Keeps An Eye On Air Quality

Voice assistants are now available from a wide variety of companies, however, [7402] didn’t like the idea of these devices sending data off to the cloud for potentially-nefarious purposes. Thus, the goal became to build a home voice assistant that worked entirely offline, and that’s precisely what [7402] achieved.

The system had limited goals compared to commercial competitors. [7402] was more than happy to deal with a limited vocabulary of understanding as a trade off for privacy. It’s all built around a Raspberry Pi Zero, which runs the Julius speech recognition library. Ultrasonic sensors are used to only activate the device when a person leans in and directly addresses the system.

Capabilities include reporting on the weather, switching light on and off, and advising users of air quality readings from the local authorities.  Feedback to the user is via text-to-speech as well as flashing LEDs. The latter are used to create a quirky, retro “thinking” animation to indicate the system is processing, and has indeed heard a spoken command.

It’s a neat build, and one that covers most of the good things that commercial cloud devices are capable of anyway. As a bonus, no smartphone apps are required, nor will private companies impact the system’s functionality as it relies on no external servers to operate.

We’ve seen similar builds before too, such as this GlaDOS-themed voice assistant. Video after the break.

Continue reading “Homebrewed Voice Assistant Keeps An Eye On Air Quality”