Robot Vision: Detecting Obstacles with FPGAs and line lasers

Somewhere down the road, you’ll find that your almighty autonomous robot chassis is going to need some sensor feedback. Otherwise, that next small step down the road may end with a blind leap off the coffee table. The first low-cost sensors we might throw at this problem would be sonars or IR rangefinders, but there’s a problem: those sensors only really provide distance data back from the pinpoint view directly ahead of them.

Rest assured, [Jonathan] wrote in to let us know that he’s got you covered. Combining a line laser, camera, and an FPGA, he’s able to detect obstacles that fall within the field of view of the camera and laser.

If you thought writing algorithms in software is tricky, wait till to you try hardware! (We know: division sucks!) [Jonathan] knows no fear though; he’s performing gradient computation on the FPGA directly to detect the laser in the camera image at a wicked 30 frames-per-second. Why roll up your sleeves and take the hardware route, you might ask? If we took a CPU-based approach at the tiny embedded-robot scale, Jonathan estimates a mere 10 frames-per-second. With an FPGA, we’re able to process images about as fast as they’re received.

Jonathan is using the Logi Board, a Kickstarter success we’ve visited in the past, and all of his code is up on the Githubs. If you crack it open, you’ll also find that many of his modules are Wishbone compliant, so developing your own projects with just some of these parts has been made much easier than trying to rip out useful features from a sea of hairy logic.

With computer-vision hardware keeping such a low profile in the hobbyist community, we’re excited to hear more about [Jonathan’s] FPGA-based robotics endeavors.

Continue reading “Robot Vision: Detecting Obstacles with FPGAs and line lasers”

The Zork Virtual Machine Implemented In Hardware

ZorkHitchhiker’s Guide to the Galaxy, and all the other Infocom text adventures are much more clever than the appear at first glance. They actually run on a virtual machine, with all the code for the game files squirreled away in the Z-machine format. This is great if you’re writing a game for a dozen platforms; once you have an interpreter running on one system, the entire library of games can be shipped out the door.

While the Z-machine has been ported to all the retrocomputers you can imagine and a few different brands of microcontrollers, no one has yet implemented the Z-machine in hardware. There’s a reason for this: it’s crazy. Nevertheless, [Charlie] managed to implement the Z-machine in an FPGA, using only a few extra commands for driving a display.

zork2The circuit is constructed with a $10 eBay special FPGA, the Cyclone II EP2C5. Other than that, it’s just some Flash, some RAM, a display, and a whole lot of wire. The standard Z-machine spec is followed, version 3 specifically, meaning this text adventure on a chip can run nearly every Infocom game ever written. The most popular ones, at least.

This isn’t [Charlie]’s first time in the ring with the Infocom Z-machine. He ported the Z-machine to a freakin’ pen a few years ago.

You can check out [Charlie]’s video demo below. Because there was a bit of extra space in the FPGA, [Charlie] managed to put a Mandelbrot implementation and Space Invaders in as an easter egg.

Continue reading “The Zork Virtual Machine Implemented In Hardware”

Using Cell Phone Screens with any HDMI Interface

Thanks to the worldwide proliferation of smartphones, tiny high-resolution displays are common and cheap. Interfacing these displays with anything besides a phone has been a problem. [twl] has a board that does just that, converting HDMI to something these displays can understand, and providing a framebuffer so these displays can be written to through small microcontrollers.

[twl] is using a rather large FPGA to handle all the conversion from HDMI to the DSI the display understands. He’s using an Xilinx Spartan-6-SLX9, one of the most hobbyist friendly devices that is able to be hand soldered. Also on the board is a little bit of SDRAM for a framebuffer, HDMI input, and a power supply for the LCD and its backlight.

On the things [twl] has in his ‘to-do’ list, porting Doom to run on a cellphone display is obviously right at the top. He also wants to test the drawing commands for the Arduino side of his board, allowing any board with the suffix ~’ino to paint graphics and text on small, cheap, high-resolution displays. That’s a capability that just doesn’t exist with products twice [twl]’s projected BOM, and we can’t wait to see what he comes up with.

You can check out the demo video of [twl]’s board displaying the output of a Raspberry Pi below. If you look very closely, you’ll notice the boot/default screen for the display adapter is the Hackaday Jolly Wrencher.

Continue reading “Using Cell Phone Screens with any HDMI Interface”

Improving the Parallax Propeller in an FPGA

The Parallax Propeller is an interesting chip that doesn’t get a lot of love, but since the entire chip was released as open source, that might be about to change: people are putting this chip inside FPGA and modifying the binaries to give the chip functions that never existed in the original.

Last August, Parallax released the source for the P8X32A, giving anyone with an FPGA board the ability to try out the Prop for their own designs. Since then, a few people have put some time in, cleaning up the files, unscrambling ROM images, fixing bugs, and all the general maintenance that an open source microcontroller core requires.

[Sylwester] has grabbed some of the experimental changes found on the Parallax forum and included them as a branch of the Propeller source. There is support for a second 32-bit port, giving the new chip 64 I/O pins, multiply instructions, video generators, hard-coded SD card libraries, and a variant called a microProp that has four cores instead of eight.

You can grab all the updated sources right here and load them up on a DE0 Nano FPGA board. If you’re exceptionally lucky and have the Altera DE2-115 dev board, you’ll also be able to run the upcoming Propeller 2.

Building a Retro Computer that Never Existed

Sometimes you come across a build so far along you wish you could go back and enjoy it just a bit at a time. This C65 build is so far along, it’s like binge watching a retro computer build. One that never actually existed.

Okay, that’s admittedly a bit rash. But technically the C65 (successor to the Commodore C64) never saw its way through development. A good place to start looking in on the build is from the second post way back in March. The FPGA-based project is already looking promising with proof-of-concept display tests. Are we the only ones surprised by the 1920 native display resolution?

Checking back in June we see that there is some software working but a bounty of bugs will definitely keep [Paul] busy for a while. Fast forward to the beginning of September and he’s come full through to getting a network connection up and running.

The Wikipedia page on the C65 gives a good idea of how awesome this would have been back in the day had it actually made it to market. We suppose it joins the Commodore lists of would-haves and should-haves with the likes of the C128.

FPGA with Open Source Propeller 1 Running Spin


Open Sourcing something doesn’t actually acquire meaning until someone actually uses what has been unleashed in the wild. We’re happy to see a working example of Propeller 1 on an FPGA dev board. That link takes you to a short description and some remapping of the pins to work with a BeMicro CV board. But you’ll want to watch the video below, or rather listen to it, for a bit more explanation of what [Sylwester] did to get this working.

You’ll remember that Parallax released the Propeller 1 as Verilog code a few weeks back. This project first loads the code onto the FPGA, then proves it works by running SIDcog, the Commodore 64 sound emulation program written in Spin for p8x32a processors.

We do find this to be an interesting first step. But we’re still waiting to see what type of hacks are made possible because of the newly available Verilog code. If you have a proof of concept working on other hardware, certainly tell us about it below. If you’ve been hacking on it and have something you want to show off, what are you waiting for?

Continue reading “FPGA with Open Source Propeller 1 Running Spin”

A MIPI DSI Display Shield/HDMI Adapter

MIPI DSI shield

[Tomasz] tipped us about the well documented MIPI DSI Display Shield / HDMI Adapter he put on The Display Serial Interface (DSI) is a high speed packet-based interface for delivering video data to recent LCD/OLED displays. It uses several differential data lanes which frequencies may reach 1 GHz depending on the resolution and frame rate required.

The board explained in the above diagram therefore allows any HDMI content to be played on the DSI-enabled scrap displays you may have lying around. It includes a 32MB DDR memory which serves as a frame buffer, so your “slow” Arduino platform may have enough time to upload the picture you want to display.

The CP2103 does the USB to UART conversion, allowing your computer to configure the display adapter internal settings. The platform is based around the XC6SLX9 Spartan-6 FPGA and all the source code may be downloaded from the official GitHub repository, along with the schematics and gerbers. After the break we’ve embedded a demonstration video in which a Raspi drives an iPhone 4 LCD.

Continue reading “A MIPI DSI Display Shield/HDMI Adapter”