Fix Steam Controller Issues in Linux

Last time I was praising Steam Controller for running smoothly in Ubuntu. Well, I must have jinxed it. As you might have noticed, after a recent update, it stopped working all together. The reason is, Valve have changed the protocol for wireless communication between the controller and the computer. Luckily, the fix is easy. You just have to edit the udev rules. So, open them with a text editor:

$ sudo nano /lib/udev/rules.d/99-steam-controller-perms.rules

and change them to the following:

# This rule is needed for basic functionality of the controller in Steam and
# keyboard/mouse emulation
SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0666"

# This rule is necessary for gamepad emulation; make sure you
# replace 'pgriffais' with a group that the user that runs Steam belongs to
KERNEL=="uinput", MODE="0660", GROUP="pgriffais", OPTIONS+="static_node=uinput"

# Valve HID devices over USB hidraw
KERNEL=="hidraw*", ATTRS{idVendor}=="28de", MODE="0666"

# Valve HID devices over bluetooth hidraw
KERNEL=="hidraw*", KERNELS=="*28DE:*", MODE="0666"

# DualShock 4 over USB hidraw
KERNEL=="hidraw*", ATTRS{idVendor}=="054c", ATTRS{idProduct}=="05c4", MODE="0666"

# DualShock 4 wireless adapter over USB hidraw
KERNEL=="hidraw*", ATTRS{idVendor}=="054c", ATTRS{idProduct}=="0ba0", MODE="0666"

# DualShock 4 Slim over USB hidraw
KERNEL=="hidraw*", ATTRS{idVendor}=="054c", ATTRS{idProduct}=="09cc", MODE="0666"

# DualShock 4 over bluetooth hidraw
KERNEL=="hidraw*", KERNELS=="*054C:05C4*", MODE="0666"

# DualShock 4 Slim over bluetooth hidraw
KERNEL=="hidraw*", KERNELS=="*054C:09CC*", MODE="0666"

Now, save them with Ctrl + x.

I wonder, how much of a problem would be to update the udev package along the Steam update. While the updated rules were mentioned in the change log, it did not say which file you were supposed to edit. And of course, not everybody reads changelogs. So this caused a headache to lot of users. Hopefully, Valve will handle updates better in the future.

Diggin’ in the Carts - History of Japanese Game Music

As a kid, I spent countless hours playing 8-bit games. Atari, Nintendo, Sega - had it all. And 8-bit music has had a special place in my heart ever since. Even now, I like to pop a song or two from my favorite games. Not just because of the nostalgia, but because of the special sound qualities of 8-bit, that you won’t find anywhere else. Some of soundtracks are true masterpieces, as evidenced by their being performed by orchestras all over the world. It is amazing how the composers could achieve such acoustic richness, given how little they had to work with.

When I heard from my brother about a Diggin’ in the Carts, a documentary series by Red Bull Music Academy, that covers the history of Japanese game music, I was overjoyed. It features numerous interviews with the composers, giving a unique insight into how some of the most iconic game songs came to light, with a sprinkle of comments by musicians and electronic producers from around the world, who talk about the impact that Japanese game music had on their works. If you are a fan of the 8-bit sound or retro gaming, this is a must-see. As an added bonus, you can turn off the subtitles to get some quality Japanese practice. You can find the whole series on the following page:

Diggin’ in the Carts

Using Steam Controller in Ubuntu

I have recently picked up the Steam controller. With it, I can finally enjoy some of the platformers that have been sitting in my Steam library for ages (such as Never Alone and Feist). Why Steam controller? The reason is twofold. Firstly, it seems to be one of best gamepads around according to the reviews. Secondly, it was also supposed to run out of the box on Linux. Well, that might be the case if you connect it by USB (I have not tried that). But in order to run it in wireless mode, you have to manually install the drivers. Hopefully, they will be automatically downloaded when you install Steam in future releases, but for now, you have to run this command.

$ sudo apt install steam-devices

Or in OpenSuse:

$ sudo zypper install steam-controller

When the installation completes, just fire up Steam in the Big Picture Mode and add your controller. A bit more work that I would have hoped for, but still simple enough. I might sum up my impressions in another blog post. Now I am off to play some games.

Trouble after update

Edit: If you are experiencing problems with your Steam controller after a recent update, check out this blog post.

Autostart Linux Applications in One Command

Usually, when I am done working on the computer, I just suspend it. Thanks to that, I can easily pick up where I left off. But sometimes, I have to swallow the pill and turn it off (for example to preserve charge while traveling). In such cases, you can autostart Linux apps to quickly setup your work environment and get back to being productive. Fortunately, you can easily set this up in desktop environments adhering to Freedesktop standards. These include Gnome and KDE, among others. You just need to copy the .desktop files of your favorite programs from /usr/share/applications/ to the autostart directory. For instance your browser, password manager or a roll-down terminal. If you only want it to start for yourself, copy it to $HOME/.config/autostart. However, for system-wide configuration, the directory is /etc/xdg/autostart. As a result, you don’t have to waste time starting up the same 5 applications every time you reboot. And you can set everything up using just command line. So you can even use it is part of your computer installation script. If you are looking for other ways to automize tedious tasks, check out this guide to automatically configure your computer with Ansible.

Impacts and Ethics of Eating Meat

The health benefits of vegan diet over a balanced omnivorous one have been largely disproved by nutritional research. Since then, the argument has shifted to the negative environmental impact of producing meat. Recently, media has been swarming with articles such as Mean is horrible on Washington Post, or Tax meat and dairy to cut emissions and save lives, study urges on The Guardian. Their authors cherry-pick arguments to support their position, that eating meat (especially beef) is detrimental to the environment. Meanwhile, they ignore any downsides of growing crops. On the latest episode of Revolution Health Radio, Diana Rogers presents a more complete picture of the situation. In the process, she dispels the notion that growing crops is the only environmentally and ethically feasible way of producing food. Listen to it here:

Impacts and Ethics of Eating Meat

20th Anniversary of Diablo

Diablo was my favorite game as a kid. I remember the captivating gloomy, haunted atmosphere, that kept you incessantly on your toes, as if it were yesterday. It is hard to believe that twenty years have come by. Yesterday, Blizzard have announced that they have something special in store for the 20th Diablo anniversary. In the upcoming patch of Diablo 3, they will have recreated the original Diablo campaign. And to make the experience as authentic as possible, characters will only be able to move in 8 directions (instead of 360 degrees). Also, a special grainy filter will be applied to graphics.

Original Diablo remade in Diablo
3

Perhaps it is time to finally buy Diablo 3?

Use Pi-Hole to Block Ads with Raspberry Pi

We live surrounded by ads. Not only in the physical space, but also in the virtual reality of Internet. They don’t just consume a lot of bandwidth and are very obstructive, they usually also unethically track you. While I understand, that content creators need the means to make ends meet, I believe there are better ways to accomplish that, such as Patreon. Now, there are plenty of ways to get rid of ads on traditional computers. For example, browser extensions, such as Privacy Badger and uBlock Origin, or proxys, such as Privoxy). However, on mobile devices, the situation is far less ideal. One way to tackle the problem, is to filter out ads for your whole network. Welcome to Pi-Hole. It is a DNS server for Raspberry Pi, that keeps a blacklist of advertising sites and serves an empty response instead of them, saving both your bandwidth and your sanity.

Installation

As you can see on its website, Pi-Hole’s installation process is very easy. Once you have your Raspberry Pi set up, connect to it via SSH. Then run the following command to download Pi-Hole:

Read more…

Attack on the Titan Board Game

Last weekend Spiel 2016, the biggest board game trade fair, took place in Essen, Germany. While there, I had a chance to catch up with Antoine Bauza, designer of such gems as Tokaido, 7 Wonders and Samurai Spirit. Currently, he is working on Attack on the Titan: The Last Stand. The game based is on the hugely popular Japanese manga and anime, where the remnants of humanity live in a wall-protected city, defending themselves from titans, who have an appetite for humans. In this board game, one player takes on the role of a titan. Their goal is to eat innocent citizens, destroy the city’s defenses and kill the members of the defense corps. The other players team up, trying to take the titan down.

Attack on the Titan: The Last Stand

I got to try out the game prototype as well. The game-play was very immersive and action packed, even though it was a bit too dice heavy for my taste. That was quite surprising for me, since Bauza’s games usually do not utilize dice at all. But I will be definitely buying the full game once it comes out in February 2017 anyway.

Automatically Turn Off the LEDs on Raspberry Pi

Raspberry Pi is my little busy-bee, working as a torrentbox and a Nextcloud server, among other things. But man, those blinking LEDs are not good for your sleep. So, I have written a small script with a systemd service to keep the LEDs turned off at night. You can find it at my Gitlab page. Enabling it on your own Raspberry is as easy as 1-2-3:

  1. First, download the script with git clone https://gitlab.com/radek-sprta/automate-raspberry-leds (you might have to install git first).
  2. Then copy raspberry-leds.sh to /usr/local/bin.
  3. And make it executable with sudo chmod +x /usr/local/bin/raspberry-leds.sh.
  4. Afterwards, raspberry-leds.service and raspberry-leds.timer to /etc/systemd/system/multi-user.target.wants.
  5. Finally, run sudo systemctl daemon-reload.

Well, that was more like 1-2-3-4-5. But still pretty easy I would say. No more blinking lights bothering you at night anymore. Yay!

Install Nextcloud on Raspberry Pi

For a lot of people, using a cloud service such as Dropbox or Google Drive for syncing their data between different machines has become a necessity. However, it comes at a cost - you lose control over your data once you uploaded them. What if you could run a cloud service at your personal server? Welcome to Nextcloud. You might have a heard about Owncloud. Due to disagreements over the goals of the project, the Owncloud founder and few other key figures have forked it into Nextcloud. Between the Nextcloud conference and the Nextcloud Box, the project seems to be gaining a lot of traction. And that’s why I chose it rather than Owncloud. As in my previous guides for Setting Up Headless Raspberry Pi Server and Turning Raspberry Pi Into Torrentbox, I will guide you step by step how to install Nextcloud on Raspberry Pi, turning it into your personal cloud. In the examples, I am using Raspbian, but the instructions should be similar for other systems.

Read more…