scan-manager -- python app for controlling tethered cameras

General discussion about software packages and releases, new software you've found, and threads by programmers and script writers.

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 18 Apr 2012, 02:40

Hi TKR,

It sounds like its the auto-calibration code again; I've put up yet another version!

Inspired by you I ordered one of these http://www.amazon.co.uk/exec/obidos/ASIN/B005OFKXXK too. This seems to be the same board or chipset used in a lot of very cheap USB capture sticks so it seems like a good place to start. If OpenCV can talk to it then integrating it into the app should be straightforward (and from googling it seems that OpenCV probably does work with these if you can find the right drivers).
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 20 Apr 2012, 03:50

Here's a qick explanation of how to measure chessboards for calibration. It's supposed to pop up automatically if you do something wrong but that's not always happening.
calibration.jpg
Calibration error popup
calibration.jpg (35.95 KiB) Viewed 447 times

I'm just finishing off my new scanner build today so I should be able to have a new release up tonight.
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby Fab52 » 21 Apr 2012, 09:50

Hi,

Thanks for the explanation of how to figure out the chessboard... I was completly lost... A photo worth 1000 words. :D

Just to make sure I get it right, the size of the chessboard should be the same of the printed text of the book we are scanning ? Or???

To make it clear, if I'm scanning a A4 book with different margin size than the printed chessboard, I just re-size the margin in ScanManager in the calibration module. Right ??

Fab
Fab52
 
Posts: 63
Joined: 21 Feb 2012, 21:10
Location: Montreal South Shore, Quebec, Canada

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 21 Apr 2012, 13:11

Hi,

The chessboard is just there as a target to correct lens distortion and perspective; it doesn't have to be exactly the same size as the book. I haven't played with it that much, but any size that more or less fills the area you're interested in should be enough. That's the area that will 'look right' after processing. Beyond that may be somewhat distorted.

So it may be enough to just have an A4 pattern and use that every time. I'm playing with it myself right now and I'll let you know what results I get.

By the way, I've uploaded a PNG version of the chessboard as well (300dpi). The PDF is a better bet though since it's vector.
Attachments
chessboard.zip
PNG version of the chessboard (use the PDF version if you can -- this is in case you have trouble resizing that one)
(870 Bytes) Downloaded 25 times
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby daniel_reetz » 21 Apr 2012, 15:20

og200, I've changed this topic to a "sticky". Thanks for all your work.
User avatar
daniel_reetz
 
Posts: 2487
Joined: 03 Jun 2009, 13:56

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 21 Apr 2012, 18:20

I've finally gone through my first book with ScanManager and it worked pretty well; I've put in a number of bug fixes to deal with issues that have stopped people from getting this working with their cameras (it's much clerver about not trying to write to read-only properties like focal length on DSLRs now). I also fixed a memory leak in the gphoto code on Windows.

It's getting a bit late over here so I won't have time to retest the installer (I usually do this on a blank Virtual Machine to make sure it all works) but the code works for me. It's up on the google code site now as 0.4.4 (I'm leaving 0.4.3 up and non-deprecated for now).
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby Fab52 » 21 Apr 2012, 23:01

Hi Og,

I was able to test the calibration module it work fine on my side and correct the perspective and barrel distorsion fine. But it still print 178 pages(photos) of the chessboard in the process folder.

I was unable to shoot with the D90... Clicking "start viewfinder" but nothing happen... The laptop seem to take control of the D90 since I saw the focus moving and the the release of the shutter during the time WIA was install. After the initial set-up the control panel on the D90 instead of showing all the infos setting of the camera just show "PC".

I PM the log file....


I hope this will help !!!

Fab
Fab52
 
Posts: 63
Joined: 21 Feb 2012, 21:10
Location: Montreal South Shore, Quebec, Canada

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 22 Apr 2012, 03:01

Hi Fab,

Thanks for sending the logs -- I'll try to figure out why viewfinder is breaking on your D90. I notice you got the 'Could not claim the USB device' error. If you do get this, you need to use the Task Manager to find any instances of gphotoremote.exe and kill it. It's supposed to exit when the app does but that doesn't always happen. I'm working on that but finding a way to ensure the child process is really always killed on exit has been difficult.

Ideally someone would just port libgphoto2 using Mingw and I could do without having a subprocess altogether -- I had a go but it was looking like a very long job.

O
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 22 Apr 2012, 03:19

Getting ScanManager running with different cameras can still be tricky. I'm working on making the process smoother but for now, here's a procedure for getting started:

First, get your camera working with gphoto2 -- SM uses libgphoto2 to talk to it so if it doesn't work with gphoto2 it won't work with SM's libgphoto2 backend. (There are others but they only support a few cameras or limited control.)

If you're running on Windows, I've put up a Windows build of gphoto2 here. Don't forget to read what it says in the readme about environment variables (or just use gphoto2.bat from the directory where you unzip it rather than using the .exe).

The main command lines to try are:
  • gphoto2 --summary
  • gphoto2 --capture-and-download
  • gphoto2 --capture-preview

Summary will just print out a long list of stuff if the camera is responsive; the others do what they say they do!

If this --capture-and-download works, ScanManager's gphoto backend should be able to talk to your camera and shoot pictures; if --capture-preview works you may get viewfinder support too (and you may get viewfinder support even if it doesn't work).

I'd love to hear about any successes/failures.
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

Re: scan-manager -- python app for controlling tethered came

Postby og200 » 22 Apr 2012, 17:04

A quick note on Windows XP -- I didn't included the MS Visual C runtime dlls in the builds so this may not have run at all on a fresh XP install. You can download them here but the next build (0.4.5) won't require them to be installed.
og200
 
Posts: 62
Joined: 26 Mar 2012, 15:38
Location: Oxford, United Kingdom

PreviousNext

Return to Programs, Software releases, and more.

Who is online

Users browsing this forum: No registered users and 1 guest