kopia lustrzana https://gitlab.com/sane-project/backends
Mainly documentation updates...
rodzic
60ef6c0d21
commit
0388dd02a5
|
@ -1,6 +1,12 @@
|
|||
2003-09-24 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
|
||||
* doc/sane.man, AUTHORS: added plustek_pp information
|
||||
* doc/backend-writing.txt: Updated CHECKLIST information
|
||||
* doc/sane-plustek.man: removed parport sections
|
||||
* doc/sane-plustek_pp.man: removed usb sections
|
||||
* backend/plustek.c: changed version number
|
||||
* backend/plustek-pp.*: changed file headers and copyright info
|
||||
applied some minor fixes
|
||||
|
||||
2003-09-23 Frank Zago <fzago at austin dot rr dot com>
|
||||
|
||||
|
|
|
@ -97,8 +97,6 @@
|
|||
#define _NEG_X ((double)_NegativePageWidth/300.0 * MM_PER_INCH)
|
||||
#define _NEG_Y ((double)_NegativePageHeight/300.0 * MM_PER_INCH)
|
||||
|
||||
#define _MAX_ID_LEN 20
|
||||
|
||||
/******************** from former plustek-share.h ***************************/
|
||||
|
||||
/*
|
||||
|
|
|
@ -1,50 +1,75 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustek-pp_dac.c - all the shading function formerly found in
|
||||
* shading.c.
|
||||
* don't ask me why I called this file dac.c...
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_dac.c -
|
||||
* @brief all the shading function formerly found in shading.c.
|
||||
* don't ask me why I called this file dac.c...
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - no changes
|
||||
* 0.32 - no changes
|
||||
* 0.33 - added some comments
|
||||
* 0.34 - slight changes
|
||||
* 0.35 - removed SetInitialGainRAM from structure pScanData
|
||||
* 0.36 - added dacP96001WaitForShading and changed dacP96WaitForShading to
|
||||
* dacP96003WaitForShading
|
||||
* changes, due to define renaming
|
||||
* 0.37 - removed dacP98FillShadingDarkToShadingRegister()
|
||||
* removed // comments
|
||||
* some code cleanup
|
||||
* 0.38 - added P12 stuff
|
||||
* 0.39 - no changes
|
||||
* 0.40 - disabled the A3I stuff
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - no changes
|
||||
* - 0.32 - no changes
|
||||
* - 0.33 - added some comments
|
||||
* - 0.34 - slight changes
|
||||
* - 0.35 - removed SetInitialGainRAM from structure pScanData
|
||||
* - 0.36 - added dacP96001WaitForShading and changed dacP96WaitForShading to
|
||||
* dacP96003WaitForShading
|
||||
* - changes, due to define renaming
|
||||
* - 0.37 - removed dacP98FillShadingDarkToShadingRegister()
|
||||
* - removed // comments
|
||||
* - some code cleanup
|
||||
* - 0.38 - added P12 stuff
|
||||
* - 0.39 - no changes
|
||||
* - 0.40 - disabled the A3I stuff
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -2416,7 +2441,7 @@ static Bool dacP98003WaitForShading( pScanData ps )
|
|||
|
||||
/**
|
||||
*/
|
||||
int DacInitialize( pScanData ps )
|
||||
_LOC int DacInitialize( pScanData ps )
|
||||
{
|
||||
DBG( DBG_HIGH, "DacInitialize()\n" );
|
||||
|
||||
|
@ -2452,7 +2477,7 @@ int DacInitialize( pScanData ps )
|
|||
|
||||
/** Fill out the R/G/B GainOut value
|
||||
*/
|
||||
void DacP98FillGainOutDirectPort( pScanData ps )
|
||||
_LOC void DacP98FillGainOutDirectPort( pScanData ps )
|
||||
{
|
||||
ps->OpenScanPath( ps );
|
||||
|
||||
|
@ -2465,7 +2490,7 @@ void DacP98FillGainOutDirectPort( pScanData ps )
|
|||
|
||||
/**
|
||||
*/
|
||||
void DacP98FillShadingDarkToShadingRegister( pScanData ps )
|
||||
_LOC void DacP98FillShadingDarkToShadingRegister( pScanData ps )
|
||||
{
|
||||
pUChar pValue;
|
||||
Byte bReg;
|
||||
|
@ -2486,7 +2511,7 @@ void DacP98FillShadingDarkToShadingRegister( pScanData ps )
|
|||
|
||||
/**
|
||||
*/
|
||||
void DacP98AdjustDark( pScanData ps )
|
||||
_LOC void DacP98AdjustDark( pScanData ps )
|
||||
{
|
||||
Byte bCorrectTimes; /* used to be a global var !*/
|
||||
|
||||
|
@ -2542,7 +2567,7 @@ void DacP98AdjustDark( pScanData ps )
|
|||
|
||||
/**
|
||||
*/
|
||||
void DacP96WriteBackToGammaShadingRAM( pScanData ps )
|
||||
_LOC void DacP96WriteBackToGammaShadingRAM( pScanData ps )
|
||||
{
|
||||
/* ModifyGammaShadingOffset(ps) */
|
||||
ps->OpenScanPath( ps);
|
||||
|
@ -2566,7 +2591,7 @@ void DacP96WriteBackToGammaShadingRAM( pScanData ps )
|
|||
|
||||
/**
|
||||
*/
|
||||
void DacP98003FillToDAC( pScanData ps, pRGBByteDef regs, pColorByte data )
|
||||
_LOC void DacP98003FillToDAC( pScanData ps, pRGBByteDef regs, pColorByte data )
|
||||
{
|
||||
if ( ps->DataInf.wPhyDataType > COLOR_256GRAY ) {
|
||||
|
||||
|
@ -2583,7 +2608,7 @@ void DacP98003FillToDAC( pScanData ps, pRGBByteDef regs, pColorByte data )
|
|||
|
||||
/**
|
||||
*/
|
||||
void DacP98003AdjustGain( pScanData ps, ULong color, Byte hilight )
|
||||
_LOC void DacP98003AdjustGain( pScanData ps, ULong color, Byte hilight )
|
||||
{
|
||||
if( hilight < ps->Shade.bGainLow ) {
|
||||
|
||||
|
@ -2613,7 +2638,7 @@ void DacP98003AdjustGain( pScanData ps, ULong color, Byte hilight )
|
|||
|
||||
/**
|
||||
*/
|
||||
Byte DacP98003SumGains( pUChar pb, ULong pixelsLine )
|
||||
_LOC Byte DacP98003SumGains( pUChar pb, ULong pixelsLine )
|
||||
{
|
||||
Byte bHilight, tmp;
|
||||
ULong dwPixels, dwAve;
|
||||
|
|
|
@ -8,19 +8,44 @@
|
|||
*
|
||||
*.............................................................................
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __DEBUG_H__
|
||||
#define __DEBUG_H__
|
||||
|
|
|
@ -1,47 +1,73 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustek-pp_detect.c - automatic scanner detection
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_detect.c
|
||||
* @brief automatic scanner detection
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - no changes
|
||||
* 0.32 - no changes
|
||||
* 0.33 - added portmode check
|
||||
* 0.34 - no changes
|
||||
* 0.35 - no changes
|
||||
* 0.36 - added some debug messages
|
||||
* replace the old _OUTB/_INB macros
|
||||
* 0.37 - cosmetic changes
|
||||
* added speed-test for the parallel-port
|
||||
* 0.38 - added P12 stuff - replaced detectP9636 by detectAsic9800x
|
||||
* added detectResetPort() function
|
||||
* 0.39 - fixed problem in ASIC9800x detection
|
||||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - no changes
|
||||
* - 0.32 - no changes
|
||||
* - 0.33 - added portmode check
|
||||
* - 0.34 - no changes
|
||||
* - 0.35 - no changes
|
||||
* - 0.36 - added some debug messages
|
||||
* - replace the old _OUTB/_INB macros
|
||||
* - 0.37 - cosmetic changes
|
||||
* - added speed-test for the parallel-port
|
||||
* - 0.38 - added P12 stuff - replaced detectP9636 by detectAsic9800x
|
||||
* - added detectResetPort() function
|
||||
* - 0.39 - fixed problem in ASIC9800x detection
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -377,7 +403,7 @@ static int detectAsic98001( pScanData ps )
|
|||
/*.............................................................................
|
||||
* here we try to find the scanner, depending on the mode
|
||||
*/
|
||||
int DetectScanner( pScanData ps, int mode )
|
||||
_LOC int DetectScanner( pScanData ps, int mode )
|
||||
{
|
||||
Byte asic;
|
||||
int result = _E_INTERNAL;
|
||||
|
|
|
@ -1,54 +1,80 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustek-pp_genericio.c - all i/o functions
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_genericio.c
|
||||
* @brief all i/o functions
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - moved ioP96ReadScannerImageData and ioP98ReadScannerImageData
|
||||
* into this file
|
||||
* added SPP-read functions
|
||||
* 0.32 - changes in function ioControlLampOnOff()
|
||||
* made IOReadingImage a local function -> ioP98ReadingImage()
|
||||
* rewritten function ioP96ReadScannerImageData()
|
||||
* moved function IOSetStartStopRegister to p9636.c
|
||||
* 0.33 - added debug messages to IOPutOnAllRegisters
|
||||
* fixed a bug in ioP96InitialSetCurrentSpeed
|
||||
* 0.34 - no changes
|
||||
* 0.35 - no changes
|
||||
* 0.36 - removed some warning conditions
|
||||
* 0.37 - moved functions IOSPPWrite(), IODataToScanner(), IODataToRegister(),
|
||||
* IODataFromRegister() to io.c
|
||||
* moved the data read functions to io.c
|
||||
* renamed IOInitialize to IOFuncInitialize
|
||||
* 0.38 - moved some functions to io.c
|
||||
* added P12 stuff
|
||||
* 0.39 - no changes
|
||||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - moved ioP96ReadScannerImageData and ioP98ReadScannerImageData
|
||||
* into this file
|
||||
* - added SPP-read functions
|
||||
* - 0.32 - changes in function ioControlLampOnOff()
|
||||
* - made IOReadingImage a local function -> ioP98ReadingImage()
|
||||
* - rewritten function ioP96ReadScannerImageData()
|
||||
* - moved function IOSetStartStopRegister to p9636.c
|
||||
* - 0.33 - added debug messages to IOPutOnAllRegisters
|
||||
* - fixed a bug in ioP96InitialSetCurrentSpeed
|
||||
* - 0.34 - no changes
|
||||
* - 0.35 - no changes
|
||||
* - 0.36 - removed some warning conditions
|
||||
* - 0.37 - moved functions IOSPPWrite(), IODataToScanner(), IODataToRegister(),
|
||||
* IODataFromRegister() to io.c
|
||||
* - moved the data read functions to io.c
|
||||
* - renamed IOInitialize to IOFuncInitialize
|
||||
* - 0.38 - moved some functions to io.c
|
||||
* - added P12 stuff
|
||||
* - 0.39 - no changes
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -1005,7 +1031,7 @@ static void ioP98InitialSetCurrentSpeed( pScanData ps )
|
|||
/*.............................................................................
|
||||
* here we do some init work
|
||||
*/
|
||||
int IOFuncInitialize( pScanData ps )
|
||||
_LOC int IOFuncInitialize( pScanData ps )
|
||||
{
|
||||
DBG( DBG_HIGH, "IOFuncInitialize()\n" );
|
||||
|
||||
|
@ -1044,7 +1070,7 @@ int IOFuncInitialize( pScanData ps )
|
|||
* 2) Refresh the scan states if necessary
|
||||
* 3) Wait for motor running within half-second period.
|
||||
*/
|
||||
Byte IOSetToMotorRegister( pScanData ps )
|
||||
_LOC Byte IOSetToMotorRegister( pScanData ps )
|
||||
{
|
||||
ps->OpenScanPath( ps );
|
||||
|
||||
|
@ -1068,7 +1094,7 @@ Byte IOSetToMotorRegister( pScanData ps )
|
|||
* 2) Read the recent state count
|
||||
* 3) Disconnect the path if necessary
|
||||
*/
|
||||
Byte IOGetScanState( pScanData ps, Bool fOpenned )
|
||||
_LOC Byte IOGetScanState( pScanData ps, Bool fOpenned )
|
||||
{
|
||||
Byte bScanState, bScanStateNow;
|
||||
|
||||
|
@ -1092,7 +1118,7 @@ Byte IOGetScanState( pScanData ps, Bool fOpenned )
|
|||
/*.............................................................................
|
||||
* ASIC 98003 specific function to read status 2 regiser
|
||||
*/
|
||||
Byte IOGetExtendedStatus( pScanData ps )
|
||||
_LOC Byte IOGetExtendedStatus( pScanData ps )
|
||||
{
|
||||
Byte b;
|
||||
|
||||
|
@ -1106,7 +1132,7 @@ Byte IOGetExtendedStatus( pScanData ps )
|
|||
/*.............................................................................
|
||||
* Read the scan state. Return the count with status bit, and count.
|
||||
*/
|
||||
void IOGetCurrentStateCount( pScanData ps, pScanState pScanStep )
|
||||
_LOC void IOGetCurrentStateCount( pScanData ps, pScanState pScanStep )
|
||||
{
|
||||
pScanStep->bStatus = IOGetScanState( ps, _FALSE );
|
||||
pScanStep->bStep = pScanStep->bStatus & _SCANSTATE_MASK;
|
||||
|
@ -1122,7 +1148,7 @@ void IOGetCurrentStateCount( pScanData ps, pScanState pScanStep )
|
|||
* This routine combines from SetupAsicDependentVariables & IsReadyForScan
|
||||
* routines in assembly source.
|
||||
*/
|
||||
int IOIsReadyForScan( pScanData ps )
|
||||
_LOC int IOIsReadyForScan( pScanData ps )
|
||||
{
|
||||
ULong dw;
|
||||
pULong pdwTable;
|
||||
|
@ -1186,7 +1212,7 @@ int IOIsReadyForScan( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void IOSetXStepLineScanTime( pScanData ps, Byte b )
|
||||
_LOC void IOSetXStepLineScanTime( pScanData ps, Byte b )
|
||||
{
|
||||
ps->AsicReg.RD_LineControl = b;
|
||||
ps->bSpeed1 = b;
|
||||
|
@ -1206,7 +1232,7 @@ void IOSetXStepLineScanTime( pScanData ps, Byte b )
|
|||
* 2) Refresh scan state
|
||||
* 3) Wait for motor running within half second.
|
||||
*/
|
||||
void IOSetToMotorStepCount( pScanData ps )
|
||||
_LOC void IOSetToMotorStepCount( pScanData ps )
|
||||
{
|
||||
ULong dw;
|
||||
pUChar pb;
|
||||
|
@ -1246,7 +1272,7 @@ void IOSetToMotorStepCount( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void IOSelectLampSource( pScanData ps )
|
||||
_LOC void IOSelectLampSource( pScanData ps )
|
||||
{
|
||||
ps->AsicReg.RD_ScanControl &= (~_SCAN_LAMPS_ON);
|
||||
|
||||
|
@ -1260,7 +1286,7 @@ void IOSelectLampSource( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
Bool IOReadOneShadingLine( pScanData ps, pUChar pBuf, ULong len )
|
||||
_LOC Bool IOReadOneShadingLine( pScanData ps, pUChar pBuf, ULong len )
|
||||
{
|
||||
TimerDef timer;
|
||||
|
||||
|
@ -1283,7 +1309,7 @@ Bool IOReadOneShadingLine( pScanData ps, pUChar pBuf, ULong len )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
ULong IOReadFifoLength( pScanData ps )
|
||||
_LOC ULong IOReadFifoLength( pScanData ps )
|
||||
{
|
||||
DataType Data;
|
||||
|
||||
|
@ -1313,7 +1339,7 @@ ULong IOReadFifoLength( pScanData ps )
|
|||
* ps->RegGreenGainOutDirect (P9363) or from ps->RegModeControl to
|
||||
* ps->RegModeControl2 (48xx)
|
||||
*/
|
||||
void IOPutOnAllRegisters( pScanData ps )
|
||||
_LOC void IOPutOnAllRegisters( pScanData ps )
|
||||
{
|
||||
pUChar pValue;
|
||||
Byte bReg;
|
||||
|
@ -1429,7 +1455,7 @@ void IOPutOnAllRegisters( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void IOReadColorData( pScanData ps, pUChar pBuf, ULong len )
|
||||
_LOC void IOReadColorData( pScanData ps, pUChar pBuf, ULong len )
|
||||
{
|
||||
ps->AsicReg.RD_ModeControl = _ModeFifoRSel;
|
||||
IOReadScannerImageData( ps, pBuf, len );
|
||||
|
|
|
@ -31,22 +31,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - added _OVR_PLUSTEK_4800P definition
|
||||
* 0.42 - added _OVR_PRIMAX_4800D30 definition
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __HWDEFS_H__
|
||||
#define __HWDEFS_H__
|
||||
|
|
|
@ -1,56 +1,82 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustek-pp_image.c - functions to convert scanner data into image
|
||||
* data
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_image.c
|
||||
* @brief functions to convert scanner data into image data
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - no changes
|
||||
* 0.32 - no changes
|
||||
* 0.33 - no changes
|
||||
* 0.34 - reactivated code in imageP96WaitLineData() to recover from
|
||||
* loosing data
|
||||
* 0.35 - no changes
|
||||
* 0.36 - removed comment
|
||||
* added wDither exchange to imageP9xSetupScanSettings
|
||||
* added fnHalftoneDirect1 which provides dithering by using random
|
||||
* thresholds
|
||||
* removed the swapping behaviour for model OP_600 in fnP96ColorDirect()
|
||||
* according to the Primax 4800 Direct tests
|
||||
* changes, due to define renaming
|
||||
* removed _ASIC_96001 specific stuff to invert colors
|
||||
* 0.37 - removed // comments
|
||||
* corrected output of 12bit/pixel
|
||||
* 0.38 - added P12 stuff
|
||||
* renamed WaitLineData functions to ReadOneImageLine
|
||||
* 0.39 - fixed a problem in imageP98003ReadOneImageLine, that causes
|
||||
* these I/O timeouts...
|
||||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - fixed a problem for the 12bit modes fo ASIC9800x based devices
|
||||
* changed include names
|
||||
*.............................................................................
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - no changes
|
||||
* - 0.32 - no changes
|
||||
* - 0.33 - no changes
|
||||
* - 0.34 - reactivated code in imageP96WaitLineData() to recover from
|
||||
* loosing data
|
||||
* - 0.35 - no changes
|
||||
* - 0.36 - removed comment
|
||||
* - added wDither exchange to imageP9xSetupScanSettings
|
||||
* - added fnHalftoneDirect1 which provides dithering by using random
|
||||
* thresholds
|
||||
* - removed the swapping behaviour for model OP_600 in
|
||||
* fnP96ColorDirect() according to the Primax 4800 Direct tests
|
||||
* - changes, due to define renaming
|
||||
* - removed _ASIC_96001 specific stuff to invert colors
|
||||
* - 0.37 - removed // comments
|
||||
* - corrected output of 12bit/pixel
|
||||
* - 0.38 - added P12 stuff
|
||||
* - renamed WaitLineData functions to ReadOneImageLine
|
||||
* - 0.39 - fixed a problem in imageP98003ReadOneImageLine, that causes
|
||||
* these I/O timeouts...
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - fixed a problem for the 12bit modes fo ASIC9800x based devices
|
||||
* - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -1604,10 +1630,9 @@ static int imageP98003SetupScanSettings( pScanData ps, pScanInfo pInf )
|
|||
|
||||
/************************ exported functions *********************************/
|
||||
|
||||
/*.............................................................................
|
||||
*
|
||||
/**
|
||||
*/
|
||||
int ImageInitialize( pScanData ps )
|
||||
_LOC int ImageInitialize( pScanData ps )
|
||||
{
|
||||
DBG( DBG_HIGH, "ImageInitialize()\n" );
|
||||
|
||||
|
|
|
@ -1,43 +1,69 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustekpp-io.c - as the name says, here we have all the I/O
|
||||
* functions according to the parallel port hardware
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustekpp-io.c
|
||||
* @brief as the name says, here we have all the I/O
|
||||
* functions according to the parallel port hardware
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.37 - initial version
|
||||
* added Kevins' suggestions
|
||||
* 0.38 - added Asic 98003 stuff and ioP98ReadWriteTest()
|
||||
* added IODataRegisterToDAC()
|
||||
* replaced function IOSPPWrite by IOMoveDataToScanner
|
||||
* modified ioP98OpenScanPath again and reuse V0.36 stuff again
|
||||
* added IO functions
|
||||
* 0.39 - added IO functions
|
||||
* added f97003 stuff from A3I code
|
||||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* - 0.37 - initial version
|
||||
* - added Kevins' suggestions
|
||||
* - 0.38 - added Asic 98003 stuff and ioP98ReadWriteTest()
|
||||
* - added IODataRegisterToDAC()
|
||||
* - replaced function IOSPPWrite by IOMoveDataToScanner
|
||||
* - modified ioP98OpenScanPath again and reuse V0.36 stuff again
|
||||
* - added IO functions
|
||||
* - 0.39 - added IO functions
|
||||
* - added f97003 stuff from A3I code
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -617,7 +643,7 @@ static void ioEnterReadMode( pScanData ps )
|
|||
/*.............................................................................
|
||||
* here we do some init work
|
||||
*/
|
||||
int IOInitialize( pScanData ps )
|
||||
_LOC int IOInitialize( pScanData ps )
|
||||
{
|
||||
DBG( DBG_HIGH, "IOInitialize()\n" );
|
||||
|
||||
|
@ -649,7 +675,7 @@ int IOInitialize( pScanData ps )
|
|||
* Write specific length buffer to scanner
|
||||
* The scan path is already established
|
||||
*/
|
||||
void IOMoveDataToScanner( pScanData ps, pUChar pBuffer, ULong size )
|
||||
_LOC void IOMoveDataToScanner( pScanData ps, pUChar pBuffer, ULong size )
|
||||
{
|
||||
#ifdef DEBUG
|
||||
if( 0 == ps->IO.bOpenCount )
|
||||
|
@ -666,7 +692,7 @@ void IOMoveDataToScanner( pScanData ps, pUChar pBuffer, ULong size )
|
|||
* Calling SITUATION: Scanner path is established.
|
||||
* download a scanstate-table
|
||||
*/
|
||||
void IODownloadScanStates( pScanData ps )
|
||||
_LOC void IODownloadScanStates( pScanData ps )
|
||||
{
|
||||
TimerDef timer;
|
||||
#ifdef DEBUG
|
||||
|
@ -696,7 +722,7 @@ void IODownloadScanStates( pScanData ps )
|
|||
* Calling SITUATION: Scanner path is established.
|
||||
* Write a data to asic
|
||||
*/
|
||||
void IODataToScanner( pScanData ps, Byte bValue )
|
||||
_LOC void IODataToScanner( pScanData ps, Byte bValue )
|
||||
{
|
||||
ULong deltime = 4;
|
||||
|
||||
|
@ -725,7 +751,7 @@ void IODataToScanner( pScanData ps, Byte bValue )
|
|||
* Calling SITUATION: Scanner path is established.
|
||||
* Write a data to specific asic's register
|
||||
*/
|
||||
void IODataToRegister( pScanData ps, Byte bReg, Byte bData )
|
||||
_LOC void IODataToRegister( pScanData ps, Byte bReg, Byte bData )
|
||||
{
|
||||
#ifdef DEBUG
|
||||
if( 0 == ps->IO.bOpenCount )
|
||||
|
@ -743,7 +769,7 @@ void IODataToRegister( pScanData ps, Byte bReg, Byte bData )
|
|||
* Calling SITUATION: Scanner path is established.
|
||||
* Read the content of specific asic's register
|
||||
*/
|
||||
Byte IODataFromRegister( pScanData ps, Byte bReg )
|
||||
_LOC Byte IODataFromRegister( pScanData ps, Byte bReg )
|
||||
{
|
||||
IORegisterToScanner( ps, bReg );
|
||||
|
||||
|
@ -761,7 +787,7 @@ Byte IODataFromRegister( pScanData ps, Byte bReg )
|
|||
* Calling SITUATION: Scanner path is established.
|
||||
* Write a register to asic (used for a command without parameter)
|
||||
*/
|
||||
void IORegisterToScanner( pScanData ps, Byte bReg )
|
||||
_LOC void IORegisterToScanner( pScanData ps, Byte bReg )
|
||||
{
|
||||
#ifdef DEBUG
|
||||
if( 0 == ps->IO.bOpenCount )
|
||||
|
@ -812,7 +838,7 @@ void IORegisterToScanner( pScanData ps, Byte bReg )
|
|||
/*.............................................................................
|
||||
* write data to the DAC - ASIC 98001/3 only
|
||||
*/
|
||||
void IODataRegisterToDAC( pScanData ps, Byte bReg, Byte bData )
|
||||
_LOC void IODataRegisterToDAC( pScanData ps, Byte bReg, Byte bData )
|
||||
{
|
||||
ULong i;
|
||||
|
||||
|
@ -836,7 +862,7 @@ void IODataRegisterToDAC( pScanData ps, Byte bReg, Byte bData )
|
|||
* Calling SITUATION: Scanner path was not established.
|
||||
* Read the content of specific asics' register
|
||||
*/
|
||||
Byte IODataRegisterFromScanner( pScanData ps, Byte bReg )
|
||||
_LOC Byte IODataRegisterFromScanner( pScanData ps, Byte bReg )
|
||||
{
|
||||
Byte bData;
|
||||
|
||||
|
@ -851,7 +877,7 @@ Byte IODataRegisterFromScanner( pScanData ps, Byte bReg )
|
|||
* Calling SITUATION: Scanner path not established.
|
||||
* Write a value of register to asic
|
||||
*/
|
||||
void IOCmdRegisterToScanner( pScanData ps, Byte bReg, Byte bData )
|
||||
_LOC void IOCmdRegisterToScanner( pScanData ps, Byte bReg, Byte bData )
|
||||
{
|
||||
ps->OpenScanPath( ps );
|
||||
IODataToRegister( ps, bReg, bData );
|
||||
|
@ -862,7 +888,7 @@ void IOCmdRegisterToScanner( pScanData ps, Byte bReg, Byte bData )
|
|||
* Calling SITUATION: Scanner path not established.
|
||||
* Write a register to asic (used for a command without parameter)
|
||||
*/
|
||||
void IORegisterDirectToScanner( pScanData ps, Byte bReg )
|
||||
_LOC void IORegisterDirectToScanner( pScanData ps, Byte bReg )
|
||||
{
|
||||
ps->OpenScanPath( ps ); /* establish the connection */
|
||||
IORegisterToScanner( ps, bReg ); /* write register to asic */
|
||||
|
@ -872,7 +898,7 @@ void IORegisterDirectToScanner( pScanData ps, Byte bReg )
|
|||
/*.............................................................................
|
||||
* perform a SW reset of ASIC 98003 models
|
||||
*/
|
||||
void IOSoftwareReset( pScanData ps )
|
||||
_LOC void IOSoftwareReset( pScanData ps )
|
||||
{
|
||||
if( _ASIC_IS_98003 != ps->sCaps.AsicID )
|
||||
return;
|
||||
|
@ -908,7 +934,7 @@ void IOSoftwareReset( pScanData ps )
|
|||
* Read specific length data from scanner and the method depends on the
|
||||
* mode defined in registry.
|
||||
*/
|
||||
void IOReadScannerImageData( pScanData ps, pUChar pBuf, ULong size )
|
||||
_LOC void IOReadScannerImageData( pScanData ps, pUChar pBuf, ULong size )
|
||||
{
|
||||
if( _ASIC_IS_98003 != ps->sCaps.AsicID )
|
||||
ps->OpenScanPath( ps);
|
||||
|
@ -929,31 +955,22 @@ void IOReadScannerImageData( pScanData ps, pUChar pBuf, ULong size )
|
|||
ps->OpenScanPath( ps );
|
||||
}
|
||||
|
||||
/*.............................................................................
|
||||
* to program the ASIC 97003 on some scanner devices
|
||||
*/
|
||||
void IOFill97003Register( pScanData ps, Byte bDecode1, Byte bDecode2 )
|
||||
{
|
||||
IODataToRegister( ps, ps->RegWriteIOBusDecode2, bDecode2 );
|
||||
IODataToRegister( ps, ps->RegWriteIOBusDecode1, bDecode1 );
|
||||
}
|
||||
|
||||
/*.............................................................................
|
||||
* the wrapper functions to support delayed and non-delayed I/O
|
||||
*/
|
||||
void IOOut( Byte data, UShort port )
|
||||
_LOC void IOOut( Byte data, UShort port )
|
||||
{
|
||||
DBG( DBG_IOF, "outb(0x%04x, 0x%02x)\n", port, data );
|
||||
outb( data, port );
|
||||
}
|
||||
|
||||
void IOOutDelayed( Byte data, UShort port )
|
||||
_LOC void IOOutDelayed( Byte data, UShort port )
|
||||
{
|
||||
DBG( DBG_IOF, "outb_p(0x%04x, 0x%02x)\n", port, data );
|
||||
outb_p( data, port );
|
||||
}
|
||||
|
||||
Byte IOIn( UShort port )
|
||||
_LOC Byte IOIn( UShort port )
|
||||
{
|
||||
#ifdef DEBUG
|
||||
Byte data = inb( port );
|
||||
|
@ -965,7 +982,7 @@ Byte IOIn( UShort port )
|
|||
#endif
|
||||
}
|
||||
|
||||
Byte IOInDelayed( UShort port )
|
||||
_LOC Byte IOInDelayed( UShort port )
|
||||
{
|
||||
#ifdef DEBUG
|
||||
Byte data = inb_p( port );
|
||||
|
|
|
@ -1,50 +1,75 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
*.............................................................................
|
||||
* File: plustek-pp_map.c - functions to create and manipulate
|
||||
* lookup tables.
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_map.c
|
||||
* @brief functions to create and manipulate lookup tables.
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - brightness and contrast is working (see mapAdjust)
|
||||
* 0.32 - no changes
|
||||
* 0.33 - disabled a few functions
|
||||
* 0.34 - added new dither matrix for checking
|
||||
* 0.35 - no changes
|
||||
* 0.36 - activated Dithermap 1
|
||||
* removed some unused functions
|
||||
* added additional SCANDEF_Inverse check to MapSetupDither()
|
||||
* fixed the double inversion bug, the map always compensates
|
||||
* the scanner hw-settings
|
||||
* 0.37 - code cleanup
|
||||
* 0.38 - added P12 stuff
|
||||
* 0.39 - no changes
|
||||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - made MapAdjust global
|
||||
* changed include names
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - brightness and contrast is working (see mapAdjust)
|
||||
* - 0.32 - no changes
|
||||
* - 0.33 - disabled a few functions
|
||||
* - 0.34 - added new dither matrix for checking
|
||||
* - 0.35 - no changes
|
||||
* - 0.36 - activated Dithermap 1
|
||||
* - removed some unused functions
|
||||
* - added additional SCANDEF_Inverse check to MapSetupDither()
|
||||
* - fixed the double inversion bug, the map always compensates
|
||||
* - the scanner hw-settings
|
||||
* - 0.37 - code cleanup
|
||||
* - 0.38 - added P12 stuff
|
||||
* - 0.39 - no changes
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - no changes
|
||||
* - 0.42 - made MapAdjust global
|
||||
* - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -171,7 +196,7 @@ static void mapBuildLinearMap( pScanData ps )
|
|||
* and the is being downloaded to the driver, as I don't have the code
|
||||
* we have to try to build up such a table here
|
||||
*/
|
||||
void MapInitialize( pScanData ps )
|
||||
_LOC void MapInitialize( pScanData ps )
|
||||
{
|
||||
mapBuildLinearMap( ps );
|
||||
MapAdjust( ps, _MAP_MASTER );
|
||||
|
@ -179,7 +204,7 @@ void MapInitialize( pScanData ps )
|
|||
|
||||
/** setup dither maps
|
||||
*/
|
||||
void MapSetupDither( pScanData ps )
|
||||
_LOC void MapSetupDither( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "MapSetupDither() - %u\n", ps->DataInf.wAppDataType );
|
||||
|
||||
|
@ -193,7 +218,7 @@ void MapSetupDither( pScanData ps )
|
|||
|
||||
/** adjust acording to brightness and contrast
|
||||
*/
|
||||
void MapAdjust( pScanData ps, int which )
|
||||
_LOC void MapAdjust( pScanData ps, int which )
|
||||
{
|
||||
ULong i, tabLen;
|
||||
pULong pdw;
|
||||
|
|
|
@ -1,53 +1,79 @@
|
|||
/*.............................................................................
|
||||
* Project : linux driver for Plustek parallel-port scanners
|
||||
* Project : SANE library for Plustek parallelport flatbed scanners.
|
||||
*.............................................................................
|
||||
* File: plustek-pp_misc.c - here we have some helpful functions
|
||||
*.............................................................................
|
||||
*
|
||||
*/
|
||||
|
||||
/* @file plustek-pp_misc.c
|
||||
* @brief here we have some helpful functions
|
||||
*
|
||||
* based on sources acquired from Plustek Inc.
|
||||
* Copyright (C) 1998 Plustek Inc.
|
||||
* Copyright (C) 2000-2003 Gerhard Jaeger <gerhard@gjaeger.de>
|
||||
* also based on the work done by Rick Bronson
|
||||
*.............................................................................
|
||||
*
|
||||
* History:
|
||||
* 0.30 - initial version
|
||||
* 0.31 - no changes
|
||||
* 0.32 - moved the parport functions inside this module
|
||||
* now using the information, the parport-driver provides
|
||||
* for selecting the port-mode this driver uses
|
||||
* 0.33 - added code to use faster portmodes
|
||||
* 0.34 - added sample code for changing from ECP to PS/2 bidi mode
|
||||
* 0.35 - added Kevins´ changes (new function miscSetFastMode())
|
||||
* moved function initPageSettings() to module models.c
|
||||
* 0.36 - added random generator
|
||||
* added additional debug messages
|
||||
* changed prototype of MiscInitPorts()
|
||||
* added miscPreemptionCallback()
|
||||
* 0.37 - changed inb_p/outb_p to macro calls (kernel-mode)
|
||||
* added MiscGetModelName()
|
||||
* added miscShowPortModes()
|
||||
* 0.38 - fixed a small bug in MiscGetModelName()
|
||||
* 0.39 - added forceMode support
|
||||
* 0.40 - no changes
|
||||
* 0.41 - merged Kevins' patch to make EPP(ECP) work
|
||||
* 0.42 - changed get_fast_time to _GET_TIME
|
||||
* changed include names
|
||||
* - 0.30 - initial version
|
||||
* - 0.31 - no changes
|
||||
* - 0.32 - moved the parport functions inside this module
|
||||
* - now using the information, the parport-driver provides
|
||||
* - for selecting the port-mode this driver uses
|
||||
* - 0.33 - added code to use faster portmodes
|
||||
* - 0.34 - added sample code for changing from ECP to PS/2 bidi mode
|
||||
* - 0.35 - added Kevins´ changes (new function miscSetFastMode())
|
||||
* - moved function initPageSettings() to module models.c
|
||||
* - 0.36 - added random generator
|
||||
* - added additional debug messages
|
||||
* - changed prototype of MiscInitPorts()
|
||||
* - added miscPreemptionCallback()
|
||||
* - 0.37 - changed inb_p/outb_p to macro calls (kernel-mode)
|
||||
* - added MiscGetModelName()
|
||||
* - added miscShowPortModes()
|
||||
* - 0.38 - fixed a small bug in MiscGetModelName()
|
||||
* - 0.39 - added forceMode support
|
||||
* - 0.40 - no changes
|
||||
* - 0.41 - merged Kevins' patch to make EPP(ECP) work
|
||||
* - 0.42 - changed get_fast_time to _GET_TIME
|
||||
* - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -86,10 +112,13 @@
|
|||
static int port_feature;
|
||||
static long randomnum = 1;
|
||||
|
||||
#ifdef __KERNEL__
|
||||
static int portIsClaimed[_MAX_PTDEVS] = { [0 ... (_MAX_PTDEVS-1)] = 0 };
|
||||
|
||||
#ifdef __KERNEL__
|
||||
MODELSTR; /* is a static char array (see plustek-share.h) */
|
||||
|
||||
#else
|
||||
static int portIsClaimed[_MAX_PTDEVS] = { 0, 0, 0, 0 };
|
||||
#endif
|
||||
|
||||
/*************************** local functions *********************************/
|
||||
|
@ -618,7 +647,7 @@ static void miscSeedLongRand( ULong seed )
|
|||
|
||||
/** allocate and initialize some memory for the scanner structure
|
||||
*/
|
||||
pScanData MiscAllocAndInitStruct( void )
|
||||
_LOC pScanData MiscAllocAndInitStruct( void )
|
||||
{
|
||||
pScanData ps;
|
||||
|
||||
|
@ -635,7 +664,7 @@ pScanData MiscAllocAndInitStruct( void )
|
|||
|
||||
/** re-initialize the memory for the scanner structure
|
||||
*/
|
||||
int MiscReinitStruct( pScanData ps )
|
||||
_LOC int MiscReinitStruct( pScanData ps )
|
||||
{
|
||||
if( NULL == ps )
|
||||
return _E_NULLPTR;
|
||||
|
@ -666,7 +695,7 @@ int MiscReinitStruct( pScanData ps )
|
|||
/** in USER-Mode: probe the specified port and try to get the port-mode
|
||||
* in KERNEL-Mode: only use the modes, the driver returns
|
||||
*/
|
||||
int MiscInitPorts( pScanData ps, int port )
|
||||
_LOC int MiscInitPorts( pScanData ps, int port )
|
||||
{
|
||||
int status;
|
||||
|
||||
|
@ -699,7 +728,7 @@ int MiscInitPorts( pScanData ps, int port )
|
|||
|
||||
/** here we restore the port
|
||||
*/
|
||||
void MiscRestorePort( pScanData ps )
|
||||
_LOC void MiscRestorePort( pScanData ps )
|
||||
{
|
||||
if( 0 == ps->IO.pbSppDataPort )
|
||||
return;
|
||||
|
@ -730,7 +759,7 @@ void MiscRestorePort( pScanData ps )
|
|||
|
||||
/** starts a timer
|
||||
*/
|
||||
inline void MiscStartTimer( pTimerDef timer , unsigned long us)
|
||||
_LOC inline void MiscStartTimer( pTimerDef timer , unsigned long us)
|
||||
{
|
||||
struct timeval start_time;
|
||||
|
||||
|
@ -745,7 +774,7 @@ inline void MiscStartTimer( pTimerDef timer , unsigned long us)
|
|||
|
||||
/** checks for timeout
|
||||
*/
|
||||
inline int MiscCheckTimer( pTimerDef timer )
|
||||
_LOC inline int MiscCheckTimer( pTimerDef timer )
|
||||
{
|
||||
struct timeval current_time;
|
||||
|
||||
|
@ -770,7 +799,7 @@ inline int MiscCheckTimer( pTimerDef timer )
|
|||
/** checks the function pointers
|
||||
*/
|
||||
#ifdef DEBUG
|
||||
Bool MiscAllPointersSet( pScanData ps )
|
||||
_LOC Bool MiscAllPointersSet( pScanData ps )
|
||||
{
|
||||
ULong i;
|
||||
pULong ptr;
|
||||
|
@ -790,7 +819,7 @@ Bool MiscAllPointersSet( pScanData ps )
|
|||
|
||||
/** registers this driver to use port "portAddr" (KERNEL-Mode only)
|
||||
*/
|
||||
int MiscRegisterPort( pScanData ps, int portAddr )
|
||||
_LOC int MiscRegisterPort( pScanData ps, int portAddr )
|
||||
{
|
||||
#ifndef __KERNEL__
|
||||
int i;
|
||||
|
@ -865,7 +894,7 @@ int MiscRegisterPort( pScanData ps, int portAddr )
|
|||
|
||||
/** unregisters the port from driver (KERNEL-Mode only)
|
||||
*/
|
||||
void MiscUnregisterPort( pScanData ps )
|
||||
_LOC void MiscUnregisterPort( pScanData ps )
|
||||
{
|
||||
#ifdef __KERNEL__
|
||||
if( NULL != ps->pardev ) {
|
||||
|
@ -880,7 +909,7 @@ void MiscUnregisterPort( pScanData ps )
|
|||
/*.............................................................................
|
||||
* try to claim the port (KERNEL-Mode only)
|
||||
*/
|
||||
int MiscClaimPort( pScanData ps )
|
||||
_LOC int MiscClaimPort( pScanData ps )
|
||||
{
|
||||
#ifdef __KERNEL__
|
||||
if( 0 == portIsClaimed[ps->devno] ) {
|
||||
|
@ -898,7 +927,7 @@ int MiscClaimPort( pScanData ps )
|
|||
/*.............................................................................
|
||||
* release previously claimed port (KERNEL-Mode only)
|
||||
*/
|
||||
void MiscReleasePort( pScanData ps )
|
||||
_LOC void MiscReleasePort( pScanData ps )
|
||||
{
|
||||
if( portIsClaimed[ps->devno] > 0 ) {
|
||||
portIsClaimed[ps->devno]--;
|
||||
|
@ -915,7 +944,7 @@ void MiscReleasePort( pScanData ps )
|
|||
/*.............................................................................
|
||||
* get random number
|
||||
*/
|
||||
Long MiscLongRand( void )
|
||||
_LOC Long MiscLongRand( void )
|
||||
{
|
||||
randomnum = miscNextLongRand( randomnum );
|
||||
|
||||
|
@ -925,7 +954,7 @@ Long MiscLongRand( void )
|
|||
/*.............................................................................
|
||||
* according to the id, the function returns a pointer to the model name
|
||||
*/
|
||||
const char *MiscGetModelName( UShort id )
|
||||
_LOC const char *MiscGetModelName( UShort id )
|
||||
{
|
||||
DBG( DBG_HIGH, "MiscGetModelName - id = %i\n", id );
|
||||
|
||||
|
|
|
@ -36,22 +36,46 @@
|
|||
* 0.42 - added SFLAG_CUSTOM_GAMMA to capabilities
|
||||
* added _OVR_PRIMAX_4800D30 switch
|
||||
* changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -227,7 +251,7 @@ static void modelSetBufferSizes( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to 4800
|
||||
*/
|
||||
void ModelSet4800( pScanData ps )
|
||||
_LOC void ModelSet4800( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet4800()\n" );
|
||||
|
||||
|
@ -282,7 +306,7 @@ void ModelSet4800( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to 4830
|
||||
*/
|
||||
void ModelSet4830( pScanData ps )
|
||||
_LOC void ModelSet4830( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet4830()\n" );
|
||||
|
||||
|
@ -341,7 +365,7 @@ void ModelSet4830( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to 600, tested on a Primax Direct 4800 and OP600
|
||||
*/
|
||||
void ModelSet600( pScanData ps )
|
||||
_LOC void ModelSet600( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet600()\n" );
|
||||
|
||||
|
@ -378,7 +402,7 @@ void ModelSet600( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to 12000P, 96000P (tested on a OP96000P)
|
||||
*/
|
||||
void ModelSet12000( pScanData ps )
|
||||
_LOC void ModelSet12000( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet12000()\n" );
|
||||
|
||||
|
@ -403,7 +427,7 @@ void ModelSet12000( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to A3I
|
||||
*/
|
||||
void ModelSetA3I( pScanData ps )
|
||||
_LOC void ModelSetA3I( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSetA3I()\n" );
|
||||
|
||||
|
@ -468,7 +492,7 @@ void ModelSetA3I( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to 9630
|
||||
*/
|
||||
void ModelSet9630( pScanData ps )
|
||||
_LOC void ModelSet9630( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet9360()\n" );
|
||||
|
||||
|
@ -541,7 +565,7 @@ void ModelSet9630( pScanData ps )
|
|||
* set the model to 9636 (ASIC 98001 models)
|
||||
* works for 9636P Turbo and 9636T /12000T
|
||||
*/
|
||||
void ModelSet9636( pScanData ps )
|
||||
_LOC void ModelSet9636( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSet9636()\n" );
|
||||
|
||||
|
@ -584,7 +608,7 @@ void ModelSet9636( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set the model to P12 (ASIC 98003 models)
|
||||
*/
|
||||
void ModelSetP12( pScanData ps )
|
||||
_LOC void ModelSetP12( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "ModelSetP12()\n" );
|
||||
|
||||
|
|
|
@ -38,22 +38,46 @@
|
|||
* 0.40 - changed back to build 0.39-3 (disabled A3I stuff)
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -2731,7 +2755,7 @@ static void motorP98003PositionModuleToHome( pScanData ps )
|
|||
* initialize this module and setup the correct function pointer according
|
||||
* to the ASIC
|
||||
*/
|
||||
int MotorInitialize( pScanData ps )
|
||||
_LOC int MotorInitialize( pScanData ps )
|
||||
{
|
||||
DBG( DBG_HIGH, "MotorInitialize()\n" );
|
||||
|
||||
|
@ -2782,7 +2806,7 @@ int MotorInitialize( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorSetConstantMove( pScanData ps, Byte bMovePerStep )
|
||||
_LOC void MotorSetConstantMove( pScanData ps, Byte bMovePerStep )
|
||||
{
|
||||
DataPointer p;
|
||||
ULong dw;
|
||||
|
@ -2847,7 +2871,7 @@ void MotorSetConstantMove( pScanData ps, Byte bMovePerStep )
|
|||
/*.............................................................................
|
||||
* function to bring the sensor back home
|
||||
*/
|
||||
void MotorToHomePosition( pScanData ps )
|
||||
_LOC void MotorToHomePosition( pScanData ps )
|
||||
{
|
||||
TimerDef timer;
|
||||
ScanState StateStatus;
|
||||
|
@ -2920,7 +2944,7 @@ void MotorToHomePosition( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP98GoFullStep( pScanData ps, ULong dwStep )
|
||||
_LOC void MotorP98GoFullStep( pScanData ps, ULong dwStep )
|
||||
{
|
||||
memset( ps->pColorRunTable, 1, dwStep );
|
||||
memset( ps->pColorRunTable + dwStep, 0xff, 0x40);
|
||||
|
@ -2938,7 +2962,7 @@ void MotorP98GoFullStep( pScanData ps, ULong dwStep )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP96SetSpeedToStopProc( pScanData ps )
|
||||
_LOC void MotorP96SetSpeedToStopProc( pScanData ps )
|
||||
{
|
||||
Byte bData;
|
||||
TimerDef timer;
|
||||
|
@ -2974,7 +2998,7 @@ void MotorP96SetSpeedToStopProc( pScanData ps )
|
|||
* Position Scan Module to specified line number (Forward or Backward & wait
|
||||
* for paper flag ON)
|
||||
*/
|
||||
void MotorP96ConstantMoveProc( pScanData ps, ULong dwLines )
|
||||
_LOC void MotorP96ConstantMoveProc( pScanData ps, ULong dwLines )
|
||||
{
|
||||
Byte bRemainder, bLastState;
|
||||
UShort wQuotient;
|
||||
|
@ -3051,7 +3075,7 @@ void MotorP96ConstantMoveProc( pScanData ps, ULong dwLines )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
Bool MotorP96AheadToDarkArea( pScanData ps )
|
||||
_LOC Bool MotorP96AheadToDarkArea( pScanData ps )
|
||||
{
|
||||
Byte bDark;
|
||||
UShort wTL;
|
||||
|
@ -3137,7 +3161,7 @@ Bool MotorP96AheadToDarkArea( pScanData ps )
|
|||
/*.............................................................................
|
||||
* limit the speed settings for 96001/3 based models
|
||||
*/
|
||||
void MotorP96AdjustCurrentSpeed( pScanData ps, Byte bSpeed )
|
||||
_LOC void MotorP96AdjustCurrentSpeed( pScanData ps, Byte bSpeed )
|
||||
{
|
||||
if (bSpeed != 1) {
|
||||
|
||||
|
@ -3151,7 +3175,7 @@ void MotorP96AdjustCurrentSpeed( pScanData ps, Byte bSpeed )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP98003ForceToLeaveHomePos( pScanData ps )
|
||||
_LOC void MotorP98003ForceToLeaveHomePos( pScanData ps )
|
||||
{
|
||||
TimerDef timer;
|
||||
|
||||
|
@ -3175,7 +3199,7 @@ void MotorP98003ForceToLeaveHomePos( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP98003BackToHomeSensor( pScanData ps )
|
||||
_LOC void MotorP98003BackToHomeSensor( pScanData ps )
|
||||
{
|
||||
TimerDef timer;
|
||||
|
||||
|
@ -3236,7 +3260,7 @@ void MotorP98003BackToHomeSensor( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP98003ModuleForwardBackward( pScanData ps )
|
||||
_LOC void MotorP98003ModuleForwardBackward( pScanData ps )
|
||||
{
|
||||
switch( ps->Scan.bModuleState ) {
|
||||
|
||||
|
@ -3290,7 +3314,7 @@ void MotorP98003ModuleForwardBackward( pScanData ps )
|
|||
/*.............................................................................
|
||||
*
|
||||
*/
|
||||
void MotorP98003PositionYProc( pScanData ps, ULong steps)
|
||||
_LOC void MotorP98003PositionYProc( pScanData ps, ULong steps)
|
||||
{
|
||||
TimerDef timer;
|
||||
|
||||
|
|
|
@ -14,22 +14,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - removed setting of ps->sCaps.dwFlag in p12InitiateComponentModel()
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -541,7 +565,7 @@ static int p12Calibration( pScanData ps )
|
|||
/*.............................................................................
|
||||
* initialize the register values and function calls for the 98003 asic
|
||||
*/
|
||||
int P12InitAsic( pScanData ps )
|
||||
_LOC int P12InitAsic( pScanData ps )
|
||||
{
|
||||
int result;
|
||||
|
||||
|
@ -726,7 +750,7 @@ int P12InitAsic( pScanData ps )
|
|||
/*.............................................................................
|
||||
* set all necessary register contents
|
||||
*/
|
||||
void P12SetGeneralRegister( pScanData ps )
|
||||
_LOC void P12SetGeneralRegister( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "P12SetGeneralRegister()\n" );
|
||||
|
||||
|
|
|
@ -17,22 +17,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -856,7 +880,7 @@ static void fnDACDarkSamsung( pScanData ps, pDACTblDef pDacTbl,
|
|||
* according to detected CCD and DAC, we set their correct init values
|
||||
* and functions
|
||||
*/
|
||||
void P12InitCCDandDAC( pScanData ps, Bool shading )
|
||||
_LOC void P12InitCCDandDAC( pScanData ps, Bool shading )
|
||||
{
|
||||
UShort w;
|
||||
pDACTblDef pDAC_CCD;
|
||||
|
|
|
@ -37,22 +37,46 @@
|
|||
* 0.40 - disabled A3I stuff
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -764,7 +788,7 @@ static int p48xxCalibration( pScanData ps )
|
|||
/*.............................................................................
|
||||
* initialize the register values and function calls for the 96001/3 asic
|
||||
*/
|
||||
int P48xxInitAsic( pScanData ps )
|
||||
_LOC int P48xxInitAsic( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "P48xxInitAsic()\n" );
|
||||
|
||||
|
|
|
@ -35,22 +35,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -885,7 +909,7 @@ static int p9636Calibration( pScanData ps )
|
|||
/*.............................................................................
|
||||
* initialize the register values and function calls for the 98001 asic
|
||||
*/
|
||||
int P9636InitAsic( pScanData ps )
|
||||
_LOC int P9636InitAsic( pScanData ps )
|
||||
{
|
||||
int result;
|
||||
|
||||
|
|
|
@ -13,22 +13,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifdef __KERNEL__
|
||||
#include <linux/proc_fs.h>
|
||||
|
|
|
@ -32,189 +32,217 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - added MapAdjust
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __PROCS_H__
|
||||
#define __PROCS_H__
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-misc.c
|
||||
*/
|
||||
pScanData MiscAllocAndInitStruct( void );
|
||||
int MiscReinitStruct ( pScanData ps );
|
||||
|
||||
int MiscInitPorts ( pScanData ps, int port );
|
||||
void MiscRestorePort ( pScanData ps );
|
||||
inline void MiscStartTimer ( pTimerDef timer, unsigned long us );
|
||||
inline int MiscCheckTimer ( pTimerDef timer );
|
||||
|
||||
int MiscRegisterPort ( pScanData ps, int portAddr );
|
||||
void MiscUnregisterPort ( pScanData ps );
|
||||
int MiscClaimPort ( pScanData ps );
|
||||
void MiscReleasePort ( pScanData ps );
|
||||
Long MiscLongRand ( void );
|
||||
const char *MiscGetModelName( UShort id );
|
||||
|
||||
#ifdef DEBUG
|
||||
Bool MiscAllPointersSet( pScanData ps );
|
||||
#ifdef _BACKEND_ENABLED
|
||||
# define _LOC static
|
||||
#else
|
||||
# define _LOC
|
||||
#endif
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-detect.c
|
||||
* implementation in plustek-pp_misc.c
|
||||
*/
|
||||
int DetectScanner( pScanData ps, int mode );
|
||||
_LOC pScanData MiscAllocAndInitStruct( void );
|
||||
_LOC int MiscReinitStruct ( pScanData ps );
|
||||
|
||||
_LOC int MiscInitPorts ( pScanData ps, int port );
|
||||
_LOC void MiscRestorePort ( pScanData ps );
|
||||
_LOC inline void MiscStartTimer ( pTimerDef timer, unsigned long us );
|
||||
_LOC inline int MiscCheckTimer ( pTimerDef timer );
|
||||
|
||||
_LOC int MiscRegisterPort ( pScanData ps, int portAddr );
|
||||
_LOC void MiscUnregisterPort ( pScanData ps );
|
||||
_LOC int MiscClaimPort ( pScanData ps );
|
||||
_LOC void MiscReleasePort ( pScanData ps );
|
||||
_LOC Long MiscLongRand ( void );
|
||||
_LOC const char *MiscGetModelName( UShort id );
|
||||
|
||||
#ifdef DEBUG
|
||||
_LOC Bool MiscAllPointersSet( pScanData ps );
|
||||
#endif
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-p48xx.c
|
||||
* implementation in plustek-pp_detect.c
|
||||
*/
|
||||
int P48xxInitAsic( pScanData ps );
|
||||
_LOC int DetectScanner( pScanData ps, int mode );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-p9636.c
|
||||
* implementation in plustek-pp_p48xx.c
|
||||
*/
|
||||
int P9636InitAsic( pScanData ps );
|
||||
_LOC int P48xxInitAsic( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-p12.c
|
||||
* implementation in plustek-pp_p9636.c
|
||||
*/
|
||||
int P12InitAsic ( pScanData ps );
|
||||
void P12SetGeneralRegister( pScanData ps );
|
||||
_LOC int P9636InitAsic( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-p12ccd.c
|
||||
* implementation in plustek-pp_p12.c
|
||||
*/
|
||||
void P12InitCCDandDAC( pScanData ps, Bool shading );
|
||||
_LOC int P12InitAsic ( pScanData ps );
|
||||
_LOC void P12SetGeneralRegister( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-models.c
|
||||
* implementation in plustek-pp_p12ccd.c
|
||||
*/
|
||||
void ModelSet4800 ( pScanData ps );
|
||||
void ModelSet4830 ( pScanData ps );
|
||||
void ModelSet600 ( pScanData ps );
|
||||
void ModelSet12000( pScanData ps );
|
||||
void ModelSetA3I ( pScanData ps );
|
||||
void ModelSet9630 ( pScanData ps );
|
||||
void ModelSet9636 ( pScanData ps );
|
||||
void ModelSetP12 ( pScanData ps );
|
||||
_LOC void P12InitCCDandDAC( pScanData ps, Bool shading );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-dac.c
|
||||
* implementation in plustek-pp_models.c
|
||||
*/
|
||||
int DacInitialize( pScanData ps );
|
||||
|
||||
void DacP98AdjustDark ( pScanData ps );
|
||||
void DacP98FillGainOutDirectPort ( pScanData ps );
|
||||
void DacP98FillShadingDarkToShadingRegister( pScanData ps );
|
||||
|
||||
void DacP96WriteBackToGammaShadingRAM( pScanData ps );
|
||||
|
||||
void DacP98003FillToDAC ( pScanData ps, pRGBByteDef regs, pColorByte data );
|
||||
void DacP98003AdjustGain( pScanData ps, ULong color, Byte hilight );
|
||||
Byte DacP98003SumGains ( pUChar pb, ULong pixelsLine );
|
||||
_LOC void ModelSet4800 ( pScanData ps );
|
||||
_LOC void ModelSet4830 ( pScanData ps );
|
||||
_LOC void ModelSet600 ( pScanData ps );
|
||||
_LOC void ModelSet12000( pScanData ps );
|
||||
_LOC void ModelSetA3I ( pScanData ps );
|
||||
_LOC void ModelSet9630 ( pScanData ps );
|
||||
_LOC void ModelSet9636 ( pScanData ps );
|
||||
_LOC void ModelSetP12 ( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-motor.c
|
||||
* implementation in plustek-pp_dac.c
|
||||
*/
|
||||
int MotorInitialize ( pScanData ps );
|
||||
void MotorSetConstantMove( pScanData ps, Byte bMovePerStep );
|
||||
void MotorToHomePosition ( pScanData ps );
|
||||
_LOC int DacInitialize( pScanData ps );
|
||||
|
||||
void MotorP98GoFullStep ( pScanData ps, ULong dwStep );
|
||||
_LOC void DacP98AdjustDark ( pScanData ps );
|
||||
_LOC void DacP98FillGainOutDirectPort ( pScanData ps );
|
||||
_LOC void DacP98FillShadingDarkToShadingRegister( pScanData ps );
|
||||
|
||||
void MotorP96SetSpeedToStopProc( pScanData ps );
|
||||
void MotorP96ConstantMoveProc ( pScanData ps, ULong dwLines );
|
||||
Bool MotorP96AheadToDarkArea ( pScanData ps );
|
||||
void MotorP96AdjustCurrentSpeed( pScanData ps, Byte bSpeed );
|
||||
_LOC void DacP96WriteBackToGammaShadingRAM( pScanData ps );
|
||||
|
||||
void MotorP98003BackToHomeSensor ( pScanData ps );
|
||||
void MotorP98003ModuleForwardBackward( pScanData ps );
|
||||
void MotorP98003ForceToLeaveHomePos ( pScanData ps );
|
||||
void MotorP98003PositionYProc ( pScanData ps, ULong steps);
|
||||
_LOC void DacP98003FillToDAC (pScanData ps, pRGBByteDef regs, pColorByte data);
|
||||
_LOC void DacP98003AdjustGain(pScanData ps, ULong color, Byte hilight );
|
||||
_LOC Byte DacP98003SumGains ( pUChar pb, ULong pixelsLine );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-map.c
|
||||
* implementation in plustek-pp_motor.c
|
||||
*/
|
||||
void MapInitialize ( pScanData ps );
|
||||
void MapSetupDither( pScanData ps );
|
||||
void MapAdjust ( pScanData ps, int which );
|
||||
_LOC int MotorInitialize ( pScanData ps );
|
||||
_LOC void MotorSetConstantMove( pScanData ps, Byte bMovePerStep );
|
||||
_LOC void MotorToHomePosition ( pScanData ps );
|
||||
|
||||
_LOC void MotorP98GoFullStep ( pScanData ps, ULong dwStep );
|
||||
|
||||
_LOC void MotorP96SetSpeedToStopProc( pScanData ps );
|
||||
_LOC void MotorP96ConstantMoveProc ( pScanData ps, ULong dwLines );
|
||||
_LOC Bool MotorP96AheadToDarkArea ( pScanData ps );
|
||||
_LOC void MotorP96AdjustCurrentSpeed( pScanData ps, Byte bSpeed );
|
||||
|
||||
_LOC void MotorP98003BackToHomeSensor ( pScanData ps );
|
||||
_LOC void MotorP98003ModuleForwardBackward( pScanData ps );
|
||||
_LOC void MotorP98003ForceToLeaveHomePos ( pScanData ps );
|
||||
_LOC void MotorP98003PositionYProc ( pScanData ps, ULong steps);
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-image.c
|
||||
* implementation in plustek-pp_map.c
|
||||
*/
|
||||
int ImageInitialize( pScanData ps );
|
||||
_LOC void MapInitialize ( pScanData ps );
|
||||
_LOC void MapSetupDither( pScanData ps );
|
||||
_LOC void MapAdjust ( pScanData ps, int which );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-genericio.c
|
||||
* implementation in plustek-pp_image.c
|
||||
*/
|
||||
int IOFuncInitialize ( pScanData ps );
|
||||
Byte IOSetToMotorRegister ( pScanData ps );
|
||||
Byte IOGetScanState ( pScanData ps, Bool fOpenned );
|
||||
Byte IOGetExtendedStatus ( pScanData ps );
|
||||
void IOGetCurrentStateCount( pScanData, pScanState pScanStep);
|
||||
int IOIsReadyForScan ( pScanData ps );
|
||||
|
||||
void IOSetXStepLineScanTime( pScanData ps, Byte b );
|
||||
void IOSetToMotorStepCount ( pScanData ps );
|
||||
void IOSelectLampSource ( pScanData ps );
|
||||
Bool IOReadOneShadingLine ( pScanData ps, pUChar pBuf, ULong len );
|
||||
ULong IOReadFifoLength ( pScanData ps );
|
||||
void IOPutOnAllRegisters ( pScanData ps );
|
||||
void IOReadColorData ( pScanData ps, pUChar pBuf, ULong len );
|
||||
_LOC int ImageInitialize( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-io.c
|
||||
* implementation in plustek-pp_genericio.c
|
||||
*/
|
||||
int IOInitialize ( pScanData ps );
|
||||
void IOMoveDataToScanner ( pScanData ps, pUChar pBuffer, ULong size );
|
||||
void IODownloadScanStates( pScanData ps );
|
||||
void IODataToScanner ( pScanData, Byte bValue );
|
||||
void IODataToRegister ( pScanData ps, Byte bReg, Byte bData );
|
||||
Byte IODataFromRegister ( pScanData ps, Byte bReg );
|
||||
void IORegisterToScanner ( pScanData ps, Byte bReg );
|
||||
void IODataRegisterToDAC ( pScanData ps, Byte bReg, Byte bData );
|
||||
|
||||
Byte IODataRegisterFromScanner( pScanData ps, Byte bReg );
|
||||
void IOCmdRegisterToScanner ( pScanData ps, Byte bReg, Byte bData );
|
||||
void IORegisterDirectToScanner( pScanData, Byte bReg );
|
||||
void IOSoftwareReset ( pScanData ps );
|
||||
void IOReadScannerImageData ( pScanData ps, pUChar pBuf, ULong size );
|
||||
void IOFill97003Register ( pScanData ps, Byte bDecode1, Byte bDecode2 );
|
||||
|
||||
void IOOut ( Byte data, UShort port );
|
||||
void IOOutDelayed( Byte data, UShort port );
|
||||
Byte IOIn ( UShort port );
|
||||
Byte IOInDelayed ( UShort port );
|
||||
_LOC int IOFuncInitialize ( pScanData ps );
|
||||
_LOC Byte IOSetToMotorRegister ( pScanData ps );
|
||||
_LOC Byte IOGetScanState ( pScanData ps, Bool fOpenned );
|
||||
_LOC Byte IOGetExtendedStatus ( pScanData ps );
|
||||
_LOC void IOGetCurrentStateCount( pScanData, pScanState pScanStep);
|
||||
_LOC int IOIsReadyForScan ( pScanData ps );
|
||||
|
||||
_LOC void IOSetXStepLineScanTime( pScanData ps, Byte b );
|
||||
_LOC void IOSetToMotorStepCount ( pScanData ps );
|
||||
_LOC void IOSelectLampSource ( pScanData ps );
|
||||
_LOC Bool IOReadOneShadingLine ( pScanData ps, pUChar pBuf, ULong len );
|
||||
_LOC ULong IOReadFifoLength ( pScanData ps );
|
||||
_LOC void IOPutOnAllRegisters ( pScanData ps );
|
||||
_LOC void IOReadColorData ( pScanData ps, pUChar pBuf, ULong len );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-tpa.c
|
||||
* implementation in plustek-pp_io.c
|
||||
*/
|
||||
void TPAP98001AverageShadingData( pScanData ps );
|
||||
void TPAP98003FindCenterPointer ( pScanData ps );
|
||||
void TPAP98003Reshading ( pScanData ps );
|
||||
_LOC int IOInitialize ( pScanData ps );
|
||||
_LOC void IOMoveDataToScanner ( pScanData ps, pUChar pBuffer, ULong size );
|
||||
_LOC void IODownloadScanStates( pScanData ps );
|
||||
_LOC void IODataToScanner ( pScanData, Byte bValue );
|
||||
_LOC void IODataToRegister ( pScanData ps, Byte bReg, Byte bData );
|
||||
_LOC Byte IODataFromRegister ( pScanData ps, Byte bReg );
|
||||
_LOC void IORegisterToScanner ( pScanData ps, Byte bReg );
|
||||
_LOC void IODataRegisterToDAC ( pScanData ps, Byte bReg, Byte bData );
|
||||
|
||||
_LOC Byte IODataRegisterFromScanner( pScanData ps, Byte bReg );
|
||||
_LOC void IOCmdRegisterToScanner ( pScanData ps, Byte bReg, Byte bData );
|
||||
_LOC void IORegisterDirectToScanner( pScanData, Byte bReg );
|
||||
_LOC void IOSoftwareReset ( pScanData ps );
|
||||
_LOC void IOReadScannerImageData ( pScanData ps, pUChar pBuf, ULong size );
|
||||
|
||||
_LOC void IOOut ( Byte data, UShort port );
|
||||
_LOC void IOOutDelayed( Byte data, UShort port );
|
||||
_LOC Byte IOIn ( UShort port );
|
||||
_LOC Byte IOInDelayed ( UShort port );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-scale.c
|
||||
* implementation in plustek-pp_tpa.c
|
||||
*/
|
||||
void ScaleX( pScanData ps, pUChar inBuf, pUChar outBuf );
|
||||
_LOC void TPAP98001AverageShadingData( pScanData ps );
|
||||
_LOC void TPAP98003FindCenterPointer ( pScanData ps );
|
||||
_LOC void TPAP98003Reshading ( pScanData ps );
|
||||
|
||||
/*
|
||||
* implementation in plustekpp-procfs.c (Kernel-mode only)
|
||||
* implementation in plustek-pp_scale.c
|
||||
*/
|
||||
_LOC void ScaleX( pScanData ps, pUChar inBuf, pUChar outBuf );
|
||||
|
||||
/*
|
||||
* implementation in plustek-pp_procfs.c (Kernel-mode only)
|
||||
*/
|
||||
#ifdef __KERNEL__
|
||||
int ProcFsInitialize ( void );
|
||||
|
|
|
@ -54,22 +54,46 @@
|
|||
* improved the cancel functionality
|
||||
* added LINUX_26 stuff
|
||||
* changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifdef __KERNEL__
|
||||
#include <linux/module.h>
|
||||
|
@ -1783,7 +1807,7 @@ static int pt_drv_ioctl( struct inode *inode, struct file *file,
|
|||
/*.............................................................................
|
||||
* here we only have wrapper functions
|
||||
*/
|
||||
int PtDrvInit( int portAddr, UShort model_override )
|
||||
static int PtDrvInit( int portAddr, UShort model_override )
|
||||
{
|
||||
int result = _OK;
|
||||
|
||||
|
@ -1802,7 +1826,7 @@ int PtDrvInit( int portAddr, UShort model_override )
|
|||
return result;
|
||||
}
|
||||
|
||||
int PtDrvShutdown( void )
|
||||
static int PtDrvShutdown( void )
|
||||
{
|
||||
int result;
|
||||
|
||||
|
@ -1816,7 +1840,7 @@ int PtDrvShutdown( void )
|
|||
return result;
|
||||
}
|
||||
|
||||
int PtDrvOpen( void )
|
||||
static int PtDrvOpen( void )
|
||||
{
|
||||
if( _FALSE == PtDrvInitialized )
|
||||
return _E_NOT_INIT;
|
||||
|
@ -1824,7 +1848,7 @@ int PtDrvOpen( void )
|
|||
return _OK;
|
||||
}
|
||||
|
||||
int PtDrvClose( void )
|
||||
static int PtDrvClose( void )
|
||||
{
|
||||
if( _FALSE == PtDrvInitialized )
|
||||
return _E_NOT_INIT;
|
||||
|
@ -1832,7 +1856,7 @@ int PtDrvClose( void )
|
|||
return ptdrvClose( PtDrvDevices[0] );
|
||||
}
|
||||
|
||||
int PtDrvIoctl( UInt cmd, pVoid arg )
|
||||
static int PtDrvIoctl( UInt cmd, pVoid arg )
|
||||
{
|
||||
if( _FALSE == PtDrvInitialized )
|
||||
return _E_NOT_INIT;
|
||||
|
@ -1840,7 +1864,7 @@ int PtDrvIoctl( UInt cmd, pVoid arg )
|
|||
return ptdrvIoctl( PtDrvDevices[0], cmd, arg);
|
||||
}
|
||||
|
||||
int PtDrvRead ( pUChar buffer, int count )
|
||||
static int PtDrvRead ( pUChar buffer, int count )
|
||||
{
|
||||
if( _FALSE == PtDrvInitialized )
|
||||
return _E_NOT_INIT;
|
||||
|
|
|
@ -19,32 +19,55 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
/************************ exported functions *********************************/
|
||||
|
||||
/*.............................................................................
|
||||
* scaling picture data in x-direction, using a DDA algo
|
||||
* (digital differential analyzer).
|
||||
/** scaling picture data in x-direction, using a DDA algo
|
||||
* (digital differential analyzer).
|
||||
*/
|
||||
void ScaleX( pScanData ps, pUChar inBuf, pUChar outBuf )
|
||||
_LOC void ScaleX( pScanData ps, pUChar inBuf, pUChar outBuf )
|
||||
{
|
||||
UChar tmp;
|
||||
int step;
|
||||
|
|
|
@ -22,22 +22,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __PLUSTEK_SCAN_H__
|
||||
#define __PLUSTEK_SCAN_H__
|
||||
|
|
|
@ -47,22 +47,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - no changes
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __SCANDATA_H__
|
||||
#define __SCANDATA_H__
|
||||
|
|
|
@ -16,22 +16,46 @@
|
|||
* 0.41 - no changes
|
||||
* 0.42 - added _GET_TIME
|
||||
* - added LINUX_26 for new kernel
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef _SYSDEP_H_
|
||||
#define _SYSDEP_H_
|
||||
|
|
|
@ -27,22 +27,46 @@
|
|||
* 0.40 - no changes
|
||||
* 0.41 - no changes
|
||||
* 0.42 - changed include names
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#include "plustek-pp_scan.h"
|
||||
|
||||
|
@ -653,7 +677,7 @@ static void tpaP98RecalculateShadingGainandData( pScanData ps )
|
|||
/*.............................................................................
|
||||
* perform some adjustments according to the source (normal, transparency etc)
|
||||
*/
|
||||
void TPAP98001AverageShadingData( pScanData ps )
|
||||
_LOC void TPAP98001AverageShadingData( pScanData ps )
|
||||
{
|
||||
DBG( DBG_LOW, "TPAP98001AverageShadingData()\n" );
|
||||
|
||||
|
@ -764,7 +788,7 @@ void TPAP98001AverageShadingData( pScanData ps )
|
|||
/*.............................................................................
|
||||
* perform some adjustments according to the source (normal, transparency etc)
|
||||
*/
|
||||
void TPAP98003FindCenterPointer( pScanData ps )
|
||||
_LOC void TPAP98003FindCenterPointer( pScanData ps )
|
||||
{
|
||||
ULong i;
|
||||
ULong width;
|
||||
|
@ -811,7 +835,7 @@ void TPAP98003FindCenterPointer( pScanData ps )
|
|||
* this function does some reshading, when scanning negatives on an ASIC 98003
|
||||
* based scanner
|
||||
*/
|
||||
void TPAP98003Reshading( pScanData ps )
|
||||
_LOC void TPAP98003Reshading( pScanData ps )
|
||||
{
|
||||
Byte bHi[3], bHiLeft[3], bHiRight[3];
|
||||
ULong i, dwR, dwG, dwB, dwSum;
|
||||
|
|
|
@ -26,22 +26,46 @@
|
|||
* 0.40 - moved _VAR_NOT_USED and TabDef to plustek-share.h
|
||||
* 0.41 - no changes
|
||||
* 0.42 - moved errorcodes to plustek-share.h
|
||||
* .
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
*
|
||||
*.............................................................................
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
* MA 02111-1307, USA.
|
||||
*
|
||||
* As a special exception, the authors of SANE give permission for
|
||||
* additional uses of the libraries contained in this release of SANE.
|
||||
*
|
||||
* The exception is that, if you link a SANE library with other files
|
||||
* to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public
|
||||
* License. Your use of that executable is in no way restricted on
|
||||
* account of linking the SANE library code into it.
|
||||
*
|
||||
* This exception does not, however, invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public
|
||||
* License.
|
||||
*
|
||||
* If you submit changes to SANE to the maintainers to be included in
|
||||
* a subsequent release, you agree by submitting the changes that
|
||||
* those changes may be distributed with this exception intact.
|
||||
*
|
||||
* If you write modifications of your own for SANE, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
* <hr>
|
||||
*/
|
||||
#ifndef __DRV_TYPES_H__
|
||||
#define __DRV_TYPES_H__
|
||||
|
|
|
@ -62,26 +62,62 @@
|
|||
|
||||
/******************* wrapper functions for parport device ********************/
|
||||
|
||||
/*
|
||||
* stuff needed for user space stuff
|
||||
/** stuff needed for user space stuff
|
||||
*/
|
||||
int PtDrvInit ( int portAddr, unsigned short model_override );
|
||||
int PtDrvShutdown ( void );
|
||||
int PtDrvOpen ( void );
|
||||
int PtDrvClose ( void );
|
||||
int PtDrvIoctl ( unsigned int cmd, void *arg );
|
||||
int PtDrvRead ( unsigned char *buffer, int count );
|
||||
|
||||
#ifdef _USER_MODE
|
||||
|
||||
|
||||
#define _IOCTL(hd,cmd,arg) PtDrvIoctl(cmd,arg)
|
||||
|
||||
#else
|
||||
|
||||
#define _IOCTL(hd,cmd,arg) ioctl(hd,cmd,arg)
|
||||
#if 0
|
||||
int PtDrvInit ( int portAddr, unsigned short model_override );
|
||||
int PtDrvShutdown( void );
|
||||
int PtDrvOpen ( void );
|
||||
int PtDrvClose ( void );
|
||||
int PtDrvIoctl ( unsigned int cmd, void *arg );
|
||||
int PtDrvRead ( unsigned char *buffer, int count );
|
||||
#endif
|
||||
|
||||
#ifndef _BACKEND_ENABLED
|
||||
|
||||
static int PtDrvInit( int portAddr, unsigned short model_override )
|
||||
{
|
||||
_VAR_NOT_USED( portAddr );
|
||||
_VAR_NOT_USED( model_override );
|
||||
DBG( _DBG_ERROR, "Backend does not support direct I/O!\n" );
|
||||
return -1;
|
||||
}
|
||||
|
||||
static int PtDrvShutdown( void )
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int PtDrvOpen( void )
|
||||
{
|
||||
DBG( _DBG_ERROR, "Backend does not support direct I/O!\n" );
|
||||
return -1;
|
||||
}
|
||||
|
||||
static int PtDrvClose( void )
|
||||
{
|
||||
DBG( _DBG_ERROR, "Backend does not support direct I/O!\n" );
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int PtDrvIoctl( unsigned int cmd, void *arg )
|
||||
{
|
||||
DBG( _DBG_ERROR, "Backend does not support direct I/O!\n" );
|
||||
_VAR_NOT_USED( cmd );
|
||||
if( arg == NULL )
|
||||
return -2;
|
||||
return -1;
|
||||
}
|
||||
|
||||
static int PtDrvRead( unsigned char *buffer, int count )
|
||||
{
|
||||
DBG( _DBG_ERROR, "Backend does not support direct I/O!\n" );
|
||||
_VAR_NOT_USED( count );
|
||||
if( buffer == NULL )
|
||||
return -2;
|
||||
return -1;
|
||||
}
|
||||
#endif /* _BACKEND_ENABLED */
|
||||
|
||||
/**
|
||||
*/
|
||||
|
@ -94,7 +130,6 @@ static int ppDev_open( const char *dev_name, void *misc )
|
|||
unsigned short version = _PTDRV_IOCTL_VERSION;
|
||||
Plustek_Device *dev = (Plustek_Device *)misc;
|
||||
|
||||
|
||||
if( dev->adj.direct_io ) {
|
||||
|
||||
/* convert device name to port-address... */
|
||||
|
@ -207,58 +242,60 @@ static int ppDev_close( Plustek_Device *dev )
|
|||
*/
|
||||
static int ppDev_getCaps( Plustek_Device *dev )
|
||||
{
|
||||
return _IOCTL( dev->fd, _PTDRV_GET_CAPABILITIES, &dev->caps );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_GET_CAPABILITIES, &dev->caps );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_GET_CAPABILITIES, &dev->caps );
|
||||
}
|
||||
|
||||
/**
|
||||
*/
|
||||
static int ppDev_getLensInfo( Plustek_Device *dev, pLensInfo lens )
|
||||
{
|
||||
#ifdef _USER_MODE
|
||||
_VAR_NOT_USED( dev );
|
||||
#endif
|
||||
return _IOCTL( dev->fd, _PTDRV_GET_LENSINFO, lens );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_GET_LENSINFO, lens );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_GET_LENSINFO, lens );
|
||||
}
|
||||
|
||||
/**
|
||||
*/
|
||||
static int ppDev_getCropInfo( Plustek_Device *dev, pCropInfo crop )
|
||||
{
|
||||
#ifdef _USER_MODE
|
||||
_VAR_NOT_USED( dev );
|
||||
#endif
|
||||
return _IOCTL( dev->fd, _PTDRV_GET_CROPINFO, crop );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_GET_CROPINFO, crop );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_GET_CROPINFO, crop );
|
||||
}
|
||||
|
||||
/**
|
||||
*/
|
||||
static int ppDev_putImgInfo( Plustek_Device *dev, pImgDef img )
|
||||
{
|
||||
#ifdef _USER_MODE
|
||||
_VAR_NOT_USED( dev );
|
||||
#endif
|
||||
return _IOCTL( dev->fd, _PTDRV_PUT_IMAGEINFO, img );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_PUT_IMAGEINFO, img );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_PUT_IMAGEINFO, img );
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
static int ppDev_setScanEnv( Plustek_Device *dev, pScanInfo sinfo )
|
||||
{
|
||||
#ifdef _USER_MODE
|
||||
_VAR_NOT_USED( dev );
|
||||
#endif
|
||||
return _IOCTL( dev->fd, _PTDRV_SET_ENV, sinfo );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_SET_ENV, sinfo );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_SET_ENV, sinfo );
|
||||
}
|
||||
|
||||
/**
|
||||
*/
|
||||
static int ppDev_startScan( Plustek_Device *dev, pStartScan start )
|
||||
{
|
||||
#ifdef _USER_MODE
|
||||
_VAR_NOT_USED( dev );
|
||||
#endif
|
||||
return _IOCTL( dev->fd, _PTDRV_START_SCAN, start );
|
||||
if( dev->adj.direct_io )
|
||||
return PtDrvIoctl( _PTDRV_START_SCAN, start );
|
||||
else
|
||||
return ioctl( dev->fd, _PTDRV_START_SCAN, start );
|
||||
}
|
||||
|
||||
/** function to send a gamma table to the kernel module. As the default table
|
||||
|
|
|
@ -61,7 +61,7 @@
|
|||
* - 0.46 - added plustek-usbcal.c for extra CIS device calibration
|
||||
* based in Montys' great work
|
||||
* - added altCalibration option
|
||||
* - removed parallelport support
|
||||
* - removed parallelport support --> new backend: plustek_pp
|
||||
*.
|
||||
* <hr>
|
||||
* This file is part of the SANE package.
|
||||
|
@ -135,7 +135,7 @@
|
|||
#include "sane/sanei.h"
|
||||
#include "sane/saneopts.h"
|
||||
|
||||
#define BACKEND_VERSION "0.46-TEST2"
|
||||
#define BACKEND_VERSION "0.46-1"
|
||||
#define BACKEND_NAME plustek
|
||||
#include "sane/sanei_backend.h"
|
||||
#include "sane/sanei_config.h"
|
||||
|
@ -166,7 +166,7 @@
|
|||
/*****************************************************************************/
|
||||
|
||||
#define _SECTION "[merlin-device]"
|
||||
#define _DEFAULT_DEVICE "/dev/usb/scanner0"
|
||||
#define _DEFAULT_DEVICE "auto"
|
||||
|
||||
/* declare it here, as it's used in plustek-usbscan.c too :-( */
|
||||
static SANE_Bool cancelRead;
|
||||
|
@ -208,7 +208,6 @@ static const SANE_String_Const mode_list[] =
|
|||
SANE_I18N("Halftone"),
|
||||
SANE_I18N("Gray"),
|
||||
SANE_I18N("Color"),
|
||||
/* SANE_I18N("Color30"), */
|
||||
NULL
|
||||
};
|
||||
|
||||
|
@ -1220,13 +1219,10 @@ static SANE_Status attach( const char *dev_name, pCnfDef cnf,
|
|||
/** function to preset a configuration structure
|
||||
* @param cnf - pointer to the structure that should be initialized
|
||||
*/
|
||||
static void init_config_struct( pCnfDef cnf, SANE_Bool is_usb )
|
||||
static void init_config_struct( pCnfDef cnf )
|
||||
{
|
||||
memset( cnf, 0, sizeof(CnfDef));
|
||||
|
||||
if( is_usb )
|
||||
strcpy( cnf->devName, "auto" );
|
||||
|
||||
cnf->adj.warmup = -1;
|
||||
cnf->adj.lampOff = -1;
|
||||
cnf->adj.lampOffOnEnd = -1;
|
||||
|
@ -1274,7 +1270,7 @@ SANE_Status sane_init( SANE_Int *version_code, SANE_Auth_Callback authorize )
|
|||
num_devices = 0;
|
||||
|
||||
/* initialize the configuration structure */
|
||||
init_config_struct( &config, SANE_FALSE );
|
||||
init_config_struct( &config );
|
||||
|
||||
if( version_code != NULL )
|
||||
*version_code = SANE_VERSION_CODE(V_MAJOR, V_MINOR, 0);
|
||||
|
@ -1283,7 +1279,7 @@ SANE_Status sane_init( SANE_Int *version_code, SANE_Auth_Callback authorize )
|
|||
|
||||
/* default to _DEFAULT_DEVICE instead of insisting on config file */
|
||||
if( NULL == fp ) {
|
||||
return attach(_DEFAULT_DEVICE, &config, 0);
|
||||
return attach( _DEFAULT_DEVICE, &config, 0 );
|
||||
}
|
||||
|
||||
while( sanei_config_read( str, sizeof(str), fp)) {
|
||||
|
@ -1350,16 +1346,20 @@ SANE_Status sane_init( SANE_Int *version_code, SANE_Auth_Callback authorize )
|
|||
char *tmp;
|
||||
|
||||
/* new section, try and attach previous device */
|
||||
if( config.devName[0] != '\0' )
|
||||
if( config.devName[0] != '\0' ) {
|
||||
attach( config.devName, &config, 0 );
|
||||
} else {
|
||||
DBG( _DBG_WARNING, "section contains no device name,"
|
||||
" ignored!\n" );
|
||||
}
|
||||
|
||||
/* re-initialize the configuration structure */
|
||||
init_config_struct( &config, SANE_TRUE );
|
||||
init_config_struct( &config );
|
||||
|
||||
tmp = config.usbId;
|
||||
decodeUsbIDs( str, &tmp );
|
||||
|
||||
DBG( _DBG_SANE_INIT, "next device is an USB device\n" );
|
||||
DBG( _DBG_SANE_INIT, "... next device\n" );
|
||||
continue;
|
||||
|
||||
} else if( SANE_TRUE == decodeDevName( str, config.devName )) {
|
||||
|
|
|
@ -88,14 +88,13 @@
|
|||
#include "sane/sanei.h"
|
||||
#include "sane/saneopts.h"
|
||||
|
||||
#define BACKEND_VERSION "0.01"
|
||||
#define BACKEND_VERSION "0.01-1"
|
||||
#define BACKEND_NAME plustek_pp
|
||||
#include "sane/sanei_backend.h"
|
||||
#include "sane/sanei_config.h"
|
||||
|
||||
#define _BACKEND_ENABLED
|
||||
|
||||
#ifdef _BACKEND_ENABLED
|
||||
#ifdef HAVE_IOPERM
|
||||
# define _BACKEND_ENABLED
|
||||
# define _USER_MODE
|
||||
#endif
|
||||
|
||||
|
@ -121,8 +120,6 @@
|
|||
*/
|
||||
MODELSTR;
|
||||
|
||||
#define _DEFAULT_DEVICE "0x378"
|
||||
|
||||
#ifdef _BACKEND_ENABLED
|
||||
|
||||
/* needed to statisfy the module code ... */
|
||||
|
@ -146,14 +143,19 @@ MODELSTR;
|
|||
# include "plustek-pp_procfs.c"
|
||||
# include "plustek-pp_scale.c"
|
||||
# include "plustek-pp_tpa.c"
|
||||
#endif
|
||||
|
||||
#include "plustek-pp_wrapper.c"
|
||||
#define _DEFAULT_DEVICE "0x378"
|
||||
#else
|
||||
#define _DEFAULT_DEVICE "/dev/pt_drv"
|
||||
#endif
|
||||
|
||||
#ifdef _BACKEND_ENABLED
|
||||
# include "plustek-pp_ptdrv.c"
|
||||
#endif
|
||||
|
||||
#include "plustek-pp_wrapper.c"
|
||||
|
||||
|
||||
/************************** global vars **************************************/
|
||||
|
||||
static int num_devices;
|
||||
|
@ -1179,7 +1181,11 @@ SANE_Status sane_init( SANE_Int *version_code, SANE_Auth_Callback authorize )
|
|||
num_devices = 0;
|
||||
|
||||
/* initialize the configuration structure */
|
||||
#ifdef _BACKEND_ENABLED
|
||||
init_config_struct( &config, SANE_TRUE );
|
||||
#else
|
||||
init_config_struct( &config, SANE_FALSE );
|
||||
#endif
|
||||
|
||||
if( version_code != NULL )
|
||||
*version_code = SANE_VERSION_CODE(V_MAJOR, V_MINOR, 0);
|
||||
|
@ -1188,7 +1194,7 @@ SANE_Status sane_init( SANE_Int *version_code, SANE_Auth_Callback authorize )
|
|||
|
||||
/* default to _DEFAULT_DEVICE instead of insisting on config file */
|
||||
if( NULL == fp ) {
|
||||
return attach(_DEFAULT_DEVICE, &config, 0);
|
||||
return attach( _DEFAULT_DEVICE, &config, 0 );
|
||||
}
|
||||
|
||||
while( sanei_config_read( str, sizeof(str), fp)) {
|
||||
|
|
|
@ -25,9 +25,9 @@ option lampOff -1
|
|||
#
|
||||
# example for accessing the scanner via the kernel module
|
||||
#
|
||||
[kernel]
|
||||
device /dev/pt_drv
|
||||
|
||||
option warmup -1
|
||||
option lOffOnEnd -1
|
||||
option lampOff -1
|
||||
#[kernel]
|
||||
#device /dev/pt_drv
|
||||
#
|
||||
#option warmup -1
|
||||
#option lOffOnEnd -1
|
||||
#option lampOff -1
|
||||
|
|
|
@ -275,7 +275,6 @@ In sane-backends/backend/
|
|||
to DISTFILES in Makefile.in
|
||||
|
||||
In sane-backends/doc/
|
||||
* Add the name of the man page to doc/.cvsignore
|
||||
* Add an entry for the man page in sane.man
|
||||
* Add the man page file in doc/Makefile.in
|
||||
* Move the description file from descriptions-external/ to doc/descriptions/
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
.TH sane-plustek 5 "17 September 2003" "@PACKAGEVERSION@" "SANE Scanner Access Now Easy"
|
||||
.TH sane-plustek 5 "24 September 2003" "@PACKAGEVERSION@" "SANE Scanner Access Now Easy"
|
||||
.IX sane-plustek
|
||||
.SH NAME
|
||||
sane-plustek \- SANE backend for Plustek parallel port and
|
||||
|
@ -7,128 +7,20 @@ LM983[1/2/3] based USB flatbed scanners
|
|||
The
|
||||
.B sane-plustek
|
||||
library implements a SANE (Scanner Access Now Easy) backend that
|
||||
provides access to Plustek parallel port and USB flatbed scanners.
|
||||
The USB support is part of the SANE package but for usage with
|
||||
parallel port scanners you will need a kernel module, called
|
||||
pt_drv which currently can be downloaded from
|
||||
.br
|
||||
.B http://www.gjaeger.de/scanner/plustek.html
|
||||
.PP
|
||||
.B !!!Please note that you need the kernel module only for
|
||||
.B parallel port scanners!!!
|
||||
|
||||
.SH "PARALLEL PORT SUPPORT"
|
||||
|
||||
At present, the following scanners should work with this backend
|
||||
and the corresponding kernel module:
|
||||
.PP
|
||||
.B "PLUSTEK SCANNERS"
|
||||
.PP
|
||||
Parallelport Model: ASIC: Properties:
|
||||
.br
|
||||
---------------------- ----- ------------------------
|
||||
.br
|
||||
OpticPro PT12 98003 600x1200 dpi 36bit 512Kb
|
||||
.br
|
||||
OpticPro P12 98003 600x1200 dpi 36bit 512Kb
|
||||
.br
|
||||
OpticPro 9636T/12000T 98001 600x1200 dpi 36bit 512Kb
|
||||
.br
|
||||
OpticPro 12000P Turbo 98001 600x1200 dpi 36bit 512Kb
|
||||
.br
|
||||
OpticPro 9636P+/Turbo 98001 600x1200 dpi 36bit 512Kb
|
||||
.br
|
||||
OpticPro 9636P 96003 600x1200 dpi 36bit 128Kb
|
||||
.br
|
||||
OpticPro 12000P/96000P 96003 600x1200 dpi 36bit 128Kb
|
||||
.br
|
||||
OpticPro 1236P 96003 600x1200 dpi 30bit 128Kb
|
||||
.br
|
||||
OpticPro 9600P 96003 600x1200 dpi 30bit 128Kb
|
||||
.br
|
||||
OpticPro 9630P/FBIV 96003 600x1200 dpi 30bit 128Kb
|
||||
.br
|
||||
OpticPro 9630PL (14") 96003 600x1200 dpi 30bit 128Kb
|
||||
.br
|
||||
OpticPro A3I 96003 400x800 dpi 36bit 128Kb
|
||||
.br
|
||||
OpticPro 600P/6000P 96003 300x600 dpi 30bit 32Kb
|
||||
.br
|
||||
OpticPro 4831P 96003 300x600 dpi 30bit 32Kb
|
||||
.br
|
||||
OpticPro 4830P/FBIII 96003 300x600 dpi 30bit 32Kb
|
||||
.br
|
||||
OpticPro 4800P/FBII 96001 300x600 dpi 24bit 32Kb
|
||||
.br
|
||||
.PP
|
||||
|
||||
.B "PRIMAX SCANNERS"
|
||||
|
||||
There are some scanners sold by Primax, but they are in fact
|
||||
Plustek devices. These scanners are also supported.
|
||||
The following table will show the relationship:
|
||||
.PP
|
||||
Model: Plustek Model: Remarks:
|
||||
.br
|
||||
--------------------------- -------------- ------------
|
||||
.br
|
||||
Colorado 4800 OpticPro 4800 not tested
|
||||
.br
|
||||
Compact 4800 Direct OpticPro 600 mov=2
|
||||
.br
|
||||
Compact 4800 Direct 30bit OpticPro 4830 mov=7
|
||||
.br
|
||||
Compact 9600 Direct 30bit OpticPro 9630 works
|
||||
.PP
|
||||
|
||||
.B "GENIUS SCANNERS"
|
||||
|
||||
The following devices are sold as Genius Scanners, but are in fact
|
||||
Plustek devices.
|
||||
The table will show the relationship:
|
||||
.PP
|
||||
Model: Remarks:
|
||||
.br
|
||||
--------------------------- ----------------------------
|
||||
.br
|
||||
Colorpage Vivid III V2 Like P12 but has two buttons
|
||||
.br
|
||||
and Wolfson DAC
|
||||
.PP
|
||||
|
||||
.B "ARIES SCANNERS"
|
||||
|
||||
There's one scanner sold as Aries Scanner, but is in fact a
|
||||
Plustek device.
|
||||
The following table will show the relationship:
|
||||
.PP
|
||||
Model: Plustek Model: Remarks:
|
||||
.br
|
||||
--------------------------- -------------- ------------
|
||||
.br
|
||||
Scan-It 4800 OpticPro 600 mov=2
|
||||
.PP
|
||||
|
||||
.B "BrightScan SCANNERS"
|
||||
|
||||
There's one scanner sold as BrightScan OpticPro Scanner, this is also
|
||||
rebadged Plustek device.
|
||||
The following table will show the relationship:
|
||||
.PP
|
||||
Model: Remarks:
|
||||
.br
|
||||
--------------------------- ----------------------------
|
||||
.br
|
||||
BrightScan OpticPro OpticPro P12
|
||||
|
||||
.SH "USB SUPPORT"
|
||||
provides access to USB flatbed scanners based on National Semiconductor
|
||||
Merlin chipsets (LM9831, 9832 and 9833).
|
||||
If you're looking for parallel-port support for Plustek scanner
|
||||
please refer to the
|
||||
.B sane-plustek_pp
|
||||
backend.
|
||||
|
||||
.SH "SUPPORTED DEVICES"
|
||||
The Backend is able to support USB scanner based on the National
|
||||
Semiconductor chipset LM9831, LM9832 and LM9833. The following tables
|
||||
Semiconductor chipsets LM9831, LM9832 and LM9833. The following tables
|
||||
show various devices which are currently reported to work. If your
|
||||
Plustek scanner has another Product ID, then the device is
|
||||
.B NOT
|
||||
supported, as it contains unsupported ASICs inside.
|
||||
supported, as it contains an unsupported ASIC inside.
|
||||
.br
|
||||
|
||||
Vendor Plustek - ID: 0x07B3
|
||||
|
@ -257,16 +149,18 @@ CanoScan N1240U LM9833 1200x2400dpi 48bit 512Kb 0x220E
|
|||
CanoScan LIDE20 LM9833 600x1200dpi 48bit 512Kb 0x220D
|
||||
.br
|
||||
CanoScan LIDE30 LM9833 1200x2400dpi 48bit 512Kb 0x220E
|
||||
.PP
|
||||
|
||||
.SH "OTHER PLUSTEK SCANNERS"
|
||||
|
||||
For parallelport device support see the
|
||||
.B plustek_pp
|
||||
backend.
|
||||
.br
|
||||
The SCSI scanner OpticPro 19200S is a rebadged Artec AM12S scanner
|
||||
and is supported by the
|
||||
.B Artec
|
||||
backend.
|
||||
.br
|
||||
Only the National Semiconductor LM9831/2 based devices of Plustek
|
||||
Only the National Semiconductor LM983[1/2/] based devices of Plustek
|
||||
are supported by this driver. Older versions of the U12, the UT12,
|
||||
the U1212 and U1248 (GrandTech chipset) are not supported.
|
||||
.PP
|
||||
|
@ -277,227 +171,18 @@ Model Chipset backend
|
|||
U1248 GrandTech gt68xx
|
||||
.br
|
||||
UT16B GrandTech gt68xx
|
||||
.PP
|
||||
|
||||
.SH "DEVICE NAMES"
|
||||
This backend expects a default device called:
|
||||
.PP
|
||||
.RS
|
||||
.I /dev/pt_drv
|
||||
.RE
|
||||
.PP
|
||||
This default device will be used, if no configuration
|
||||
file can be found.
|
||||
.PP
|
||||
The device-driver is currently not part of the SANE distribution.
|
||||
It has to be downloaded from:
|
||||
.br
|
||||
.B http://www.gjaeger.de/scanner/plustek.html
|
||||
.br
|
||||
See the INSTALL file there for a proper setup. Currently only Linux
|
||||
is supported by this driver (Kernel 2.2.x and higher).
|
||||
.PP
|
||||
As the backend and the driver support up to four devices
|
||||
per system, it is possible to specify them in the configuration
|
||||
file
|
||||
.PP
|
||||
.RS
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.RE
|
||||
.PP
|
||||
See the plustek.conf file for examples.
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION"
|
||||
.PP
|
||||
The configuration of this backend can be divided into two sections:
|
||||
.br
|
||||
.PP
|
||||
.B "CONFIGURATION - parallel port scanner"
|
||||
.PP
|
||||
.br
|
||||
.B "CONFIGURATION - USB scanner"
|
||||
.PP
|
||||
.br
|
||||
Please make sure, that the configuration matches the real world,
|
||||
namely your configuration. And note again, .I pt_drv is only needed
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION - PARALLEL PORT SCANNER"
|
||||
.PP
|
||||
Beside the kernel-module options, which are described below, you
|
||||
need to enable the parallel port device in the configuration file
|
||||
.PP
|
||||
.RS
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.RE
|
||||
.PP
|
||||
For a proper setup, you will need at least two entries:
|
||||
|
||||
.TP
|
||||
.I [parport]
|
||||
.TP
|
||||
.I device /dev/pt_drv
|
||||
.PP
|
||||
.I parport
|
||||
tells the backend, that the following devicename (here
|
||||
.I /dev/pt_drv
|
||||
) has to be interpreted as parallel port scanner device.
|
||||
.PP
|
||||
To have this device, you will need to setup the kernel module.
|
||||
As the driver is a loadable kernel module, it is configured
|
||||
by invoking insmod with the appropriate parameters or
|
||||
appending the options to the file
|
||||
.B /etc/conf.modules
|
||||
.PP
|
||||
.B
|
||||
The Options:
|
||||
.br
|
||||
lampoff=lll
|
||||
.RS
|
||||
The value
|
||||
.I lll
|
||||
tells the driver, after how many seconds to
|
||||
switch-off the lamp(s). The default value is 180.
|
||||
0 will disable this feature.
|
||||
.br
|
||||
.B HINT:
|
||||
Do not use a value that is too small, because often
|
||||
switching on/off the lamps will reduce their lifetime.
|
||||
.RE
|
||||
.PP
|
||||
port=ppp
|
||||
.RS
|
||||
.I ppp
|
||||
specifies the port base address, where the scanner
|
||||
is connected to. The default value is 0x378 which
|
||||
normaly is standard.
|
||||
.RE
|
||||
.PP
|
||||
warmup=www
|
||||
.RS
|
||||
.I www
|
||||
specifies the time in seconds, how long a lamp has to be on,
|
||||
until the driver will start to scan. The default value is 30.
|
||||
.RE
|
||||
.PP
|
||||
lOffonEnd=e
|
||||
.RS
|
||||
.I e
|
||||
specifies the behaviour when unloading the driver, 1 --> switch
|
||||
lamps off, 0 --> do not change lamp status
|
||||
.RE
|
||||
.PP
|
||||
slowIO=s
|
||||
.RS
|
||||
.I s
|
||||
specifies which I/O functions the driver should use, 1 --> use
|
||||
delayed functions, 0 --> use the non-delayed ones
|
||||
.RE
|
||||
.PP
|
||||
forceMode=fm
|
||||
.RS
|
||||
.I fm
|
||||
specifies port mode which should be used, 0 --> autodetection,
|
||||
1 --> use SPP mode and 2 --> use EPP mode
|
||||
.RE
|
||||
.PP
|
||||
mov=m
|
||||
.RS
|
||||
.I m
|
||||
=0 - default: no override
|
||||
.br
|
||||
.I m
|
||||
=1 - OpticPro 9630PL override (works if OP9630
|
||||
.br
|
||||
has been detected) forces legal size (14")
|
||||
.br
|
||||
.I m
|
||||
=2 - Primax 4800Direct override (works if OP600
|
||||
.br
|
||||
has been detected) swaps red/green color
|
||||
.br
|
||||
.I m
|
||||
=3 - OpticPro 9636 override (works if OP9636 has
|
||||
.br
|
||||
been detected) disables backends
|
||||
.br
|
||||
transparency/negativ capabilities
|
||||
.br
|
||||
.I m
|
||||
=4 - OpticPro 9636P override (works if OP9636 has
|
||||
.br
|
||||
been detected) disables backends
|
||||
.br
|
||||
transparency/negativ capabilities
|
||||
.br
|
||||
.I m
|
||||
=5 - OpticPro A3I override (works if OP12000 has
|
||||
.br
|
||||
been detected) enables A3 scanning
|
||||
.br
|
||||
.I m
|
||||
=6 - OpticPro 4800P override (works if OP600
|
||||
.br
|
||||
has been detected) swaps red/green color
|
||||
.br
|
||||
.I m
|
||||
=7 - Primax 4800Direct 30bit override (works if OP4830
|
||||
.br
|
||||
has been detected)
|
||||
.br
|
||||
.RE
|
||||
.PP
|
||||
Sample entry for file
|
||||
.B "/etc/modules.conf"
|
||||
:
|
||||
.br
|
||||
.I alias char-major-40 pt_drv
|
||||
.br
|
||||
.I pre-install pt_drv modprobe -k parport
|
||||
.br
|
||||
.I options pt_drv lampoff=180 warmup=15 port=0x378 lOffonEnd=0 mov=0 slowIO=0 forceMode=0
|
||||
.PP
|
||||
For multidevice support, simply add values separated by commas to
|
||||
the different options
|
||||
.br
|
||||
.I options pt_drv port=0x378,0x278 mov=0,4 slowIO=0,1 forceMode=0,1
|
||||
.PP
|
||||
Remember to call depmod after changing /etc/conf.modules.
|
||||
.PP
|
||||
.B "PARALLEL PORT MODES"
|
||||
.PP
|
||||
The current driver works best, when the parallel port
|
||||
has been set to EPP-mode. When detecting any other
|
||||
mode such as ECP or PS/2 the driver tries to set to a
|
||||
faster, supported mode. If this fails, it will use the
|
||||
SPP mode, as this mode should work with all Linux supported
|
||||
parallel ports.
|
||||
.PP
|
||||
Former Plustek scanner models (4830, 9630) supplied a
|
||||
ISA parallel port adapter card. This card is
|
||||
.BR not
|
||||
supported by the driver.
|
||||
.PP
|
||||
The ASIC 96001/3 based models have sometimes trouble with
|
||||
high resolution modes. If you encounter sporadic corrupted
|
||||
images (parts duplicated or shifted horizontally) kill all
|
||||
other applications before scanning and (if sufficient
|
||||
memory available) disable swapping.
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION - USB SCANNER"
|
||||
.PP
|
||||
To use the USB device with this backend, you need at least
|
||||
two entries in the configuration file
|
||||
To use your scanner with this backend, you need at least two
|
||||
entries in the configuration file
|
||||
.br
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.TP
|
||||
.I [usb] vendor-id product-id
|
||||
.I [merlin-device] vendor-id product-id
|
||||
.TP
|
||||
.I device /dev/usbscanner
|
||||
.PP
|
||||
.I usb
|
||||
.I merlin-device
|
||||
tells the backend, that the following devicename (here
|
||||
.I /dev/usbscanner
|
||||
) has to be interpreted as USB scanner device. If vendor- and
|
||||
|
@ -536,6 +221,36 @@ option invertNegatives b
|
|||
1 --> invert picture
|
||||
.RE
|
||||
.PP
|
||||
option cacheCalData b
|
||||
.RS
|
||||
.I b
|
||||
0 --> do not save coarse calibration results,
|
||||
1 --> save results of coarse calibration in ~/.sane/ directory
|
||||
.RE
|
||||
.PP
|
||||
option altCalibrate b
|
||||
.RS
|
||||
.I b
|
||||
0 --> use standard calibration routines,
|
||||
1 --> use alternate calibration (only non Plustek
|
||||
.br
|
||||
devices, standard for CIS devices)
|
||||
.RE
|
||||
.PP
|
||||
option skipFine b
|
||||
.RS
|
||||
.I b
|
||||
0 --> perform fine calibration,
|
||||
1 --> skip fine calibration (only non Plustek devices)
|
||||
.RE
|
||||
.PP
|
||||
option skipFineWhite b
|
||||
.RS
|
||||
.I b
|
||||
0 --> perform white fine calibration,
|
||||
1 --> skip white fine calibration (only non Plustek devices)
|
||||
.RE
|
||||
.PP
|
||||
option skipCalibration b
|
||||
.RS
|
||||
.I b
|
||||
|
@ -628,7 +343,17 @@ device, simply load the USB subsystem and plug in your
|
|||
scanner. Then do a
|
||||
.I cat /proc/bus/usb/devices
|
||||
and look for the scanner.
|
||||
.br
|
||||
Alternatively, the backend is able to access your scanner via
|
||||
libusb. You might use
|
||||
.B sane-find-scanner
|
||||
to check that you have access to your device.
|
||||
.PP
|
||||
.B Note:
|
||||
.br
|
||||
If there's no configuration file, the backend defaults to
|
||||
.B device auto
|
||||
. So it
|
||||
|
||||
.SH FILES
|
||||
.TP
|
||||
|
@ -641,13 +366,8 @@ The static library implementing this backend.
|
|||
.I @LIBDIR@/libsane-plustek.so
|
||||
The shared library implementing this backend (present on systems that
|
||||
support dynamic loading).
|
||||
.TP
|
||||
.I /lib/modules/<Kernel-Version>/misc/pt_drv.o
|
||||
The Linux Kernelmodule.
|
||||
.PP
|
||||
|
||||
.SH "CONTACT AND BUG-REPORTS"
|
||||
.PP
|
||||
Please send any information and bug-reports to:
|
||||
.br
|
||||
.B Plustek Driver Mailing List <plustek@linuxhacker.org>
|
||||
|
@ -678,21 +398,8 @@ values greater than 19 force the backend to output raw data files,
|
|||
which could be rather large. The ending of these files is ".raw".
|
||||
For problem reports it should be enough the set the verbosity to
|
||||
13.
|
||||
.PP
|
||||
|
||||
.SH "KNOWN BUGS & RESTRICTIONS"
|
||||
.PP
|
||||
.br
|
||||
* The Halftoning works, but the quality is poor
|
||||
.br
|
||||
* Printers (especially HP models) will start to
|
||||
.br
|
||||
print during scanning. This in fact is a problem
|
||||
.br
|
||||
to other printers too, using bidirectional protocol
|
||||
.br
|
||||
(see www.plustek.com (TAIWAN) page for further details)
|
||||
.br
|
||||
* The driver does not support these manic scalings up
|
||||
.br
|
||||
to 16 times the physical resolution. The only scaling
|
||||
|
@ -707,37 +414,6 @@ For problem reports it should be enough the set the verbosity to
|
|||
.br
|
||||
600dpi but the motor is capable to perform 800dpi steps.
|
||||
.br
|
||||
* On some devices, the pictures seems to be bluished
|
||||
.PP
|
||||
ASIC 98001 based models:
|
||||
.br
|
||||
* The 300dpi transparency and negative mode does not work
|
||||
.br
|
||||
correctly.
|
||||
.br
|
||||
* There is currently no way to distinguish a model with
|
||||
.br
|
||||
and without transpareny unit.
|
||||
.br
|
||||
* The scanned images seem to be too dark (P9636T)
|
||||
.PP
|
||||
ASIC 96003/1 based models:
|
||||
.br
|
||||
* 30bit mode is currently not supported.
|
||||
.br
|
||||
* On low-end systems and under heavy system load, the
|
||||
.br
|
||||
driver will loosing data, this might causes the sensor
|
||||
.br
|
||||
to hit the scan-bed and/or the picture is corrupted.
|
||||
.br
|
||||
* The scanspeed on 600x1200 dpi models is slow.
|
||||
.br
|
||||
* The scanquality of the A3I is poor
|
||||
.br
|
||||
.PP
|
||||
USB models:
|
||||
.br
|
||||
* Plusteks' model policy is somewhat inconsistent. This
|
||||
.br
|
||||
means, they sell technical different devices under the
|
||||
|
@ -750,4 +426,4 @@ USB models:
|
|||
.br
|
||||
the one your device has.
|
||||
.br
|
||||
* Negative scanning quality is poor.
|
||||
* Negative/Slide scanning quality is poor.
|
||||
|
|
|
@ -1,26 +1,24 @@
|
|||
.TH sane-plustek 5 "17 September 2003" "@PACKAGEVERSION@" "SANE Scanner Access Now Easy"
|
||||
.IX sane-plustek
|
||||
.TH sane-plustek_pp 5 "24 September 2003" "@PACKAGEVERSION@" "SANE Scanner Access Now Easy"
|
||||
.IX sane-plustek_pp
|
||||
.SH NAME
|
||||
sane-plustek \- SANE backend for Plustek parallel port and
|
||||
LM983[1/2/3] based USB flatbed scanners
|
||||
sane-plustek_pp \- SANE backend for Plustek parallel port
|
||||
flatbed scanners
|
||||
.SH DESCRIPTION
|
||||
The
|
||||
.B sane-plustek
|
||||
.B sane-plustek_pp
|
||||
library implements a SANE (Scanner Access Now Easy) backend that
|
||||
provides access to Plustek parallel port and USB flatbed scanners.
|
||||
The USB support is part of the SANE package but for usage with
|
||||
parallel port scanners you will need a kernel module, called
|
||||
pt_drv which currently can be downloaded from
|
||||
.br
|
||||
.B http://www.gjaeger.de/scanner/plustek.html
|
||||
.PP
|
||||
.B !!!Please note that you need the kernel module only for
|
||||
.B parallel port scanners!!!
|
||||
provides access to Plustek ASIC 9600[1/3] and P9800[1/3] based
|
||||
parallel port flatbed scanners.
|
||||
The access of the scanner is either done directly by the backend
|
||||
or via kernel module, called pt_drv which can be created out of
|
||||
the plustek_pp backend code - see also section
|
||||
.B "BUILDING THE KERNEL MODULE"
|
||||
for further information.
|
||||
|
||||
.SH "PARALLEL PORT SUPPORT"
|
||||
.SH "SUPPORTED DEVICES"
|
||||
|
||||
At present, the following scanners should work with this backend
|
||||
and the corresponding kernel module:
|
||||
and/or the kernel module:
|
||||
.PP
|
||||
.B "PLUSTEK SCANNERS"
|
||||
.PP
|
||||
|
@ -112,7 +110,7 @@ Scan-It 4800 OpticPro 600 mov=2
|
|||
.B "BrightScan SCANNERS"
|
||||
|
||||
There's one scanner sold as BrightScan OpticPro Scanner, this is also
|
||||
rebadged Plustek device.
|
||||
a rebadged Plustek device.
|
||||
The following table will show the relationship:
|
||||
.PP
|
||||
Model: Remarks:
|
||||
|
@ -121,225 +119,54 @@ Model: Remarks:
|
|||
.br
|
||||
BrightScan OpticPro OpticPro P12
|
||||
|
||||
.SH "USB SUPPORT"
|
||||
|
||||
The Backend is able to support USB scanner based on the National
|
||||
Semiconductor chipset LM9831, LM9832 and LM9833. The following tables
|
||||
show various devices which are currently reported to work. If your
|
||||
Plustek scanner has another Product ID, then the device is
|
||||
.B NOT
|
||||
supported, as it contains unsupported ASICs inside.
|
||||
.br
|
||||
|
||||
Vendor Plustek - ID: 0x07B3
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
OpticPro U12 LM9831 600x1200dpi 42bit 512Kb 0x0010
|
||||
.br
|
||||
OpticPro UT12 LM9831 600x1200dpi 42bit 512Kb 0x0013
|
||||
.br
|
||||
OpticPro UT12 LM9832 600x1200dpi 42bit 512Kb 0x0017
|
||||
.br
|
||||
OpticPro UT16 LM9832 600x1200dpi 42bit 512Kb 0x0017
|
||||
.br
|
||||
OpticPro U24 LM9831 1200x2400dpi 42bit 2Mb 0x0011
|
||||
.br
|
||||
OpticPro U24 LM9832 1200x2400dpi 42bit 2Mb 0x0015
|
||||
.br
|
||||
OpticPro UT24 LM9832 1200x2400dpi 42bit 2Mb 0x0017
|
||||
.PP
|
||||
|
||||
Vendor KYE/Genius - ID: 0x0458
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
Colorpage HR6 V2 LM9832 600x1200dpi 42bit 512Kb 0x2007
|
||||
.br
|
||||
Colorpage HR6 V2 LM9832 600x1200dpi 42bit 512Kb 0x2008
|
||||
.br
|
||||
Colorpage HR6A LM9832 600x1200dpi 42bit 512Kb 0x2009
|
||||
.br
|
||||
Colorpage HR7 LM9832 600x1200dpi 42bit 512Kb 0x2013
|
||||
.br
|
||||
Colorpage HR7LE LM9832 600x1200dpi 42bit 512Kb 0x2015
|
||||
.br
|
||||
Colorpage HR6X LM9832 600x1200dpi 42bit 512Kb 0x2016
|
||||
.PP
|
||||
|
||||
Vendor Hewlett-Packard - ID: 0x03F0
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
ScanJet 2100C LM9831 600x1200dpi 42bit 512Kb 0x0505
|
||||
.br
|
||||
ScanJet 2200C LM9832 600x1200dpi 42bit 512Kb 0x0605
|
||||
.PP
|
||||
|
||||
Vendor Mustek - ID: 0x0400
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
BearPaw 1200 LM9831 600x1200dpi 42bit 512Kb 0x1000
|
||||
.br
|
||||
BearPaw 2400 LM9832 1200x2400dpi 42bit 2Mb 0x1001
|
||||
.PP
|
||||
|
||||
Vendor UMAX - ID: 0x1606
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
UMAX 3400/3450 LM9832 600x1200dpi 42bit 512Kb 0x0060
|
||||
.br
|
||||
UMAX 5400 LM9832 1200x2400dpi 42bit 512Kb 0x0160
|
||||
.PP
|
||||
|
||||
Vendor COMPAQ - ID: 0x049F
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
S4-100 LM9832 600x1200dpi 42bit 512Kb 0x001A
|
||||
.PP
|
||||
|
||||
Vendor Epson - ID: 0x04B8
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
Perfection 1250 LM9832 1200x2400dpi 42bit 512Kb 0x010F
|
||||
.br
|
||||
Perfection 1260 LM9832 1200x2400dpi 42bit 512Kb 0x011D
|
||||
.PP
|
||||
|
||||
Vendor CANON - ID: 0x04A9
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
USB Model: ASIC: Properties: Prod-ID
|
||||
.br
|
||||
----------------------------------------------------------
|
||||
.br
|
||||
CanoScan N650/656U LM9832 600x1200dpi 42bit 512Kb 0x2206
|
||||
.br
|
||||
CanoScan N1220U LM9832 1200x2400dpi 42bit 512Kb 0x2207
|
||||
.br
|
||||
CanoScan N670/676U LM9833 600x1200dpi 48bit 512Kb 0x220D
|
||||
.br
|
||||
CanoScan N1240U LM9833 1200x2400dpi 48bit 512Kb 0x220E
|
||||
.br
|
||||
CanoScan LIDE20 LM9833 600x1200dpi 48bit 512Kb 0x220D
|
||||
.br
|
||||
CanoScan LIDE30 LM9833 1200x2400dpi 48bit 512Kb 0x220E
|
||||
.PP
|
||||
|
||||
.SH "OTHER PLUSTEK SCANNERS"
|
||||
|
||||
The SCSI scanner OpticPro 19200S is a rebadged Artec AM12S scanner
|
||||
and is supported by the
|
||||
.B Artec
|
||||
backend.
|
||||
.br
|
||||
Only the National Semiconductor LM9831/2 based devices of Plustek
|
||||
are supported by this driver. Older versions of the U12, the UT12,
|
||||
the U1212 and U1248 (GrandTech chipset) are not supported.
|
||||
.PP
|
||||
Model Chipset backend
|
||||
.br
|
||||
---------------------------
|
||||
.br
|
||||
U1248 GrandTech gt68xx
|
||||
.br
|
||||
UT16B GrandTech gt68xx
|
||||
.PP
|
||||
|
||||
.SH "DEVICE NAMES"
|
||||
This backend expects a default device called:
|
||||
This backend works in two modes, the so called "direct-mode"
|
||||
and the "kernel-mode". In direct-mode, the user-space backend is
|
||||
used, in kernel-mode, you should have a kernel-module named pt_drv
|
||||
loaded.
|
||||
This backends default device is:
|
||||
.PP
|
||||
.RS
|
||||
.I /dev/pt_drv
|
||||
.I 0x378
|
||||
.RE
|
||||
.PP
|
||||
This default device will be used, if no configuration
|
||||
file can be found.
|
||||
This "default device" will be used, if no configuration
|
||||
file can be found. It is rather the base address of the parallel port
|
||||
on i386 machines.
|
||||
.PP
|
||||
The device-driver is currently not part of the SANE distribution.
|
||||
It has to be downloaded from:
|
||||
.br
|
||||
.B http://www.gjaeger.de/scanner/plustek.html
|
||||
.br
|
||||
See the INSTALL file there for a proper setup. Currently only Linux
|
||||
is supported by this driver (Kernel 2.2.x and higher).
|
||||
.PP
|
||||
As the backend and the driver support up to four devices
|
||||
per system, it is possible to specify them in the configuration
|
||||
file
|
||||
As the backend supports up to four devices, it is possible to
|
||||
specify them in the configuration file
|
||||
.PP
|
||||
.RS
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.I @CONFIGDIR@/plustek_pp.conf
|
||||
.RE
|
||||
.PP
|
||||
See the plustek.conf file for examples.
|
||||
See the plustek_pp.conf file for examples.
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION"
|
||||
.PP
|
||||
The configuration of this backend can be divided into two sections:
|
||||
.br
|
||||
.PP
|
||||
.B "CONFIGURATION - parallel port scanner"
|
||||
.PP
|
||||
.br
|
||||
.B "CONFIGURATION - USB scanner"
|
||||
.PP
|
||||
.br
|
||||
Please make sure, that the configuration matches the real world,
|
||||
namely your configuration. And note again, .I pt_drv is only needed
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION - PARALLEL PORT SCANNER"
|
||||
.PP
|
||||
Beside the kernel-module options, which are described below, you
|
||||
need to enable the parallel port device in the configuration file
|
||||
.PP
|
||||
.RS
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.I @CONFIGDIR@/plustek_pp.conf
|
||||
.RE
|
||||
.PP
|
||||
For a proper setup, you will need at least two entries:
|
||||
|
||||
.TP
|
||||
.I [parport]
|
||||
.I [direct]
|
||||
.TP
|
||||
.I device 0x378
|
||||
.PP
|
||||
or
|
||||
.TP
|
||||
.I [kernel]
|
||||
.TP
|
||||
.I device /dev/pt_drv
|
||||
.PP
|
||||
.I parport
|
||||
.I direct
|
||||
tells the backend, that the following devicename (here
|
||||
.I /dev/pt_drv
|
||||
) has to be interpreted as parallel port scanner device.
|
||||
|
@ -485,160 +312,23 @@ images (parts duplicated or shifted horizontally) kill all
|
|||
other applications before scanning and (if sufficient
|
||||
memory available) disable swapping.
|
||||
.PP
|
||||
See the plustek_pp.conf file for examples.
|
||||
.PP
|
||||
|
||||
.SH "CONFIGURATION - USB SCANNER"
|
||||
.PP
|
||||
To use the USB device with this backend, you need at least
|
||||
two entries in the configuration file
|
||||
.br
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.TP
|
||||
.I [usb] vendor-id product-id
|
||||
.TP
|
||||
.I device /dev/usbscanner
|
||||
.PP
|
||||
.I usb
|
||||
tells the backend, that the following devicename (here
|
||||
.I /dev/usbscanner
|
||||
) has to be interpreted as USB scanner device. If vendor- and
|
||||
product-id has not been specified, the backend tries to
|
||||
detect this by its own. If device ist set to
|
||||
.I auto
|
||||
then the next matching device is used.
|
||||
.PP
|
||||
.B
|
||||
The Options:
|
||||
.PP
|
||||
option warmup t
|
||||
.RS
|
||||
.I t
|
||||
specifies the warmup period in seconds
|
||||
.RE
|
||||
.PP
|
||||
option lampOff t
|
||||
.RS
|
||||
.I t
|
||||
is the time in seconds for switching off the lamps in
|
||||
standby mode
|
||||
.RE
|
||||
.PP
|
||||
option lOffonEnd b
|
||||
.RS
|
||||
.I b
|
||||
specifies the behaviour when closing the backend, 1 --> switch
|
||||
lamps off, 0 --> do not change lamp status
|
||||
.RE
|
||||
.PP
|
||||
option invertNegatives b
|
||||
.RS
|
||||
.I b
|
||||
0 --> do not invert the picture during negativ scans,
|
||||
1 --> invert picture
|
||||
.RE
|
||||
.PP
|
||||
option skipCalibration b
|
||||
.RS
|
||||
.I b
|
||||
0 --> perform calibration,
|
||||
1 --> skip calibration (only non Plustek devices)
|
||||
.RE
|
||||
.PP
|
||||
option enableTPA b
|
||||
.RS
|
||||
.I b
|
||||
0 --> default behaviour, specified by the internal tables,
|
||||
1 --> override internal tables and allow TPA mode (EPSON only)
|
||||
.RE
|
||||
|
||||
.PP
|
||||
option posOffX x
|
||||
.br
|
||||
option posOffY y
|
||||
.br
|
||||
option tpaOffX x
|
||||
.br
|
||||
option tpaOffY y
|
||||
.br
|
||||
option negOffX x
|
||||
.br
|
||||
option negOffY y
|
||||
.RS
|
||||
.I x y
|
||||
By using this settings, the user can adjust the given image
|
||||
positions.
|
||||
.B Please note, that there's no internal range checking for
|
||||
.B this feature.
|
||||
.RE
|
||||
.PP
|
||||
option posShadingY p
|
||||
.br
|
||||
option tpaShadingY p
|
||||
.br
|
||||
option negShadingY p
|
||||
.RS
|
||||
.I p
|
||||
overrides the internal shading position. The values are in steps.
|
||||
.B Please note, that there's no internal range checking for
|
||||
.B this feature.
|
||||
.RE
|
||||
.PP
|
||||
option redGamma r
|
||||
.br
|
||||
option greenGamma g
|
||||
.br
|
||||
option blueGamma b
|
||||
.br
|
||||
option grayGamma gr
|
||||
.RS
|
||||
.I r g b gr
|
||||
.RE
|
||||
By using these values, the internal linear gamma table (r,g,b,gr = 1.0)
|
||||
can be adjusted.
|
||||
.PP
|
||||
option red_gain r
|
||||
.br
|
||||
option green_gain g
|
||||
.br
|
||||
option blue_gain b
|
||||
.RS
|
||||
.I r g b
|
||||
These values can be used to adjust the internally detected gain values of
|
||||
the AFE for each channel. The range is between 0 and 63.
|
||||
.RE
|
||||
|
||||
.PP
|
||||
See the plustek.conf file for examples.
|
||||
.PP
|
||||
.B Note:
|
||||
.br
|
||||
You have to make sure, that the USB subsystem is loaded
|
||||
correctly and the module
|
||||
.I scanner
|
||||
has been loaded too. To make this module recognize your
|
||||
scanner, you might have to add the following line to
|
||||
your
|
||||
.B "/etc/modules.conf"
|
||||
:
|
||||
.br
|
||||
.I options scanner vendor=0x7b3 product=0x17
|
||||
.PP
|
||||
.br
|
||||
If you're not sure about the vendor and product id of your
|
||||
device, simply load the USB subsystem and plug in your
|
||||
scanner. Then do a
|
||||
.I cat /proc/bus/usb/devices
|
||||
and look for the scanner.
|
||||
.SH "BUILDING THE KERNEL MODULE"
|
||||
As mentioned before, the plustek_pp backend code can also
|
||||
be compiled and installed as linux kernel module...
|
||||
.PP
|
||||
|
||||
.SH FILES
|
||||
.TP
|
||||
.I @CONFIGDIR@/plustek.conf
|
||||
.I @CONFIGDIR@/plustek_pp.conf
|
||||
The backend configuration file
|
||||
.TP
|
||||
.I @LIBDIR@/libsane-plustek.a
|
||||
.I @LIBDIR@/libsane-plustek_pp.a
|
||||
The static library implementing this backend.
|
||||
.TP
|
||||
.I @LIBDIR@/libsane-plustek.so
|
||||
.I @LIBDIR@/libsane-plustek_pp.so
|
||||
The shared library implementing this backend (present on systems that
|
||||
support dynamic loading).
|
||||
.TP
|
||||
|
@ -671,13 +361,9 @@ environment-variable
|
|||
.I SANE_DEBUG_PLUSTEK
|
||||
before calling your favorite scan-frontend (i.e. xscanimage).
|
||||
.br
|
||||
.B i.e.: export SANE_DEBUG_PLUSTEK=20 ; xscanimage
|
||||
.B i.e.: export SANE_DEBUG_PLUSTEK_PP=20 ; xscanimage
|
||||
.PP
|
||||
The value controls the verbosity of the backend. Please note, that
|
||||
values greater than 19 force the backend to output raw data files,
|
||||
which could be rather large. The ending of these files is ".raw".
|
||||
For problem reports it should be enough the set the verbosity to
|
||||
13.
|
||||
The value controls the verbosity of the backend.
|
||||
.PP
|
||||
|
||||
.SH "KNOWN BUGS & RESTRICTIONS"
|
||||
|
@ -727,7 +413,7 @@ ASIC 96003/1 based models:
|
|||
.br
|
||||
* On low-end systems and under heavy system load, the
|
||||
.br
|
||||
driver will loosing data, this might causes the sensor
|
||||
driver will loose data, this might causes the sensor
|
||||
.br
|
||||
to hit the scan-bed and/or the picture is corrupted.
|
||||
.br
|
||||
|
@ -735,19 +421,3 @@ ASIC 96003/1 based models:
|
|||
.br
|
||||
* The scanquality of the A3I is poor
|
||||
.br
|
||||
.PP
|
||||
USB models:
|
||||
.br
|
||||
* Plusteks' model policy is somewhat inconsistent. This
|
||||
.br
|
||||
means, they sell technical different devices under the
|
||||
.br
|
||||
same product name. Therefore it is possible that some
|
||||
.br
|
||||
devices like the UT12 or U12 won't work - please check
|
||||
.br
|
||||
the model list above and compare the product-id to
|
||||
.br
|
||||
the one your device has.
|
||||
.br
|
||||
* Negative scanning quality is poor.
|
||||
|
|
Ładowanie…
Reference in New Issue