Using the iCEBreaker with an Open Source FPGA toolchain on OS X



When I used FPGAs in the past, e.g. for my LED Display, I was using Xilinx FPGAs with their proprietary software which unfortunately runs only under Windows or Linux. This was very inconvenient and in addition the software was slow as hell.

Fortunately a new era has begun: Open-Source FPGA toolchains! It was started some time back by Clifford Wolf, who first wrote a synthesis tool called Yosys and later reverse-engineered the bitstream format for Lattice iCE-40 FPGAs. Recently a new place-and-route tool called nextpnr was developed as well. Continue reading

BeagleBone Black

For my recent electronics projects I wanted something more powerful than the usual Atmel megaAVR or AVR XMEGA microcontrollers I used in the past. The obvious step upwards in performance is some embedded system running Linux. A few years ago I played a little bit with an ALIX.3D3 embedded board, but nowadays most people would start with a Raspberry Pi and I also used to have an early model of those as well. Even though the Raspberry Pi seems to be everywhere there is a better alternative in my view: The BeagleBone Black. The most obvious advantage of the the Raspberry Pi (even compared to the Model B) is the much high flexibility concerning I/O. Most important it provides with its general-purpose memory controller (GPMC) a high-bandwidth parallel memory interface which is ideal for a fast interconnection e.g. with FPGAs.
Continue reading

My first iOS app – hue⁺

When I first heard of Philips hue I really liked the idea of controllable LED bulbs. I googled a little bit to understand how it works and finally found out the it is based on ZigBee Light Link. So I had the idea to buy one of these starter kits and build some AVR based controller for them on which I wanted to implement the protocol myself. On the embedded world 2013 in Nürnberg I even found some non-Philips stuff from Dresden Elektronik that was compatible to ZigBee Light Link. So I bought a ZigBee Sniffer from Dresden Elektronik and some XBee ZB modules and was ready to start. Continue reading

Non-uniform distributed random numbers

Creating non-uniform distrubed random numbers is not straightforward. Usally programming languages like C provide functions like rand() which returns an integer random number between 0 and RAND_MAX or drand48() with returns a double random number between 0 and 1. The numbers returned by these functions are uniform distributed meaning that if you run them very often you get each number by the same amount.
If you want random numbers in other ranges, these can be rescaled easily. For example, if you need integer random numbers between 1 and 10 you simply could get a random number x from rand() and apply the function \(f(x) = 1 + 9 \cdot x\) to it.

But what if you want to distribute them in a non-uniform way? Continue reading

Tune Terminal in OS X Lion

If your are using terminals on other operatings systems than OS X on a daily basis, you might have noticed that the Terminal App behaves a little bit different in some aspects. When I installed my iMac a year ago I needed some time to adopt everything to my needs. Yesterday, I received my new MacBook Air running OS X Lion and when I tried to get everything like on my iMac I found some things which changed in Lion. So I decided to write a small post about my Terminal tweaks. Continue reading