Configuring the Lattice ECP5 PLL

The Lattice ECP5 is a capable little FPGA, and has good support for open-source synthesis through the Yosys EDA toolchain. However, information on the details of configuring the FPGA’s builtin PLL clocks is a little thin on the ground. I’m going to try and help a little bit with that here. The ECP5 chip contains a handful of PLL modules. Each one takes a clock signal in, and can derive up to 4 output clocks of higher or lower frequency, with customizable phase offsets and a few other tuning knobs.

TAI64 in the wild is (sometimes) not TAI

The very short version of the clickbait title: if you create TAI64 timestamps and your implementation mimics libtai, then your timestamps are likely not TAI. The rest of this post is an explanation of what’s going on.

Finding the Bottom Turtle

If you’ve never read the classic Reflections on Trusting Trust, and you like the idea of being unsettled about the foundations of computing, go have a read. It’s amazing. It details the strange reality that we can’t truly trust most of the software we use today. Over time, the ideas from that speech evolved into an important question for open-source software: do we know for sure that the programs we’re running correspond to the source code we have access to?

Getting started with FPGA hacking

I recently got a ULX3S FPGA board, and have been playing with it. This post will be a short introduction to getting a fully OSS toolchain up and running to develop for this board, using the Bluespec programming language and the Yosys ecosystem of synthesis and programming tools. The ULX3S is a great little hacking board. Its centerpiece is a Lattice ECP5 FPGA, a very featureful little FPGA. The board has a bunch of interesting peripherals hooked up to the FPGA: a USB port, an HDMI port, some DRAM, and of course the obligatory buttons and LEDs.

Fun with IP address parsing

In my quest to write a fast IPv4+6 parser, I wrote a slow-but-I-think-correct parser, to use as a base of comparison. In doing so, I discovered more cursed IP address representations that I was previously unaware of. Let’s explore together!

A better Kubernetes, from the ground up

Recently I had a chat with the excellent Vallery Lancey, about Kubernetes. Specifically, what we would do differently if we built something new, from the ground up, with no regard for compatibility with Kubernetes. I found that conversation so stimulating that I feel the need to write things down, so here we are.

Building a NAS, Part 4: Assembly!

In parts one, two and three, we went from requirements to a honking big Ebay order of various computer parts. Well, they’ve all arrived, and so it’s time to put our machine together.

Building a NAS, Part 3: Finding and buying parts

In parts one and two we went from a list of requirements to a set of constraints on the hardware we’ll need to buy. In this part, we take to Ebay and turn those vague ideas into a concrete parts list!

Building a NAS, Part 2: Storage napkin math

In part one we got together some requirements, and got a rough idea of the kind of server we’re thinking about. Now it’s time for some napkin math to work out some minimum hardware specs related to the storage on the box.

Building a NAS, Part 1: Requirements

A friend would like a new NAS, with a combo of features and performance that would normally place them in the $10k+ range for enterprise grade storage. I offered to see what I could do with hardware from Ebay, and I figured I’d write down my thought process for this kind of thing, in case it’s of use to other homelab shoppers.