holandes777 has asked for the wisdom of the Perl Monks concerning the following question:

I'd like to use my parallel port to get input from a pushbutton switch button, the following:
use strict; use Device::ParallelPort::drv; my $pp = Device::ParallelPort::drv::auto->new("'LPT':1");
Generates the following error
 
Can't locate object method "new" via package "Device::ParallelPort::drv::auto" ( perhaps you forgot to load "Device::ParallelPort::drv::auto"?) at kk.pl line 3.
 
Has anyone used the Device::ParallelPort stuff successfully? If so, what's the secret please? Thanks!

Replies are listed 'Best First'.
Re: Parallel Port Puzzlement
by grep (Monsignor) on Oct 21, 2006 at 23:03 UTC
    I would not recommend a parallel port, there is more to it than just reading an on/off signal. Use a joystick port it's the simplest way to get analog or pushbutton data into a PC (trust me I have spent days figuring this out).

    As to your question, Device::ParallelPort::drv::auto says to do:

    use Device::ParallelPort; my $pp = Device::ParallelPort->new('auto:0');


    grep
    One dead unjugged rabbit fish later
Re: Parallel Port Puzzlement
by Joost (Canon) on Oct 21, 2006 at 22:57 UTC