README: Update to match changes from 2106ebf1

This commit is the result of running `make doc`, which keeps README.rst
in sync with the reality of the default values in stbt.conf.
Travis Integration: Add travis file, and other minor fixes to ensure build works

The new .travis.yml file contains all the instructions travis-ci needs
to build and test stb-tester. I've dry-run it on my public fork of
stb-tester (as can be seen here:
https://travis-ci.org/stestagg/stb-tester/builds/6815758).

In order to accomodate some differences between Fedora and Ubuntu, I had
to tweak the pylint settings. Some of the (more pedantic) exceptions
have been moved into extra/pylint.sh rather than being repeatedly
declared inline.

I also slightly refactored the two context manager classes to use
collections.contextmanager, which is a more common pattern, and also
removes some pylint complaints. The VirtualRemote listener wait time was
also increased slightly to prevent some intermittent failures I was
seeing with the travis VMs.

[Committer's note:

travis-ci.org provides a free service for open-source projects: They
monitor your repository on github, and for every commit they spin up a
VM running Ubuntu 12.04, set it up according to your instructions in
.travis.yml, and run your unit tests. GitHub's web interface shows the
Travis status for each pull request, which is particularly handy.

The pylint changes were necessary due to differences in the pylint
version supplied with Ubuntu 12.04 (0.25.1?) vs. Fedora 17 (0.26).

The formatting change at stbt.py:1240 is necessary to avoid confusing
pylint: You need to disable the E1101 because of poor interface
inference, but doing so seemed to make the pylint parser think that line
1240 had stuff after the opening "(". This meant that the '000000' line
was considered under-indented (E128).
]
stbt.py nosetests: Exit gracefully on failure

The significance of the `threading.Thread.daemon` flag is that the
entire Python program exits when only daemon threads are left.

This way, if the test fails or you press Control-C, the test exits
instead of hanging.

Thanks to Steve Stagg for the tip.
stbt.py: Cleanup: Fix typo in comment
stbt.py: Support multiple lirc devices connected to the same host

To use multiple LIRC devices connected to the same host:

(1) Stop and disable lirc service:

sudo systemctl stop lirc.service
sudo systemctl disable lirc.service

(2) Run multiple `lircd` instances, and set the TCP ports that each
device listens to:

sudo lircd --device=/dev/lirc0 --pidfile=/var/run/lirc/lirc0.pid \
    --listen=8700 --output=/var/run/lirc/lircd
sudo lircd --device=/dev/lirc1 --pidfile=/var/run/lirc/lirc1.pid \
    --listen=8701

lirc0 and lirc1 can be addressed individually using the assigned TCP
ports.

(3) Send keys by sending a LIRC command string to the TCP socket:

echo -e "SEND_ONCE humax MENU" | nc localhost 8765

It's also possible to output keys via a LIRC device of a remote computer.

(4) To auto-launch lircd when a new device is attached, and auto-kill it
when the device is removed, add the following to
/etc/udev/rules.d/10-local.rules:

ACTION=="add", KERNEL=="lirc*", RUN+="/usr/bin/sh -c '/usr/sbin/lircd --device=/dev/$kernel --listen=$((8700 + $number)) --pidfile=/var/run/lirc/$kernel.pid 2>&1 | xargs -rL1 logger'"
ACTION=="remove", KERNEL=="lirc*", RUN+="/usr/bin/sh -c 'kill $(</var/run/lirc/$kernel.pid) 2>&1 | xargs -rL1 logger'"

Make sure not to break a rule to multiple lines.

It starts lircd listener on port (8700 + N) where 'N' is the device
number as in /dev/lircN. Errors are logged to /var/log/messages.

(These instructions were tested with Fedora 17.)

* * *

To put both IR devices into use by stb-tester, all we need is a new
remote type with "hostname", "port" and "remote_control_name" parameters
that uses 'VirtualRemote._connect' to connect and 'LircRemote.press' to
send keys. Similarly, for recording, a new listener type that uses
'VirtualRemote._connect' to connect and 'lirc_key_reader' to interpret
remote keys.

Closes #9.
Add a standalone irnetproxy.py script for the RedRat irNetBox III

The irNetBox only allows one network connection at a time.  This means
the 16 ir ports it has cannot be easily controlled by multiple clients
simultaneously.

This script allows many clients to connect to the device, and use
the ports concurrently.  **Note**, this only makes sense for the
Asynchronous IO Output Commands, other commands will be run
synchronously as before.

http://www.redrat.co.uk/products/IRNetBox_Comms-V3.X.pdf

Usage
-----

```
$ irnetproxy -r <irNetBox address>
```

OR

```
$ irnetproxy --irnetbox-addresss <irNetBox address> \
             --irnetbox-port 10001\
             --listen-port 10001\
             --listen-address 127.0.0.1\
             -vv

> Listening for connections on 127.0.0.1:10001
```

Existing irNetBox network clients should then connect to the proxy
server, rather than the irNetBox.  Everything else should behave the
same.

Features
--------

 - Session multiplexing: irnetproxy dynamically maps Asyncronous
   Sequence IDs on the fly, meaning that multiple clients can use the
   same Sequence ID concurrently, and the irnet box will continue to
   work.  Both the command acknowledgement, and the subsequent Async
   complete message are always routed to the correct client.

 - On/Off management: irnetproxy will silently accept the on and off
   messages (5 and 6).  A standard ACK response is returned to the
   client, but the command is never sent to the device. This allows
   multiple scripts to try to turn off the device while other devices
   use it.  irnetproxy issues the ON command when it connects, and
   issues an OFF command when it is stopped.