Posts with «arduino» label

Automated Sentry Turret For Your Secret Lab

There are few things as frustrating when you’re trying to get some serious hacking done than intruders repeatedly showing up without permission. [All Parts Combined] has the solution for you, with a Kinect-based robotic sentry turret to keep them at bay.

The system consists of a Microsoft Kinect V2 connected to a PC, which runs an app to do all the processing, and outputs the targeting information to an Arduino over serial. The Arduino controls a simple 2-axis servo mount with an electric airsoft gun zip-tied to it. The trigger switch is replaced with a relay, also connected to the Arduino.

The Kinect V2 comes with SDKs that really simplify tracking human movement, and outputs the data in an easy-to-use format. [All Parts Combined] used the SDK in Unity, which allows him to choose which body parts to track. He added scripts that detect a few basic gestures, issues voice commands, and generates the serial commands for the Arduino. The servo angles are calculated with simple geometry, using XY coordinates of the target received from the SDK, and the known distance between the Kinect and turret. When an intruder enters the Kinect’s field of view it immediately starts aiming at the intruder’s heart, issues a “Hands Up!” command, and tells the intruder to leave. If the intruder doesn’t comply, it starts an audible countdown before firing. [All Parts Combined] also added a secret disarming gesture (double hand pistols), which turns the turret into an apologetic comrade. All it needs is a Portal-inspired enclosure.

It’s a fun project that illustrates how the Kinect can make complex computer vision tasks relatively simple. Unfortunately the V2 is no longer in production, having been replaced by the more expensive, developer focused Azure Kinect. We’ve covered several Kinect-based projects, including a 3D room scanner and a robotic basketball hoop.

Hack a Day 07 Jun 03:01

[Emily]’s Eerie Educational Electric Eyeball Entertains

Like many of us, [Emily’s Electric Oddities] has had a lot of time for projects over the past year or so, including one that had been kicking around since late 2018. It all started at the Hackaday Superconference, when [Emily] encountered the Adafruit Hallowing board in the swag bag. Since that time, [Emily] has wanted to display the example code eyeball movement on a CRT, but didn’t really know how to go about it. Spoiler alert: it works now.

See? It’s educational.

Eventually, [Emily] learned about the TV out library for Arduino and got everything working properly — the eyeball would move around with the joystick, blink when the button is pressed, and the pupil would respond visually to changes in ambient light. The only problem was that the animation moved at a lousy four frames per second. Well, until she got Hackaday’s own [Roger Cheng] involved.

[Roger] was able to streamline the code to align with [Emily]’s dreams, and then it was on to our favorite part of this build — the cabinet design. Since the TV out library is limited to black and white output without shades of gray, Emily took design cues from the late 70s/early 80s, particularly the yellow and wood of the classic PONG cabinet. We love it!

Is Your Pet Eye the worst video game ever, as [Emily] proclaims it to be? Not a chance, and we’re pretty sure that the title still rests with Desert Bus, anyway. Even though the game only lasts until the eye gets tired and goes to sleep, it’s way more fun than Your Pet Rock. Don’t miss the infomercial/explanation/demonstration video after the break. If one video is just not enough, learn more about [Emily’s] philosophy of building weird projects from the Supercon talk she presented. It’s also worth mentioning that this one fits right into the Reinvented Retro contest.

Why are eyeballs so compelling? We can’t say for sure, but boy, this eyeball web cam sure is disconcerting.

Thanks for the tip, [Jake_of_All_Trades]!

Hack a Day 31 May 21:01

Robot Arm Adds Freedom to 3D Printer

3D printers are an excellent tool to have on hand, largely because they can print other tools and parts rapidly without needing to have them machined or custom-ordered. 3D printers have dropped in price as well, so it’s possible to have a fairly capable machine in your own home for only a few hundred dollars. With that being said, there are some limitations to their function but some of them can be mitigated by placing the printer head on a robot arm rather than on a traditional fixed frame.

The experimental 3D printer at the University of Nottingham adds a six-axis robotic arm to their printer head, which allows for a few interesting enhancements. Since the printer head can print in any direction, it allows material to be laid down in ways which enhance the strength of the material by ensuring the printed surface is always correctly positioned with respect to new material from the printer head. Compared to traditional 3D printers which can only print on a single plane, this method also allows for carbon fiber-reinforced prints since the printer head can follow non-planar paths.

Of course, the control of this printer is much more complicated than a traditional three-axis printer, but it is still within the realm of possibility with readily-available robotics and microcontrollers. And this is a hot topic right now: we’ve seen five-axis 3D printers, four-axis 3D printers, and even some clever slicer hacks that do much the same thing. Things are finally heating up in non-planar 3D printing!

Thanks to [Feinfinger] for the tip!

Ground Effect Drone Flies Autonomously

There are a number of famous (yet fictional) sea monsters in the lakes and oceans around the world, but in the Caspian Sea one turned out to be real. This is where the first vehicles specifically built to take advantage of the ground effect were built by the Soviet Union, and one of the first was known as the Caspian Sea Monster due to the mystery surrounding its discovery. While these unique airplane/boat hybrids were eventually abandoned after several were built for military use, the style of aircraft still has some niche uses and can even be used as a platform for autonomous drones.

This build from [Think Flight] started off as a simple foam model of just such a ground effect vehicle (or “ekranoplan”) in his driveway. With a few test flights the model was refined enough to attach a small propeller and battery. The location of the propeller changed from rear-mounted to front-mounted and then back to rear-mounted for the final version, with each configuration having different advantages and disadvantages. The final model includes an Arudino running an autopilot program called Ardupilot, and with an air speed sensor installed the drone is able to maintain flight in the ground effect and autonomously navigate pre-programmed waypoints around a lake at high speed.

For a Cold War technology that’s been largely abandoned by militaries in favor of other modes of transportation due to its limited use case and extremely narrow flight tolerances, ground effect vehicles are relatively popular as remote controlled vehicles. This RC ekranoplan used the same Ardupilot software but paired with a LIDAR system instead of GPS to navigate its way around its environment.

Thanks to [TTN] for the tip!

Send Old-Fashioned Pager Messages with New-Fashioned Hardware

In a world of always-connected devices and 24/7 access to email and various social media and messaging platforms, it’s sometimes a good idea to take a step away from the hustle and bustle for peace of mind. But not too big of a step. After all, we sometimes need some limited contact with other humans, so that’s what [EverestX] set out to do with his modern, pocket-sized communication device based on pager technology from days of yore.

The device uses the POCSAG communications protocol, a current standard for pager communications that allows for an SMS-like experience for those still who still need (or want) to use pagers. [EverestX] was able to adapt some preexisting code and port it to an Atmel 32u4 microcontroller. With a custom PCB, small battery, an antenna, and some incredibly refined soldering skills, he was able to put together this build with an incredibly small footprint, slightly larger than a bottle cap.

Once added to a custom case, [EverestX] has an excellent platform for sending pager messages to all of his friends and can avoid any dreaded voice conversations. Pager hacks have been a favorite around these parts for years, and are still a viable option for modern communications needs despite also being a nostalgic relic of decades past. As an added bonus, the 32u4 microcontroller has some interesting non-pager features that you might want to check out as well.

Thanks to [ch0l0man] for the tip!

Hack a Day 18 May 21:00

Making Minty Fresh Music With Markov Chains: The After Eight Step Sequencer

Step sequencers are fantastic instruments, but they can be a little, well, repetitive. At it’s core, the step sequencer is a pretty simple device: it loops through a series of notes or phrases that are, well, sequentially ordered into steps. The operator can change the steps while the sequencer is looping, but it generally has a repetitive feel, as the musician isn’t likely to erase all of the steps and enter in an entirely new set between phrases.

Enter our old friend machine learning. If we introduce a certain variability on each step of the loop, the instrument can help the musician out a bit here, making the final product a bit more interesting. Such an instrument is exactly what [Charis Cat] set out to make when she created the After Eight Step Sequencer.

The After Eight is an eight-step sequencer that allows the artist to set each note with a series of potentiometers (which are, of course, housed in an After Eight mint tin). The potentiometers are read by an Arduino, which passes MIDI information to a computer running the popular music-oriented visual programming language Max MSP. The software uses a series of Markov Chains to augment the musician’s inputted series of notes, effectively working with the artist to create music. The result is a fantastic piece of music that’s different every time it’s performed. Make sure to check out the video at the end for a fantastic overview of the project (and to hear the After Eight in action, of course)!

[Charis Cat]’s wonderful creation reminds us of some the work [Sara Adkins] has done, blending human performance with complex algorithms. It’s exactly the kind of thing we love to see at Hackaday- the fusion of a musician’s artistic intent with the stochastic unpredictability of a machine learning system to produce something unique.

Thanks to [Chris] for the tip!

Rodriguez — IV Curve Tracer on the Cheap

In response to an online discussion on the Electrical Engineering Stack Exchange, [Joseph Eoff] decided to prove his point by slapping together a bare-bones IV curve tracer using an Arduino Nano and a handful of passives. But he continued to tinker with the circuit, seeing just how much improvement was possible out of this simple setup. He squeezes a bit of extra resolution out of the PWM DAC circuit by using the Timer1 library to obtain 1024 instead of 256 steps. For reading voltages, he implements oversampling (and in some cases oversampling again) to eke out a few extra bits of resolution from the 10-bit ADC of the Nano. The whole thing is controlled by a Python / Qt script to generate the desired plots.

While it works and gives him the IV curves, this simplicity comes at a price. It’s slow — [Joseph] reports that it takes several minutes to trace out five different values of base current on a transistor. It was this lack of speed that inspired him to name the project after cartoon character Speedy Gonzales’s cousin,  Slowpoke Rodriguez, AKA “the slowest mouse in all of Mexico”. In addition to being painstakingly slow, the tracer is limited to 5 volts and currents under 5 milliamps.

[Joseph] documents the whole design and build process over on his blog, and has made the source code available on GitHub should you want to try this yourself. We covered another interesting IV curve tracer build on cardboard ten years ago, but that one is much bigger than the Rodriguez.

Automated Watering Machine Has What Plants Crave: Fertilizer

We’ve seen countless automated plant care systems over the years, but for some reason they almost never involve the secret sauce of gardening — fertilizer. But [xythobuz] knows what’s up. When they moved into their new flat by themselves, it was time to spread out and start growing some plants on the balcony. Before long, the garden was big enough to warrant an automated system for watering and fertilizing.

This clever DIY system is based around a 5L gravity-fed water tank with solenoid control and three [jugs] of liquid fertilizer that is added to the water via peristaltic pump. Don’t worry, the water tank has float switches, and [xythobuz] is there to switch it off manually every time so it doesn’t flood the flat.

On the UI side, an Arduino Nano clone is running the show, providing the LCD output and handling the keypad input. The machine itself is controlled with an ESP32 and a pair of four-channel relay boards that control the inlet valve, the four outlet valves, and the three peristaltic pumps that squirt out the fertilizer. The ESP also serves up a web interface that mimics the control panel and adds in the debug logs. These two boards communicate using I²C over DB-9, because that’s probably what [xythobuz] had lying around. Check out the demo video after the break, and then go check on your own plants. They miss you!

Don’t want to buy just any old peristaltic pumps? Maybe you could print your own.

Go Ape with a Banana Macropad

The super fun thing about macro pads is that they’re inherently ultra-personalized, so why not have fun with them? This appealing little keeb may have been a joke originally, but [dapperrogue] makes a valid point among a bunch of banana-related puns on the project page — the shape makes it quite the ergonomic little input device.

Inside this open-source banana is that perennial favorite for macro pads, the Arduino Pro Micro, and eight switches that are wired up directly to input pins. We’re not sure what flavor of Cherry those switches are, hopefully brown or green, but we suddenly wish Cherry made yellow switches. If you want to build your own, the STLs and code are available, and we know for a fact that other switch purveyors do in fact make yellow-stemmed switches.

Contrary to what the BOM says, we believe the sticker is mandatory because it just makes the build — we imagine there would be fewer double takes without it. Hopefully this fosters future fun keyboard builds from the community, and we can’t wait to sink our teeth into the split version!

There are a bunch of ways to make a macropad, including printing everything but the microcontroller.

Via r/mk and KBD

Realistic Mission Control Box is a Blast for All Ages

A lot of electronic busy boxes that are built for children are simply that — a mess of meaningless knobs and switches that don’t do much beyond actuating back and forth (which, let’s be honest, is still pretty fun to do). But this Mission Control Center by [gcall1979] knocks them all out of orbit. The simulation runs through a complete mission, including a 10-minute countdown with pre-flight system checks, 8.5 minutes of powered flight to get out of the atmosphere that includes another four tasks, and 90 minutes to orbit the Earth while passing through nine tracking stations across the world map.

That’s a lot time to keep anyone’s attention, but fortunately [gcall1979] included a simulation speed knob that can make everything go up to 15 times faster than real-time. This knob can be twiddled at any time, in case you want to savor the countdown but get into space faster, or you don’t have 90 minutes to watch the world map light up.

The main brain of this well-built box is an Arduino Mega, which controls everything but the launch systems’ mainframe computer — this is represented by bank of active LEDs that blink along with the voice in the sound clips and runs on an Arduino Uno and a couple of shift registers. To keep things relatively simple, [gcall1979] used an Adafruit sound board for the clips.

We love everything about this build, especially the attention to detail — the more important pre-flight tasks are given covered toggle switches, and there’s a Shuttle diagram that lights up as each of these are completed. And what Shuttle launch simulator would be complete without mushroom buttons for launch and abort? Grab your victory cigar and check out the demo video after the break.

Is your child too young to be launching the Shuttle? Here’s an equally cool busy box with toddler brains in mind.