Wipeout Clone Runs Native On ESP32-S3

Psygnosis’s 1995 game Wipeout is remembered for two things: being one of the greatest games of all time, and taking advantage of the then-new PlayStation’s capacity for 3D graphics. The ESP32-S3 might not be your first choice to replace Sony’s iconic console, but [Michael Biggins] a.k.a. [PhonicUK] is working on doing just that, with his own clone of Wipeout on the Expressif MCU. 

It’s actually not that crazy when you think about it. The PlayStation had a 32-bit RISC processor, and the ESP32-S3 is a 32-bit RISC processor. The PlayStation’s was only good for about 30 Million Instructions Per Second (MIPS) but it had a graphics co-processor to help out with the polygons — the ESP32-S3 has two cores that can help each other, which combine to about 300 MIPS. In terms of RAM, the board in use has 8 MB of PSRAM, while the faster 512 kB on the chip is used, in effect, as video ram.

The demo is very impressive, especially considering he’s fit in three computer players. He’s also got it blasting out 60 frames per second, which is probably double what the original Wipeout ran on the PS1. Part of that is the two cores in action: he’s got them working together on the interlaced video output, one sending while the other finishes the second half of the frame. Each half of the video gets dedicated space in the internal memory. Using a 480×320 pixel display doesn’t hurt for speed, either. Sure, it’s paltry by modern standards, but the original Wipeout got by with even fewer pixels — and it didn’t run on a microcontroller. Granted it’s a beefy micro, but we really love how [Michael] is pushing its limits here.

Right now there’s just the Reddit thread and the demo video below. [Michael] is considering sharing the source code for his underlying 3D engine under an open license. We do hope he shares the code, as there are surely tricks in there some of us here could learn from. If it’s all old hat to you, perhaps you’d rather spend a weekend learning raytracing.

Continue reading Wipeout Clone Runs Native On ESP32-S3″

Compact VGA Output Board For The Pi Pico

Many microcontrollers can spit out simple analog video signals if that’s something you desire. However, it normally requires a bit of supporting hardware and, of course, the right connectors to work with your other video equipment. [Arnov Sharma] took that into account when whipping up this neat VGA board for the Raspberry Pi Pico.

VGA output in this case is achieved via judicious use of the Pi Pico’s PIO subsystem, which is perfect for clocking out the signals for red, green, and blue along with HSYNC and VSYNC as needed. The Pico slots right into [Arnov’s] custom PCB, which makes it a cinch to hook everything up. Supporting hardware is minimal, requiring just a few resistors between the Pico and the DE-15 VGA connector. There’s also a nice LM317 regulator on board to supply power to everything. [Arnov] also whipped up a modified version of the VGA library from [Pancrea85], which allows the Pico to output VGA in a way that’s more accepted by more recent TFT displays as well as older CRTs. The system is demoed with a few basic Hello, World programs, as well as a neat recreation of Conway’s Game of Life.

If you want to get a Pi Pico hooked up to a big screen quickly, whipping up a board like this is a great way to go. If you’re wanting something more advanced, though, you could always explore DVI and HDMI on the same platform. Video after the break.

Continue reading “Compact VGA Output Board For The Pi Pico”

Register Renaming

[Shreeyash] asks an interesting question: how many registers does your CPU have? The answer is probably more than you think. The reason? Modern CPUs — at least many of them — execute instructions out of sequence so they can perform multiple instructions per clock cycle. To do this, they may need to execute instructions that change registers that other instructions are still reading. In addition, you might be writing a result speculatively — a branch might make it where your result won’t wind up in the target register. The answer to both of these problems is register renaming.

The ARM CPU he looks at has many physical registers you can’t see. These get mapped to the registers you use on the fly. So when you read a register in software, you are really getting an underlying physical register. Which one? Depends on when you read it.

Continue reading “Register Renaming”

ESP32Synth : An Audio Synthesis Library For The ESP32

With MCUs becoming increasingly more powerful it was only a matter of time before they would enable some more serious audio-processing tasks. [Danilo Gabriel]’s ESP32Synth library is a good example here, which provides an ESP-IDF based 80+ voice mixing and synthesis engine. If you ever wanted to create a pretty impressive audio synthesizer, then all you really need to get started is an ESP32, ESP32-S3 or similar dual-core Espressif MCU that has the requisite processing power.

Audio output goes via I2S, requiring only a cheap I2S DAC like the UDA1334A or PCM5102 to be connected, unless you really want to use the internal DAC. With this wired up you get 80 voices by default, with up to 350 voices demonstrated before the hardware cannot keep up any more. You can stream multiple WAV files from an SD card for samples along with the typical oscillators like sinewave, triangle, sawtooth and pulse, as well as noise, wavetables and more.

In order to make this work in real-time a number of optimizations had to be performed, such as the removal of slow floating-point and division operations in the audio path. The audio rendering task is naturally pinned to a single core, leaving a single core for application code to use for remaining tasks. While the code is provided as an Arduino project, it uses ESP-IDF so it can likely be used for a regular ESP-IDF project as well without too much fuss.

ESP32 Hosts A Public Website

If you wanted to host a website, you could use any one of a number of online services, or spin up a server on a spare computer at home. If you’re a bit more daring, you could also do what [Tech1k] did, and run one on an ESP32 microcontroller.

The site in question is available (or at least, should be) at HelloESP.com. The first revision ran entirely on an ESP32, serving pages from a SPIFFS filesystem. The device was also fitted with a BME280 environment sensor and an OLED screen. It had an uptime of 500 days before the board failed.

The site has since been relaunched, running on a board that is framed on [Tech1k]’s wall. It runs on an ESP32-WROOM-32D, paired with a BME280 again, along with a CCS811 CO2 and air quality sensor and a DS3231 RTC for accurate timekeeping. The ESP32 is setup to hold an outbound WebSocket to a Cloudflare worker, with the Worker routing HTTP requests to the site via that route. This avoids the need for port forwarding for the ESP32 to be visible to the outside world, and the Cloudflare Worker will also serve a static version of the page in the case of WiFi dropouts or other temporary failures.

It’s true that this isn’t a completely unheard of project—microcontrollers have been working as simple web servers for a long time now. Still, [Tech1k] did a great job of making this as robust as possible and more like a real functional webserver rather than just something that runs on a local network to serve up a config page. That’s worthy of note.

You can run webservers on all kinds of chips these days, even the Raspberry Pi Pico. If you’re doing web stuff on something weird, you know we always wanna hear about it on the tipsline!

DIY Smart Button Gets Surprisingly Complicated

There’s a reason that the standards specifications for various wireless communications protocols are extremely long and detailed. [Made by Dennis] found this out first hand when he decided to build a wireless button from scratch.

The major issues with wireless devices is one of power consumption. If reliable power is available from a wall plug or solar panel, this isn’t as serious of a concern. But [Dennis] is using batteries for his buttons, so minimizing power consumption is a priority. He’s going with the nRF52, a microcontroller designed for low power and which has a built in wireless radio, and configuring it in a way that uses the least amount of energy possible.

From there, [Dennis] turns to the wireless communication. He goes into detail about how the microcontroller is woken up, how it sends its data packets to another wireless-enabled microcontroller, and how they handle handshakes and acknowledgements of data. For something as simple as a button press, it gets quickly more complicated especially when adding some basic encryption and security to the communications protocol.

With all the design decisions out of the way, the system can be built. [Dennis] has created custom PCBs for his devices, and also included some expansion I/O for other sensors and peripherals beyond just a pushbutton. All of the schematics and code are available on the project’s GitHub page and the STL files can be found at Printables.

For those new to offline home automation or who are turning away from cloud-based services lately, there are some easy entry points that don’t require much extra hardware or expenditure.

Continue reading “DIY Smart Button Gets Surprisingly Complicated”

Espressif’s New ESP32-S31: Dual-Core RISC-V With WiFi 6 And GBit Ethernet

In a move that’s no doubt going to upset and confuse many, Espressif has released its newest microcontroller — the ESP32-S31. The confusing part here is that the ESP32-S series was always the one based on Tensilica Xtensa LX7 cores, while the ESP32-C series was the one using RISC-V cores.

That said, if one looks at it as a beefier -S3 MCU it does have some appealing upgrades. The most obvious improvements are with the use of WiFi 6, as well as Bluetooth Classic and LE 5.4, including LE Audio. There is also Thread and Zigbee support for those who are into such things.

The Ethernet MAC got a bump from the 100 Mbit RMII MAC in previous MCUs and is now gigabit-rated, while the number of GPIO is significantly higher at 60 instead of 45 on the -S3. On the RAM side, things are mostly the same, except for DDR PSRAM support, with octal SPI offering up to 250 MHz compared to 80 MHz on the -S3.

On the CPU side the up-to-320 MHz RISC-V cores are likely to be about as powerful as the 240 MHz LX7 cores in the -S3, based on the ESP32-C series performance in terms of IPC. Overall it does seem like a pretty nice MCU, it’s just confusing that it doesn’t use LX7 cores with the series it was put into. When this MCU will be available for sale doesn’t seem to be known yet, with only samples available to select customers.