jay-to-the-dee / pearlfan

GNU/Linux kernel driver and libusb app for Pearl USB LED fan.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MaplinFan

Build Status License

This is a fork of PearlFan

7160 PearlFan fork provides a GNU/Linux Kernel driver and a libusb application for the Maplin USB Programmable LED fan.

Installation

Dependencies

Archlinux:

  • libusb-1.0 - Library that provides generic access to USB devices
  • netpbm - Toolkit for manipulation of graphic images (with libraries and header files)

Ubuntu:

  • libnetpbm10-dev - Netpbm libraries and header files
  • libusb-1.0-0-dev - Library that provides generic access to USB devices

Build

$ make

Usage

pearlfan -c FILE  [-f]
pearlfan -d DIRECTORY [-f]
pearlfan -t TEXT [-f]

Setting:
  -c:  Displays at most eight images with transition effects described
       in the given config FILE.
  -d:  Displays at most eight .PBM images (156x11) in DIRECTORY.
  -t:  Draws TEXT (standard ASCII table). Words are not split, only huge words.

Mode:
  -f:  Enables fast-mode. Disables all others effect transitions.

Miscellaneous:
  -h:  Prints this help and exits.
  -v:  Prints version info and exits.

Examples

$ ls images/
pacman.pbm
mario.pbm
file.config

$ cat file.config
pacman.pbm  +2-2-0
mario.pbm   +1-1-6

$ pearlfan -c images/file.config    (or)
$ pearlfan -d images/               (without config file)

Configuration File

Sample

This an example of a pfan's configuration file

pacman.pbm  +2-2-0
mario.pbm   +1-1-6
circle.pbm  +0-0-0
cols.pbm    +3-3-6
full.pbm    +2-5-0

Specifications

Each configuration file consists of the following:

  • line pattern: {image_basename}.pbm+{effects}
  • Whitespace (blanks and TABs) between {image_basename}.pbm and + are ignored (cf. example above)
  • The image must be in the same directory than the configuration file
  • The image must be .PBM image
  • The image size must be: width=11px, height=156px
  • {effects}: the fan provides transition effects when displaying and switching images
  • Effect's pattern: {open}-{close}-{beforeclose}
  • Open, close and beforeclose's exclusive values are described in the table below
  • The fan can display at most 8 images

Effect values

Effects/Value 0 1 2 3 4 5 6
open right-left left-right 2-side red-carpet top-bottom bottom-top fast-mode
close left-right right-left 2-side red-carpet top-bottom bottom-top x
before-close none x turn left-right x x x turn right-left
  • x: unused and considered as invalid value
  • none: disable
  • fast-mode: skip the 'open' and 'before-close' transition effects

About

GNU/Linux kernel driver and libusb app for Pearl USB LED fan.

License:GNU General Public License v3.0


Languages

Language:C 75.7%Language:Objective-C 22.2%Language:Makefile 2.2%