Spying On The ESP32’s GPIO

The ESP32 has been a go-to microcontroller platform for a while now, thanks to its versatile capabilities, integrated Wi-Fi and Bluetooth connectivity, and low power consumption. It’s ideal for a wide range of projects especially those revolving around IoT, partially because of all of the libraries and tools available for it now. The latest tool from [The Last Outpost Workshop] adds a feature we didn’t know we wanted until now: a webserver showing real-time updates of what all of the GPIO pins are doing.

The live GPIO pin monitoring library sets up the ESP32 to stream information about what all of the pins are doing in real time to a webserver, which displays the information as a helpful graphic. The demonstration in the video below shows and example troubleshooting a situation where the code is correct but there’s a mistake in the wiring, helping to quickly identify the problem and hopefully eliminating a wild goose chase for a bug in the software. The library can be quickly installed using the Arduino IDE and only requires the use of one other library and a few lines of code to get everything up and running.

As far as a debugging tool goes, something like this could save a lot of us a significant amount of time, especially with how easy it is to set up. A real-time look into the pins and their behavior, including those set up for PWM, is invaluable for plenty of situations. Of course if you’re building something like a real-time operating system that needs responses within a very specific interval you may want to look at more in-depth strategies for probing the GPIO.

Thanks to [Bob] for the tip!

Continue reading “Spying On The ESP32’s GPIO”

Latency Meter For Accurate Gaming

The gaming world experienced a bit of a resurgence in 2020 that is still seen in the present day. Even putting aside the effects from the pandemic, the affordability and accessibility has arguably never been better. Building a gaming PC can have its downsides, though, and a challenging issue to troubleshoot is input lag or input latency. This is something that’s best measured with standalone hardware, and if this is an issue on your setup you may want to take a look at this latency meter.

Unlike other measurement devices that use the time between a mouse button input and the monitor’s display of a bullet or shooting event, this one looks at mouse movement and the change in the scene instead. This makes it much more versatile than other methods since it’s independent of specific actions, and can be used in any game without any specific events needed to perform the measurement. A camera phototransistor is placed on the monitor’s top edge and the Arduino-based device sends mouse commands to the computer while measuring the time between those commands and the shift in the image on the monitor.

The project is open source, so with the right hardware it’s possible to build one to troubleshoot latency issues or just to learn more about a particular hardware configuration’s behavior. Arduinos and other microcontrollers have been doing all kinds of things by pretending to be human interface devices like this for a while now. One of our favorites of late was this effects pedal that replicates musical effects on mice and keyboards.

FPGA Runs IBM 5151 MDA Display

When it comes to driving a display, you can do all kinds of fancy tricks with microcontrollers to get an image up. Really, though, FPGAs are the weapon of choice for playing with these kinds of signals. [Ted Fried] put one to great work driving an ancient IBM 5151 MDA display, and shared his results on Hackaday.io.

The build relies on a Digilent Arty Z7-20 SOC FPGA development board, which has a beefy 600 MHz ARM processor on board. It also packs 500 MB of DRAM—more than enough for storing pixel data for an ancient display.

To drive the old display, [Ted] whipped up a state machine on the FPGA. It’s tasked with fetching display data from RAM and creating the appropriate timings for the MDA display interface. The images are stored directly in an array in C code running on the ARM core. From there, they are copied into the FPGA’s RAM for trucking out to the display. The 720×350 images are stored as 1 bit per pixel, and are created by converting the original JPEGs into single-bit bitmaps in GIMP, before final conversion into a C code array via utility of [Ted’s] own design.

If you’ve ever wanted to display your images in resplendent amber or green, then this could be the project for you. It’s also just a great way to learn about using FPGAs and interfacing with alternative display technologies. If you’ve been whipping up your own retro display hacks, don’t hesitate to drop us a line.

DisplayPort: A Better Video Interface

Over the years, we’ve seen a good number of interfaces used for computer monitors, TVs, LCD panels and other all-things-display purposes. We’ve lived through VGA and the large variety of analog interfaces that preceded it, then DVI, HDMI, and at some point, we’ve started getting devices with DisplayPort support. So you might think it’s more of the same. However, I’d like to tell you that you probably should pay more attention to DisplayPort – it’s an interface powerful in a way that we haven’t seen before.

By [Belkin+Abisys], CC BY-SA 3.0
The DisplayPort (shortened as DP) interface was explicitly designed to be a successor to VGA and DVI, originating from the VESA group – an organization created by multiple computer-display-related players in technology space, which has previously brought us a number of smaller-scale computer display standards like EDID, DDC and the well-known VESA mount. Nevertheless, despite the smaller scale of previous standards, DisplayPort has since become a hit in computer display space for a number of reasons, and is more ubiquitous than you might realize.

You could put it this way: DisplayPort has all the capabilities of interfaces like HDMI, but implemented in a better way, without legacy cruft, and with a number of features that take advantage of the DisplayPort’s sturdier architecture. As a result of this, DisplayPort isn’t just in external monitors, but also laptop internal displays, USB-C port display support, docking stations, and Thunderbolt of all flavors. If you own a display-capable docking station for your laptop, be it classic style multi-pin dock or USB-C, DisplayPort is highly likely to be involved, and even your smartphone might just support DisplayPort over USB-C these days. Continue reading “DisplayPort: A Better Video Interface”

Blood Pressure Monitor For Under $1

Medical equipment is not generally known for being inexpensive, with various imaging systems usually weighing in at over a million dollars, and even relatively simpler pieces of technology like digital thermometers, stethoscopes, and pulse oximeters coming in somewhere around $50. As the general pace of technological improvement continues on we expect marginal decreases in costs, but every now and then a revolutionary piece of technology will drop the cost of something like a blood pressure monitor by over an order of magnitude.

Typically a blood pressure monitor involves a cuff that pressurizes against a patient’s arm, and measures the physical pressure of the blood as the heart forces blood through the area restricted by the cuff. But there are some ways to measure blood pressure by proxy, instead of directly. This device, a small piece of plastic with a cost of less than a dollar, attaches to a smartphone near the camera sensor and flashlight. By pressing a finger onto the device, the smartphone uses the flashlight and the camera in tandem to measure subtle changes in the skin, which can be processed in an app to approximate blood pressure.

The developers of this technology note that it’s not a one-to-one substitute for a traditional blood pressure monitor, but it is extremely helpful for those who might not be able to afford a normal monitor and who might otherwise go undiagnosed for high blood pressure. Almost half of adults in the US alone have issues relating to blood pressure, so just getting information at all is the hurdle this device is attempting to overcome. And, we’ll count it as a win any time medical technology becomes more accessible, more inexpensive, or more open-source.

Play DOOM On Seven-Segment Displays

Getting DOOM to run on a computer it was never meant to run on is a fun trope in the world of esoteric retro computers. By now we’ve seen it run on everything from old NES systems to microwaves, treadmills, and basically anything with a computer inside of it. What we don’t often see are the displays themselves being set up specifically to run the classic shooter. This build might run the game itself on ordinary hardware, but the impressive part is that it’s able to be displayed on this seven-segment display.

This build makes extensive use of multiplexers to drive enough seven-segment displays to use as a passable screen. There are 1152 seven segment digits arranged in a 48 by 24 array, powered by a network of daisy-chained MAX7219 chips. A Python script running on a Raspberry Pi correlates actual image data with the digit to be displayed on each of the segments, and the Raspberry Pi sends all of that information out to the screen. The final result is a display that’s fast enough and accurate enough to play DOOM in a truly unique way.

There is much more information available about this project on their project page, and they have made everything open source for those who wish to follow along as well. The project includes more than just the ability to play DOOM, too. There’s a built-in video player and a few arcade programs programmed specifically to make use of this display. Perhaps one day we will also see something like this ported to sixteen-segment displays instead of the more common seven-segment.

Save That Old VGA Monitor From The Trash

It’s quite a while since any of us unpacked a brand new VGA monitor, but since so many machines still have the ability to drive them even through an inexpensive adaptor they’re still something that finds a use. With so many old VGA flat panel monitors being tossed away they even come at the low low price of free, which can’t be argued with. CNXSoft’s [Jean-Luc Aufranc] was tasked with fixing a dead one, and wrote an account of his progress.

Seasoned readers will no doubt be guessing where this story will lead, as when he cracked it open and exposed the PSU board there was the tell-tale puffiness of a failed electrolytic capacitor. For relative pennies a replacement was secured, and the monitor was fixed. As repair hacks go it’s a straightforward one, but still worth remarking because a free monitor is a free monitor.

We called the demise of VGA back in 2016, and have seen no reason to go back on that. But for those of us left with a few legacy monitors it’s worth remembering that DVI and thus the DVI compatibility mode of HDMI is little more than a digitised version of the R, G, and B channels you’d find on that trusty blue connector. Maybe that little dongle doesn’t make such a bad purchase, and of course you can also use it as an SDR if you want.