Showing posts with label Mint 17. Show all posts
Showing posts with label Mint 17. Show all posts

Wednesday, 24 December 2014

Setting Up the XBMC Remote On Your Android Smartphone

In my post describing how to set up a Yatse remote on your Android smartphone, I opined that the Kodi/XBMC offering was a little trickier to set up. Nonetheless, I've found persevering with the setup to be a worthwhile experience and, despite some minor shortcomings, I've found that the XBMC remote is more reliable on my Samsung Galaxy Advance than Yatse.

In order to control Kodi/XBMC via any remote control, you must first make some adjustments to the host machine. The following instructions are taken from my setup using 13.2 Gotham & my Samsung Galaxy Advance (as the remote):

  1. Start Kodi/XBMC, navigate to SYSTEM and select Services
  2. Select the Webserver menu option:
    • Check the Allow control of XBMC via HTTP option
    • Set the - Port option to 8080 (this should be the default value)
    • The - Username & - Password options can be set to any value you choose (but you'll need to remember them)
    • Leave the - Web interface option as default.
  3. Select the Remote Control menu option:
    • Check the Allow programs on this system to control XBMC option
    • Check the Allow programs on other systems to control XBMC option
  4. Select the Zeroconf menu item and check the Announce these services to other systems via Zeroconf option.

Now we need to allow the remote control access to Kodi/XBMC (via HTTP) via the firewall (because you do have it enabled, don't you!). Both Yatse & the XBMC remote controls are web-based controls; that is, they send their commands via the local area network to the PC hosting Kodi/XBMC (as opposed to an IR or bluetooth remote). Open a terminal and do:

sudo ufw allow proto tcp from 192.168.1.0/24 to any port 8080 && sudo ufw allow proto udp from 192.168.1.0/24 to any port 9777

This is really two commands rolled into one. If you prefer, you can do each separately:

sudo ufw allow proto tcp from 192.168.1.0/24 to any port 8080

Followed by:

sudo ufw allow proto udp from 192.168.1.0/24 to any port 9777

Note, that you may need to change your IP range depending on your hardware. You can check that your firewall has updated its rules using:

sudo ufw status

And then restart your firewall (perhaps not entirely necessary) using:

sudo ufw reload

Now we can set up the remote! If you haven't already, download the XBMC remote from the Google Playstore.

  1. Start the XBMC remote app on your Android smartphone.
  2. From the app home screen, tap your phone's menu button and select Settings
  3. Tap Manage XBMC Hosts.
  4. Tap your phone's menu button and select Add Host.
  5. In the Add new host dialog:
    • Name of this instance: - anything that will identify your host. XBMC can manage multiple hosts, so this is simply a name that tells you which host you are connecting to.
    • Host or IP address: - I had no joy using host names - use your IP address. If you don't want to use ifconfig (from the terminal), from the Kodi/XMBC home screen select the System info sub-menu option from the System option and look under the Summary option.
    • HTTP API port: - leave this as the default 8080 (unless you've changed it for some reason)
    • Username: - You set this earlier (I did tell you to remember it!)
    • Password: - this is the password that you set for Kodi/XBMC and not your host password.
    • EventServer port: - leave as the default 9777 value (unless you've changed it for some reason
    • Leave all other settings at their default values and tap OK
  6. Tap your smartphone's back button
  7. Tap your smartphone's back button (yes, for a second time)

You should be able to connect to your host by tapping the smartphone's menu button & selecting Switch XBMC or from the right-hand applet on the XBMC remote's home screen.

On balance, I like the reliability and stability of the XBMC remote over Yatse, but Yatse is more configurable and looks great. In the end, this is a matter of user choice, but XBMC is free and there are no paid for upgrades.

Sources & References:

Wednesday, 17 December 2014

Jogga's HTPC

Intended design of the HTPC (when I've saved enough money :)

Parts List

  1. CPU: AMD A6-5400K 3.6GHz Dual-Core Processor (£39.99 @ Amazon UK)
  2. Motherboard: ASRock FM2A88M-HD+ Micro ATX FM2+ Motherboard (£46.80 @ Amazon UK)
  3. Memory: G.Skill Ripjaws Series 4GB (2 x 2GB) DDR3-1333 Memory (£35.17 @ Amazon UK)
  4. Storage (Operating System & files): Kingston SSDNow V300 Series 60GB 2.5" Solid State Drive (£32.90 @ Amazon UK)
  5. Storage (Media): Western Digital WD Green 2TB 3.5" 5400RPM Internal Hard Drive (£59.90 @ Amazon UK)
  6. Case: Fractal Design Core 1100 MicroATX Mini Tower Case (£29.99 @ Amazon UK)
  7. Power Supply: Corsair Builder 500W 80+ Bronze Certified ATX Power Supply (£51.50 @ Amazon UK)
  8. Optical Drive: Samsung SH-224DB/BEBE DVD/CD Writer (£10.46 @ Aria PC)

Total: £306.71 (correct as of 17/12/14)

I'm living without a discrete graphics card (unless the build demonstrates a need to reconsider) and I'm recycling an existing TP-Link wireless card for networking. The speakers will probably be my existing DELL setup until I can afford a sound bar and I've already recycled a 1TB hdd from my busted NAS.

Control will be via my existing Logitech K400r wireless keyboard & my Samsung A3 advance smartphone.

The operating system will be Linux Mint 17 (obviously) although I have considered openelec. The media centre will be Kodi (formerly known as XBMC).

Criticism & advice welcome!

Sources & References:

Reconnecting With Your SSH Server after an Upgrade

I recently got around to updating my file server's operating system (from Mint 16 to Mint 17) and, in accordance with the law of unintended consequences, I found that I could no longer access my files using secure shell!

What I did get was an error message telling me that the host key verification [test had] failed. When you think about it, I should have anticipated the problem, after all, the original key was hashed under a different implementation of SSH Server as well as a different operating system! Fortunately, the fix is quite simple, particularly if you're only connecting to one host.

For a Single Host


Navigate to to the .ssh folder in the home/username directory (username will be unique to your circumstances). Remember that the period (full stop) indicates that this is a hidden folder, so you should ensure that you have the Show Hidden Files option enabled in your file browser. Delete the known_hosts file in the .ssh directory.

Now reconnect with your SSH host and a new key will be created following the usual warning that this is a new (and unknown!) host.

For Multiple Hosts

The error message will identify a line number in the know_hosts file; make a note of the number and open a terminal:

gksu gedit /home/username/.ssh/known_hosts

You will be prompted for your password. When the file is opened, delete the offending line, save the file and reconnect with your server. You should be prompted to recreate the key as if this were a first connection.

If you accidentally delete the wrong line (or the whole file, for that matter), fear not, the individual keys will be recreated when you next connect to your SSH server(s).

Sources & Resources:

  • None

Setting Up Yatse Remote Control for XBMC

My recent project to repair and consolidate my music library seems to have taken on a life of its own!

You may recall that back in September, my NAS failed leaving me with a spare 1TB hdd. Having fixed my music library, I decided to back-up my DVD library and build an HTPC around the redundant drive: it's taken months and I'm nowhere near finishing! Last night, the DELL Dimension, the DELL Inspiron, & the Compaq CQ60 were all backing-up movie files.

Designing a PC to fit around the drive has been fun, and I think that I can build a first-class rig for around £300 but money is a real issue at the moment and I've had to make compromises. One consideration is how to control the rig from my sofa: originally, I'd planned to use my Logitech K400r wireless keyboard (from my file server), saving myself a few quid on an IR remote control. However, on yesterday's RSS feed, Maximum PC did a piece on getting started with XBMC and I came across a reference to a smartphone app called Yatse XBMC also offers an official remote, which under test, is just as good but a little more difficult to set up.

Downloading and installing Yatse on your Android phone or tablet is simple (just head over to the Google Play Store & search for xbmc remote or Yatse), the basic app is free. However, getting the app to play nice with XBMC can be a little tricky! When you open the Yatse app, you should be prompted to add a server (called Host in Yatse). The nice thing with this app, is that the wizard does quite a lot of the work for you - you should only need to select the Host, add a username and a password (if you've enabled them in Kodi/XBMC. However, the setup may fail if you're running a firewall on your Linux box.

If you are running a firewall (and you should be!), you'll need to open a couple of ports for Yatse or XBMC Remote to work properly. Open a terminal and do:

sudo ufw allow proto tcp from 192.168.1.0/24 to any port 8080

Followed by:

sudo ufw allow proto udp from 192.168.1.0/24 to any port 9777

You may need to change the ip range to suit your router and, depending on your version of Kodi/XMBC, your tcp port. Unless you've done something very unusual on your system, the udp port should be left at the default value of 9777. In Kodi Gotham, you can check your tcp port under System > Settings > Services > Webserver, but I suspect that it will be a similar route in earlier versions.

Sources & References:

Sunday, 5 October 2014

Fixing The Internal Microphone - Presario CQ60

It's taken weeks of Googling, but I've finally found a fix for the internal microphone on the Presario CQ60.

I had no luck with the various fixes that I found online until I came across this post which, if I've understood it correctly, suggests that the problem with the internal microphone on the CQ60 is not a software issue but a hardware problem. As I understand the OP's problem, the kernel allocates the wrong pin id at boot: the workaround turns out to be surprisingly simple.

First we need an application developed by David Henningsson at Canonical. It's called HDAJackRetask and it was originally developed to turn unused microphone jacks into additional headphone jacks - brilliant! It's now part of the alsa-tools-gui, so there's no need to add a new repository. Open a terminal and do:

sudo apt-get install alsa-tools-gui

Alternatively, you can download it from the Software Center or Synaptic. When prompted about the additional space (in the terminal method), type y and hit enter.

Open HDAJackRetask from the Main Menu (in Mint Cinnamon it's under Sound & Video). Select your sound card and then, under the Options panel, check the Show unconnected pins option. In the Pin configuration section, look for your Internal Mic, Riser entry, click the Override checkbox, and set the spin button to Not connected.

Next, look for the Pin ID: 0x1d, check the Override checkbox, and the use the spin button to select Internal mic. Now click the Apply now option and test your microphone. If all's gone well, it's time to make this a permanent change: click the Install boot override. You'll see the following message dialog: click OK and reboot.

Sources & References:

Friday, 26 September 2014

CQ60 - Reminted

It wasn't long before the new Presario CQ60 ran into problems: despite managing to achieve stable graphics using Mint 17 Mate, I couldn't seem to maintain a persistent WiFi link. Often, the hardware button wouldn't work and, even when it did, it rarely made a difference as to whether or not the laptop connected to my network. Issuing the terminal command:

rfkill list

would show the hardware blocked and the command:

rfkill ublock all

had no effect. It was sometime before I realized that this is by design! It was clear that I had to find a way to make the hardware switch work if I wanted this laptop to be more than a vanity project.

Having read some comment online that Lubuntu had a more reliable wireless platform, I installed the latest version (14.04 LTS) of the Ubuntu derivative to see if it made any difference: it did, effectively ruling out hardware as the source of the problem. Had I merely wanted a functioning laptop I could easily have left the lightweight operating system in place but, whilst this is undoubtedly a viable solution, the truth is that I'm not terribly keen on Lubuntu and I really love Mint Cinnamon. There are also some practical networking reasons for preferring Mint over Lubuntu (specifically, native SSH support) and I want to migrate from SAMBA to manage my network, so the research effort began!

This problem with the Presario is not entirely unknown and it seems that there is no single solution. Nonetheless, there does seem to be an online consensus that replacing the ath5k driver for the Atheros chipset for the ath9k driver is the most successful fix and I resolved to give it a try. However, fate intervened to scupper my plans.

At some time on Wednesday of this week I lost my WAN connection: this makes testing a WiFi connection problematic! It was twenty-four hours before the restoration of my connection and I didn't get around to reinstalling Mint until late yesterday afternoon. I decided to go for Mint 17 Cinnamon and, as always, the WiFi connection was flawless on the live disk but, more importantly, it was also flawless after installation to the ssd and I have no idea why! This condition has persisted beyond the initial (307MB) software updates and countless reboots (both restarts & cold boots), so I'm assuming that the problem is resolved. I can only identify two candidate processes that may have influenced this change in fortune:

  1. I didn't format the /home partition during installation but used the existing partition that I set up when I installed Lubuntu.
  2. I had to reset my hybrid router yesterday in order to re-establish a link to the WAN when my connection came back up.

It's not clear if either or both of these changes had the desired effect, but I remain connected a day after installation!

Having also had some unpleasant experiences with the graphics drivers during previous implementations of Mint, I decided to install the nvidia-304 legacy driver right off the bat and it has proved to be a good decision. Sure, the boot sequence isn't as pretty as it would be using the default nouveau driver, but, with the improved boot time delivered by the new ssd, who cares? Moreover, there is absolutely no flicker or distortion during operation and I now have a stable (as well as, connected) Mint 17 Cinnamon installation.

This little laptop has exceeded expectations although it has proved to be quite a challenge to get it running the Mint OS. The irony is that, despite learning a great deal about networing drivers in Ubuntu, I can offer no explanation as to why the problem has been rectified but I'm thrilled that they have been.

Sources & Reference:

  • Ubuntu Manual Pages: rfkill (see ublock)
  • Lubuntu: Home

Monday, 11 August 2014

Mint 17 Cinnamon & The DELL DIMENSION 8400

This month (August), my DELL Dimension 8400 is ten years old & it's getting a birthday present - a new operating system!

"I'm constantly amazed at how well Ubuntu runs on older equipment."

I had been running Mint 16 on the old box, but as this is no longer supported, it's time to see how well Mint 17 will run.

Installation was, as always, painless, although I can't install from a DVD on this box (it has to be a USB). I've also taken the opportunity to encrypt the /home directory & change my password. Now I've got to:

  • Install Samba & Winbind
  • Enable UFW
  • Install my Photosmart 7600 (yes, a 7600!) local printer & my Photosmart C6280 network printer
  • Install Chromium
  • Install Bluefish
  • Install Cairo-Dock

...well, you get the idea!

Sources & References:

  • None

Tuesday, 24 June 2014

Why I've got a Taste For Cinnamon

There comes a time when you just want stuff to work. Windows & Mac users have enjoyed this feature for years and, if Linux wants to be viewed as a viable alternative, it (at least, the stable versions) has to emulate its competitors.

The other issue facing Linux distros is that the release/support cycle must be longer if Windows users are to be persuaded to abandon their point & click systems. Ubuntu has led the way in this regard and it's nice to welcome the fabulous Mint distro to the long term support stable.

But, is Mint a viable system for new users? With the Petra release's forthcoming end-of-life, it was time to upgrade the various pc hanging around the apartment and an ideal opportunity to evaluate its potential as an out-of-the-box operating system.

As I'd been using (and thoroughly enjoying) the Mate desktop since migrating my systems from Ubuntu, I thought I'd simply upgrade to Qiana (17) using the GNOME 2 successor and maintain some continuity between releases. Installing Linux Mint's new LTS release on Inspiron 6400 was painless enough and the OS looked as great as ever but I had some niggles:

  • The wireless network applet left an on-screen artefact after displaying notification pop-ups.
  • Cairo Dock would flicker on mouse hover.
  • The main menu wouldn't always activate on demand.
  • Bluetooth wouldn't accept transfer requests even after installing Blueman.

To be sure, these are minor problems and I'm confident that, with a little effort, they could all be resolved. Nonetheless, whilst I've always been happy to tweak my Linux systems to get them working to my satisfaction (and I hope that this Blog bears testimony to that claim), for once it would be nice to have a system that worked out of the box. So, rather than spend hours resolving these problems, I thought I'd see if the Cinnamon desktop gave me any more joy.

Just like it's stable-mate, installing Qiana with the Cinnamon desktop is easy and it looks even more stunning than the Mate desktop. Even better, on the DELL Inspiron, the menu works as it should and there are no strange artefacts to worry about.

So far, so good. But, does Bluetooth work? Well, not out-of-the-box: but simply installing Blueman resolves the transfer problem and you can do that without even opening a terminal by installing from the Software Manager. Only Cairo-Dock to sort out and I'd already found the answer to that problem!

Ok, so not quite out-of-the-box: as always I had to install the b43 WiFi driver and setup Samba to get network shares but I'd have to do that with any Linux distro. This will always be a barrier to casual Windows users adopting Linux. Nonetheless, Mint is as close to the real deal as Ubuntu and, in my view, looks better. Moreover, Mint is more flexible and extensible: more in keeping with the tradition of Linux operating systems.

Sources & References:

Monday, 23 June 2014

Quick Tip - Fix the Flicker

If you're using Cairo Dock on Mint 17 & you are witnessing flickering when you hover the mouse over the dock, the fix is simple!

Open the Startup Applications dialog (Main Menu > Preferences > Startup Applications), select the Cairo-Dock entry, & click Edit.

Amend the Command field to read:

cairo-dock -o

This forces Cairo Dock to use the Open Graphics Library at startup and should resolve any flickering problems.

If this doesn't do the trick, try using the Cairo backend:

cairo-dock -c

Sources & References: