Robware Software by Rob

Blog

Van Conversion: Part 3 - Slide out step, hookup points, and sound dampening

Slide out step

Whilst I can get in and out of the van without a fuss I understand that it's not so easily accessible to others, and I want it so that people can get in and out with little fuss, so I've fitted a Thule slide out step. I will eventually be hooking it up so it opens and closes with the sliding door. I do have a prototype circuit to control the step, which shows promise.

As an extra usability upgrade I put an LED strip under the front of the step to illuminate the ground underneath.

The LED strip, in aluminium profile, with 3D printed holders
The LED strip, in aluminium profile, with 3D printed holders

I had to drill the step arm to route the cable for the strip
I had to drill the step arm to route the cable for the strip

Routing the cable in the arm means that it'll be protected and kept neat and tidy both in transit and as the step actuates.

![Sealed up to stop water and dirt ingress and to protect the cable from the sharp edges](https:/

Posted on Monday the 8th of February 2021

Read more...

Van Conversion: Part 2 - Holey edition

Pretty much the first proper job on a van is the installation of windows, which means cutting some rather large holes. For my build that consists of 2 roof lights and 3 windows.

Roof lights

I started with the roof lights. First I made some frames. These helped with drawing the cutout as they gave me a rectangle to trace around once I'd made my measurements.

Frames, two of them
Frames, two of them

Front Roof light

Starting measurements
Starting measurements

The morning started off a bit damp, but the forecast was dry. However, it lied and the mizzle slowly came down so...
I put a tent up on the roof
I put a tent up on the roof

This worked out really well, but it means that a lot of the following imagery has a very green hue. I then took a heat gun to the roof to dry it up.
![Cut out measured up](https://uploads.ro

Posted on Monday the 1st of February 2021

Read more...

Van Conversion: Part 1 - Acquisition, Swivel Seats, and Suspension

I bought a van
I bought a van

The plan

My plan is to have something I can securely take mountain bikes and have as much comfort as I can fit in the van. So it needs to be warm, have heating, hot shower, toilet, garage (thus a fixed bed), cooking facilities and a few other bits. I also want to be able to accommodate a decent size social gathering of 6 to 8 people, as well as make it 4 birth.

Here's what I've come up with so far
Here's what I've come up with so far

What you see above isn't the first iteration, and it's not the final one either in all likelihood, but it's very close to what I'm pretty sure will be the final plan.

Main features, from left to right (front to back of van) are:

  • Double seat on the driver's side and single seat on the passenger's. These will expand out to make another bed.
  • Coat storage
  • Shower
  • Kitchen
  • Fixe
Posted on Wednesday the 25th of November 2020

Read more...

3D printing UK road signs

Beware of Sheep
Beware of Sheep

Don't ask me what inspired this, as I have no idea. I'm just going to detail the process on how I got this from an SVG to a 3 colour 3D print using FreeCAD.

It turns out there's a list of UK road signs in SVG format. Simply download whichever sign takes your fancy and follow these steps to make a model using FreeCAD.

Design

First, do the usual and create a new document with a new body. Then go File->Import and select the SVG file, then click on SVG as geometry followed by Select.

Import
Import

SVG as geometry
SVG as geometry

When you import the SVG there may be a whole load of redundant paths. Select and

Posted on Wednesday the 15th of July 2020

Read more...

Git: Ignoring specific lines - prevent personal config being comitted in 3 easy steps!

One of the key things I like to do when setting up a new project for my team is to make it as easy as possible to get up and running. One major facet of this is making sure any local dev config stays local, even if it's part of a deployed config file (as is the case in Umbraco). In this situation you need to be able to ignore or exclude certain lines within git.

Note: I'll be using what I did with Umbraco throughout as a practical example, but the same principles apply to any file.

The three steps

First I created a new bash script, clean-umbraco-config.sh, to clean out the offending content:

#!/bin/sh

sed \
-e 's/<add key="Umbraco.Core.ConfigurationStatus" value=".*" \/>/<add key="Umbraco.Core.ConfigurationStatus" value="" \/>/g' \
-e 's/<add name="umbracoDbDSN" connectionString=".*" providerName=".*" \/>/<add name="umbracoDbDSN" connectionString="" providerName="" \/>/g' \
$1

What this

Posted on Saturday the 14th of March 2020

Read more...

Using Umbraco in a cloud/serverless environment

One of the major drawbacks with Umbraco is the need to manage the config when making a new deployment over an existing one. When you're in a managed environment, such as Azure App Service in my case, you can't log on to a box to do the usual backup/deploy/restore so easily. Also; I don't want to have to do that every time I want to deploy, particularly for a CI environment where multiple developers could be pushing multiple times a day.

So why not just commit the config changes after install, then you don't have to do that, I hear you ask? Well I also don't want to have to delete the install specific config when deploying to a fresh environment, or when a new developer pulls the repo.

To start the process I put in a git clean filter to strip out any install specific config. Now developers won't be able to commit their environment specific config and mess up the deployment. I've described how I did that [here](/blog/view/git-ignoring-specific-lines-prevent-personal-config-being-co

Posted on Friday the 7th of February 2020

Read more...

Startup performance on .NET Core AWS Lambda

When working on a microsevice architecture utilising AWS lambda my team and I were finding that it was taking over 30 seconds to complete our web requests after the service had been idle for a while (AWS kills lambda instances idle for greater than 15 mins). This was a problem for 2 reasons; the lambda function sits behind API gateway which has a timeout of 30 seconds, and it's unacceptable to have a request take that long. We needed to improve this situation and we had two obvious options; stop the lambda from being idle, and improve startup performance.

And with a microservice architecture this is exacerbated because each service you talk to has to go through the startup procedure.

Stopping the idle lambda from dying

There's a common concept among those that have used AWS lambda in the past to serve up sites: warming. This is basically when there is a scheduled job to call the lambda at intervals below 15 minutes in order to keep AWS from killing it. This can either be a se

Posted on Saturday the 25th of January 2020

Read more...

A simple script to update a collection of repositories

When you're dealing with a microservice architecture solution, it's likely you have a lot of small repositories. Keeping them up to date can be a pain, so I wrote a simple script to update each directory:

Bash:

#!/usr/bin/env bash

for f in *; do
	if [ -d "$f" ]; then
		cd $f
		git pull
		cd ..
	fi
done

Batch:

@echo off
FOR /D %%f IN ("*") DO (
	cd %%f
	git pull
	cd ..
)

Pretty basic stuff; just goes in to each directory and does a pull. Saves having to do the same thing yourself. Particularly useful if you've not picked up the project in a while.

Posted on Wednesday the 22nd of January 2020

Read more...

New Year New Website

This site has been a thing of neglect. I've been looking at it from afar thinking about how I should just put it out of its misery. It was written in PHP in a self rolled MVC framework many years ago. At the time I was happy with what I accomplished with it, and I learned a lot from doing it all myself, but it's not aged well.

So I've redone it from the ground up in ASP.NET Core MVC. It uses markdown for the blog entry now instead of my own parser, it includes a list of my 5 most recently worked on projects in the nav, and has a much more basic front end design. I've gotten rid of all the Javascript because I don't really need it. The design is a bit ugly, but I'll get round to investing some more time in it at some point (yeah, right).

I'm hoping with this much simpler setup that I will write down some of the more interesting challenges I've had to overcome and their solutions. There's a few things I've had to do that I wanted to write about, but didn't want to deal with the web

Posted on Friday the 3rd of January 2020

Read more...

Using a JSON string as a configuration source for a .NET Core project

I recently had a project at work that I wanted to pass in a JSON string as a means of configuration. There is a .NET package that will read in a JSON file, but not one to read in a string. So below you will find a set of classes I made to take in a JSON string and parse it in to the application config using the Newtonsoft JSON library.

public static class ConfigurationExtensions
{
	public static IConfigurationBuilder AddJsonString(this IConfigurationBuilder configurationBuilder, string json)
	{
		configurationBuilder.Add(new JsonStringConfigurationSource(json));
		return configurationBuilder;
	}
}

public class JsonStringConfigurationSource : IConfigurationSource
{
	private readonly string _json;

	public JsonStringConfigurationSource(string json) => _json = json;

	public IConfigurationProvider Build(IConfigurationBuilder builder) => new JsonStringConfigurationProvider(_json);
}

public class JsonStringConfigurationProvider : ConfigurationProvider
{
	private readonly string _js
Posted on Wednesday the 3rd of October 2018

Read more...

Previous