Extract the zip file to a directory. This will create the following files:
twain.pyd - the twain module executable demo - demonstration programs directory twexplore - the twexplore program directory docs - the module documentation
For Python 2.2 or later
Copy the file 'twain.pyd' to your site-packages directory, i.e.
copy twain.pyd c:\python22\lib\site-packages
For Python 2.1.x
Copy the file 'twain.pyd' to your DLLs directory, i.e.
copy twain.pyd c:\python21\DLLs
You need to have wxPython installed to run the twexplore python scripts. If you do not have wxPython installed, you can download a binary version of this program, see below.
The source can be downloaded from CVS on SourceForge, or can be extracted from the 'tarball' file, twainsrc_1.0b1.zip, where 1.0b1 refers to beta 1 of release 1 of the module. Extract the source from the server, either a zipped file, or via CVS. Place the directory 'twainmodule' parallel to the 'Libs' directory in your python installation.
Download and install the TWAIN Toolkit from the TWAIN website. The header file twain.h is in the twain toolkit. If you do not install the TWAIN toolkit in the default location, you will have to change the twain module project definition to set the include path to this file.
Change directory to the twainmodule/src directory. Load the project workspace into Microsoft Visual C++. Build the DLL and place it in your python path, e.g. in the site-packages directory.
Extract the file to a directory. You can run the program (twexplore.exe) from this directory.