joepie91s Ramblings

Random posts about technology, activism, programming, people, and anything inbetween.

Month: May, 2012

Useful software you never heard of: Radio Tray

The About screen for Radio Tray

The About screen for Radio Tray

There are no doubt quite a few people that regularly listen to various internet radio stations. After all, it’s pretty much the easiest way to have music constantly playing without having to take care of playlists. A quite useful utility for Linux is Radio Tray, which is literally not much more than an icon in your tray that allows you to listen to configurable internet radio stations. It’s extremely lightweight, has almost no user interface, and doesn’t get in your way.

By clicking the tray icon, you will see a list of configured radio stations – to listen to one, you simply click it. If you want to, you can easily add your own radio stations as well.

Radio station configuration

Radio station configuration

It also offers notifications (through libnotify) of new tracks that just started playing.

Tray notifications for Radio Tray (under XFCE)

Tray notifications for Radio Tray (under XFCE)

 

Installing Radio Tray

To install it on OpenSuSE, you just have to do

zypper install radiotray

It’s also packaged on various other distributions – check the repositories for your distribution to see what the package name is.

Running Runescape HD (and other OpenGL Java applications?) in OpenGL mode on Linux

I decided to, after two years or so, once again check out what has come of Runescape – but, predictably, that didn’t go as smoothly as I had hoped. Even after installing Sun Java and the proprietary ATI fglrx drivers (both are a requirement for reliable working of Runescape and many other Java and non-Java games, by the way), it simply would not go into OpenGL or Software mode, and constantly fall back to Safe Mode with the message “Runescape was unable to enter that display mode”. After some searching I figured out that the issue was in the Java browser plugin, which apparently failed to use OpenGL properly. Had I been using Windows or OS X, it would’ve been easy as a stand-alone client is offered on the Runescape website. However, there is no such thing for Linux – at least, officially there isn’t.

Someone has apparently written his own ‘port’ (wrapper, actually), to run the stand-alone client on Linux. It supports resizable mode, HD, and OpenGL mode – so basically everything you need to play Runescape HD. To get it running, just do the following and follow the instructions:

wget http://dl.dropbox.com/u/11631899/opensource/Perl/unix-runescape-client.tar.gz
tar -vxzf unix-runescape-client.tar.gz
cd runescape/
./runescape

It will automatically update with the latest version from the Runescape website, and launch the applet stand-alone. Et voila, problem solved 🙂

(additionally, a similar approach probably works for other OpenGL Java applications as well.)

Update (September 6, 2012)

HikariKnight, the author of the wrapper, has responded in a comment below, clarifying about the issue and giving an additional tip for users of his wrapper. I have added emphasis and edited some things for readability.

You however forgot to mention that you can add application menu entries by running ~/runescape/install-desktop-icons – that way you don’t need the terminal to be open. You can also update it by running ~/runescape/update-runescape-client .

About the OpenGL issue:
The reason it kicks into safe mode, is because Java 7 (as well as OpenJDK 7) have been compiled without linking the plugin libraries – meaning it has no idea where to find the native Java libraries. This results in the application either crashing, or being kicked into safe mode.

 

Getting Atheros-based USB dongles (TP-Link, ICIDU, etc) to work under OpenSuSE 11.4 and others

Since it was pretty hard to find the appropriate documentation on this, here goes. If you’re trying to get your WiFi USB adapter to work under OpenSuSE 11.4 and it’s based on an Atheros chipset (mine had device ID 0cf3:7015 according to lsusb), you’ll need to install some additional drivers for it. On OpenSuSE 11.4 (and probably 12.1 and other versions), this is done by installing the MadWiFI drivers.

Note that you need to be root to execute the below commands!

 

Step 1: Adding the repository

First off, you need to add the MadWiFi repository to your repository list. According to the OpenSuSE wiki, the repository addresses are as follows:

Version: 12.1 http://download.opensuse.org/repositories/driver:/wireless/openSUSE_12.1/
Version:
11.4 http://download.opensuse.org/repositories/driver:/wireless/openSUSE_11.4/
Version:
11.3 http://download.opensuse.org/repositories/driver:/wireless/openSUSE_11.3/
Version:
11.1 http://madwifi-project.org/suse/11.1

You can add these using either zypper:

zypper ar http://location/of/repository MadWiFi

… or using YaST: YaST Control Center -> Software Repositories -> Add -> Specify URL

 

Step 2: Figure out your kernel type

Open a terminal and run:

uname -r

This will show you your kernel version. It will look like this:

sven@linux-8ne5:~> uname -r
2.6.37.6-0.11-desktop

In the above example, ‘desktop’ is the kernel type.

 

Step 3: Install the madwifi packages

For this you should probably use YaST: YaST Control Center -> Software Management

Search for madwifi and select the packages madwifi and madwifi-kmp-KERNELTYPE, where KERNELTYPE is the kernel type you found in step 2.

Accept the changes, start installation, grab a cup of coffee, and wait!

 

Step 4: Loading the kernel module

When the packages are installed, run the following command in your terminal as root:

modprobe ath_pci

The kernel module should now be loaded, and your network manager should detect your USB adapter.

Doesn’t work? Check if the kernel module is really loaded:

modprobe -l | grep ath

Don’t have a network manager? If you haven’t enabled a network manager yet, you need to do that now – continue to step 5.

 

Optional step 5: Enabling NetworkManager

If you are using GNOME or XFCE (and probably also LXDE), you’ll need to enable NetworkManager if you haven’t done so already. The ifup method will not detect your USB adapter.

To enable NetworkManager, go to YaST Control Panel -> Network Devices -> Network Settings -> Global Options tab. Ensure that at the very top, the User Controlled with NetworkManager option is selected, and save your changes. You may have to enable the NetworkManager applet if you don’t see it appearing in your notification area. To do so, run the following command in a terminal, including the ampersand:

nm-applet&

Using KDE? Sorry, I have no idea how to enable the network manager there – all I know is that it’s called KNetworkManager. The method to enable it is probably similar to the above method for GNOME and XFCE.

 

Congratulations, you should now have a completely working internet connection using your Atheros-based USB WiFi dongle!