Sinclair BASIC For Today

If you are of a certain age, your first exposure to computer programming was probably BASIC. For a few years, there were few cheaper ways to program in BASIC than the Sinclair ZX series of computers. If you long for those days, you might find the 1980-something variant of BASIC a little limiting. Or you could use SpecBasic from [Paul Dunn].

SpecBasic is apparently reasonably compatible with the Spectrum, but lets you use your better hardware. For example, instead of a 256×192 8-color screen, SpecBas accommodates larger screens and up to 256 colors. However, that does lead to certain incompatibilities that you can read about in the project’s README file.

Continue reading “Sinclair BASIC For Today”

The Laser Power Record Has Been Broken

Lasers do all sorts of interesting things and — as with so many things — more is better. Korean scientists announced recently they’ve created the most powerful laser beam. 1023 watts per square centimeter, to be exact. It turns out that 1022 Watts/cm2 may not be commonplace, but has been done many times already at several facilities, including the CoReLS petawatt (PW) laser used by the researchers.

Just as improving a radio transmitter often involves antenna work instead of actual power increases, this laser setup uses an improved focus mechanism to get more energy in a 1.1 micron spot. As you might expect, doing this requires some pretty sophisticated optics.

Continue reading “The Laser Power Record Has Been Broken”

Four Servo Fingers Play Simon Better Than You Ever Could

Remember Simon? We sure do. Simon — as in “Simon says…” — from the leading edge of electronic games in the 1970s, which used four buttons, colored lights, and simple tones as the basis for a memory game. Players had to remember the specific sequence of lights and replay the pattern in order to advance to the next round. It was surprisingly addictive, at least for the era.

For those who never quite got into the Simon groove, fear not — the classic game has now been fully automated. While there were plenty of approaches that could have taken to interfacing to the game, [ido roseman] went with the obvious — and best, in our opinion — technique and simulated a human player’s finger presses with servo-controlled arms. Each arm carries a light-dependent resistor that registers the light coming from the key it’s poised above; the sequence of lights is sensed and recorded by an Arduino, which then drives the servo fingers’ replay attack. The fingers aren’t exactly snappy in their response, which might cause problems — if we recall correctly, Simon is somewhat picky about the speed with which the keys are pressed, at least at higher levels of play.

On the whole, we really like this one, not least for the nostalgia factor. We’ve had a lot of recreations of Simon over the years, including a Dance Dance Revolution version, but few attempts to automate it. And a crazy idea: wouldn’t it be fun to replace the replay attack with a machine learning system that figures out how to play Simon by randomly pressing keys and observing the results?

Continue reading “Four Servo Fingers Play Simon Better Than You Ever Could”

Tetris For Game Boy Gets Online Multiplayer

Released in 1989, the Game Boy version of Tetris is notable for being the first game to support multiplayer via the so-called “Game Link Cable” accessory. So it’s fitting that, 32 years later, that same game is now playable with others over the Internet thanks to an open source USB adapter from [stacksmashing].

As explained in the video below, the adapter is essentially just a Raspberry Pi Pico paired with some level shifters so that it can talk to the Game Boy’s link port. That said, the custom PCB does implement some very clever edge connectors that let you plug it right into the Link Cable for the original “brick” Game Boy as well as the later Color and Advance variants. This keeps you from having to cut up a Link Cable just to get a male end, which is what [stacksmashing] had to do during the prototyping phase.

The DIY breadboard approach works as well.

Of course, the hardware is only one half of the equation. There’s also an open source software stack which includes a Python server and WebUSB frontend that handles communicating with the Game Boy and connecting players. While the original game only supported a two person head-to-head mode, the relatively simplistic nature of the multiplayer gameplay allowed [stacksmashing] to expand that to an arbitrary number of players with his code. The core rules haven’t changed, and each client Game Boy still thinks it’s in a two player match, but the web interface will show the progress of other players and who ends up on top at the end.

To be clear, this isn’t some transparent Link Cable to TCP/IP solution. While something like that could potentially be possible with the hardware, as of right now, the software [stacksmashing] has put together only works for Tetris. So if you want to battle Pokemon over the net, you’ll have to do your own reverse engineering (or at least wait for somebody else to inevitably do it).

The Link Cable port on the Game Boy, especially on the later versions of the hardware, is a surprisingly versatile interface capable of much more than just multiplayer gaming. While we’re certainly keen to see [stacksmashing] develop this project farther, we’re equally excited to see the non-gaming applications of such an easy to use computer interface for the iconic handheld.

Continue reading Tetris For Game Boy Gets Online Multiplayer”

TrueTape64 Is A PC Interface For Your C64 Datasette

Back in the distant past of the 1980s, software was distributed on audio tape. Ones and zeroes were encoded as tones of different frequencies, and tapes were decoded by specialised hardware which could then spit out raw digital data to an attached computer. While software methods now exist to simply record audio from old tapes and turn them into data, [Francesco] wanted to do it the hardware way, and built a PC interface for his Commodore 64 Datasette.

The TrueTape64, as it has been named, is built around an Atmel ATTiny2313 microcontroller. This interfaces with the original Datasette hardware which takes care of reading the analog tape output and turning it into digital data. From there, the microcontroller communicates with an FTDI232 serial-to-USB adapter to get the data into a modern PC, where it’s compiled into a TAP image file via some Python magic.

It’s a barebones build, which goes so far as to run the Datasette’s motor off the USB power supply via a boost converter; those facing issues with the tape mechanism might do well to look there first. However, it does work, and a done job is a good job at the end of the day. We’ve seen similar hacks before, too – it’s great to see the community keeping cassette software alive!

The ARMv9 ISA, And What It Can Do For You

The number of distinct ARM Instruction Set Architectures (ISA) versions has slowly increased, with Arm adding a new version every few years. The oldest ISA version in common use today is ARMv6, with the ARMv6 ISA (ARM11) found in the original Raspberry Pi SBC and Raspberry Pi Zero (BCM2835). The ARMv6 ISA was introduced in 2002, followed by ARMv7 in 2005 (start of Cortex-A series) and ARMv8 in 2011. The latter was notable for adding 64-bit support.

With ARMv7 being the first of the Cortex cores, and ARMv8 adding 64-bit support in the form of AArch64, what notable features does ARMv9 bring to the table? As announced earlier this year, ARMv9’s focus appears to be on adding a whole host of features that should improve vector processing (vector extensions, or SVE) as well as digital signal processing (DSP) and security, with its Confidential Compute Architecture (CCA).

In addition to this, ARMv9 also includes all of the features that were added with ARMv8.1, v8.2, v8.3 and so on. In essence, this makes an ARMv9-based processor theoretically capable of going toe-to-toe with the best that Intel and AMD have to offer.

Continue reading “The ARMv9 ISA, And What It Can Do For You”

Embedded Rust Hack Chat

Join us on Wednesday, May 12 at noon Pacific for the Embedded Rust Hack Chat with James Munns!

Programming languages, like fashion, are very much a matter of personal taste. Professional developers often don’t have much say in which language they’ll use for a given project, either for legacy or team reasons, but if they did have a choice, they’d probably choose the language that works best with the way they think. Some languages just “fit” different brains better than others, and when everything is in sync between language and developer, code just seems to flow effortlessly through the keyboard and onto the screen.

One language that consistently scores at the top of developers’ “most loved” lists is Rust. For a language that started as a personal project and has only existed for a little more than a decade, that’s really saying something. The emphasis Rust puts on safety and performance probably has a lot to do with that. And thanks to its safe concurrency, its memory safety, and its interoperability with C and other languages, Rust has made considerable in-roads with the embedded development community.

To learn more about Rust in embedded systems, James Munns will stop by the Hack Chat. James is an embedded systems engineer, with a history of working on software for a wide range of systems, including safety-critical avionics, and rapidly prototyped IoT systems. He’s a founding member of the Rust Embedded Working Group, as well as a founder of Ferrous Systems, a consultancy focused on systems development in Rust, with a specialty in embedded systems development. James also used to write for Hackaday, so he must be a pretty cool guy. So swing by the Hack Chat and find out where Rust might be able to help you out with your next embedded project.

join-hack-chatOur Hack Chats are live community events in the Hackaday.io Hack Chat group messaging. This week we’ll be sitting down on Wednesday, May 12 at 12:00 PM Pacific time. If time zones have you tied up, we have a handy time zone converter.

Click that speech bubble to the right, and you’ll be taken directly to the Hack Chat group on Hackaday.io. You don’t have to wait until Wednesday; join whenever you want and you can see what the community is talking about.
Continue reading “Embedded Rust Hack Chat”