Daniel 'MaTachi' Jonsson

How to Get Your Playstation 3 Dualshock 3 Sixaxis Controller to Work on Linux


To see if the controller works, install jstest-gtk (it’s in Ubuntu’s repository). It will list all connected game controllers and show which buttons are pressed and which not.

Install it with:

sudo apt-get install jstest-gtk


My Playstation 3 Dualshock 3 Sixaxis controller worked quite well, sometimes, without any drivers. But it was quite unreliable, and the L2 and R2 triggers wouldn’t get recognized in Euro Truck Simulator 2. A much better solution is to install and run xboxdrv to emulate it as a Xbox 360 controller when you want to play games.

Install xboxdrv:

sudo apt-get install xboxdrv

Start it with:

sudo xboxdrv --detach-kernel-driver

Press the Playstation button on the controller to get xboxdrv start receiving and processing the inputs from the controller. This will print a lot of text in the terminal. If you want to quit it, press Ctrl-c. When it’s running, open Jstest-gtk and see if the controller now shows up as a Xbox Gamepad instead, and if all buttons, triggers and joysticks work.

I connected my controller with a USB cable, so I can’t say if this will work through Bluetooth.

How to Copy Your Euro Truck Simulator 2 Savegame from Windows to Linux


  1. A Euro Truck Simulator 2 game profile on Windows.
  2. A Euro Truck Simulator 2 game profile on Linux. It’s enough to have started it once and configured a basic profile.

Locating your savegame folder from Windows

In Ubuntu, open Nautilus (the file manager/browser), click on your Windows partition in the left sidebar under Devices to mount it. Then navigate to:

/media/[linux-username]/[xxxxxxxxxxxxx]/Users/[windows-username]/Documents/Euro Truck Simulator 2/profile

There you will find a folder containing your savegame and profile. My folder was called 417A757361.

Locating your savegame folder on Linux

Open a new window and navigate to the following folder on Linux:

/home/[linux-username]/.local/share/Euro Truck Simulator 2/profiles

Here I also found a folder named 417A757361.

Copy over your Windows savegame

Rename the Linux folder to 417A757361_old, then copy over your savegame folder 417A757361 from Windows into the profiles folder on Linux. Now you should have the following folders:

/media/[linux-username]/[xxxxxxxxxxxxx]/Users/[windows-username]/Documents/Euro Truck Simulator 2/profile/417A757361
/home/[linux-username]/.local/share/Euro Truck Simulator 2/profiles/417A757361_old
/home/[linux-username]/.local/share/Euro Truck Simulator 2/profiles/417A757361

The first one is a backup of your progress from Windows, the second is a backup of your dummy profile you created on Linux, and the last one is the real, new savegame folder.

Copy over your controls config

Copy controls.sii from 417A757361_old and paste it into the new 417A757361. Because the Windows controls won’t work on Linux. Now the mouse and such should also work when launching the game.

Copy your Windows controls over to Linux

It should be possible to keep your controls you configured on Windows. However, I haven’t tried this. Open controls.sii in 417A757361_old. Instead of replacing the whole controls.sii file in the new 417A757361 folder, just copy over third line looking like this:

input_config : _nameless.0x.14d6.d5d0 {

Copy that line and replace the third line in controls.sii in the new 417A757361, assuming it contains the Windows controls. Otherwise you need to get a new copy of the controls.sii from the Windows folder.

Cloaked Chatter – Bot that automatically posts links to tech news on /r/technology

One week ago I wrote a bot that automatically posts links to tech news on Reddit’s subreddit /r/technology. The bot is written in Python and is called Cloaked Chatter. The code is licensed under the FOSS license Mozilla Public License 2.0 and the source code is available on Github at:

As a back-end I use TechHeat which lists the most popular tech news in social media.

I only ran the bot for a few days, but it is fairly successful at grabbing and posting links. On the following screenshot from the other day you can see it snatching place 1, 9, 13, 14 and 20 of the most popular news in /r/technology:


The link “NASA trailer reaches crowdfunding goal, will be shown before ‘Star Trek: Into Darkness’” got the following incredible stats:

3,418 points (55% like it), 16,825 up votes, 13,407 down votes

On this screenshot you can see it on place #2 on /r/all:


I don’t know if it ever reached #1, but my account was awarded with the trophy “Best link”:


The problem is that the my account KanemotoYokose seems to have been blocked since then. I can still login on it, but new posts won’t appear any longer under the ‘new’ tab in /r/technology for other people. Neither can other people see my account page, instead it says “page not found, the page you requested does not exist”.

I may have gotten my account blocked since I had one cronjob set to run the script once every hour, and one to run it once every second hour. So basically I were posting 36 links a day. I can see how this could be interpreted as a little spammy, but I never intended to write a spam bot. My goal was to write a bot that would post good links that people would upvote.

Anyway, the code is open source, it was a fun and educative experiment, and I got to write and learn some more Python.

Got my first bitcents

I have known about Bitcoin for about two years. But the recent growth made me want to try it out, play a bit with it and see how it works. It’s a really fascinating currency which is revolutionizing payment.

To purchase my bitcents I used the Swedish Bitcoin trading site Kapiton. I transferred 60 SEK (~9 USD), which took about a day until it showed up on my Kapiton account. I got 0.05869422 BTC for that which I then transferred to my own maintained wallet.

There is a really cool website called blockchain.info where it’s possible to see all transactions made in the Bitcoin network. Here is a link to my public address where the transfer is visible:

I have spent a lot of time reading questions and answers on Stack Exchange’s Q&A site dedicated to Bitcoins, and there is really a lot of interesting technical details to learn about. I highly recommend checking out that site.

For Reddit users there is an active Bitcoin subreddit which is pretty fun to read.

I also stumbled upon a cool site where it’s possible to see the Bitcoin exchange rate in real-time:

In my opinion Bitcoins aren’t very useful today since not many sites take them. But it feels like it could be Internet’s equivalent to cash, because it makes it really easy for private persons, artists and smaller developers etc. to accept payment, instead of fiddling with Paypal and such solutions. With Bitcoins you can transfer money to anybody across the whole globe in about only 10 minutes for a really small transaction fee. That’s incredible, so I hope it takes off.

Third game completed – Slashat: The Game

bannerDuring March for One Game A Month I made something less serious. It’s called Slashat: The Game and you can find more information about it here.

I’m pretty sure that I will try to make something in C++ with SDL and possibly OpenGL for April. Mainly because I would like to get learn more low-level programming. But I also can’t get over that Java feels wrong for making games. Wish me good luck – I guess it will be needed!

February game Geometri Destroyer is complete


During February for One Game A Month I decided to play around with Box2D and learn how it works. The result is Geometri Destroyer. It’s mainly made for Android and can be downloaded from Google Play. Since I have had a lot to do in school and such I couldn’t put in a ton of time into the game, but I’m happy with the result.

Skuttande Nyan Cat

1gam-logoPrior to the new year I signed up for One Game A Month. It’s essentially a year long game jam where you are tasked to create and submit a new game during each of the year’s months. There are no prizes, so you are only doing it for your own sake. My #1GAM profile can be found here:

For January I decided to create a 2D side-scrolling platformer where you jump on platforms as Nyan Cat. Today I finished it, submitted it to Google Play and it’s called Skuttande Nyan Cat. It can be found on the following URL:


I’m proud of the result and I had tons of fun developing it. :) It’s not that much content in it tho, but considering it was developed during about 2 weeks I think it’s fair.

Skuttande Nyan Cat is written in Java, and I’m using the game library LibGDX and the entity system framework Artemis. This is the first program I have finished with those libraries, and I must say that they are really good and fun to work with. I used AndEngine in a previous project, and that sucks hard in comparison. With LibGDX it’s also possible to run the same code base on the desktop and in some cases in the browser too, which is really cool. In fact I did most of the testing on my desktop, with the game running as a regular Java application.

If you haven’t already, sign up for 1GAM! It’s motivating and forces you to learn to finish projects. It will also give you a lot of coding experience and games in your portfolio.

Allow Newer Clients to Publish Results to RoboRumble Server

If you have set up a RoboRumble server to Robocode and you want to be able to submit battle results from newer clients, do the following steps:

  1. Open upload_results.php in the server’s root folder.
  2. Edit the line:
    $version_allowed = array('', '');

    to something like:

    $version_allowed = array('', '', '');
  3. Save and you are done!