Vista Normal

Hay nuevos artículos disponibles. Pincha para refrescar la página.
AnteayerHackaday

Spinning Magnets Do Your Dice Rolling for You

28 Junio 2024 at 08:00

Dice are about the simplest machines possible, and they’ve been used since before recorded history to generate random numbers. But no machine is so simple that a little needless complexity can’t make it better, as is the case with this mechanical spinning dice. Or die. Whatever.

Inspiration for the project came from [Attoparsec]’s long history with RPG and tabletop games, which depend on different kinds of dice to generate the randomness that keeps them going — that and the fortuitous find of a seven-segment flip-dot display, plus the need for something cool to show off at OpenSauce. The flip-dot is controlled by an array of neodymium magnets with the proper polarity to flip the segments to the desired number. The magnets are attached to an aluminum disk, with each array spread out far enough to prevent interference. [Attoparsec] also added a ring of magnets to act as detents that lock the disk into a specific digit after a spin.

The finished product ended up being satisfyingly clicky and suitably random, and made a good impression at OpenSauce. The video below documents the whole design and build process, and includes some design dead-ends that [Attoparsec] went down in pursuit of a multiple-digit display. We’d love to see him revisit some of these ideas, mechanically difficult though they may be. And while he’s at it, maybe he could spice up the rolls with a little radioactivity.

Portable, Full-Size Arcade Cabinets

27 Junio 2024 at 20:00

Believe it or not, there was a time when the only way for many of us to play video games was to grab a roll of quarters and head to the mall. Even though there’s a working computer or video game console in essentially every house now doesn’t mean we don’t look back with a certain nostalgia on those times, though. Some have turned to restoring vintage arcade cabinets and others build their own. This hackerspace got a unique request for a full-sized arcade cabinet that was also easily portable as well.

The original request was for a portable arcade cabinet, and the original designs were for a laptop-like tabletop arcade. But further back-and-forth made it clear they wanted full-size cabinets that just happened to also be portable. So with that criteria in mind the group started building the units. The updated design is modular, allowing the controls, monitor, and Raspberry Pi running the machines to be in self-contained units, with the cabinets in two parts that can quickly be assembled on-site. The base is separate and optional, with the top section capable of being assembled on the base or on something like a tabletop or bar, and the electronics section quickly drops in.

While the idea of a Pi-powered arcade cabinet is certainly nothing new, the quick build, prototyping, design, and final product that’s mobile and quickly assembled are all worth checking out. There is even more information on the build at the project’s GitHub page including Fusion 360 models. If you need your cabinets to be even more portable, this tabletop MAME cabinet is a great place to start.

Easy Retro 3D Look With Voxel Displacement Renderer

Por: Maya Posch
15 Junio 2024 at 05:00

Voxels are effectively like 3D pixels, and they form an integral part of what is commonly referred to as a ‘retro 3D’ look, with pixelated edges sharp enough to cut your retinas on. The problems with modeling a scene using voxels come in the form of creating the geometry and somehow making a physics engine work with voxels rather than conventional triangular (or quad) meshes.

The same scene in Blender (above) and in the voxel-based renderer (below). (Credit: Daniel Schroeder)
The same scene in Blender (above) and in the voxel-based renderer (below). (Credit: Daniel Schroeder)

The approach demonstrated by [Daniel Schroeder] comes in the form of a Voxel Displacement Renderer implemented in C++ and using the Vulkan API. Best part of it? It only requires standard meshes along with albedo and displacement maps.

These inputs are processed by the C++-based tools, which generate the voxels that should be rendered and their properties, while the GLSL-based shader handles the GPU-based rendering step. The pre-processing steps required make it a good idea to bake these resources rather than try to process it in real-time. With that done, [Daniel]’s demo was able to sustain a solid 100+ FPS on a Radeon RX 5700 XT GPU at 1440p, and 60+ FPS on a Steam Deck OLED.

In a second blog post [Daniel] goes through his motivations for this project, with it originally having been intended as a showpiece for his resume, but he can imagine it being integrated into a game engine.

There are still questions to be resolved, such as how to integrate this technique for in-scene characters and other dynamic elements (i.e. non-static scenery), but in terms of easing voxel-based rendering by supporting a standard mesh-based workflow it’s an intriguing demonstration.

Tight Handheld CRT Asteroids Game Curses in Tuscan

12 Junio 2024 at 20:00

How many Arduini does it take to make a tiny CRT Asteroids game? [Marco Vallegi] of MVV Blog’s answer: two. One for the game mechanics and one for the sound effects. And the result is a sweet little retro arcade machine packed tightly into a very nicely 3D printed case.

If you want to learn to curse like a Tuscan sailor, you can watch the two-part video series, embedded below, in its entirety. Otherwise, we have excerpted the good stuff out of the second video for you.

For instance, we love the old-school voice synthesis sound of the Speak and Spell. Here, playback is implemented using the Talkie library for Arduino, and [Marco] is using the BlueWizard software on a dated Macbook for recording and encoding. (We’d use the more portable Python Wizard ourselves.) Check out [Marco] tweaking the noise parameters here to get a good recording.

And since the Talkie Arduino library uses PWM on a digital output pin to create the audio, the high-frequency noise was freaking out his simple transistor amplifier. Here, [Marco] adds a feedback capacitor to cancel that high-frequency hash out.

The build needs to be quite compact, and the stacked-Arduino-with-PCB-case design is tight. And the 3D-printed case has a number of nice refinements that you might like. We especially like the use of thin veneers that cover the case all around with the build-plate’s surface texture, and the contrasting “Asteroids” logos are very nice.

All in all, this is a really fun build that’s also full of little details that might help you with your own projects. Heck, even if it just encourages you to play around with the Talkie library, it’s worth your time in our opinion. And while you’re at it, you can turn on the subtitles and pick up some vocab that’ll make your nonna roll over in her grave.

Part One: Rebuilding the CRT

Part Two: Adding Sound

Thanks [ZioTibia81] for the tip!

Baldur’s Gate III Comes to the TRS-80 Model 100

Por: Tom Nardi
12 Junio 2024 at 11:00

To say that Tandy’s TRS-80 Model 100 was an influential piece of computer hardware would be something of an understatement. While there’s some debate over which computer can historically be called the “first laptop”, the Model 100 was early enough that it helped influence our modern idea of portable computing. It was also one of the most successful of these early portables, due in part to how easy it was to write your own software for it using the built-in BASIC interpreter.

But as handy and capable as that integrated development environment might have been, it never produced anything as impressive as this Baldur’s Gate III “demake” created by [Alex Bowen]. Written in assembly, the game’s engine implements a subset of the Dungeons & Dragons Systems Reference Document (SRD), and is flexible enough that you could use it to produce your own ASCII art role-playing game that can run on either a Model 100 emulator like Virtual-T or on the real hardware.

Don’t worry about not having enough experience with the Model 100’s hardware to conjure up your own fantasy adventure. Assembly is done through zasm, and even though the code is intended for the 8085 CPU used in the Model 100, it’s actually written in Z80 syntax. The assembler’s support for mapping unicode characters also allows you to get a serviceable preview of what the levels will look like on the Model 100’s display right inside of your editor.

As you might imagine, getting such a complex game running on the meager hardware of the Model 100 took considerable trickery. [Alex] goes into plenty of detail in the project’s documentation and the video below, but perhaps our favorite optimization is the text compression routine. A Python script ran through all of the text strings used in the game to identify the most commonly used character sequences, and then mapped them to values which could be used to piece together words and sentences. This saved approximately 1500 bytes, which might not sound like a lot to a modern game developer, but it’s much appreciated on a machine that’s only got 24 kilobytes of RAM to begin with.

We’ve seen a number of projects featuring the TRS-80 Model 100, but most of them involve ripping out the original hardware and replacing it with something modern. That said, if you’ve got a stock Model 100 and give this technical masterpiece a shot, we’d love to hear about it in the comments.

Happy Birthday, Tetris!

8 Junio 2024 at 14:00

Porting DOOM to everything that’s even vaguely Turing complete is a sport for the advanced hacker. But if you are just getting started, or want to focus more on the physical build of your project, a simpler game is probably the way to go. Maybe this explains the eternal popularity of games like PONG, Tetris, Snake, or even Pac-Man. The amount of fun you can have playing the game, relative to the size of the code necessary to implement them, make these games evergreen.

Yesterday was Tetris’ 40th birthday, and in honor of the occasion, I thought I’d bring you a collection of sweet Tetris hacks.

On the big-builds side of things, it’s hard to beat these MIT students who used colored lights in the windows of the Green Building back in 2012. They apparently couldn’t get into some rooms, because they had some dead pixels, but at that scale, who’s complaining? Coming in just smaller, at the size of a whole wall, [Oat Foundry]’s giant split-flap display Tetris is certainly noisy enough.

Smaller still, although only a little bit less noisy, this flip-dot Tetris is at home on the coffee table, while this one by [Electronoobs] gives you an excuse to play around with RGB LEDs. And if you need a Tetris for your workbench, but you don’t have the space for an extra screen, this oscilloscope version is just the ticket. Or just play it (sideways) on your business card.

All of the above projects have focused on the builds, but if you want to tackle your own, you’ll need to spend some time with the code as well. We’ve got you covered. Way back, former Editor in Chief [Mike Szczys] ported Tetris to the AVR platform. If you need color, this deep dive into the way the NES version of Tetris worked also comes with demo code in Java and Lua. TetrOS is the most minimal version of the game we’ve seen, coming in at a mere 446 bytes, but it’s without any of the frills.

No Tetris birthday roundup would be complete without mentioning the phenomenal “From NAND to Tetris” course, which really does what it says on the package: builds a Tetris game, and your understanding of computing in general, from the ground up.

Can you think of other projects to celebrate Tetris’ 40th? We’d love to see your favorites!

This article is part of the Hackaday.com newsletter, delivered every seven days for each of the last 200+ weeks. It also includes our favorite articles from the last seven days that you can see on the web version of the newsletter. Want this type of article to hit your inbox every Friday morning? You should sign up!

Tarzan, Lost Since 1983, Swings Back Onto The Atari 2600

Por: Jenny List
6 Junio 2024 at 11:00

Computer gaming history is littered with tales of fabled lost hardware and software. Some of them are very famous such as the E.T. cartridges buried in a desert landfill or the few prototype SNES/CD-ROM hybrid that Nintendo was developing with Sony before the introduction of the PlayStation, but others have faded somewhat into obscurity. Among these is Tarzan for the Atari 2600, a game which was never released due to the 1983 console crash, and which the [Video Game History Foundation] have a report on its rediscovery and preservation.

The game was to be published by Coleco for their ColecoVision console as well as the 2600. The ColecoVision version was released and was apparently even fairly well reviewed, but the Atari port was canceled and its very existence eventually faded into obscurity.

Then a manual surfaced in 2011, and in 2022, a pair of prototype cartridges were sold off by a former Coleco employee. The write-up goes into great detail on the video game production and provides a fascinating snapshot of the turbulence in the industry at the time. But what really caught our eye were the two cartridges themselves. We have an obvious prototype board and a more professional looking example, both with a ROM and set of TTL chips used for bank switching. Interestingly the chips are different on each board, as well as the variety of manufacturers and date codes pointing to a hand-assembled board.

While the game seems quaint to modern eyes, it’s definitely pushing the boundaries of the console as much as any modern AAA game pushes that console under your TV today. If you’re thirsty for more tales of 1980s consumer computing, look no further than our colleague [Bil Herd]’s account of his days at Commodore.

Play Giant Tetris On Second-Floor Window

28 Mayo 2024 at 20:00

Sometimes it seems like ideas for projects spring out of nothingness from a serendipitous set of circumstances. [Maarten] found himself in just such a situation, with a combination of his existing Tetris novelty lamp and an awkwardly-sized window on a second-floor apartment, he was gifted with the perfect platform for a giant playable Tetris game built into that window.

To make the giant Tetris game easily playable by people walking by on the street, [Maarten] is building as much of this as possible in the browser. Starting with the controller, he designed a NES-inspired controller in JavaScript that can be used on anything with a touch screen. A simulator display was also built in the browser so he could verify that everything worked without needing the giant display at first. From there it was on to building the actual window-sized Tetris display which is constructed from addressable LEDs arranged in an array that matches the size of the original game.

There were some issues to iron out, as would be expected for a project with this much complexity, but the main thorn in [Maarten]’s side was getting his controller to work in Safari on iPhones. That seems to be mostly settled and there were some other gameplay issues to solve, but the unit is now working in his window and ready to be played by any passers-by, accessed by a conveniently-located QR code. Tetris has been around long enough that there are plenty of unique takes on the game, like this project from 2011 that uses Dance Dance Revolution pads for controllers.

Adafruit Badges Turned Electronic Invitations

Por: Tom Nardi
28 Mayo 2024 at 08:00

Despite what you might have heard, even the most devout Hackaday readers may eventually find themselves getting married. Should you ever find yourself in a situation where you need to send out invitations for your big day, or any other major celebration for that matter, you could do worse than follow the example [Mokas] and their partner set with these memorable electronic wedding invitations.

Inspired by the electronic badges distributed at hacker cons, [Mokas] decided to use Adafruit’ EdgeBadge and PyBadge devices to create a similar interactive keepsake that would be a bit more exciting than a piece of paper. While it would have been enough to have the wedding information pop up on the screen when they were turned on, the final invites actually boot into a retro-style game where you walk around talking to characters to uncover information about the event and the venue.

The game was created in Microsoft MakeCode Arcade, with a sprinkling of original and commissioned sprites. Early versions of the game ended up being a bit much for the Adafruit badge’s to handle, but after doing a bit of research on creating games for computationally-constrained platforms, [Mokas] was able to optimize the performance. For those that didn’t get a physical invite (no doubt ours was simply lost in the mail), you can play the whole thing right in your browser.

It’s a very clever idea, and while using custom hardware would have allowed for a more bespoke package, we can’t blame [Mokas] for wanting to keep this one simple. Getting everything ready for your wedding is already enough stress — it’s hardly the time to spin up a new board.

For a similar reasons, another Adafruit offering was selected to power the couple’s e-ink baby development display.

How A DOS Format Blunder Revealed Some Priceless Source Code

Por: Jenny List
25 Mayo 2024 at 20:00

As those of us who worked in the consumer software world back when physical media was king can attest, when a master disc has been sent for duplication and distribution there is no turning back from whatever code is in the hands of thousands of users. Usually such worries were confined to bugs or inadvertently sending out pre-release software versions, but [Lance Ewing] is here with the story of how Sierra On-Line once inadvertently released most of the source code for their game engine.

If you have some 720k floppy disk versions of the 1988 game Space Quest II, the first disk in the set appears to have nothing out of the ordinary, but a closer look reveals that the free space on the disk reported by DOS is greater than its used space. Diving in to the disk block contents with a hex editor reveals that many of the unused blocks in fact contain C code, and some further detective work allows the recovery of a not-quite complete set of source files for the company’s AGI, or adventure game interpreter. They had been left behind when the original master disk had been emptied by deleting them, rather than by formatting it afresh.

In commercial terms this would in 1988 have been something of a disaster for Sierra had it been discovered at the time, because it was the cornerstone of their success. As it was we’re told the code sat peacefully undetected until 2016, since when it has proved invaluable to those interested in computer game archaeology. Or did it? We’ll never know if a sharp-eyed competitor snagged it, and kept quiet.

Of course, these days, there are game engines that are open source. Some of them are very modern. Others… not so much.

Orange FM Brings Radio to the GameBoy

23 Mayo 2024 at 23:00
An amber on black interface on a green reproduction Game Boy screen. It has the FM station 88.9 in large letters in the middle of the display and "Ice Cream (Pay Phone) by Black Pumas" displayed in a box below. A volume indicator is on the left side of the tuner numbers and various status icons are along the top of the screen. A paper cutout of an orange is next to the Game Boy on a piece of paper with the words "Orange FM Prototype" written underneath.

We’ve all been there. You left your Walkman at home and only have your trusty Game Boy. You want to take a break and just listen to some tunes. What to do? [orangeglo] has the answer now with the Orange FM cartridge.

This prototype cart features an onboard antenna or can also use the 3.5 mm headphone/antenna port on the cartridge to boost reception with either a dedicated antenna or a set of headphones. Frequencies supported are 64 – 108 Mhz, and spacing can be set for 100 or 200 kHz to accomodate most FM broadcasts setups around the world.

Older Game Boys can support audio through the device itself, but Advances will need to use the audio port on the cartridge. The Super Game Boy can pipe audio to your TV though, which seems like a delightfully Rube Goldberg-ian way to listen to the radio. Did we mention it also supports RDS, so you’ll know what that catchy tune is? Try that FM Walkman!

Can’t decide between this and your other carts? Try this revolving multi-cart solution. Have a Game Boy that needs some restoration? If it’s due to electrolyte damage, maybe start here?

Static Recompilation Brings New Life to N64 Games

Por: Maya Posch
21 Mayo 2024 at 11:00

Over the past few years a number of teams have been putting a lot of effort into taking beloved Nintendo 64 games, decompiling them, and lovingly crafting them into highly portable C code. This allows for these games to not only run natively on PCs, but also for improvements to be made to the rendering engine and other components.

Yet this artisan approach to porting these games means a massive time investment, something which static binary translation (static recompilation) may conceivably speed up. Enter the N64: Recompiled project, which provides a binary translation tool to ease the translation of the N64’s binaries into C code.

This is effectively quite similar to what an emulator does in real-time, just with the goal of creating a permanent copy of the translated instructions. After this static binary translation, the C code can be compiled again, but as noted by the project’s documentation, a suitable runtime is needed to get a functional game. An example of this is the Zelda 64: Recompiled project, which uses the N64: Recompiled project at its core, while providing the necessary scaffolding and wrappers to create a working copy of The Legend of Zelda: Majora’s Mask as output.

In the video below, [Modern Vintage Gamer] takes the software for a test drive and comes away very excited about the potential it has to completely change the state of N64 emulation. To be clear, this isn’t a one-button-press solution — it still requires capable developers to roll up their sleeves and get the plumbing in. It’s going to take some time before you favorite game is supported, but the idea of breathing new life into some of the best games from the 1990s and early 2000s certainly has us eager to see where this technology goes

Thanks to [Keith Olson] for the tip.

Hack Your Own Adventure Story with Yarn Spinner

18 Mayo 2024 at 23:00

We are big fans of programmed texts for education. You know, the kind where you answer a question and go to a new page based on your answer. But they can also be entertaining “choose your own adventure” stories. You might say, “You are standing in front of an oak door, two meters high, with an iron handle. Do you a) open it? b) knock on it? c) ignore it?” Then, based on your answer, you go to a different part of the story. These are tough to write, but you can get some help using Yarn Spinner and the Yarn scripting language.

The original purpose of Yarn is to produce conversations for games. There’s a tutorial for that. The difference is to produce a book, you get a choose your own adventure PDF at the end. For the tutorial, you can try to read the text on the left-hand side of the editor or just press Test (at the top) and let it “read” the tutorial to you, which is a little more fluid.

The scripting language is mostly text, but you can have branching logic, which is critical for the book generation. You can also set variables as in:

<<set $gold to 5>>

Then you can test variables with <<if>> as you might expect. You can also jump to other parts of the script using <<jump>>. This works with nodes that look like this:

title: HackadayNode
---// Yarn script goes here===

That’s about it. We took the liberty of writing a cheeky Hackaday adventure. The source code is available, too. You’ll notice the script is simplistic. It doesn’t merge the lines, so if you have, say, three jumps to node X, you will get three copies of node X in the book. Then again, that helps your page count, and it doesn’t distract from the enjoyment of the finished product. And, yes, we added the title graphic after the fact.

It should be possible to write programmed instruction material with this, too. Why just pretend to submit a project to Hackaday when you could do it for real so easily?

Gather ‘Round This Unique 4-Player Arcade Cabinet

Por: Tom Nardi
11 Mayo 2024 at 11:00

Usually when we see arcade cabinet builds, they’re your standard single-player stand up variety. Even one of them takes up quite a bit of room, so as appealing as it might be to link up two or more cabinets together for the occasional multiplayer session, the space required makes it a non-starter for most of us.

But this cleverly designed 4-player cocktail cabinet from [OgrishGadgeteer] goes a long way towards solving that problem. The circular design of the cabinet gives each player a clear view of their respective display in a much smaller footprint than would otherwise be possible, and the glass top allows the whole thing to double as an actual cocktail table when it’s not game time.

The cabinet was modelled in 3D before construction.

According to a post on r/cade, it took [OgrishGadgeteer] three months to go from paper sketches of the cabinet’s basic shape to the final product. Most of the components were picked up on the second hand market, which brought the total cost of the build to around $350. That wouldn’t have been a surprising price for a traditional full-size cabinet build, so for this, it seems like an absolute steal.

A Dell OptiPlex 7060 small form factor PC provides the power for this build, with the video output passing through a 4-way VGA distribution amplifier into 20 inch monitors. At $75, the four player control kit ended up being the single most expensive component of the build, though you could make do with some parts bin buttons and a Pi Pico if you wanted to really bring this one in on a budget.

Perhaps the most surprising element of the whole build is that, despite the cabinet’s complex design, [OgrishGadgeteer] pulled it off without a CNC to cut the plywood panels. Instead, a vinyl cutter was used to make full-size templates of the cuts and holes that needed to be made, which were attached directly to the wood. After that, it was just a matter of following the lines with a jigsaw. Not the fastest or most convenient solution, but it’s hard to argue with the final results.

We’ve seen other cocktail cabinet builds in the past, but this is the first that managed to cram four players in. Well, unless you count Dungeons & Dragons, anyway.

ROG Ally SD Card Slot Fix Shines Light On PTC Fuse Failure Modes

4 Mayo 2024 at 08:00
the PTC fuse to blame for the fault described, on the ROG Ally board, with a wire soldered across the fuse

The Asus ROG Ally is a handheld that, to our pleasant surprise, has attracted a decently sized modding community. Recently, we’ve stumbled upon a Reddit post investigating a somewhat common failure mode of this handheld — the microSD card slot going out of order, where an inserted card fails to be recognized, pretty irritating to encounter. Now, it turns out, this is down to a certain model of PTC fuses being failure-prone.

It makes sense to fuse the SD card slot. The cards are dense pieces of technology that are subject to some wear and tear in daily use. As such, it’s not unheard of that a microSD card can short-circuit internally — heating up to the point of melting plastic and giving people severe burns. Given that such a card is typically connected to a beefy 3.3 V rail, any mass-manufactured device designer could want to put a fuse between the 3.3 V rail and the card. However, on some ROG Ally batches, a certain make of the fuse is used, that appears to be likely to develop faults: the fuse’s resistance increasing dramatically during the card’s normal operation, with the SD card being supplied subpar power as a result.

There’s a fair bit of investigating happening in the comment section, with people posting oscilloscope captures, using breakouts to tap the SD card, and figuring out the fuse part numbers for the affected models. As for Reddit’s solution, it’s short-circuiting the fuse with a piece of thin wire — we would probably source a suitable fuse and solder it on top of the faulty one.

This isn’t the first ROG Ally modification we’ve covered so far, and given the activity we’re seeing, it’s unlikely to be our last.

❌
❌