Adventures In Emulation

Posted on

I'm writing an emulator, a bit of a way through and thought I'd write keep a development log of what I'm doing. First let's have a look at what I'm emulating, an early eighties Williams arcade game sound board.

I love William's arcade machines, in the early eighties these rock hard assault on the senses were utterly unlike everything else in the arcades and a beautiful blend of incredibly tasteful design decisions coupled with stone cold technical precision. Defender, Stargate, Robotron, all works of a team at the top of their game.

And in particular the audio is truly wonderful. Written by Eugene Jarvis the audio system lives on it's own board and the most mature aspect of the early Williams titles having been created for their pin tables a few years before. This is the little beauty:

So what is It

So how does it make those amazing sounds? Well it's a separate little single board computer around a Motorola 6808. It doesn't have any specific hardware but just a DAC to pump samples out of:

wms sound board

  • 4K ROM - SFX code
  • 128 bytes RAM - temp store
  • 800khz 6808 - CPu
  • 6820 PIA - IO to main game + DAC

That's pretty sweet but with only 4K of ROM there's no space to store any samples. There's not really enough space for small wavetables. So instead of playing samples it just makes them up as it goes along. The ROM has a bunch of little programs in that store values to the DAC as fast as they can. Simples.

So it's a simple system and a good one to start with for a nascent emulator coder like myself :)


Happy with last week

Posted on

Hey! It's Monday and I'm feeling pretty chipper. Which I'm pretty happy about after managing to squeeze out 30km last week. Yesterday I did a slow 15km in Tentsmuir as planned in some slightly damp bit refreshing weather. The run went well, wasn't too knackered after but spent the afternoon feeling pretty nauseous. A couple of home made scotch eggs in the evening seem to fix me. Result.

All of that aside my legs feel good, practically no hamstrinng or calf niggles and a great ride into work this morning. I'd like to get another 30km under my belt this week but would settle for 25. I really don't want to pick any injuries so I'm listening to my body a bit more than I did last year :)

Running. Again.

Posted on

Last time on I was in the middle of a training program with the aim of upping my time and pace. Which it did! And also gave me a horrible bit of hamstring trouble. Completely my fault for an overly ambitious increase in distance and effort while being, quite frankly, a bit old.

So I haven't written here for a while but right now? I'm in the middle of a mini-renaissance and quite enjoying a bit of running again.

I'm still carrying some niggles on my hamstring it still twinges a bit. However a switch from the Nike Free Run's I usually run in to the lower drop New Balance Minimus Trail seems to have helped a lot. I've done 15km this week so far and the shoes seem to have traded hamstring ache for calve ache. And I can deal with that. It's happened every time I've gone back onto zero drop shoes and soon goes away with a bit of perseverance.

The runs have been good too. Even the slow times in near storms of a few weeks back put a grin on my face and hopefully helped build back some base stamina.

I feel incredibly lucky to be able to run in this part of the world. Recently I added Tentsmuir Forest to the small set of routes I use and it's been lovely ambling through am amazing pine forest sitting on the edge of the Tay. And even when the weather isn't all that helpful, which is quite often, it's impossible not end up with a massive grin after battling through the elements.

Aiming for a long slow, 10 miler this weekend which will bring me up to 30km for the week.

Run 4

Posted on

Today's aim was a long slow run after a Monday's rest up. It wasn't great to be honest. I hit the slower pace I'd been aiming for but as much as I'd like to claim a win for increased discipline it was mostly down to some horrible hamstring ache.

Ow. Really hoping this calms down by Thursday for intervals. It's a harder schedule than last week so I'm toying with the idea of delaying by a day if the arse ache continues.

More positively I got to try out the bold claims of my running socks wet weather performance. They promised to wick away any moisture and keep my toes in fine fettle. And do you know what? They did. Three cheers for the FEETURES HIGH PERFORMANCE LIGHT CUSHION running socks.

Run 3

Posted on

Run 3

Long, slow run in Tentsmuir and it was pretty nice. I like running here, it's mostly in shade and even when the sun's out there's little to no chance of overheating. I got 13km in and would probably classify this as a partial success.

Let's start with the bad. I should have gone a bit slower. Easy / long runs for my current race pace should be around 5:50 m/km but I went faster than that. And also I didn't got for as far as I'd wanted having started out with the idea of doing 14km in all.

The good though; I managed to slow down a bit after an overly enthusiastic start and tried to push a bit harder on the tenth kilometer and found 5:18 m/km. But that fucked me :D

And the very bad: didn't feel too bad after but a few days later I now have a hamstring strain. Ow.

Overall though 30km running for the week and I feel pretty good. Next week should be about the same.

Run 2

Posted on

Okay, about to Fartlek. Key points are:

  • Don't push hard on warm up
  • Try and stick to plan
  • Don't worry if I can't, it's my first go
  • Enjoy warm down

And now I am back, having fartlekked. After 20 minutes of a slow, warm up jog I did 8 sets of a minute fast running followed by a minute recovery. And then a gentle warm down of 15 minutes.

I had a fair bit of trepidation before kicking off but despite that it was really good; all of the 1 minutes sprints came in well under an average pace of 5 minutes per km and the at 5:27 minutes per kilometer not a completely awful pace for near the near 10km covered. I even scored a PB on one segment despite the weird slow down / speed up pacing. Great :)

Next week's fartlek session is a bit more demanding, the speed sections are double the length at 2 minutes but still with a minute recovery between them. Again some trepidation but hopefully unfounded again :)

Run 1

Posted on

Oh well. Let's see if I can break the fifty minute barrier 10km this year. This is day one of an 8 week program that I got off of Strava.

Starting nice and easy with a 30 - 40 minute Easy Run. What's that then? According to McMillan's pace calculator I that should be ~ 5:50 minutes per kilometer. The run was definitely easy and pretty nice too as I managed to get out just before sun rise to run alongside Monifieth beach down by the Tay. A bit nippy out and thanks to some bad wardrobe planning I went our wearing mis-matched gloves. Luckily the few people out and about that time of day didn't mind the fashion transgression.

Run for just over 6km as the sun rose through the mist and overall came in at 5:20 minutes per kilometer. It's too fast though my splits were fairly even. I need to work on dialing in a pace and sticking to it. Next up fartleks on Wednesday. I hate Fartleks though pace management will be a lot easier, just run as fast as I can for a bit :D Going to have a go at programming in a training plan to the watch to help me.


Posted on

Yeah all right mum

Time for another fad diet! I'm 3 years into low carbohydrate eating and on the whole it's been great; lost a load of weight, gave energy to exercise and blunted the majority of type 2 diabetes risks.

That's been great but I need a new project. One of the downsides is that despite losing a lot of weight I'm a bit skinny fat; slim but carrying more midriff weight than I'd like and a little punier than I'd prefer. And I probably weigh a little more than I'd like. I think my body has got pretty efficient running under low carbohydrate regimen and after hitting a low of 11st 12lb in the early days I'm settled at around 13st. For 6'2" that's okay and huge improvement over the heady heights of 17st but my I'm not hitting my goals. I'd like are a bit more muscle mass (particularly in the core area), lose some fat to get a little lighter and ultimately have a better build for running / cycling.

So time to try something new and this time it's Carb Nite; an ultra low carbohydrate (ULC) diet punctuated with weekly carbohydrate backloading while swapping out cardio for strength training.

The theory is on a low carb diet your body can get the idea it's starving and cling on it to is fat. On Carb Nite ULC forces the body to metabolize fat while a weekly carb pig out stops you going into starvation mode.

It could be cobblers but there's a graph and everything :D

Play to your strengths yeah? I do best when I have some sort of framework to fit activity into irrespective of how stupid that framework is. It won't kill me and I'm measuring my progress pretty closely to see if it's something works for me.

Cutting down cardio and doing gym work again has been fun but a bit painful. Cycling's given me a good base level fitness but there's a shit load of muscles I haven't been using that have taken a bit of a battering in the weight room. Basically it's given me horrible arse DOMS. That'll soon go.

Day #5 right now and your initial Carb Nite is supposed to be on Day #10. Having not eaten carbs in any meaningful way for a couple of years now this is going to be an interesting experience. Not sure what I'll choose for that evening yet either but I'm pretty sure that there'll be a Twix on the menu :D

That's More Like It

Posted on :)

That's more like it.

Getting closer to my personal best of 2012. I'm a bit surprised to be honest, the intention was to go for a long slow run after over a week off. 1km in my watch beeped up a relatively fast (for me) first k so I switched to a shorter, faster 5km. I was kind of worried that the time off since last running would be a problem but it was fine.

24:16 for the 5km at an average pace of 4:51 m/km and 3rd fastest mile at 7:21. Really glad it's now below 5m/km average, something I've been aiming for since getting back into running. And I'm typing this now and bar a few calf twinges feeling pretty good. Bonus!

Next up a long slow one. Probably on Thursday morning. It's an absolute privilege to be running next to the Tay and even more of a joy now it's the weather's getting a little bit more spring like.

Exercise Plan 24/3/15

Posted on

Very lazy 10 days :) So I need a plan and this is it.

  • Goals
    • 30km running
    • 100km cycling
    • 1 gym trip
  • Strategies
    • Plan out week
    • Index cards in office / tick off daily
    • My Fitness Pal
    • Daily weight measure
    • Daily tracking on here?
  • Todo
    • Re-connecet Withings scale to internet
    • Post this on blog
    • Find and print out park run barcode
    • Change CX tires to slicks
    • Can I print index cards on new printer?
Day Cycling Running Other Notes
Monday 34km (10 / 24) Fast
Tuesday 0 12.5km 5:30 run
Wednesday 34km (24 / 10)
Thursday 0 12.5km Gym 1 day gym
Friday 48km (24 / 24)
Saturday 0 5km Park run
Sunday ? ? ? ?


Posted on

I tried a bit harder on this run but didn't get much out of it except being a bit knackered. There's a lot of people around me suffering from colds and what not to right now so it may be down to a mild dose of that. Or I'm shit. One of the two. And it's a bit windy out. Even so, pushed hard-ish and ended up with 5:08 m/km but I wanted better.

Sometimes it's like that though, you give it the extra effort to end up with not a in the way of extra performance. And it cut both ways, out of nowhere you'll get a cracking time. It's a law of averages in some ways; just keep at it and your times will improve and every now and again a PB will pop out of nowhere.

Positives are a fairly consistent pace with the worse K (the one where I had to turn around and start running back) 5 minutes 18 seconds long. To be fair that's something I'd have been very happy with a month ago.

All that aside, and despite the wind, it's pretty nice out. Spring is most definitely almost sprung and pretty soon it's going to be back one layer running clothes :)

10km tomorrow, likely a run home. Nothing fast.

Welcome To The Kingdom Of Fife

Posted on

Welcome To The Kingdom Of Fife


Yeah! Early morning run in an exceptionally pretty Scottish forest just south of the Tay. A little nippy but mostly a beautiful day and managed to put in 5km sans headphones just listening to nature get off to an early morning start.

It was good, seems a medium effort 5km currently equates to 5:17 m/km and I'm pretty happy with that progression. Especially on the back of yesterday's 12km.

I've not done any off road running before and though the path was a bit bumpier than what I'm usually used to it could hardly be termed trail running. Even so it was a nice change and if I got a bit more confidence up there's always some bumpier terrain to have a go at.

But a great way to start the day. I'm currently trying out the Headspace Take 10 free introduction to guided meditation and worked through one the episodes just before running. Felt good. And now I'm typing this in the David Lloyds post a fairly nice cooked breakfast. It can only go downhill from here :)

Slow 10 plus 2

Posted on

Well yeah, that was good. Aimed for form and distance while ignoring pace. It's windy as all get out and there's no point trying for speed. Managed to get back up to 12km and it wasn't really super slow.

The last kilometer slot into place nicely, my form felt good with faster cadence light footfalls and it turned out to be the fastest of the twelve.

All in all? Happy. Might try for a slower five around Tentsmuir Point tomorrow. It's pretty flat forest tracks, something I haven't really done before but should also give me a bit of protection from Scotland's windy weather. If I hit eight it'll be 40km for the week.

The Downside of Metricisation

Posted on

Gah! Forgot to write about this one:

Aim was for a slowish 10km on a relatively hilly route. I pushed a little harder than I'd planned not to the point of knackeration and kind of happy with the time. A little bit of mucking about at the start; a couple of stops to re-insert a tugged out headphone lead but eventually got into a bit of a groove.

It's Saturday morning now and I haven't run since. I want to get out this morning but looking out the window there's a bit of a filthy storm going on.

I don't really running in that but Strava is stopping me :D The downside of metricisation, I want to run and would get in some good exercise but rubbing against that is knowing it'll look slow on Strava :D What an idiot.


Posted on

Pretty happy with that. An extra-curricular 5km hot on the heels of yesterday's. Went out because I really fancied it and despite a load of wind and snow nearly managed to crack the 5 min / kilometer barrier. Nearly

Love running by the Tay even if the weather can be challenging. On the way out it meant a load of wincing to keep snowflake to eyeball pinging at a minimum but the return leg was a lot nicer. Cold but bright and fresh. Before and after below :)

All good and looking forward to a less windy day to see if I've a bit more pace.

Still haven't sorted a proper running plan out but finishing off the week with a couple of long, slow 10km-ers is probably the right way to go. If I drive in early tomorrow I can run along the Tay in Dundee and maybe catch a flinglish at the Mal Maison after.

I have an at home day today. Charlie got some horrid vomiting bug. He's all fine now but we need at least a full day without a hint of vom before sending him back into school. Suzie took care of him yesterday and it's my turn today. Might try and get to the gym this evening and start up with strength training again. Not going to have my bike for a bit so I need something else to justify eating loads.

A Faster Five

Posted on

5:08 m/km and broadly happy with that. A little gutting as a sub 5 m/km is definitely back on the cards and if it hadn't been so horribly windy this might have been the run that delivered it. Kilometer 2 spells out how horrible it was; full of energy but getting onto a stretch of the Tay not shielded by buildings meant slow going.

Also idiotically chose an asymetric route that meant 3km of the run was into the wind and only 2km of it had the wind helping me along. But even so, faster than I've run for a while in extenuating circustances.

I still haven't worked out a proper running plan for the week but I'm writing this early the morning after and feeling v tempted to get out in a bit for another try at a fast five :)

In other news I broke a spoke on my bike. That's okay, this stuff happens, but given it's some fancy schmancy carbon rimmed wheel it'll take a little while to fix. Got to keep an eye on what I'm eating if daily cycling is going to be out for a small while.

Back To Running

Posted on

Back To Running

I wanted to collect my thoughts on getting back to running; hopefully get some perspective on where I am now and what I should be aiming for.

It's coming up for 2 months now. There's a load of good stuff:

  • 5km pace from 5:53 m/km to 5:12 m/km
  • 10km pace from 6:18 m/km to 5:33 m/km
  • 15km per week to 30km per week
  • Bought a Forerunner 620 running watch, love it
  • 10 km doesn't feel hard
  • Coping well with increased running volume and commute cycling

And not so good stuff to:

  • Scottish weather
    • Don't mind the cold and the rain but the wind is a pain
  • Not enough training variety
    • All 10km last week
    • No tempo runs
    • Not many hills
    • No intervals
  • 5km pace isn't improving as much as I'd hoped
  • Relatively high weight
    • Around 13 st but would be happier at 12.5
    • And quicker too :)

So next up I need to:

  • Define some goals, probably:
    • Sub 5 m/km pace for 5km
    • Sub 5:20 m/km pace for 10km, sub 5 m/km long term
    • A race?
  • Set out a training plan
    • Intervals
    • Heart rate zone training (specificaly greater than 10km LSR)
    • Strength training (3 sessions a week? Squats and rows?)
    • Balance that all with cycling commute

So plenty to do but right now I'm pretty happy, feel I've a good base to build on and it's only going to get easier. And sunnier. And less windy too.

Natty Dreads

Posted on


Won a ebay thing and I've now a painfully hip Vulpine Harrington riding jacket in a delightul snot green. £60 but a bit better than that RRP of £190 and it's brand new :)

Probably more suited to riding a fixie with a big beard than my CX but it's nice gear. I particularly like the magnetic button for the neck top. Also around the age of 14 I was a skinhead, not a horrid punchy one but more interested in ska music and the clothes. As well as tonic trousers, tasselovas, button down shirt I also wore a bright red harrington.

So three decades on it's nice to be back wearing one.

Flattered By My Phone

Posted on

Definitely got the hang of running a slow 10km again after another stressless run back from work again on Friday.

Got an amazing (for me) pace of 5:18 m/km too! Except it was cobblers. I'd left my garmin watch at home and resorted to the strava Android app. Unfortunately the ropier phone based GPS seemed to think I was staggering about like a pissed idiot so the run came in at 10.6km instead of the actual 10km distance. Bugger.

See here! The first kilometer of both runs. First of all a rock steady account of events from the Garmin 620

fig(i) Fine!

And a rather more eratic record of my run from Strava on my Galaxy Note 4

fig(ii) Not so fine!

Back of the fag packet calculation relegates me to around 5:35m/km. But that's okay, it's faster than the previous day, seemed to take less effort and second of two consecutive 10k-ers. :)

EDIT: That all said the run route for the 620 at the start is pretty nonsensical as well, the first K has me taking shortcuts through houses which isn't right either. In short: I DUNNO!

That Was Nice

Posted on

That Was Nice

I was supposed to run yesterday but for various tedious reasons it ended up a rest day. Cycled in to work this morning but left the bike in the office in favor of a gentle 10km run home; along the East Dock Road and then up onto the A92.

It's nearly Spring now ad leaving at the still light 5pm gives you a nice amble through the descending twilight past Baldovie's wind turbines as the sun sets :)

Not too cold or windy and no sign of rain either. Lovely :)

I'm happy with an average of 5:37 mins per km from no pushing up a mostly uphill route wearing around 4kg of backpack. Good opportunity to concentrate on finding good form while having a laugh at The Infinite Monkey Cage podcast.

20km so far this week but no attempts at anything involving any kind of pace. I'll have to sort that out, maybe a faster 5km on Saturday.

It is taking a while but I'm feeling like a runner again.

Bit of a Struggle

Posted on

Ha! Very nearly didn't go out but pushed on. It's not a great time but I don't feel too bad about it, the weather wasn't helping much :)

Probably the windiest run I've ever been on and the first leg out to the science park was ludicrous. The wind helps on the return I was so knackered from the last half hour of battling a borderline storm that help didn't translate to much in the way of pace.

But I'm glad I went. Writing this the next day and feeling really good with nothing in the way of aches and pains. I wanted to do a faster 5km tomorrow but if the current weather continues I don't think that's going deliver any pace.

Tempted to do a recovery run tonight though :)

Recovery Run

Posted on

Well that was interesting.

This was my first run where the goal wasn't primarily pace or time but heart rate zone.

It was just a 5km but the day after a harder 10km and intended as a Zone 2 recovery run. The Garmin 620 I've got let me set this as a goal and it was a bit of surprise. I wasn't able to keep within the Garmin's definition of Zone 2 and the watch just moaned at me all the way through. Every time it kicked off I slowed down some more and ended up going at around 7km/m

And that felt a bit weird but after a while I kind of got into it and enjoyed the run. Not stressful in the slightest and a nice chance to take in the Tay's beauty and enjoy the News Quiz podcast.

Strava was less critical and given my best guess at RHR and HRM said I'd been Zone Two all the way through.

So all in all I dunno. A recovery run is supposed to help you acclimatise to upping run distance without stressing out your body and the benefits only apparent over a longish period. So I'll keep at it for a while, I mean it's fun, despite lowering my average pace on Strava :D

Still, around 30km this week. A big step up and something I hope I can carry forward. Tempo 10km at lunch in what looks like some horrible wind.

Tedious Running Post

Posted on

Not a lot to write here but want to keep up a document of my return to running. A few weeks in now and had a great 10km this morning. The goal was for a slow, long run and I kind of kept to that. Average heart rate was down from last week's 10km but I was faster too :)

In fact for that course it's my fifth fastest time.

This is good. Pose running is starting to click nicely and does seem to reduce cv effort without sacrificing any pace. The downside is an increased strain on my calves and hips. I'll get some strength there over time. All in all pretty good and I'm up to 24km for the week now :)

Want to try a slow and short recovery run tomorrow and then have a look at my plan for the rest of the month.


Posted on

Ha! What a gurning idiot. But I'm pretty happy :D

That was pretty good.

Original goal was to try and improve on my current 5km time by pushing as hard as possible. A catalog of errors got in the way of that though:

  • Forgot the heart rate monitor
  • Realized watch wasn't on a kilometer in
  • So promptly gave up

The giving turned out to be the best bit. After a sulky second kilometer decided to try and get something out of the run by concentrating on form, specifically paying attention to:

  • Moving my landing foot to more mid-sole
  • Getting my trailing foot of the ground quicker
  • Going through the POSE position
  • Leaning forward from the ankle
  • Not hunching

Like last time it was a bit of a fight against habit and natural instincts with a lot of oscillation between over thinking and finding a bit of flow. But also like last time everything seemed to click on the final couple of kilometers.

Happy with that. Also quite happy that my 'giving up' pace is still on the right side of 5:30m/km

Onwards and upwards, enjoying this a lot right now. Got some goals to hit for the end of the month and I -seem- to be making some progress towards them :)

Running (again)

Posted on

Good run today down by the front of the Tay. Bright but markedly cold and windy. That's Scotland for you :) My goals were to try and experiment form over a long slow run. I've been watching running videos and this one got me off my arse:

It's hard running differently and being a bit out of my comfort zone while contending with shit load of blustery Dundonean wind was pretty frustrating for a while. Lots of trying to maintain a straight back while leaning into my stride form the ankle and it wasn't gelling.

Luckily something clicked on the final kilometer and ended up in a pleasent groove without going slower.

It's hard to explain but I was moving into a shuffle and then concentrating on getting my feet back off the ground quickly. It felt great and managed the last k at 5:12m/km pace, the second fastest split. Interestingly my heart rate went down a bit too.

Current plan is one run a week like this, don't strive for pace but experiment with different form styles and see what I can learn. I'll try this technique some more and see if this was a one off fluke or actually something that will help me improve.

Next up, a crack at a faster 5km on Thursday.

It's great to be back running again :) Hope I can keep up the momentum.

Liked in 14 : GeoWars3

Posted on

fig(i) The Lights!

Bullet pointing to give the impression I'm a busy boy rather than just too lazy to write it all out proper like. Here we go! This game has my attention I just don't know if I like it or not.

First of all:

The Good

  • The lights! Gorgeously pretty 60hz assault on the senses
  • Music, the GW theme and a bunch of new tunes beautifully recorded
  • Same old GW responsive control, allowing you to do the odd impossible thing. Always a rush
  • Multi platform! One of the rare few who prefers a PS pad over Microsoft's offerings
  • Topological challenge! Despite initial fears transferring from planes to 3D shapes -mostly- works

fig(ii) Impossible feats @ 0:31

The Bad

  • Adventure mode
    • Lots of activities but that just doesn't seem in the spirit of 10p a go arcade fun
    • Get the feeling the team realized no one played the many modes of GW
    • So thought they'd force them on the player
    • "Just ignore that stuff Gaz! Play the classic mode the game comes with!"
    • Well yeah, no one is on those leader boards. And it's all about the leader boards yeah?
  • Game Design Gaffa Tape
    • Boss battles in particular, feels like bodge on top of bodge
    • Outrun style timers and boss invulnerability don't feel good
    • Horrible you can kill the boss but not win the level
    • Or get a star without killing the boss
      • Bizarre have previous on this
      • Always found it weird you could win a race in Gotham but get flip all kudos
    • Red discs also a good example of badly tacked on player hurrying
  • Gold Coin Pick Ups that kill you? Super State pickups are look just like Mario coins except it's instant death if you hungry dog them
  • Takes a while to get used to badly sign posted enemies warping in

And the Ugly

  • Angry Bird star awards at the end of each level.
  • Star locked later levels - go back and grind for more stars son
  • Nasty difficulty spike on final level boss
  • Topological challenge! Mostly works but when it doesn't? Steps on zone outs horribly. Basically cubes can fuck off
  • The price - it just seems a bit much
    • There's a whole load of interesting stuff going on here
    • The credit list is massive, absolutely huge
    • And the game is beautifully finished as well
    • I really wonder how much it cost to make this game
    • And if it'll ever make that money back
    • The leader boards are pretty bar
    • And they cleverly launched the same week as GTA V
    • I really hope there'll be more and more from this franchise
    • But I can't understand how the whole thing adds up
    • Particularly for a extremely commercially aggressive company like Activision


It's fair to say I've enjoyed Geometry Wars 3 far more than the above would suggest; it's a just a lot harder to vocalise the fun rather than annoyances. I've absolutely played the bollocks off of this thing and using time spent as a measure there's obviously something there for me. That said I've eat a shit tonne of Pot Noodle and watched industrial quantities of Jeremy Kyle in the past well. So I dunno.

It's kind of like your awesome, beautiful girlfriend got a really shit hair cut. She's still awesome and beautiful but in certain lights she's got you wincing.

Score: 1 out 1

(1? BUY IT! 0, don't)

Guaranteed No Programming Content At All

Posted on

Listen to this! Consequences of Technology With Ben Hammersley

Ha! The chances of anyone clinking on a link I'm recommending for a podcast called Ruby Rogues is near zero.

Even so, despite being a Nerd Podcast ostensibly about the programming language Ruby this great.

Some great insight from Ben Hammersley (he invented the term PODCAST dontcha know) about a wealth of things 5that have been buzzing around my head of late. Mainly:

  • Balance of power between governmental power structures / corporations / people
    • And how that's all looking likely to change
  • Shift of commercial focus to emerging markets from, well, us
    • Uhoh! Westernized consumer rage on the rise when corporations see their mass market as Chinese 30 year old women
    • Analogue made to white male nerd gamersgate rage happening right now

Yeah, this is pretty great all in all.

Did I Earn Notch $2.5bn?

Posted on

Probably not. But here's an email from 4 years back to Toby, a chum and biz dev contact at Microsoft:

Which he cc's onto Rog, who is now Microsoft's EP for... Minecraft. Blimey.

To be fair it was a pretty obvious thing to suggest, MS were likely already looking at it and even if they weren't they certainly would have been soon. And yes, Minecraft was always going to be hugely massive irregardless of my 2010 frothing about how awesome it was.

Even so that's no barrier to writing a blog post with a stupidly provocative title and I've decided to take this as a personal claim to fame. If only we'd ended up doing the conversions, eh? I'd be writing this from a zero G Space House while quaffing larks livers served on a brass platypus beak.

Or whatever the fuck it is rich people do :D

OSC in Games?

Posted on

Had Some Fun This Weekend

Had some fun this weekend :D

So something I've always wanted to have was a decent way of sequencing stuff in games. What does that mean Gaz? Well most super nice things in games are a sequence of events that creating some sort of nice audio visual 'stuff'

Demo-scene coders do this very well and generally use some sort of script specifying what happens when so the music and visuals get nicely synced. It was pretty interesting looking at how these guys did things after a few of the bigger groups chucked a load of their tools and source onto github a couple of years ago.

I'm kind of a lazy swine who doesn't like editing text files, the way this stuff is mostly done and always thought that this would rule if you had some sort of time line you could vary parameters, trigger events and do all that kind of stuff.

Loads of programs have this kind of thing, Max, Maya, Final Cut Pro and even some game engines; Unity, CryEngine and the excellent Unreal Engine 4.

But you know what? This is for home hobby projects. All of those things are tightly bound to either and activity (editing animation, music, videos) or to a specific technology (as is the case with UE4, Unity and CryEngine). I don't really want that, I'd rather write my own cack handed gaming tech that can be instrumented to receive parametric data from any old external program.

So I got a good part of that working after jack-dawing some existing technology and shoehorning it together. Tech piece the first:


Open Sound Control is a protocol for sending 'stuff'. It's basically a MIDI replacement that fills in some of the horrible gaps MIDI has (low parameter resolution, lag, built around a physical transport {cables! Yuck!}) that can work over the network nicely.

There's a slew of OSC clients and a great little library called OscPack that can receive OSC chatter. And now tech part the second.


And this is a generic OSC time line editor. With this you can send information to an OSC server, information that you edit in multiple channels and gets played back, nicely interpolated and sent to an OSC server. It's nice and general, can control MIDI too if you like it and you can find it here.

The Results

Early days but I have a little flying around demo that takes only a couple of inputs (time and field of view) but I got those hooked up to a time line I'd edited.

And it works nicely. The cuts are done by jumping different time points and then increasing / decreasing time at different rates. They sync with some music playing and despite being very remedial looks nice and was easy to put together.

Ha! I even got my iPad controlling the thing using [TouchOsc][touchosc] as you can see below. It's great, the game hasn't a clue what's telling it to do the stuff it's doing. An excellent detachment of mechanics and content :)

There's a lot of potential here. Next up I'm going to try and hook Logic via an OSC -> MIDI bride. Vezér is good but expensive to buy (I already own Logic) and though admirable is a little bit rough around the edges. The other thing I might try is hooking up a tracker like Renoise that already has OSC support directly built in. I wouldn't lose a load of parameter resolution that way and would have less need value interpolation in the game.

More Positively

Posted on

It's not all broken crank arms.

Back in July I pushed really hard to try and get a stupid monthly distance badge for cycling on Strava. Which I got! Wooo! On the plus side it gave me my biggest distance cycling in a month (1,290 km). The down side is I felt burned out and ended up doing a lot less KM in August. A real shame, nicer weather and light evenings are pretty precious in these northern climes.

So it's a surprise that without consciously trying for it October is going to end up slightly bigger than July's knackering push. I'm feeling pretty good with no signs of burnout (as yet) and there's still a couple of days left to put in ~100km.

Very happy that what previously felt like an overly onerous slog now seems pretty natural :)

Flipping Ada

Posted on


Had this happen over the weekend, the crank arm fell off mid ride. It's looking very much that the holding pins at the top weren't properly fixed during a service a few weeks back :( There's a narrow band of torque advised for attaching the crank arm; too tight and the pins can shear off under strain and too lose it'll just fall off. I suspect they've tightened it by hand rather than use a torque wrench.

Luckily it happened pootling down an unbusy cyclepath on a Saturday morning rather than on some of the excessively hard / fast runs I'd done the previous week. And there was a cab office just around the corner that got me home safely. The guy at the local bike shop was really apologetic and I'm glad it didn't turn into an argument about who's responsibility this was.

After having a bit of a read around about different crank sets I've ditched the FSA Gossamer and ordered a nicer Shimano CX specific one.

So basically I'm an idiot. Something vital falls off my bike because of a less than perfect service and I show them what's what by shelling out a load more money upgrading the thing they broke.



Posted on

Currently sitting at the riding school between Monifieth and Carnoustie watching the boy trot around a shed on the back of toffee, a slightly fluffy and scabby looking pony. He's having an awesome time. Continually chatting to the instructors explaining the relative age of his various cousins :D

Not a bad way to spend a Sunday morning.

Back In Black

Posted on

Horrendous weather for cycling last night but I got my cyclocross bike back from Spokes after being serviced.

It's been out of action for a few months so I've been on the racer for a while. It's been an interesting time; I've significantly up my mileage and that extra riding has improved my speed. And it turns out that's also given some perspective to really appreciate the CX.

Turns out it's a cracking bike. There's a load of differences (weight, geometry, ride comfort, disc brakes) but what stands out most is a feeling a lot more of my pedal effort is getting transferred into going a bit faster. It just feels really responsive at times when the Trek can be a bit sloggy.

The frame geometry means I'm nearer to the ground and maybe that's increasing the feeling of speed and acceleration. It's hard to objectively compare it to the Trek on the basis of one run last night in a near gale but 52 minutes for the trip home isn't disgraceful even in sunnier conditions.

Maybe it's just that a change is as good a rest but whatever the reason and despite arriving home drenched and cold it was with a massive grin all over my face.

Going to try for Arbroath and back before getting into work this morning.


So here's the worse thing. I'm now convinced I need an N+1, a carbon framed road bike with a better groupset :D With winter bearing in there's no point even considering getting something until the weather gets better but I'm going to start looking. Might have my eyes on some of the new, cheaper brands of power meters starting to hit the market.

Sometimes it's good to be confused

Posted on

fig(i) obligatory first image search result for 'confused'

Really enjoyed a This American Life podcast from a few weeks ago:

Really interesting about local civic democratic power in the states, it's susceptibility to coercion by the highly motivated and what can you do when taxes won't pay for needed services delivered in a way sympathetic to your community's culture.

It's interesting in the context of a push towards decentralization of power in the UK. It's not that we shouldn't do that but as well as running towards emotively loaded benefits (MOAR FREEDOM!) it's all to easy to ignore a whole set of other issues localized democracy tends to have.

Hard to draw any conclusions from this particular set of events and I like that. It's a great example of TAL at it's best; thoughtful insights into complex situations without clumsily pushing the listener through an ill-fitting story arc.

If you're left you going "eh?", that's not always a bad thing. Sometimes confusion is a far more appropriate response than certainty to everyday life.

Back To Montrose

Posted on

Great cycling weekend all in all and appropriate for a little reflection on where I've got to. Best indication was Sunday's 98km round trip to Montrose, back via Dundee. It's a route I've done once before but utterly wrecked me, I remember being wobbly legged for the rest of the day and completely good for nothing.

Sunday's ride was different; I tried hard but ended feeling chipper and had a relatively active remainder of the day (including a really nice trip to the Monifieth playpark with Suzie ans Charlie). Managed a small speed increase in weather conditions a bit more challenging than the balmy July day on the original run (28.4km/h vs 27.9km/h) :)

And I'd done a 75km run the day before as well. So all in all a little bit of a step up and also my longest distance in a week.

Pretty happy but I need to get a bit faster. 100km @ 30km/h average sounds like a good goal though I think that may have to wait until next year. The Scottish weather's starting to get a lot more Scottish as we move towards winter.

gvim $PATH Malarkey

Posted on

What's the problem then?

I've had some funny issues with PATH in gvim and in turn was giving me a bit of gyp running plugins that called external programs (see the excellent Syntastic, ghcmod, a slew of other useful things but most importantly :make)

Sometimes it'd work and sometimes it wouldn't which isn't very computery. I ended up wasting a bit of time on it and this is what I found:

  • It all depends on how gvim is launched
    • If I launched gvim from the command line everything would be fine
    • If I launched from gmrun it wouldn't be fine
    • Or via a shortcut key I'd configured in XMonad
  • In all circumstances running the :!echo $PATH returned the correct values
  • When it wasn't working echoing gvim's path (:echo $PATH {dropping the !}) return a different value

Weird. It's like gvim had two different paths

Do What?

Running a shell command from the ex prompt (:!echo $PATH) spins up an interactive shell which reads .bashrc just fine and returns the correct PATH from the interactive shell's environment.

The ex command :echo $PATH (again no !) shows gvim's environment inherited from whatever process launched it. Plugins spawning processes use this PATH.

If I launch from the terminal gvim inherits the correct path because .bashrc is read which isn't the case for gmrun, XMonad etc.

And you can fix that?

Yes! Set the path you want for all programs in your ~/.login file and this will be inherited by everything.

This is pretty well documented shell behavior, why so tricky?

Well yeah it is. I read this detailing bash startup files pretty early on which put me on the right path (Ha!) but I still ended up wasting load of time for a number of reasons.

The main trap I fell into was not realizing you have to logout and login again for any changes in .profile to take effect which totally makes sense if you think about it for a couple of seconds.

Also I used terminal Vim a lot (works fine) and sometimes launch gvim from a terminal prompt (also works fine) which made testing tricky until I realized some basic home truths about *nix environments are inherited.

And that sent me down the rabbit hole for longer that it should which is why I'm making a not for myself here :D

aapt not Working on 64 bit Ubuntu

Posted on

fig(i) I was quite literally tearing my hair out! Clip art. Man I love clipart. One day an artist of great talent will reappropriate this under appreciated ouevre and elevate it to high art treading the same path as Warhol and Litchenstein. Fast forward 100 years and it'll be out with formaldahyde drenched sharks and in with gigantic canvas' of Clippy

Handy hints for Android development!

On a 64 bit install I couldn't get my project building, it came up with a cryptic message that aapt would was missing. It's a packaging tool and it was an executable that was exactly in the place it was supposed to be. Oddly enough it didn't run from the command line either and with an arcane message of FILE NOT FOUND.

The problem?

The Anroid build tools I'd installed are 32 bit versions. They won't work without 32 bit installs of glibc and libc++

It was a bit of a pain figuring out that was the problem but once I had it was easily fixed. Tada!

    sudo apt-get install lib32stdc++6 lib32z1

Babun - Making Windows less Windows

Posted on

Babun is very cool, a very tastefully pre-configured distro of Cygwin along with a useful (though simplistic) package manager called pact.

Introduction to the Babun Project from Tom Bujok on Vimeo.

Sometimes you have to use Windows, it's just the way it is. I find it a bit painful though that's mainly a function of unfamiliarity than any absolute awfulness on Windows' part. I installed Babun earlier this week and the awfulness lessened a bit as it has several things to help me create an environment I feel a bit more comfortable with.

These are the ways that Babun makes me happy:

  • Vim nicely installed and pre-configured
  • Zsh - and even better Oh My Zsh - just the same as one my Mac
    • Git aware too! I really like that my prompt has my current branch in it
  • Nicely isolated - doesn't clash with existant Cygwin installs
  • Update everything script
  • Nice colour scheme and font setup for terminal :D
  • And the terminal is setup well for 256 cols

All in all very happy. I have Vim, Irssi and Tmux using pretty much the same configs I have on the Mac / Linux and can petty much ignore the mouse :D

Cycling Weekend

Posted on

I've set some goals. This time it's cycle straight a 100km.

Not a biggy and I've allowed myself a few weeks to get there. This weekend was a good step towards that and an excellent cock up brought me with 3km of what I was after :D

I've cycled to Perth one before and quite honestly it was horrible. An idiotic misreading of the weather coupled with a overly light clothing saw me complete the ride colder than I've ever been in my life. Got the train back, it wasn't nice. This weekend was a bit more clement so I thought I'd give it a go.

My cycling does seem to have come on since the last try. A particularly vile hill that I had to walk my bike up last time got ridden and instead of heading directly for the nearest Costa for half an hour of shivering I turned around and headed back home.

What I hadn't got quite right was the distance, I thought it was a ~80km round trip to Perth but it's actually 96.7km :D Man, if I'd know a few spins around the block would have got me to 100 :D It's not a bad ride I guess. It did piss down horribly part way through and I don't have much hill experience so the slowish average of 24km/h isn't bad for a first try at this? 4 hours in total.

What I am happy about is it wasn't physically too bad. On Sunday I managed my quickest Monifieth -> Arborath round trip and it seemed really easy. I remember one half of this trip would be knackering demanding a solid hour in the coffee shop half way through :D

This week I'll continue upping my daily distance taking a longer route home and then give it another go next weekend :D Hopefully the weather will be good and it'd be nice to try the same route. Fingers crossed for something under 4 hours :)

Some lessons learnt:

  • I need to drink on rides of this length : nothing during but sank 1.5 litres of water when I got home
  • Food might be an idea: though I didn't feel hungry. I eat near to zero carbohydrates so the high energy / sugar snacks recommended by most sites don't appeal
  • Moar Podcasts: run out on the way home :)

Nice Break

Posted on

That was lovely, a really nice few days away glamping at Comrie Croft and will definitley be back there at some point. We haven't been a way for a while and a few days central Scotland's hills was really welcome. Mostly a pretty lazy time hanging around the campsite but had a trip out to the excellent Auchingarrich which Charlie very mucn enjoyed.


Charlie very excited to be staying in Kata 2, on the trail of the red squirrel's butt.


Getting the hang of making a fire. It's easy learning stuff when bacon's an incentive. Put on a half stone mostly thanks to sausages :D