Troy New York’s Tech Valley Center of Gravity is following up their January IoT Hackathon with another installment. The April 16-17 event promises to be a doozy, and anyone close to the area with even a passing interest in gaming and AR/VR should really make an effort to be there.
Not content to just be a caffeine-fueled creative burst, TVCoG is raising the bar in a couple ways. First, they’re teaming up with some corporate sponsors with a strong presence in the VR and AR fields. Daydream.io, a new company based in the same building as the CoG, is contributing a bunch of its Daydream.VR smartphone headsets to hackathon attendees, as well as mentors to get your project up and running. Other sponsors include 1st Playable Productions and Vicarious Visions, game studios both located in the Troy area. And to draw in the hardcore game programmers, a concurrent Ludum Dare game jam will be run by the Tech Valley Game Space, with interaction and collaboration between the AR/VR hackers and the programmers encouraged. Teams will compete for $1000 in prizes and other giveaways.
This sounds like it’s going to be an amazing chance to hack, to collaborate, and to make connections in the growing AR/VR field. And did we mention the food? There was a ton of it last time, so much they were begging us to take it home on Sunday night. Go, hack, create, mingle, and eat. TVCoG knows how to hackathon, and you won’t be disappointed.
Thanks to [Duncan Crary] for the heads up on this.
There’s no holy war holier than establishing whether PC games are superior to console games (they are). But even so, there’s no denying that there are some good console titles out there. What if you’d still like to play them using a mouse and keyboard? If you’re [Agent86], you’d build up the most ridiculous chain of fun electronics to get the job done.
Now there is an overpriced off-the-shelf solution for this problem, and a pre-existing open-source project that’ll get the same job done for only a few bucks in parts. But there’s nothing like the fun in solving a problem your own way, with your own tangle of wires, darn it all! The details of the build span four (4!) pages in [Agent86]’s blog, so settle down with a warm cup of coffee.
Here’s the summary: an Xbox 360 controller is taken apart and turned into an Xbox controller. The buttons and joysticks are put under computer control via a Teensy microcontroller. GPIOs press the controller’s buttons, and digipots replace the analog sticks. Software on the Teensy drives the digipots and presses the buttons, interpreting a custom protocol sent over USB from the computer, which also gets some custom software to send the signals.
So if you’re keeping score: a button press on a keyboard is converted to USB, sent to a PC, converted to a custom serial protocol, sent to a Teensy which emulates a human for a controller that then coverts the signals back into the Xbox’s USB protocol. Pshwew!
Along the way, there’s learning at every stage, which is really the point of an exercise like this. And [Agent86] says that it mostly works, with some glitches in the mouse-to-joystick mapping. But if you’re interested in any part of this crazy chain, you’ve now got a model for each of them.
Let’s face it, we all love arcades, but not all of us can fit a full size stand-up in our homes. [Bentika] knew the solution was a bartop style cabinet, but it had to be designed and built to his specifications. You see, he’s a bit of an aspect ratio nerd. Only a proper 4:3 screen would do for emulating games designed for just such a display. Modern 4:3 displays are hard to come by, unless of course you have an iPad handy. The 1024 x 768 screens used on the early model iPads are perfect for the task.
Driving these screens used to be a chore, but thanks to hacker reverse engineering and overseas manufacturing, these days, controllers are only a few clicks away. [Bentika] ordered a controller for the iPad 1 screen from eBay. What he got was a controller that only worked with the iPad 2 screen. Thankfully he had a pile of old iPads to play with, so it wasn’t an issue.
[Bentika] designed his cabinet using AutoDesk 123D based upon a basic outline provided by [Joshendy]. His final cut patters were created with Adobe Illustrator. He was able to get the entire cabinet laser cut for around $160, including materials. Cabinet assembly was easy, thanks to plenty of square gussets used to align the various pieces.
The controller for this arcade is of course a Raspberry Pi 2 running RetroPie. [Bentika] used a control block to interface the joystick and buttons to the Pi itself. RetroPie lends itself to “keyboardless” operation, he didn’t have to bring any of the Pi’s USB ports outside the case.
Video arcades may be a thing of the past, but they’re still alive, well and were ready to play at this year’s World Maker Faire. The offerings weren’t old favorites, all were brand new games many being shown for the first time like the long-awaited VEC9. The Hall of Science building was filled with cabinets and no quarters were necessary, all were free-play.
Death By Audio Arcade was there in force with games like Particle Mace and Powerboat Italia ’88. Our personal favorite was Nothing Good Can Come of This. [Michael P. Consoli] devised a simple game: Two players in an empty room. A bullet drops from a hole in the ceiling, followed by a gun shortly thereafter. What happens next is up to the players. The simple graphics and gameplay give this title its charm. [Michael] was showing off a new stand-up cabinet for the game this year. He built the entire thing himself, working until the wee hours before load-in at Maker Faire.
[Batsly Adams], [Todd Bailey], and [Mike Dooley] teamed up to create what may be the first new vector arcade in decades. VEC9 has been teased for over 2 years. They’ve finally wrapped this game up and showed it off at the faire. VEC9 started with an old
Asteroids vector monitor found by [Batsly].
[lactobacillusprime] had a non-working Commodore C16 and too many Raspberry Pi computers, so he decided to bring the C16 back to life by emulating it on the Pi. At the heart of the project is the Pi, along with a small board that converts the old style Commodore keyboards (and joysticks) to a USB port.
Once you have the keyboard as a USB port, the rest of the project is more or less mechanics and software. [lactobacillusprime] did a nice job of getting everything in the new case, along with all the I/O wires routed through the existing ports. For software, Emulation Station does the job of launching the Commodore emulation on the Pi.
Of course, there’s no reason to limit yourself to just the Commodore emulator. Emulation Station along with the right back end emulators will allow this machine to play games that no real Commodore C16 could.
Of course, we were happiest to see him boot up Commodore 64 BASIC. Perhaps we should complete all those half finished C64 BASIC projects we started back in the 1980’s. In general, we hate to see old computers gutted instead of repaired, but at least this one will continue running its software. If you are upset about seeing a machine gutted, you can always switch over to our previous coverage of putting Commodore guts in a new box.
Web sites have figured out that “gamifying” things increases participation. For example, you’ve probably boosted your postings on a forum just to get a senior contributor badge (that isn’t even really a badge, but a picture of one). Now [Yash Soni] has brought the same idea to physical therapy.
[Yash]’s father had to go through boring physical therapy to treat a slipped disk, and it prompted him into developing KinectoTherapy which aims to make therapy more like a video game. They claim it can be used to help many types of patients ranging from stroke victims to those with cerebral palsy.
Patients can see their onscreen avatar duplicate their motions and can provide audio and visual feedback when the player makes a move correctly or incorrectly. Statistical data is also available to the patient’s health care professionals.
I usually see retro-gaming projects using tiny screens with a fair number of pixels (64×64) but what I really like is the look of making every pixel count. With this in mind I built 1-Pixel Pac-Man, the classic coin-op experience but with characters that consist of just one pixel. Playing a throw-back like this wouldn’t be the same without some vintage controls so I picked up an Atari joystick, patched it into a microcontroller, and started coding. Check it out:
Smartmatrix Bundle
32×32 RGB panel with acrylic diffuser
Back of the Smartmatrix
This piece of hardware made the project build really easy: the Smartmatrix. [Louis Beaudioin] developed the Smartmatrix and it’s been in the Hackaday Store for a while now. The display module itself is a commodity item that is used in LED billboards. There are shrouded headers on the back of the panels, to the left and right sides, which allow them to be daisy chained. The Smartmatrix PCB plugs into one of these shields, provides a soldering footprint for the Teensy 3.1 which drives the display, and gives you the wiring to connect screw terminals from the PCB to the power terminals on the module. Why the need for beefy power jumpers? At full white the thing can draw about 3.5A — don’t worry there’s a power supply included in the bundle.
Also integral to making this look good is the diffuser panel which is frosted acrylic. The Smartmatrix is designed to be housed in a shadowbox frame; it even includes a frame backer board with a cut-out for the Teensy 3.1 so it can be programmed without opening the thing up. I like looking at the guts so I’m leaving my free floating until I come up with an interesting way to mount everything as one unit.
Programming Pac-Man from the Ground Up
If you haven’t looked into it before, the ghost AI and gameplay details for Pac-Man are absolutely brilliant. [Toru Iwatani] did a masterful job with the original, and you should take a look at all of the analysis that has been done over the years. The best collection I could find was the Pac-Man Dossier and I based most of my code on the rules described there.
Basically the ghosts have two modes, chase and scatter. The modes set the enemy targets differently; to points at the four corners of the board in scatter, and to points relative to the player in chase. The relative part is key; only the red enemy actually chases you. Another one of them looks at the red enemy’s distance and angle, and targets the reflection of that vector. Really easy, really clever, and results in enemy behavior that’s believable. It isn’t just the enemy movement, little touches like a speed penalty (1/60 of a second) for each dot the player gobbles up means the enemies can catch up if you continuously eat, but you can escape by taking the path already-eaten.
Library, DMA, and Extra Hardware
Teensy 3.1
DB9 Connector for Joystick
Extras in the Bundle
Kickstarter remote and RTC Module
The hardware and software running the Smartmatrix made the display portions of the project really simple. First off, the Teensy 3.1 is fast, running at 96MHz in this case. Second, it has Direct Memory Access (DMA) which [Louis] used in the Smartmatrix library. This means that driving the display takes almost no CPU time at all, leaving the rest for your own use. This example of a game is under-utilizing this power… it’s totally capable of full-motion video and calculating amazing visualizations on the fly.
The PCB hosting the Teensy 3.1 breaks out several pins to one side. I’m not sure what I’ll add in the future so I actually used the extra surface-mount IO pins on the bottom of the Teensy to connect the Atari joystick (which is simply a set of switches). The are enough pads for two joysticks so I used pin sockets to interface the Teensy to the PCB so that I can get to it again later.
The kit also includes an IR receiver and remote, and also a microSD card to loading animations (there’s an SD socket on the PCB). The bundle in the Hackaday Store is a kit you solder yourself, but [Louis’] company, Pixelmatix, has a Kickstarter running for fully-assembled versions that come with a black remote and sound-visualization hardware.
Future Improvements
The game is fully working, but there are a few key things that I really want to add. The Teensy 3.1 has a single DAC pin available. I’m fairly certain the original coin-op game had mono audio. It should be possible to reproduce the sound quite accurately with this board. That would really make the project pop.
There are also a bunch of touch-ups that need to happen. I’d like to add an animation when the player is eaten by an enemy, and a countdown before the level restarts. The score, shown in binary on the right column, should be scrolled out in decimal when the game ends, and what’s a coin-op recreation without a high-score screen?