Shrinking mbed binaries

I'm currently working on a 1wire library for mbed, so that 1wire devices can be implemented on mbed compatible microcontrollers (really, just STM32 for now).

One of the things that would be really useful is to be able to update the firmware of these devices over the 1wire bus, so that they don't need to be decomissioned for updates.

Jenkins GroovyAxis - basing an axis on the content of the build

It took me a while to figure this one out, the docs online were pretty thin, so I'm putting this here to help the next person who gets stuck.

There are 2 tricks here.

  1. It's not clear how to get the workspace in GroovyAxis. It has to be accessed through the 'context' object, but is null when the script is run when the job is saved. It is populated when the job is built.
  2. The workspace exists on the slave node, but the Groovy script is run on the master. You must use the FilePath object to correctly access the files on the slave

 

Creating a Ubuntu 14.04.4 Docker image for Power PC

I also needed a ubuntu image. Creating this was for less painful than the Fedora image:

  • curl -o debootstrap.sh     https://raw.githubusercontent.com/docker/docker/master/contrib/mkimage/debootstrap
  • chmod 755 debootstrap.sh
  • sudo ./debootstrap.sh ubuntu --components=main,universe trusty
  • sudo tar -C ubuntu -c . | docker import - ubuntu:14.04.4
  • docker tag ubuntu:14.04.4-new ubuntu:14.04

Creating a Fedora 23 base Docker Image for Power PC

Docker is a great way to fully describe and implement an installed Linux environment, and we make use of it at work as part of our continuous integration system to provide a clean environment for the jobs that we run.Unfortunately, the main public repo (docker.io) currently only contains images for x64, so if you want a different architecture, you may need to build it yourself.

In this situation, I required a Fedora 23 image on Power PC. I started with a working Fedora 23 in PowerKVM.

The problems I had to address:

Getting OpenWRT onto the DLink DIR-865L AC1750 Router

A while ago I got hold of a couple of DLink DIR-865L AC1750 802.11ac routers as there was a generous cashback offer.

I was originally using it as a glorified access point, but since updating my main router to carve off a variety of ethernet segments for home automation, guest networks, etc, I wanted to expose these as different wifi networks, using the DIR-865L units to extend the wifi network, with ethernet backhaul to the main router.

To get OpenWRT onto the router (where the router's IP is 10.0.1.200 and the tftp server is 10.0.1.16):

Accessing Port Forwarded Servers on a DLink DSL-2740B rev C2 (Local Loopback)

I just replaced my Asus DSL-N13 with a new DLink DSL-2740B ADSL modem as the Asus unit would not allow me to access servers (such as mail servers) that are hosted on my local network and port forwarded from the router, when the computer attempting the connection is also within the local network.

Imagine my dismay when the new router had a similar web interface, and exhibited the same problem!

Arduino based Switchmode Voltage Regulator

In order to minimize component count, stocked items in my junk box, and to improve efficiency as well as have software control of the power supply, I wanted to do away with inefficient, standalone linear regulators and instead use spare PWM pins on the microcontroller to generate voltages instead.

This library creates a simple feedback loop, where you specify the target voltage, and the microcontroller alters the PWM duty cycle to create the requested voltages.

Subscribe to