## Static Website with Pandoc

I needed to pull off a quick website that would have various mathematics questions, and thought to try and use pandoc. Here are my learnings:

I first installed pandoc-bin because I didn't to deal with a lot of haskell dependencies.

yay -S pandoc-bin


The first iteration I made generated an …

## Comment System Using Recursive Queries

I was reading SQL antipatterns and got into the chapter about recursive queries and how there are different ways to approach this. I wanted to experiment with this and found that postgresql supports recursive queries. I decided to make a simple commenting database and see how it would work.

## Copying Pass Secrets to Another Machine

I had a new laptop but couldn't access my previous one, so I had to figure out how to get my pass secrets. I had these problems:

• How would I get my old password store?
• How would I be able get my old gpg keys into this new laptop?
• I …

## Setting up Hspec on a Haskell Project

I'd started the Kindle-Highlights project without tests. This was a problem because I couldn't add features as fast as I wanted because I'd break something without knowing. I needed to add tests to speed up my development. For haskell, hspec is a tool/library for this. Setting this up on …

## Control: Controllability and Observability

The state space equations are given by:

\begin{align*} x'(t) = Ax(t) + Bu(t)\\ y(t) = Cx(t) + Du(t) \end{align*}

If we discretize the system, the equation can be written as:

\begin{align*} x(n+1) = A_dx(n) + B_du(n)\\ y(n) = C_dx(n …

## System Clock Prescalers and Their Hazards

One means of saving power with the attiny13A is by slowing down the clock frequency of the microcontroller. One option of doing this is by using the system clock prescaler. The attiny13A is shipped with running on a 9.6MHz internal RC Oscillator. It has the CKDIV8 fuse set (which …

## Prepare Kicad PCB for Elecrow Production

Before designing the PCB, set the following design rules:

• Minimum PCB Track : greater than 0.2mm
• Minimum Track /Vias space: greater than 0.2mm
• Minimum pads space: greater than 0.2mm

The defaults provided by Kicad are OK, so no need to change them unless you have some special requirements …

## Scrolling Text With 5*4 LED Array

I usually see lights in Nairobi scrolling text from right to left. It is an interesting thing to see, and if done right is usually beautiful. I wanted to make one, and so this is how I went about it.

## Multiplexing LEDs

To light and LED one needs 5V supplied …

## Disabling Blanking in Raspberry Pi

Blanking is whereby a screen just goes blank (i.e. black screen). This usually happens after some time of no usage on the raspberry pi which is about 15 minutes. This can sometimes become frustrating especially if it is a screen set up for monitoring something.

So to disable it …

## Setting Up Raspberry Pi

The raspberry pi is a mini computer with GPIO pins that can be used to interface with various sensors and actuators. More information of the raspberry pi can be found here

The SD card should be of a size greater than 4GB, especially if you want to install Raspbian Jesse …