Kinetic Sculpture Achieves Balance Through Machine Learning

We all know how important it is to achieve balance in life, or at least so the self-help industry tells us. How exactly to achieve balance is generally left as an exercise to the individual, however, with varying results. But what about our machines? Will there come a day when artificial intelligences and their robotic bodies become so stressed that they too will search for an elusive and ill-defined sense of balance?

We kid, but only a little; who knows what the future field of machine psychology will discover? Until then, this kinetic sculpture that achieves literal balance might hold lessons for human and machine alike. Dubbed In Medio Stat Virtus, or “In the middle stands virtue,” [Astrid Kraniger]’s kinetic sculpture explores how a simple system can find a stable equilibrium with machine learning. The task seems easy: keep a ball centered on a track suspended by two cables. The length of the cables is varied by stepper motors, while the position of the ball is detected by the difference in weight between the two cables using load cells scavenged from luggage scales. The motors raise and lower each side to even out the forces on each, eventually achieving balance.

The twist here is that rather than a simple PID loop or another control algorithm, [Astrid] chose to apply machine learning to the problem using the Q-Behave library. The system detects when the difference between the two weights is decreasing and “rewards” the algorithm so that it learns what is required of it. The result is a system that gently settles into equilibrium. Check out the video below; it’s strangely soothing.

We’ve seen self-balancing systems before, from ball-balancing Stewart platforms to Segway-like two-wheel balancers. One wonders if machine learning could be applied to these systems as well.

Continue reading “Kinetic Sculpture Achieves Balance Through Machine Learning”

3D Printers Get A Fuel Gauge: Adding A Filament Scale To OctoPrint

It seems a simple enough concept: as a 3D printer consumes filament, the spool becomes lighter. If you weighed an empty spool, and subtracted that from the weight of the in-use spool, you’d know how much filament you had left. Despite being an easy way to get a “fuel gauge” on a desktop 3D printer, it isn’t something we often see on DIY machines, much less consumer hardware. But with this slick hack from [Victor Noordhoek] as inspiration, it might become a bit more common.

He’s designed a simple filament holder which mounts on top of an HX711 load cell, which is in turn connected to the Raspberry Pi running OctoPrint over SPI. If you’re running OctoPrint on something like an old PC, you’ll need to use an intermediate device such as an Arduino to get it connected; though honestly you should probably just be using a Pi.

On the software side, [Victor] has written an OctoPrint plugin that adds a readout of current filament weight to the main display. He’s put a fair amount of polish into the plugin, going through the effort to add in a calibration routine and a field where you can enter in the weight of your empty spool so it can be automatically deducted from the HX711’s reading.

Hopefully a future version of the plugin will allow the user to enter in the density of their particular filament so it can calculate an estimate of the remaining length. The next logical step would be adding a check that will show the user a warning if they try to start a print that requires more filament than the sensor detects is currently loaded.

This is yet another excellent example of the incredible flexibility and customization offered by OctoPrint. If you’re looking for more reasons to make the switch, check out our guide on using OctoPrint to create impressive time lapse videos of your prints, or how you can control the printer from your mobile device.

Assess Your Output With A Cheap DIY Urine Flowmeter

Some things about the human body are trivial to measure. Height, weight, blood pressure, pulse, temperature — these are all easily quantifiable with the simplest of instruments and can provide valuable insights into our state of health. Electrical activity in the heart and the brain can be captured with more complex instruments, too, and all manner of scopes can be inserted into various orifices to obtain actionable information about what’s going on.

But what about, err, going? Urine flow can be an important leading indicator for a host of diseases and conditions, but it generally relies on subjective reports from the patient. Is there a way to objectively measure how well urine is flowing? Of course there is.

The goal for [GreenEyedExplorer]’s simple uroflowmeter is simple: provide a cheap, easy to use instrument that any patient can use to quantify the rate of urine flow while voiding. Now, we know what you’re thinking — isn’t liquid flow usually measured in a closed system with a paddlewheel or something extending into the stream? Wouldn’t such a device for urine flow either be invasive or messy, or both? Rest assured, this technique is simple and tidy. A small load cell is attached to an ESP8266 through an HX711 load cell amp. A small pan on the load cell receives urine while voiding, and the force of the urine striking the pan is assessed by the software. Reports can be printed to share with your doctor, and records are kept to see how flow changes over time.

All kidding aside, this could be an important diagnostic tool, and at 10€ to build, it empowers anyone to take charge of their health. And since [GreenEyedExplorer] is actually a urologist, we’re taking this one seriously.

Continue reading “Assess Your Output With A Cheap DIY Urine Flowmeter”

Dumb Box? Make It Really Smart!

[Stephen Harrison]’s Really Smart Box is a great concept, it’s simultaneously a simple idea while at the same time being super clever. The Really Smart Box isn’t really a box; it’s a drop-in platform that can be made any size, intended to turn any dumb storage box into one that helps manage and track levels and usage of any sort of stock or consumable.

It does this by measuring the weight of the stuff piled on top of it, while also monitoring temperature and humidity. The platform communicates this information wirelessly to a back end, allowing decisions to be made about stock levels, usage, and monitoring of storage conditions. It’s clearly best applied to consumables or other stock that comes and goes. The Really Smart Box platform is battery-powered, but spends most of its time asleep to maximize battery life. The prototype uses the SigFox IoT framework for the wireless data, which we have seen before in a wireless swimming pool monitor.

This is still just a prototype and there are bugs to iron out, but it works and [Stephen] intends to set-and-forget the prototype into the Cambridge Makespace with the task of storing and monitoring 3D printer filament. A brief demo video is embedded below.

Continue reading “Dumb Box? Make It Really Smart!”

Instrument Packed Pedal Keeps Track Of Cyclist’s Power

Exactly how much work is required to pedal a bike? There are plenty of ways to measure the power generated by a cyclist, but a lot of them such as heavily instrumented bottom brackets and crank arms, can be far too expensive for casual use. But for $30 in parts you can build this power-measuring bike pedal. and find out just how hard you’re stoking.

Of course it’s not just the parts but knowing what to do with them, and [rabbitcreek] has put a lot of thought and engineering into this power pedal. The main business of measuring the force applied to the crank falls to a pair of micro load cells connected in parallel. A Wemos, an HX711 load-cell amp, a small LiPo pack and charging module, a Qi wireless charger, a Hall sensor, a ruggedized power switch, and some Neopixels round out the BOM. Everything is carefully stuffed into very little space in a modified mountain bike pedal and potted in epoxy for all-weather use. The Hall sensor keeps tracks of the RPMs while the strain gauges measure the force applied to the pedal, and the numbers from a ride can be downloaded later.

We recall a similar effort using a crank studded with strain gauges. But this one is impressive because everything fits in a tidy package. And the diamond plate is a nice touch.

Hackaday Prize Entry: Dynamometer For Post Stroke Rehabilitation

For those who have suffered a stroke, recovery is a long and slow process that requires rehabilitation to start as early as possible. Quite often, secondary stroke attacks complicate matters. Spasticity — muscle contraction and paresis — muscular weakness, are two of the many common after-effects of stroke. Recovery involves doing repeated exercises to strengthen the muscles and bring back muscle memory. Benchmarking progress becomes difficult when caregivers are only able to use qualitative means such as squeezing tennis balls to monitor improvement. To help provide quantitative measurements in such cases, [Sergei V. Bogdanov] is building a Dynamometer for Post-Stroke Rehabilitation. It is an Open Source, 4-channel differential force gauge for measuring and logging the progress of the patient. The device measures, graphs, and logs the force exerted by the four fingers when they push down on the four force gauges.

The device consists of four strain gauges obtained from cheap kitchen scales. The analog outputs from these are fed to HX-711 24-bit ADC boards. An Arduino Nano processes the data and displays it on two banks of eight-digit LED modules. [Sergei] also experimented with a 20×4 character LCD in place of the LED display. In the standalone mode, the device can only indicate the measured forces on the LED (or LCD) display which is calibrated to display either numerical values or a logarithmic scale. When connected to a serial port and using the (Windows only) program, it is possible to not only view the same information but also save it at regular, set intervals. The data can also be viewed in graphical form.

The project page provides links to their Arduino code, Windows monitor program as well as build instructions. Check out the related assistive technology project that [Sergei] is working on — A Post Stroke Spasticity Rehab Helper.

Continue reading “Hackaday Prize Entry: Dynamometer For Post Stroke Rehabilitation”

Load Cells Tell You To Lay Off The Donuts

Our old algebra teacher used to say, “You have to take what you know and use it to get what you don’t know.” That saying always reminds of us sensors that convert physical quantities into things our microcontrollers can measure. Sometimes the key to a project is knowing what kind of sensor will read the physical properties of the system you are interested in. If that physical property is weight, you can use what is known as a load cell. [DegrawSt] uses four 50 kg load cells to create a bathroom scale using an Arduino.

Load cells typically contain strain gauges that change resistance when deformed. This actually measures force, but if you mount them so they measure the force exerted by you standing on a platform, you get a scale. A load cell usually has four strain gauges in a bridge configuration. This causes a voltage across the bridge, although the output can be noisy and on the order of millivolts.

Continue reading “Load Cells Tell You To Lay Off The Donuts”