Ascii Art Generator

Sun, beer, volleyball, travel, bathing, swimming, longboarding, and of course… programming!

It is the time of year when I have the time to dedicate time to some personal projects. Today has been a long day of coding and the result was a JavaScript Ascii Art Generator. I have been doing some image manipulation using HTML5 recently and this was simply a natural next step. The image above shows the result from a render i did.

The applications is stand alone and can handle most images, although images with a lot of contrast seems to work the best. The current version works well, but I might want to tweak it at a later point to get be able to handle darker images better.

If you want to give it a try, you can find it here: Ascii Art Generator

I have also got myself a longboard. It is much easier to start out with than I would have thought and it is so much fun! The thought is to use it as a means of transport, but at my current skill level I am most like better off simply walking.


EDIT: The code can be found here:

2014-09-04 13.42.27

Throwback Thursday

After almost two years here at Hamar it is time to move on. Today is my last day at Norsk Tipping and now its time to take a well earned vacation before moving to Oslo. The time here in Hamar has been very varied and I have learned so much, truly a great time! It is a bittersweet goodbye with my colleagues at Norsk Tipping, but new challenges are waiting.

This August I will be starting a new job at Schibsted Products & Technology. I am really looking forward to getting started, as the challenges will be just as difficult as it will be rewarding.

Read more to see some of the greatest moments during my time at Hamar:


Just Cause 3 coming December 1st

As mentioned in the last post, Square Enix had a press conference at E3 this year. One of the games they confirmed is Just Cause 3 from Avalanche Studios. The release date is December 1st 2015 for all platforms. Can’t wait!


The mobile game from Bethesda; Fallout Shelter is also coming for Android in a couple months.




Top 10 games from E3

There are just too many cool things being shown at the E3 expo this year! Up until now, we’ve had Bethesda, Microsoft, EA, Ubisoft and Sony presenting. Still, we have the press conferences of Nintendo and Square Enix (their first ever press conference at E3) to look forward to.

Anyways, here is my top 10 list for E3 so far:

  1. [Revealed] Mirror’s Edge: Catalyst
  2. [Revealed] For Honor
  3. [Update] Star Wars Battlefront
  4. [Update] The Division
  5. [Revealed] Ghost Recon Wildlands
  6. [Update] Rainbow Six Siege
  7. [Revealed] Fallout Shelter
  8. [Revealed] Hitman
  9. [Revealed] Anno 2205
  10. [Revealed] Dishonored 2


Here are some of the trailers that you really should check out:






PHP Server redirect

After a couple months of moving, putting together IKEA furniture and reconfiguring servers and devices there is still one thing missing; a static IP. I am currently running OpenProject as my choice of project management tool. The challenge of using this is that it runs on Ruby, so it has to be hosted on one of my servers and these are placed in my apartment at the moment.

Normally, when having a static IP you would simply add a CNAME record for the IP and it would have been working as intended. At the moment this is unfortunately not the case. So how do we get around this?

In my case, only HTTP needs to be supported at the moment so the solution was making a simple PHP script handling the redirection. This stores the server IP on request and redirects everything else. It also handles subdirectories and GET requests correctly.

To use the script, create a folder with the desired name of your server( would be achieved by creating a folder named server1 in the root directory of your web host. Then all you have to do is extract the source in that directory and create a cron job on your server for updating the server IP. Remember to update your auth token in index.php.

Cron Job setup

Append the following content to your crontab:

*/10 * * * * wget -q -O /dev/null "http://<folder-name><your-auth-code>"

Save and exit.

Example usage

Manually update your server IP to your current public IP
Retrieve the server IP in a browser
Get your server IP in a terminal
$ echo Server ip is: $(curl -sL

Get the code

You can either download the source, or browse it on the wiki.