Posts | Comments

Planet Arduino

Archive for the ‘games’ Category

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]!

The trick to a fun escape room is layers. For [doktorinjh]’s Spacecase, you start with an enigmatic aluminum briefcase and a NASA drawstring backpack. A gamemaster reads the intro speech to set the mood, and you’re ready to start your escape from the planet. The first layer is the backpack with puzzles you need to solve to get into the briefcase. In there, you discover a hidden compartment and enough sci-fi references to put goofy smiles on our faces. We love to see tools reused as they are in one early puzzle, you use a UV LED to reveal a hidden message, but that light also illuminates puzzle clues later.

All the tech in Spacecase makes it a wonder of mixed media. The physical layer has laser engraved wood featuring the font from the 1975 NASA logo, buttons, knobs, LEDs, toggle switches, and a servo. Beneath the visible faceplate is an RGB sensor, audio player, speaker, and at the center is an Arduino MEGA. We’d love to get our hands on Spacecase for a game, and we’re inspired to pull out all the stops and build games with our personal touches. Maybe something with a mousetrap.

This isn’t the first escape room hardware we’ve seen and [doktorinjh] similarly made a bomb diffusing game.

Farkle is a classic dice game that only requires 6 dice and a way to write down scores based on the numbers rolled. Even so, this type of game isn’t inherently portable — it would be fairly difficult to play on a road trip, for instance. [Sunyecz22] decided that Farkle would make an excellent electronic game and got to work designing his first PCB.

This little game has everything you could want from a splash screen introduction to a handy scoring guide on the silkscreen. After choosing the number of players, the first player rolls using the momentary button and the electronic dice light up to indicate what was rolled. As long as the player rolled at least one scoring die, they can take the points by selecting the appropriate die/dice with the capsense pads, and either pass or keep going. The current player’s score is shown on the 7-segment, and the totals for each player are on the OLED screen at the bottom.

The brains of the operation is an Arduino Pro Mini. It controls two MAX7219s that drive the 42 LEDs plus the 7-segment display. A game like this is all in the code, and lucky for us, [Sunyecz22] made it available. We love how gorgeous the glossy 3D printed enclosure looks — between the glossy finish and the curved back, it looks very comfortable to hold. In the future, [Sunyecz22] plans to make a one player versus the computer mode. Check out the demo and walk-through video after the break.

The capsense modules are a great touch, but some people want a little more tactility in their handheld games. We say bring on the toggle switches.

Wouldn’t it be nice if beer pong could somehow get easier the more you drink? You know, so you can drink more? [Ty Palowski] has made it so with automated, mind-controlled beer pong.

[Ty] started by making a beer pong table that moves the cups back and forth at both ends. An Arduino Nano controls a stepper that controls a slider, and the cups move with the slider through the magic of magnets. The mind control part came cheaper than you might think. Back in 2009, Mattel released a game called Mind Flex that involves an EEG headset and using brain waves to guide a foam ball on a stream of air through a little obstacle course. These headsets are available for about $12 on ebay, or at least they were before this post went up.

[Ty] cracked open the headset added an HC-06 Bluetooth module to talk to the Arduino. It’s using a program called Brainwave OSC to get the raw data from the headset and break it into levels of concentration and relaxation. The Arduino program monitors the attention levels, and when a certain threshold of focus is reached, it moves the cups back and forth at a predetermined speed ranging from 1 to an impossible-looking 10. Check out the two videos after the break. The first one covers the making of the the automatic beer pong part, and the second is where [Ty] adds mind control.

We’ve seen a different headset — the hacker-friendly NeuroSky Mindwave — pop up a few times. Here’s one that’s been hacked to induce lucid dreaming.

Via r/duino

Wouldn’t it be nice if beer pong could somehow get easier the more you drink? You know, so you can drink more? [Ty Palowski] has made it so with automated, mind-controlled beer pong.

[Ty] started by making a beer pong table that moves the cups back and forth at both ends. An Arduino Nano controls a stepper that controls a slider, and the cups move with the slider through the magic of magnets. The mind control part came cheaper than you might think. Back in 2009, Mattel released a game called Mind Flex that involves an EEG headset and using brain waves to guide a foam ball on a stream of air through a little obstacle course. These headsets are available for about $12 on ebay, or at least they were before this post went up.

[Ty] cracked open the headset added an HC-06 Bluetooth module to talk to the Arduino. It’s using a program called Brainwave OSC to get the raw data from the headset and break it into levels of concentration and relaxation. The Arduino program monitors the attention levels, and when a certain threshold of focus is reached, it moves the cups back and forth at a predetermined speed ranging from 1 to an impossible-looking 10. Check out the two videos after the break. The first one covers the making of the the automatic beer pong part, and the second is where [Ty] adds mind control.

We’ve seen a different headset — the hacker-friendly NeuroSky Mindwave — pop up a few times. Here’s one that’s been hacked to induce lucid dreaming.

Via r/duino

For some reason, when slot machines went digital, they lost their best feature — the handle. Who wants to push a button on a slot machine, anyway? Might as well just play video poker. [John Bradnam] seems to agree, and has built an open-source three-color matrix slot machine complete with handle.

In this case, you’ll be losing all of your nickels to an Arduino Pro Mini. The handle is an upgrade to an earlier slot machine project that uses three 8×8 matrices and a custom driver board. When the spring-loaded handle is pulled, it strikes a micro switch to spins the reels and then snaps back into place. Between each pull, the current score is displayed across the matrix. There’s even a piezo buzzer for victory squawks. We only wish the button under the handle were of the clickier variety, just for the feels. Check out the short demo video after the break.

If you’re not a gambler, you could always turn your slot machine into a clock.

We suppose it’s a bit early to call it just yet, but we definitely have a solid contender for Father of the Year. [DIY_Maxwell] made a light-up hockey game for his young son that looks like fun for all ages. Whenever the puck is hit with the accompanying DIY hockey stick (or anything else), it lights up and produces different sounds based on its acceleration.

Inside the printed puck is an Arduino Nano running an MPU6050 accelerometer, a 12-NeoPixel ring, and a piezo buzzer. [DIY_Maxell] reused a power bank charging circuit to charge up the small LiPo battery.

The original circuit used a pair of coin cells, but the Arduino was randomly freezing up, probably because of the LEDs’ current draw. Be sure to check out the video after the break, which begins with a little stop motion and features a solder stand in the shape of a 3D printer.

Got a house full of carpet or breakables? You could always build an air hockey table instead.

When [ccooper] told his parents he was gonna start up his electronics habit again, the last thing he expected was to save his parents’ marriage in the process. But as soon as he dropped this news, they made a special request: build us something to replace the multi-purpose manual cribbage board. It’s too ambiguous and starts too many arguments.

Cribbage is a card game that involves scoring based on hands. Traditionally, the score is kept with pegs on a wooden board with two or three sets of 60 holes. To build a digital cribbage board, [ccooper] decided to represent the positions on a field made from chained-together RGBW matrices.

These four matrices are run by an Arduino Nano Every and will display one of three scoring schemes that the parents usually play. A set of eight AA batteries ensures that Mum and Dad can play out in bright daylight and still see the LEDs. You can see how the brightness rivals the sun in the demo after the break. The code and Gerber files for the custom board are there if you want to make one for yourself, or know of another marriage that needs saving.

Every game deserves tidy record-keeping. If you’re more the RPG type, check out this amazing stat tracker made of stacked-up FR4 boards.

Via adafruit

We have seen quite a few DIY joystick designs that use Hall effect sensors, but [Akaki]’s controller designs (YouTube video, embedded below) really make the most of 3D printing to avoid the need for any other type of fabrication. He’s been busy using them to enhance his Microsoft Flight Simulator 2020 experience, and shares not just his joystick design, but makes it a three-pack with designs for throttle and pedals as well.

Hall effect sensors output a voltage that varies in proportion to the presence of a magnetic field, which is typically provided by a nearby magnet. By mounting sensors and magnets in a way that varies the distance between them depending on how a control is moved, position can be sensed and communicated to a host computer. In [akaki]’s case, that communication is done with an Arduino Pro Micro (with ATmega32U4) whose built-in USB support allows it to be configured and recognized as a USB input device. The rest is just tweaking the physical layouts and getting spring or elastic tension right. You can see it all work in the video below.

Hall effect sensors have featured in DIY joystick builds, but for something as delightful as it is different, don’t miss this fantastic high-speed magnetic imager based on them.

Bowling is great and all, but the unpredictability of that little ball jump in Skee-Ball is so much more exciting. You can play it straight, or spend a bunch of time perfecting the 100-point shot. And unlike bowling, there’s nothing to reset, because gravity gives you the balls back.

In one of [gcall1979]’s earlier Skee-Ball machines, gravity assisted the scoring mechanism, too: each ball rolls back to the player and lands in a lane labeled with the corresponding score, which is an interesting engineering challenge in its own right. He decided to build automatic scoring into his newest Skee-Ball machine.

At the bottom of each cylinder is an arcade machine coin door switch with a long wire actuator. These had to be mounted so they’re close enough to the hole, but out of the way of the balls.

Each switch is wired up to an Arduino Mega along with four large 7-segments for the score, and a giant 7-segment to show the number of balls played. Whenever the game is reset, a servo drops a door to release the balls, just like a commercial machine.

The arcade switches work pretty well, especially once he bent the wire into hook shape to cover more area. But they do fail once in a while, maybe because the targets are full-size, but the balls are half regulation size. For the next one, [gcall1979] is planning to use IR break-beam targets which ought to work with any size ball. If you prefer bowling, you won’t strike out with break-beam targets there, either.



  • Newsletter

    Sign up for the PlanetArduino Newsletter, which delivers the most popular articles via e-mail to your inbox every week. Just fill in the information below and submit.

  • Like Us on Facebook