Category Archives: Programming

Adventures with real-time clocks – part 2

The story so far: I’d been tinkering with an MCP795W20 real-time clock (RTC) chip and having a frustrating time of it. Weird things were happening. It seemed very finicky. I’d put part of the problem down to using a breadboard (still think I’m not entirely wrong about that). It turns out, however, that the biggest problem was my own stupidity…. Read more »

A newbie’s introduction to CUPL and CPLDs

When you’re dealing with computer logic, things can get very complicated very fast. This is especially true when it comes to address decoding. You can easily find yourself tangled in a messy web of AND, OR, NAND and NOR gates. And there’s a problem you can run into when stringing together a bunch of logic gates – propagation delay. It… Read more »

Sharing code: at your own risk

      No Comments on Sharing code: at your own risk

Often, when discussing projects on this blog, I share bits of code. Sometimes more than a bit. But I rarely share whole programs or libraries because, well, it’s a pain uploading it and making sure WordPress hasn’t munged characters. And it’s equally difficult to correct errors and keep code updated. Yeah, I know what you’re thinking. “FFS, use GitHub.” And… Read more »

Sharing safely on GitHub: how not to leak passwords

Recently, I found myself wanting to share some code via Github, but realised it contained my wifi password. That’s not a huge issue (see below), but neither is it a good idea. You should never hard-code credentials into your software – in principle. But when you’re hacking together an Internet of Things (IoT) toy for personal use in your own… Read more »

Go or Python for the Raspberry Pi

Pretty much all of the code I’ve written for the Raspberry Pi (and the BeagleBone for that matter) has been in Python. It’s widely regarded as the de facto language for the platform, not least because it is newbie-friendly. But does it have to be this way? Ups and downs of Python It’s not hard to enumerate a long list of… Read more »

Go on Raspberry Pi: simple cross-compiling

Go – or Golang if you prefer – is a powerful programming language, applicable to virtually any platform, from single-board computers (SBCs) such as the Raspberry Pi to supercomputer clusters. I tend to work at the lower end of that scale. And I was motivated to check out Go because it has a reputation for being fast – unlike, say,… Read more »

WordPress & Docker: solving the ERR_EMPTY_RESPONSE problem

Having messed around with Docker for the web app I’m using with my robot, Sheldon, I decided to dig a little deeper. Well, that’s probably overstating it. What I actually did was follow along with one of the videos from Traversy Media which explains how to create a Docker container to run a WordPress site. Here it is. It’s the… Read more »

Raspberry Pi: creating a cross-development environment for ARM

So here’s a confession: I hate make files. And I’m really not all that keen on the whole compilation thing, with all those flags and whatnot. Why? Because I’m lazy. But of late I’ve felt myself drawn back to C++. There is something about the language that both appeals to me and repulses me. Mostly those make files. So this… Read more »