Skittles Sorter

Only Eat Red Skittles? We’ve Got You Covered.

Are you a bit obsessive compulsive with lots of certain things? We are too. Like Skittles! If you’re the kind of person who likes to sort their Skittles, you should seriously look into making your own 3D printed Skittles Sorter.

Built more to challenge his new 3D printer, [MrPrezident] was looking for a project to combine mechanical design with a bit of image recognition prowess — so he came up with this clever, and compact, Skittle sorting machine.

It uses an Arduino Uno with a ZITRADES color sensor module to identify the color of each candy. A small LED helps illuminate the Skittles to ensure an accurate color reading. Then, depending on the color, a series of gears rotate the Skittles piece to its designated color repository.

Theoretically it should also work with M&M’s (which are a bit smaller) but unfortunately, there are 6 colors of M&M’s and only 5 colors of Skittles. What would the machine do then!? We don’t see a reject bin!

Continue reading “Only Eat Red Skittles? We’ve Got You Covered.”

How Biohackers Are Fighting A Two-front War On Antibiotic Resistance

We humans like to think of ourselves as the pinnacle of evolution on the planet, but that’s just a conceit. It takes humans roughly twenty years to reproduce, whereas some bacteria can make copies of themselves every 20 minutes. Countless generations of bacteria have honed and perfected their genomes into extremely evolved biological machines.

Most bacteria are harmless, and some are quite useful, even tasty – witness the lactofermented pickles and sauerkraut I made this summer. But some bacteria are pathogenic nightmares that have swarmed over the planet and caused untold misery and billions of deaths. For most of human history it has been so – the bugs were winning. Then a bright period dawned in the early 20th century – the Era of Antibiotics. At last we were delivered from the threat of pestilence, never more to suffer from plague and disease like our unfortunate ancestors. Infections were miraculously cured with a simple injection or pill, childhood diseases were no longer reaping their tragic harvest, and soldiers on the battlefield were surviving wounds that would have festered and led to a slow, painful death.

Now it seems like this bright spot of relief from bacterial disease might be drawing to an end. Resistant strains of bacteria are in the news these days, and the rise of superbugs seems inevitable. But is it? Have we run out of tools to fight back? Not quite yet as it turns out. But there’s a lot of work to do to make sure we win this battle.

Continue reading “How Biohackers Are Fighting A Two-front War On Antibiotic Resistance”

How To Upgrade A Chinese CNC Machine

Looking to add a small CNC machine to your garage or hackerspace’s arsenal of tools? Like any tools — China has you covered for the cheap options — but the question is, is it worth it? Typically it depends on the tool, but when you can upgrade your 3040 CNC router to use USB instead of a parallel port with the TinyG motion controller… most definitely!

The 3040 or 3020 CNC router is a popular Chinese machine used by many hobbyists — and for good reason. A rigid all-aluminum frame, decent stepper motors and pretty good resolution? It’s not a bad deal for around $1000USD. We’ve covered it many times before. Problem is, the electronics are a bit out-dated. Particularly in the fact that it uses Mach3 with a parallel port… Come on, who has a parallel port these days?

[John Lauer] set out to fix this. The TinyG is a motor controller we’ve covered a few times before as well — it was just waiting to be fitted into a 3040 CNC in order to run a better control system, like ChiliPeppr!

Continue reading “How To Upgrade A Chinese CNC Machine”

Pulse Density Modulation

[esot.eric] was trying to drive a motor and naturally thought of using pulse width modulation (PWM) to control the motor speed. However, he found that even with a large capacitor, his underpowered power supply would droop before the PWM cycles were complete. So instead of PWM he decided to experiment with pulse density modulation.

The idea is to use smaller pulses over a longer period of time and make the average power equal to the percentage motor speed desired. With a PWM system, for example, if the time period is T, a 50% PWM drive would have the  drive high for T/2 and low for the other half of the cycle. With pulse density, each pulse might be T/10 (as an example) and then the output would be on for 1/10, off for 1/10, on for 1/10 and so on, until by time T you’d still get to 50%. The advantage is the output capacitor gets a kick more often and has less opportunity to droop.

Continue reading “Pulse Density Modulation”

Hackaday Prize Semifinalist: Playing With PIDs

PID control loops are everywhere, found in flight controllers for drones and the temperature control code for 3D printers. How do you teach PID control loops? [Tim] has a great demonstration for this, and it’s also a semifinalist for the Hackaday Prize.

[Tim]’s Sab3t is an educational tool designed to illustrate how PID control loops work. It’s a robotic table on which a large ball bearing sits perfectly balanced. On this table is a resistive touch screen from a display providing feedback for the location of the ball bearing. By adjusting PID values, the ball bearing either sits stationary on the table or flails wildly around, depending on the values in the PID algorithm being used.

As a teaching tool, it’s great; with a python script displaying a log of the PID values and the position of the ball on the plate, anyone can easily visualize how oscillations happen, what a well-tuned control loop looks like, and have some fun moving the ball bearing around to different locations.

The 2015 Hackaday Prize is sponsored by:

Continue reading “Hackaday Prize Semifinalist: Playing With PIDs”

Simple USB Power Meter

The USB interface is being increasingly used as a power supply and charging port for all kinds of devices, besides data transfer. A meter to measure the electrical parameters of devices connected to a USB socket or charger would be handy on any hacker workbench. The folks at [electro-labs] designed this simple USB power meter which does just that.

The device measures voltage and current and displays them, along with the calculated power, on the small 0.5″ OLED display. The circuit is built around an ATmega328. To keep the board size small, and reduce component count, the microcontroller is run off its internal 8MHz clock. A low-resistance shunt provides current sensing which is amplified by the LT6106 a high side current sense amplifier before being fed to the 10 bit analog port of the ATmega. A MCP1525 precision voltage reference provides 2.5V to the Analog reference pin of the microcontroller, resulting in a 2.44mV resolution. Voltage measurement is via a resistive divider that has a range of up to 6V. An Arduino sketch reads voltage and current data on the analog ports and displays measurements on the display. The measured data is averaged to filter out noise.

The OLED display has a SPI interface and requires the u8glib library. The project uses all SMD parts, but is fairly easy to assemble by hand and could be a nice starter project if you want to wet your feet on surface mount assembly techniques. It’s designed using SolaPCB EDA software, and the source files for schematic and board layout are available as a ZIP archive. Download the BoM and Arduino code and you have everything needed to build this nifty device.

Thanks to [Abdulgafur] for sending in this tip. And if you are looking for a more comprehensive solution, check the awesome Friedcircuits USB Tester which we reviewed earlier and is available in the Hackaday Store.

Understanding Surface Mount

Do you know what a MELF is (and, yes, it is safe for work to Google it)? What’s the difference between a QFP, and LCC, and a PLCC package? Do you need a 0603 resistor or a 1206 resistor?

If you are an old hand at surface mount devices (SMDs) you probably know the answers to most of these questions. But if you’ve done most of your work with through hole, it is a confusing mess of acronyms and numbers. Sure, you can Google and find out that at 0603 resistor is .06 inches by .03 inches. [TopLine] has a great booklet that pulls many common definitions in one place available for download that can help you make sense of different SMD nomenclature.

Continue reading “Understanding Surface Mount”