An Open Source Toolchain For iCE40 FPGAs

FPGAs are great, but open source they are not. All the players in FPGA land have their own proprietary tools for creating bitstream files, and synthesizing the HDL of your choice for any FPGA usually means agreeing to terms and conditions that nobody reads.

After months of work, and based on the previous work of [Clifford Wolf] and [Mathias Lasser], [Cotton Seed] has released a fully open source Verilog to bitstream development tool chain for the Lattice iCE40LP with support for more devices in the works.

Last March, we saw the reverse engineering of the Lattice ICE40 bitstream, but this is a far cry from a robust, mature development platform. Along with Yosys, also written by [Clifford Wolf] it’s relatively simple to go from Verilog to an FPGA that runs your own code.

Video demo below, and there’s a ton of documentation over on the Project IceStorm project page. You can pick up the relevant dev board for about $22 as well.

Continue reading “An Open Source Toolchain For iCE40 FPGAs”

[Tesla500] Builds a High-Speed Video Camera

[Tesla500] has a passion for high-speed photography. Unfortunately, costs for high-speed video cameras like the Phantom Flex run into the tens or even hundreds of thousands of dollars. When tools are too expensive, you do the only thing you can – you build your own! [Tesla500’s] HSC768 is named for the data transfer rate of its image sensor. 768 megapixels per second translates to about 960MB/s due to the 10 bit pixel format used by the On Semiconductor Lupa1300-2 image sensor.

This is actually [Tesla500’s] second high-speed camera, the first was HSC80, based upon the much slower Lupa300 sensor. HSC80 did work, but it was tied to an FPGA devboard and controlled by a PC. [Tesla500’s] experience really shows in this second effort, as HSC768 is a complete portable system running Linux with a QT based GUI and a touchscreen. A 3D printed case gives the camera that familiar DSLR/MILC  shape we’ve all come to know and love.

The processor is a Texas Instruments TMS320DM8148 DaVinci, running TI’s customized build of Linux. The DaVinci controls most of the mundane things like the GUI, trigger I/O, SD card and SATA interfaces. The real magic is the high-speed image acquisition, which is all handled by the FPGA. High-speed image acquisition demands high-speed memory, and a lot of it! Thankfully, desktop computers have given us large, high-speed DDR3 ram modules. However, when it came time to design the camera, [Tesla500] found that neither Xilinx nor Altera had a FPGA under $1000 USD with DDR3 module support. Sure, they will support individual DDR3 chips, but costs are much higher when dealing with chips. Lattice did have a low-cost FPGA with the features [Tesla500] needed, so a Lattice ECP3 series chip went into the camera.

The final result looks well worth all the effort [Tesla500] has put into this project. The HSC768 is capable of taking SXGA (1280×1024) videos at 500 frames per second, or 800×600 gray·scale images at the 1200 frames per second. Lower resolutions allow for even higher frame rates.  [Tesla500] has even used the camera to analyze a strange air oscillation he was having in his pneumatic hand dryer.  Click past the break for an overview video of the camera, and the hand dryer video. Both contain some stunning high-speed sequences!

Continue reading “[Tesla500] Builds a High-Speed Video Camera”

Hacklet 28 – Programmable Logic Hacks

FPGAs, CPLDs, PALs, and GALs, Oh My! This week’s Hacklet focuses on some of the best Programmable Logic projects on! Programmable logic devices tend to have a steep learning curve.  Not only is a new hacker learning complex parts, but there are entire new languages to learn – like VHDL or Verilog. Taking the plunge and jumping in to programmable logic is well worth it though. High-speed projects which would be impossible with microcontrollers are suddenly within reach!

fpga-hdmiA great example of this is [Tom McLeod’s] Cheap FPGA-based HDMI Experimenting Board. [Tom’s] goal was to create a board which could output 720p video via HDMI at a reasonable frame rate. He’s using a Xilinx Spartan 6 chip to do it, along with a handful of support components. The images will be stored on an SD card. [Tom] is hoping to do some video with the setup as well, but he has yet to see if the chip will be fast enough to handle video decoding while generating the HDMI data stream. [Tom] has been quiet on this project for a few months – so we’re hoping that either he will see this post and send an update, or that someone will pick up his source files and continue the project!

ardufpgaNext up is our own [technolomaniac] with his Arduino-Compatible FPGA Shield. Starting out with FPGAs can be difficult. [Technolomaniac] has made it a bit easier with this shield. Originally started as a project on .io and now available in The Hackaday Store, the shield features a Xilinx Spartan 6 FPGA. [Technolomaniac] made power and interfacing easy by including regulators and level shifters to keep the sensitive FPGA happy. Not sure where to start? Check out [Mike Szczys’] Spartan-6 FPGA Hello World! [Mike] takes us from installing Xilinx’s free tool chain to getting a “hello world” led blinker running!

lander3Still interested in learning about Programmable Logic, but not sure where to go? Check out [Bruce Land’s] Teaching FPGA parallel computing. Actually, check out everything [Bruce] has done on – the man is a living legend, and a wealth of information on electronics and embedded systems. Being a professor of engineering at New York’s Cornell University doesn’t hurt either! In Teaching FPGA parallel computing, [Bruce] links to Cornell’s ECE 5760 class, which he instructs. The class uses an Altera/Terasic DE2 FPGA board to demonstrate parallel computing using programmable logic devices. Note that [Bruce] teaches this class using Verilog, so all you seasoned VHDL folks still can learn something new!


chamFinally, we have [Michael A. Morris] with Chameleon. Chameleon is an Arduino compatible FPGA board with a Xilinx Spartan 3A FPGA on-board. [Michael] designed Chameleon for two major purposes:  soft-core processors, and intelligent serial communications interface. On the processor side Chameleon really shines. [Michael] has implemented a 6502 core in his design. This means that it would be right at home as the core of a retrocomputing project. [Michael] is still hard at work on Chameleon, he’s recently gotten fig-FORTH 1.0 running! Nice work [Michael]!

Want more programmable logic goodness? Check out our Programmable Logic List!

That about wraps things up for this episode of The Hacklet! As always, see you next week. Same hack time, same hack channel, bringing you the best of!

Introducing the FleaFPGA Experimenter’s Board

[Valentin] recently tipped us about an FPGA development board he just finished. It is called the FleaFPGA and is aimed to get people interested in the world of Field Programmable Gate Arrays. One of the other reasons that also got [Valentin] to design his own board was that he was frustrated with the existing solutions, them being either too pricey or fairly spare in terms of connectivity.

The main components that you can see in the platform shown above are: a lattice MachX02-7000HE FPGA (6864LUTs), 256Mbits of SDRAM, a USB2.0 host port, a 4096-color VGA connector, a 3.5mm stereo connector, an SD/MMC card slot, a PS/2 keyboard/mouse combo port, a few push buttons and LEDs. An expansion header is also present in order to connect the FleaFPGA to future shields that will be developed. Unfortunately only the board schematics have been released and [Valentin] is currently aiming for a price of $60 per board for <100 quantities. You’ll be able to see a video of the board in action after the break, in which the FPGA has been loaded with a 68000 software core running a variation of the Amiga Juggler Demo.

Continue reading “Introducing the FleaFPGA Experimenter’s Board”