Driving a 7 Segment LED Display From An FT232

Sometimes, a good hack is about using less rather than more. That’s the case with this neat tutorial from [Rahul.S] on driving a 7-segment LED display with an FT232. By using this cheap USB to serial controller, [Rahul.S] was able to drive the display directly without using a microcontroller, which keeps the component cost down.

He’s bit banging an octal buffer connected to the display. You may be surprised to find that the FT232 chips do have enough outputs to make this work. Rather than send serial data number to the display and have a controller convert this into a set of signals that make the number, this conversion is done by the PC, which then sends a signal that directly illuminates the appropriate parts of the LED. By using all of the available output lines of the FT232 (including ones like the RTS/CTS line that are usually used for signalling), [Rahul.S] was able to drive all seven of the elements and the decimal point.

Of course, cynics may argue that it would be simpler to use a cheap serial LCD display. That is true, but there is always something to be said for knowing how to do something yourself rather than letting others do it for you… Continue reading “Driving a 7 Segment LED Display From An FT232”

Polarization Camera Views the Invisible

Light polarization is an interesting phenomenon that is extremely useful in many situations… but human eyes are blind to detecting any polarization. Luckily, [David] has built a polarization-sensitive camera using a Raspberry Pi and a few off-the-shelf components that allows anyone to view polarization. [David] lists the applications as:

A polarimetric imager to detect invisible pollutants, locate landmines, identify cancerous tissues, and maybe even observe cloaked UFOs!

The build uses a standard Raspberry Pi 2 and a 5 megapixel camera which sits behind a software-controlled electro-optic polarization modulator that was scavenged from an auto-darkening welding mask. The mask is essentially a specialized LCD screen, which is easily electronically controlled. [David] whipped up some scripts on the Pi that control the screen, which is how the camera is able to view various polarizations of light. Since the polarization modulator is software-controlled, light from essentially any angle can be analyzed in any way via the computer.

There is a huge amount of information about this project on the project site, as well as on the project’s official blog. There have been other projects that use polarized light for specific applications, but this is the first we’ve seen of a software-controlled polarizing camera intended for general use that could be made by pretty much anyone.

The 2015 Hackaday Prize is sponsored by:

Trick Google Used Hides Secret Messages on LCD Screens

[Travis] didn’t get picked to go to Google I/O this year, but he did have some I/O inspired fun after the fact. His friends who did go told him about specially modified LCD screens Google had scattered around the event. The screens showed normal show information when viewed with the naked eye. When viewed through a special transparent badge included with the I/O swag though, a URL for Google’s scavenger hunt would magically appear. [Travis] was intrigued by the effect, and became hell-bent on reproducing it himself.

[dual-lcd-3Travis] figured out the transparent badge was actually a polarizing filter. Every standard LCD has two of them, usually bonded to the glass of the LCD itself. If you remove the filters from a LCD, you’ll get a prime view of the backlight – unless you’re wearing polarizing glasses of course. Google’s monitors didn’t have that effect though. They showed a full color display, with a second full color hidden display only visible through the polarizer. [Travis] is intelligent and experienced, so it only took a bit of three-dimensional thinking for him to figure out Google’s trick. There are actually two LCDs used in the display. The first is a standard LCD with backlight. The trick is to strip the polarizing film off a second LCD and place it in front of the first. The second LCD will be invisible to anyone – without the polarizer.

[Travis] quickly set about replicating the display using several obsolete VGA LCDs. He quickly found that the hard part was peeling the polarizing plastic from the thin glass LCD sandwich. Several LCDs gave up their lives in the effort, but in the end [Travis] was successful. He made everything fit in one case by using a thin LED backlight in a case designed for a monitor with a Cold Cathode Fluorescent Lamp (CCFL).  The result looks exactly like a standard LCD – that is, until viewed through a polarizing filter. Click past the break to see the hidden message LCD in action!

Continue reading “Trick Google Used Hides Secret Messages on LCD Screens”

Virtual LCD Using Python

[Prashant Mohta] got hold of a Raspberry Pi, a 16×2 LCD display and got down to writing a simple game in Python. Pretty soon, he realized that it was cumbersome to have the Ras-Pi and LCD connected when all he wanted to do was write the code. So he wrote a simple Python module which renders the LCD on his computer display. A simple, quick, useful hack.

[Prashant]’s code relies on the use of Pygame, a set of Python modules designed for writing games. His code uses just two functions – one to define the LCD (characters and number of lines) while the other draws the characters on the screen by looking up an array. The code is just under 20 lines and available from his Github repo. It will be useful to those who are getting started on Python to help them understand some basics. Python is awesome and writing Python code is pretty simple.

This might draw some flak from the naysayers so if you’re commenting below on the merits, or not, of Python, just keep your comments civil and healthy. In the video below, unrelated to this hack, [Raymond Hettinger] talks about “What makes Python so Awesome”!

Continue reading “Virtual LCD Using Python”

Optimizing AVR LCD Libraries

A while ago, [Paul Stoffregen], the creator of the Teensy family of microcontrollers dug into the most popular Arduino library for driving TFT LCDs. The Teensy isn’t an Arduino – it’s much faster – but [Paul]’s library does everything more efficiently.

Even when using a standard Arduino, there are still speed and efficiency gains to be made when driving a TFT. [Xark] recently released his re-mix of the Adafruit GFX library and LCD drivers. It’s several times faster than the Adafruit library, so just in case you haven’t moved on the Teensy platform yet, this is the way to use one of these repurposed cell phone displays.

After reading about [Paul]’s experience with improving the TFT library for the Teensy, [Xark] grabbed an Arduino, an LCD, and an Open Workbench Logic Sniffer to see where the inefficiencies in the Adafruit library were. These displays are driven via SPI, where the clock signal goes low for every byte shifted out over the data line. With the Adafruit library, there was a lot of wasted time in between each clock signal, and with the right code the performance could be improved dramatically.

The writeup on how [Xark] improved the code for these displays is fantastic, and the results are impressive; he can fill a screen with pixels at about 13FPS, making games that don’t redraw too much of the screen at any one time a real possibility.

Mimimalist Arduino Gaming Platform

A pretty color LCD screen, an Arduino, a buzzer and a joystick is all you need for a minimalist gaming console for under $20. At least, that’s all [João Vilaça] needed to get this sweet version of Tetris up and running. He’s working on Breakout right now. His Breakout looks even better. See the postscript below for details.

It’s a testament to the current state of the hardware hacking scene that [João] could put this device together in an afternoon for so cheap, presumably after waiting a while for shipments from China. The 320×240 SPI color TFT LCD screen used to cost twice as much as this whole project did. And wiring it up is a simple matter of connecting this pin to that pin. Almost child’s play.

Equally impressive is the state of open source software. A TFT library from Seeed Studios makes the screen interface a piece of cake. [João] wrote his own sound and joystick code, and of course the Tetris gameplay itself, but it’d be much more than a few weeks’ work without standing on the shoulders of giants. Check out [João]’s Github for the project code and stick with us after the break for a demo video and some of our other favorite Arduino gaming hacks.

Continue reading “Mimimalist Arduino Gaming Platform”

Excruciating Quest Turns Chromebook Pixel IPS Into Exquisite Extra Monitor

[Shen] wanted an extra monitor at his desk, but not just any monitor. He wanted something particularly special and unquestionably refined. Like any super-power-possessing engineer he set out to scratch his hacking itch and was sucked into a multi-year extravaganza. For the love of everything hardware we’re glad this one came in on the weekend. If we had spent all that time drooling during a weekday we’d be so far behind.

The final product is a desktop monitor on an articulated arm. It features a Chromebook Pixel’s IPS display in a custom-crafted case everything. The journey started out with two different LCD units, the first from a Dell L502x replacement display using a generic LVDS board. The results were meh; washed out colors and obvious pixellation, with display adjustments that left [Shen] with a grimace on his mug. Installment two was an iPad Retina display. This iteration required spinning his own boards (resulting in [Shen’s] discovery of OSH Park). Alas, 9.7″ was too small coupled with short-cable-requirements making this version a no-go.

chromebook-pixel-ips-driver-boardAnd so we arrive at the meat and potatoes of this one. [Shen] identified the IPS LCD display on Google’s first Chromebook Pixel laptop as the object of his desire. The hack takes him through sourcing custom display cables, spinning rev after rev of his own board, and following Alice down the rabbit hole of mechanical design. Nothing marginal is good enough for [Shen], we discovered this with his project to get real audio out of a computer. He grinds away at the driver board, the case design, the control presentation, and everything else in the project until perfection was reached. This work of art will stand the test of time as a life fixture and not just an unappreciated workhorse.

This one is not to me missed. Head over to [Shen’s] project entry on Hackaday.io (don’t forget to give him a skull for this) and his blog linked at the top. We need to celebrate not only the people who can pull off such amazing work. But also the ones who do such a great job of sharing the story both for our enjoyment, and to inspire us.