The parallel port PWM and/or encoder kernel space Linux driver allows open/closed loop control of motors using the parallel port.
Developed to provide a very cheap alternative for motor control, which is awesome news for the robotic hobbyist., wishing to control high powered motors cheaply.
tar xvfz ParportPWMEncoderDriver-1.2.tgz
cd ParportPWMEncoderDriver-1.2
make
sudo make install
sudo insmod lp_pwm.ko
sudo insmod lp_encoder.ko
sudo insmod lp_encoder.ko lp_encoder_io_base=0x370,0x378 \ lp_encoder_linked_encoders="","5+4" lp_encoder_int_output=1
This means use two parallel ports, one at port 0x370 and one at 0x378 with the first port having no quadrature links, and the second having a link between pins 4 and 5. Also, integer output is in effect.
sudo ./MakeDevices
insmod lp_pwm.ko lp_pwm_int_input=1
sudo echo "5" > /dev/pwm0
sudo echo "0x38" > /dev/pwm0
sudo echo /dev/encoder0
The latest version can always be found within DROS at http://dros.org under: DROS/src/Utils/ParportPWMEncoderDriver/
Alternatively you can click here to download the standalone version ParportPWMEncoderDriver-1.2.tgz.
NOTE: A USB joystick command line program (jsRobot) to control one, two or four motors, locally or over the network using UDP packets, via this parallel port PWM/Encoder driver can be found within DROS under: DROS/src/Robot/Controllers/Basic/JoystickDrive
Minor fix: updated changed DECLARE_WORK marco.
Replaced deprecated MODULE_PARM() with module_param*() routines.
Inital code release. This release contains a kernel space Linux driver to send PWM's and receive Encoder signals.