On Wednesday 06 December 2006 22:08, Nicholas Perez wrote:
> Looks like all the setup stuff for the device is done with POSIX
> inside of Device::SerialPort using POSIX::Termios. Doing all of the
> setup for the device could be handled in the constructor of the
> Driver. I didn't look much farther, but this does look doable.
While we're at it, let's not forget the poor Win32 users: -
BEGIN {
$OS_win = ($^O eq "MSWin32") ? 1 : 0;
printf "Perl version: $], v%vd\n", $^V;
print "OS version: $^O\n";
# This must be in a BEGIN in order for the 'use' to be conditional
if ($OS_win) {
print "Loading Windows module\n";
eval "use Win32::SerialPort";
die "[EMAIL PROTECTED]" if ($@);
} else {
print "Loading Unix module\n";
eval "use Device::SerialPort";
die "[EMAIL PROTECTED]" if ($@);
}
} # End BEGIN
Regards,
Michael Erskine.
--
* Culus thinks we should go to trade shows and see how many people we
can kill by throwing debian cds at them