X-line LINUX KERNEL DRIVER NOTES
================================

This driver supports the following Xline boards:

- X10
- X10i
- X15
- XSpin
- XLuminate
- XTopper


To compile a module for Linux under version 2.6, a full set of configured kernel source files are needed. The makefile
is only useful if it called by the kernel makefile.


To build the driver issue the following command from the driver directory:

	make -C /usr/src/linux SUBDIRS=`pwd` modules

	
If your target kernel source isn't in /usr/src/linux then the path will need changing.

If you are compiling on the target machine:

	make -C /usr/src/linux SUBDIRS=`pwd` modules_install

will copy the newly made xline.ko to the correct place in the /lib/modules. Otherwise to install into the target
filesystem mounted on the development machine run:

	make -C /usr/src/linux SUBDIRS=`pwd` INSTALL_MOD_PATH=/mnt/target-rootfs/ modules_install


The module can then be loaded on the target machine either by issuing the command:

	modprobe xline
or:

	insmod path to file/xline.ko


To remove the driver:

	rmmod xline

This kernel driver has been built to use the 2.6 Sysfs file system. The driver 
creates a new sysfs class (in /sys/class) called Xline. When an XLine board is detected the driver adds a new
entry to this class. Each entry contains a symbolic link to the USB bus entry in /sys assoiated with that
particular device. The fflyusb library uses this to detect XLine boards, their type and what type of USB connection 
they are using.

Most modern (2.6 based) systems mount a ram based file system over /dev early in the boot process. A user space daemon
udev then walks the sysfs tree and populates this new /dev with entries specific to the hardware present.
Because the XLine driver adds entries to /sys, if udev is being used then it will automatically create /dev/Xline_x
entries as XLine devices are plugged or unplugged (it normally it takes 5 or 10 seconds for this to happen).

Certain characteristics of the device nodes created by udev can be altered using rules. For example to make the device
nodes read/writable by everyone add the following rule to the udev rules file, commonly /etc/udev/rules.d/50-udev.rules:

KERNEL=="Xline_*",NAME="%k",MODE="666"

If you wish to specify a group you can add ,GROUP="my_group_name" to the line. 


Note: if using kernel version 2.6.26 or later, ensure the kernel configuration option CONFIG_SYSFS_DEPRECATED is not
set, otherwise the Xline_x symbolic link in sysfs will not be correct and the fflyusb library will be unable to open
communications with the XLine board.


