A Relay-Based Pseudorandom Number Generator

There are a great variety of ways to build a random number generator, and similarly many ways to generate numbers that appear random, but in a pure mathematical sense generally aren’t. [Daniel Valuch] built a Christmas decoration that does the latter, displaying the results on an attractive flashing ornament.

The build relies on a 16-bit linear feedback shift register, or LFSR. The LFSR generates a stream of numbers, with each number dependent on the previous state of the register. Thus, the numbers generated are pseudorandom, not truly random, and depend on the initial seed value of the system. [Daniel] built the shift register using relays, which create a lovely clacking sound as the register operates, and LEDs, which glow depending on the values in the register.

The result is a cute Christmas ornament that blinks in a deterministic fashion, and has a great old-school look due to the exposed copper of the PCB and the retro LED colors used. The project also serves as a great way to learn about shift registers and basic relay logic, though the latter is rarely used these days for serious purposes. We’ve covered the topic before, too. Video after the break.

Continue reading “A Relay-Based Pseudorandom Number Generator” →

Sims-Style Plumb Bob Broadcasts Your Mood

While there are a lot of objects from the Sims that we wish were real, we probably wish more than anything that everyone had a mood indicator hovering above their heads at all times. It would make working from home go a lot more smoothly, for instance. [8BitsAndAByte] made this Bluetooth-controlled plumb bob as part of their Sims Halloween costume, but we think it has real day-to-day value as this pandemic wears on, either as a mood ring or a portable free/busy indicator.

The hardware is about as simple as it gets — an Adafruit Feather nRF52 Bluefruit controls a pair of NeoPixel rings, one for each half of the translucent 3D-printed plumb bob. Power comes from a 500mAh battery, and all the electronics are situated inside of an attractive hat. Check out the build video after the break.

There’s more than one way to use color to convey information. This seven-segment temperature display does it with thermochromic film.

Continue reading “Sims-Style Plumb Bob Broadcasts Your Mood” →

Halloween Pumpkin Scares With An Evil Eye

These days, a classic Jack O’ Lantern just doesn’t cut the mustard. Kids are expecting to be scared by high-quality animatronics at a minimum. This haunting work by [Zero To Infinity] might just do the trick.

A real pumpkin is pressed into service in this build, with the usual threatening grin and candlelit interior. However, where it differs is in its single, animated eye. The eye itself is constructed of a pingpong ball, drawn upon with markers for a creepy bloodshot look. A pair of servos allow the eye to twitch and roll, under the command of an Arduino Nano. For further interactivity, an ultrasonic sensor is used to only trigger the pumpkin when it senses a person approaching.

It’s a fun holiday build that also serves as a great primer on how to work with servos and microcontrollers. We can imagine a more advanced setup using more sensors and pumpkins to train multiple eyes on the unsuspecting visitor. If that’s not scary enough, perhaps just make your pumpkins breathe fire instead. Video after the break.

Continue reading “Halloween Pumpkin Scares With An Evil Eye” →

Haunted TV Does Mirror Scares With Raspberry Pi

Hallowe’en may be over for another year, but that just means you’ve got more time to prepare your build for next time. [gocivici] has a fun twist on the classic mirror scare that might be just up your alley.

The build starts with an old black and white TV, hooked up to a Raspberry Pi 3. The Pi films the scene in front of the television through a camera secreted into the screen’s headphone jack, and displays it on screen. The camera feed is run through OpenCV, which runs face and eye detection algorithms to determine when a person is looking at the screen. Based on a basic timer script, when a viewer has looked long enough, a ghostly apparition is displayed, lurking behind the viewer. When the user looks over their shoulder, the apparition quickly disappears, as per the classical horror trope.

It’s a fun build that would make an excellent set piece for your next Hallowe’en party. For extra effect, be sure to secret it down a dark hallway with some IR LEDs illuminating the scene for the camera only. If you prefer something with a little more whimsy, consider these animated singing pumpkins instead. Video after the break.

Continue reading “Haunted TV Does Mirror Scares With Raspberry Pi” →

Computer Vision Maps Christmas Lights

There’s a small but dedicated group of folks out there who spend all year planning their Christmas decorations. These aren’t simple lawn ornaments or displays, either, but have evolved into complex lightning performances that require quite a bit of computer control. For some things, hooking up a relay to a microcontroller can get the job done, but [Andy] has turned to computer vision to solve some of the more time-consuming aspects of these displays.

Specifically, [Andy] has a long string of programmable RGB LED lights to wrap around a Christmas tree, but didn’t want to spend time manually mapping out each light’s location. So he used OpenCV to register the locations of the LEDs from three different camera angles, and then used a Python script to calculate their position in the 3D space. This means that he will easily be able to take the LEDs down at the end of the holidays and string them back up next year without having to do the tedious manual mapping ever again.

While [Andy] notes that he may have spent more time writing the software to map out the LEDs than manually doing it himself, but year-after-year it may save him a lot of time and effort, not to mention the benefits of a challenge like writing this software in the first place. If you want to get started on your own display this year, all you really need is some lights and a MIDI controller.

Raspberry Raven Pi Security Camera Does Double Duty

The worst thing about holiday decorations is that while you could leave them up all year, your neighbors probably won’t like you very much for it. Christmas lights on your house are one thing, but as far as Halloween decorations go, [MisterM]’s raven security camera is one of the few exceptions to this rule.

Nevermore will [MisterM] wonder who goes there. As soon as this raven lays its beady red LED eyes on whatever is lurking in the garden, it comes to life with a bit of head swiveling and some random sounds. The bird either goes CAW! or quotes Christopher Lee’s reading of Edgar Allen Poe’s “The Raven”.

Inside this bird’s chest cavity is a Raspberry Pi 2 and standard camera, a servo to swivel the head, and an audio amplifier and speaker. This bird is running MotionEye on top of the Raspi OS so it can run a script whenever it senses motion.

We like that [MisterM] was able to find right-sized bits of plastic to mount the servo in the neck and the horn to the head. It just goes to show that not everything needs a 3D printer, a CNC, or woodworking. Check out the scary demo after the break.

Want to scare the whole neighborhood? Check out the science behind good-looking house projections.

Continue reading “Raspberry Raven Pi Security Camera Does Double Duty” →

Animated Pumpkins Sing And Scare On Halloween

The animated video combined with the 3D-printed prop makes for an excellent effect.

Carving Jack O’ Lanterns out of pumpkins is a favorite Hallowe’en tradition for many, but relying on candles and knives is decidedly low-tech. [Lewis] of [DIY Machines] decided to whip up something a little more animated to scare the local trick-or-treaters instead.

The build consists of 3D printed pumpkins, lit from behind with a low-cost projector. Driven by a Raspberry Pi, the projector plays video files that project animated faces onto the pumpkins. The effect is great, giving the illusion of a real anthropomorphic Jack O’ Lantern sitting on your very porch. To control the system, a series of arcade buttons are hooked up to the Raspberry Pi allowing visitors to activate a song, a scare, or a story.

It’s a fun build that is a great way to add some interactivity to your Hallowe’en decorations. If you want to take your work up a notch, consider projecting on to your whole house. Video after the break.

Continue reading “Animated Pumpkins Sing And Scare On Halloween” →