Pi Zero Power Optimization Leaves No Stone Unturned

If you’ve ever designed a battery-powered device with a Pi Zero, you have no doubt looked into decreasing its power consumption. Generic advice, like disabling the HDMI interface and the onboard LED, is omnipresent, but [Manawyrm] from [Kittenlabs] goes beyond the surface-level, and gifts us an extensive write-up where every recommendation is backed with measurements. Armed with the Nordic Power Profiler kit and an SD card mux for quick experimentation, she aimed at two factors, boot time and power consumed while booting, and made sure to get all the debug information we could use.

Thanks to fast experimentation cycles and immediate feedback, we learn plenty of new things about what a Pi Zero does and when, and how we can tame various power-hungry aspects of its behavior. Disabling the GPU or its aspects like HDMI output, tweaking features like HAT and other peripheral probing, and even tactical overclocking during boot – it’s an extensive look at what makes a Pi Zero tick, and no chance for spreading baseless advice or myths.

All in all, this write-up helps you decrease the boot time from twelve seconds to just three seconds, and slash the power budget of the boot process by 80%. Some recommendations are as simple as config.txt entries, while others require you to recompile the kernel. No matter the amount of effort you can put into power optimization, you’ll certainly find things worth learning while following along, and [Manawyrm]’s effort in building her solar-powered Pi setup will help us all build better Pi-Zero-powered solar devices and handhelds.

Supercon 2023 – Going Into Deep Logic Waters With The Pico’s PIO And The Pi’s SMI

The Raspberry Pi has been around for over a decade now in various forms, and we’ve become plenty familiar with the Pi Pico in the last three years as well. Still, these devices have a great deal of potential if you know where to look. If you wade beyond the official datasheets, you might even find more than you expected.

Kumar is presently a software engineer with Google, having previously worked for Analog Devices earlier in his career. But more than that, Kumar has been doing a deep dive into maxing out the capabilities of the Raspberry Pi and the Pi Pico, and shared some great findings in an excellent talk at the 2023 Hackaday Supercon.

Continue reading “Supercon 2023 – Going Into Deep Logic Waters With The Pico’s PIO And The Pi’s SMI”

Switch Your RP2040 Between 3.3 V And 1.8 V

Ever want to build a RP2040 devboard that has everything you could ever want? Bad news,  “everything” also means adding 1.8 V GPIO voltage support. The good news is that this write-up by [xenia] explains the process of adding a “3.3 V/1.8 V” slide switch onto your board.

Some parts are obvious, like the need to pick a flash chip that works at either voltage, for instance. Unfortunately, most of them don’t. But there’s more you’d be surprised by, like the crystal, a block where the recommended passives are tuned for 3.3 V, and you need to re-calculate them when it comes to 1.8 V operation – not great for swapping between voltages with a flick of a switch. Then, you need to adjust the bootloader to detect the voltage supplied — that’s where the fun begins, in large part. Modifying the second stage bootloader to support the flash chip being used proved to be quite a hassle, but we’re graced with a working implementation in the end.

All the details and insights laid out meticulously and to the point, well-deserved criticism of Raspberry Pi silicon and mask ROM design choices, code fully in Rust, and a success story in the end – [xenia]’s write-up has all you could wish for.

Want to learn more about the RP2040’s bootloader specifically? Then check this out — straight out of Cornell, a bootloader that’s also a self-spreading worm. Not only is it perfect for updating your entire RP2040 flock, but it also teaches you everything you could want to know about RP2040’s self-bringup process.

Latest PiEEG Shield Now Offers 16 Channels

We’ve previously covered the PiEEG, an affordable brain-computer interface (BCI) shield designed to connect to the Raspberry Pi. The open source project developed by [Ildar Rakhmatulin] is intended to allow students and hobbyists to experiment with detecting electroencephalography (EEG), electromyography (EMG), and electrocardiography (ECG) biosignals — unlocking a wide array of applications ranging from assistive tech to gaming.

Now, the PiEEG hardware has been upgraded to detect sixteen channels via either wet or dry electrodes. The new board, referred to as the PiEEG-16, offers up the same ease of use and features as its predecessor, including the ability to read out signals from the device using Python scripts. Compared to the eight channels supported by the previous generation of hardware, the PiEEG-16 promises to provide the fine-grain data required for more complex operations.

Since we last checked in with the PiEEG back in 2023, [Ildar] says the project has attracted plenty of attention. To help document how the community is using the capability offered by these BCIs, he’s added a page on the project’s site to show off what folks are building with the technology.

Inevitably, some express concern when talking about non-professionals working with brain interfacing hardware. But the project’s documentation is quick to point out that efforts have been taken to make the endeavour as risk-free as possible. The most important thing to remember is that the Raspberry Pi and PiEEG are intended to be powered by batteries so as to remain completely isolated. Similarly, there’s no need to connect the devices to a mains-powered computer, as everything happens on the Pi itself.

Even still, it’s made clear that the PiEEG-16 is not a medical device, and has received no formal certifications. If you want to experiment with this technology, you do so at your own risk. Just something to keep in mind…no pun intended.

Continue reading “Latest PiEEG Shield Now Offers 16 Channels”

Inkycal Makes Short Work Of E-Paper Dashboards

The e-paper “dashboard” is something we’ve seen plenty of times here at Hackaday. Use it to show your daily schedule, the news, weather, maybe the latest posts from your favorite hardware hacking website. Any information source that doesn’t need to be updated more than every hour or so is a perfect candidate. All you’ve got to do is write the necessary code to pull  down said data and turn it into a visually attractive display.

Well, that last part isn’t always so easy. There are plenty of folks who have no problem cobbling together a Raspberry Pi and one of the commercially available e-paper modules, but writing the software to turn it into a useful information center is another story entirely. Luckily, Inkycal is here to help.

This open source project uses Python to pull information from a wide variety of sources and turns it into an e-paper friendly dashboard. It works with Waveshare displays ranging from 4.2 inches all the way up to the massive 12 inch tricolor panels. While it could theoretically be deployed on any operating system running a modern version of Python, it’s primarily developed to be run under Linux and on the Raspberry Pi. All of the versions of the Pi are supported, so no need to spring for the latest and greatest model. In fact, the notoriously pokey Raspberry Pi Zero is their recommended platform thanks to its low power consumption.

With Inkycal on the Pi — they even provide a pre-configured SD card image — and the e-paper display hooked up, all you need to do is pick which sources you want to use from the web-based configuration page. Look ma, no code!

Not feeling like putting the hardware together either? Well, we might wonder how you’ve found yourself on Hackaday if that’s the case. But if you really would rather buy then build, you can get a pre-built Inkcal display right now on Tindie.

A light-dependent resistor detects cacti in the Google Chrome Offline Dinosaur game.

Jump Cacti With An LDR And A Pico

By now, probably everyone is familiar with the “You’re Offline” dinosaur that stars in Google’s T. Rex game. You know — jump cacti, avoid pterodactyls. Repeat until you lose, or, we suppose, make the leaderboard. Well, what if you theoretically couldn’t lose? That’s kind of the idea behind [Bas BotBerg]’s cactus detection-and-avoidance scheme (translated from Dutch).

Like many of us, [Bas] firmly believes that repetitive tasks should be automated, and that includes the controls of the famous T. Rex. Since the cacti are always dark gray and appear along the same plane, it’s easy to register the difference between cacti and screen electronically. In order to accomplish this, [Bas] is using a light-dependent resistor and a pull-up resistor to create a resistance bridge, which is then connected to an analog input pin on a Raspberry Pi Pico.

But [Bas] didn’t do this just to cheat at Offline Dinosaur. Really! It’s for educational purposes, to get people comfortable with embedded processing, sensors, and interfaces between different devices. Check it out in brief action after the break.

Once they get familiar with these concepts, maybe introduce the ESP32 version of Offline Dinosaur.

Continue reading “Jump Cacti With An LDR And A Pico”

The Worsening Raspberry Pi RP2350 E9 Erratum Situation

There’s currently a significant amount of confusion around the full extent of the GPIO hardware issue in the Raspberry Pi RP2350 microcontroller, with [Ian] over at [Dangerous Prototypes] of Bus Pirate fame mentioning that deliveries of the RP2350-based Bus Pirate 5XL and 6 have been put on hold while the issue is further being investigated. Recorded in the MCU’s datasheet as erratum RP2350-E9, it was originally reported as only being related to the use of internal pull-downs, but [Ian] has since demonstrated in the primary issue ticket on GitHub that the same soft latching behavior on GPIO pins occurs also without pull-downs enabled.

Ian from Dangerous Prototypes demonstrating the RP2350-E9 issue in a Bus Pirate prototype without pull-ups.
Ian from Dangerous Prototypes demonstrating the RP2350-E9 issue in a Bus Pirate prototype without pull-ups.

When we first reported on this hardware bug in the RP2350’s A2 (and likely preceding) stepping there was still a lot of confusion about what this issue meant, but so far we have seen the Bus Pirate delay and projects like [Agustín Gimenez Bernad]’s LogicAnalyzer have opted for taking the RP2350 port out back. There are also indications that the ADC and PIO peripherals are affected by this issue, with workarounds only partially able to circumvent the hardware issue.

In the case of the Bus Pirate a potential workaround is the addition of 4.7 kOhm external pull-downs, but at the cost of 0.7 mA continuous load on the GPIO when pulled high and part of that when pulled low. It’s an ugly hack, but at the very least it might save existing boards. It also shows how serious a bug this is.

Meanwhile there are lively discussions about the issue on the Raspberry Pi forums, both on the E9 erratum as well as the question of when there will be a new stepping. The official statement by Raspberry Pi is still that ‘they are investigating’. Presumably there will be a Bx stepping at some point, but for now it is clear that the RP2350’s A2 stepping is probably best avoided.