Edinburgh Loop

I've been meaning to figure out a loop like this for a while.

It's mostly off-road, with a bit of quiet back roads and a couple of tiny sections of busy roads.
The first half (if going clockwise, starting in Edinburgh) is mostly tarmac cycle paths joining the towns surrounding Edinburgh.
Then it heads into and through the Pentlands, before making it's way back into town on sections of off-road paths (avoiding the canal).

I needed to bed in some ice spike tyres which needed 40km on tarmac before riding properly, so it was the perfect ride for this.
Indeed later parts of the route were covered in black/sheet ice and would have been near impossible without having ice tyres.

The 'dog leg' at Penicuik was me missing the turn off I should have taken. Although I'll probably re-ride the route coming back into the Pentlands further West as some point. Also, if you zoom into the map at this point, it looks like there is a possible path which avoids the short road section.

GPX file: