Installation

A bit tricky, but don't worry, you'll get through it

These instructions are talyored for Ubuntu 12.04 / Linux Mint 13

Dependencies

Currently, wxDatalinkUSB depends on four things: a patched version of libdlusb for watch communication, libical for importing iCals, libcsv for importing CSV files, and wxWidgets for drawing the user interface.

Installing wxWidgets

This has gotten a bit easier lately.

Install wxWidgets:
sudo apt-get install libwxgtk2.8-dev

Installing libdlusb

Even if you already have libdlusb you need to patch it

Libdlusb requires libusb-dev. Obtain libusb-dev through your package manager. In Ubuntu, we can use apt:

Install libusb-dev:
sudo apt-get install libusb-dev

To compile software, you'll need a compiler (we'll use gcc and g++). In Ubuntu, we can again use apt:

Install gcc and g++
sudo apt-get install build-essential

As of this writing, the current version (0.0.9c) of libdlusb does not support all of the features that wxDatalinkUSB requires, so you need either use a patch-file or download the already patched source.

Here we are going to assume that you downloaded the already-patched source.

First, unpack the archive (change directory into wherever you downloaded it first):

tar -xzvf libdlusb-wxdlusb-0.0.9c.tar.gz

Next, change into the directory and run configure:

cd libdlusb-0.0.9c
./configure

Now compile the library, become root, and then install it. Note that in some distributions this is usually accomplished by using the su command instead of sudo.

make
sudo make install

Installing libical

Here we can just use apt-get again:

Install libical:
sudo apt-get install libical-dev

Installing libcsv

One last library, and then we can install wxDatalinkUSB. This one is libcsv, which is used for importing CSV formatted contacts. As usual, first download libcsv (note that we're using version 2.0.1 instead of the newest here).

First, change directory into wherever you saved the file. Then the installation procedure is basically the same except that libcsv doesn't have configure:

Unpack the archive:
tar -xzvf libcsv-2.0.1.tar.gz
cd libcsv-2.0.1


Note for 64-bit installations

Because libcsv does not have configure you have to do one extra step. First, open the makefile:

gedit Makefile

Find the following lines (line 34-35):
libcsv.o: libcsv.c csv.h
$(CC) $< -c -o $@

And change them to this:
libcsv.o: libcsv.c csv.h
$(CC) $< -c -fPIC -o $@

Run make:
make

Install:
sudo make install

Installing wxDatalinkUSB

Congratulations! All the required dependencies have been installed! That wasn't too bad, right? Installation for wxDatalinkUSB basically the same. First, get the archive.

Next, unpack it, configure, make, and make install

Unpack the archive:
tar -xzvf wxDatalinkUSB-0.0.5.tar.gz

Run configure and then make (the -j3 option uses multiple CPU cores to speed things up):
cd wxDatalinkUSB-0.0.5
./configure
make -j3

Install:
sudo make install

Configuring your system

You now have everything installed. Check to make sure that everything is working by running wxDatalinkUSB:

wxDatalinkUSB

If you see a nice window pop-up, you have installed everything correctly. However on most systems you need to configure your system to allow you to access the USB watch. To do this, we are going to configure udev to allow access to the watch.

First, create a new file called 10-timex.rules in /etc/udev/rules.d using your favorite text editor. Here we are using gedit.

Create udev rule:
sudo gedit /etc/udev/rules.d/10-timex.rules

Put the following text in the file:

# udev rules file for libdlusb
# Timex Datalink USB Watch
ATTRS{idVendor}=="0cc2", ATTRS{idProduct}=="d700", MODE="0664", GROUP="plugdev"

This file tells your computer to recognize the watch and to give access to it.
Finally, we need to reload the udev rules. This can be done by rebooting or typing:

Reload udev rules:
sudo udevadm control --reload-rules

Congratulations! You have successfully installed wxDatalinkUSB. Now just run

wxDatalinkUSB

and enjoy a user-friendly interface to the Timex Datalink USB watch.