Fotos laden direkt aus der Kamera

(DE) Anwendungen für Office, Multimedia und Spiele, Werkzeuge, Hilfsprogramme, etc
(EN) Applications for Office, Multimedia or Games, Tools, Utilities, e.g.
ajunra
Posts: 370
Joined: Mon 23. Dec 2013, 06:40
Location: Insel Rügen

Re: Fotos laden direkt aus der Kamera

Post by ajunra » Thu 15. Jan 2015, 18:29

Hallo Guzzi,
It's working but only with completely full batteries.
Ein ähnliches Problem hatte ich mal mit einer neuen Kamera: Laut Handbuch sollte ich ausschließlich Batterien (AA) verwenden, empfohlen wurden Lithium-Batterien. Doch mit diesen schaffte er auch nur vier Fotos, mit 'normalen' Batterien kam er sogar nur auf zwei bis drei. Aus Verzweiflung und Frust (irgendwann ist der heimische Batterievorrat halt erschöpft) griff ich dann zu den explizit ausgeschlossenen Akkus. Und siehe da: 40 Fotos - auch teilw. mit Blitz - sind nun ohne Akkuwechsel gar kein Problem mehr. Irgendwie haben die entweder die Technik geändert oder das (sonst recht gut geschriebene) total vergeigt. Eventuell trifft Dich ja ein ähnliches Problem...
Hoffe geholfen zu haben.
Schöne Grüße von Deutschlands größter Insel
ajunra

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Thu 15. Jan 2015, 19:27

Guzzi wrote:
I have sent the camera, you should have it in a day or two. Please save the packaging, I do want the camera back because I have found a solution for the low battery problem). I will of course pay for the postage.
O.K. I'll do that,
Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 15. Jan 2015, 23:41

ajunra » Thu 15. Jan 2015, 18:29 wrote:Hallo Guzzi,
It's working but only with completely full batteries.
Ein ähnliches Problem hatte ich mal mit einer neuen Kamera: Laut Handbuch sollte ich ausschließlich Batterien (AA) verwenden, empfohlen wurden Lithium-Batterien. Doch mit diesen schaffte er auch nur vier Fotos, mit 'normalen' Batterien kam er sogar nur auf zwei bis drei. Aus Verzweiflung und Frust (irgendwann ist der heimische Batterievorrat halt erschöpft) griff ich dann zu den explizit ausgeschlossenen Akkus. Und siehe da: 40 Fotos - auch teilw. mit Blitz - sind nun ohne Akkuwechsel gar kein Problem mehr. Irgendwie haben die entweder die Technik geändert oder das (sonst recht gut geschriebene) total vergeigt. Eventuell trifft Dich ja ein ähnliches Problem...
Hoffe geholfen zu haben.
Lithium batterien schaffen etwa 1,3 volt. Mein enloesung ist andere batterien. NiZh. Nickel Zinc . Unbelastete klammervoltage 1,6 volt. Belastet immer ueber 1,3. Dass problem ist immerhin fehlerhafte software. Aber wenn mann batterien verwendet mit hoeheren stromspannung soll es funktionieren.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Sun 18. Jan 2015, 10:07

Hallo Guzzi,
I have sent the camera, you should have it in a day or two. Please save the packaging, I do want the camera back because I have found a solution for the low battery problem). I will of course pay for the postage.
The camera arrived yesterday in good order. Thank you. I can right now confirm the following:

1. PtPro110 does work here with the usbcalls.dll and usbresmg.sys from PtPro110.
2. PtPro110 does work here with the usbcalls.dll and usbresmg.sys from Camera15.
3. PtPro110 does NOT work with the usbcalls.dll and usbresmg.sys from usbres01.

The Camera15 usbcalls.dll and usbresmg.sys are equal to the eComStation 2.0 ones.
N.B. PtPro110 does work here with the LarsErdmann version 197 usbresmg.sys too.

I tested with "ptpro -d" which showed the camera and "ptpro -l" which showed the list of files.
I tested on eComStation 2.0 (single core cpu) and Lars Erdmann version 197 usb drivers.

Wim.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Mon 19. Jan 2015, 10:48

Hallo DonLucio and Guzzi,
3. PtPro110 does NOT work with the usbcalls.dll and usbresmg.sys from usbres01.
I have updated my Usb Resource Manager. Go to my website, download usbres02.zip and do the installation.

Both PrPro110 and Camera15 work here. Most likely Tame/2 will work too.

Regards, Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Mon 19. Jan 2015, 18:19

Wimpie » Mon 19. Jan 2015, 10:48 wrote:Hallo DonLucio and Guzzi,
3. PtPro110 does NOT work with the usbcalls.dll and usbresmg.sys from usbres01.
I have updated my Usb Resource Manager. Go to my website, download usbres02.zip and do the installation.

Both PrPro110 and Camera15 work here. Most likely Tame/2 will work too.

Regards, Wim.
Just tried, still get read errors. I tried with both the latest AN usb drivers and the Lars Erdmann 197 drivers. I also see bulk read errors in scanimage.exe, Scanning breaks off at about 65% (Breaks off at about 50% with AN latest usbcalls)

LIBUSB: Found device 1 on bus 1
LIBUSB: Found device 2 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 3 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 4 on bus 1

Device list
===========
Bus Device VendorID ProductID Camera
PTPRO: USB read response failed - code= 0x1002 rc= 0x000a
1 1 0x04A9 0x1730 could not open device
LIBUSB: unable to read from bulk endpoint - size= 36 rtn= 0 rc= 8040
PTPRO: USB read response failed - code= 0x1002 rc= 0x000b
1 2 0x058F 0x6364 could not open device
LIBUSB: unable to write to bulk endpoint - size= 16 rc= 1b5b
PTPRO: USB write command failed - code= 0x1002 rc= 0xffffffff
1 3 0x0A81 0x0205 could not open device
1 4 0x04B0 0x041E D60
PTPRO: USB read response failed - code= 0x1003 rc= 0x2006
PTPRO: Could not close session.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Mon 19. Jan 2015, 22:47

To Guzzi, I am puzzled... Are you sure that your nikon d60 camera is set to ptp mode? Could you just try:

ptpro -d -v2

ptpro -l -v2

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Tue 20. Jan 2015, 01:12

Wimpie » Mon 19. Jan 2015, 22:47 wrote:To Guzzi, I am puzzled... Are you sure that your nikon d60 camera is set to ptp mode? Could you just try:

ptpro -d -v2
ptpro -l -v2
F:\apps\pmraw>ptpro -d -v2
usb_set_debug: Setting debugging level to 2 (on)
LIBUSB: Found device 1 on bus 1
LIBUSB: Found device 2 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 3 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 4 on bus 1

Device list
===========
Bus Device VendorID ProductID Camera
1 4 0x04B0 0x041E D60
PTPRO: USB read response failed - code= 0x1003 rc= 0x2006
PTPRO: Could not close session.


F:\apps\pmraw>ptpro -l -v2
usb_set_debug: Setting debugging level to 2 (on)
LIBUSB: Found device 1 on bus 1
LIBUSB: Found device 2 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 3 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 4 on bus 1
PTPRO: USB read response failed - code= 0x1002 rc= 0x201e
ERROR: unable to open session

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Wed 21. Jan 2015, 09:01

Hallo Guzzi,

I don't know what the best way is to tackle the problem, but I decided to let you try out some intermediate versions first. There were some major changes that I implemented in steps. The version in guzzi8.zip is about halfway of these steps. If it does not work I'll go some more steps backwards.

Download guzzi8.zip from my website and rename the files into usbcalls.dll and usbresmg.sys and install these.

Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Wed 21. Jan 2015, 12:32

Wimpie » Wed 21. Jan 2015, 09:01 wrote:Hallo Guzzi,

I don't know what the best way is to tackle the problem, but I decided to let you try out some intermediate versions first. There were some major changes that I implemented in steps. The version in guzzi8.zip is about halfway of these steps. If it does not work I'll go some more steps backwards.

Download guzzi8.zip from my website and rename the files into usbcalls.dll and usbresmg.sys and install these.

Wim.
These behave somewhat different. After I switch the camera on and it has connected to usb and I run ptpro -l -v2 I get a file listing that ends with:

1075380553 4159971 2015-01-15 19:25 DSC_0329.JPG
PTPRO: USB read response failed - code= 0x1003 rc= 0x2006
PTPRO: Could not close session.

If I run the command a second time I get the same error as before:
F:\apps\pmraw>ptpro -l -v2
usb_set_debug: Setting debugging level to 2 (on)
LIBUSB: Found device 1 on bus 1
LIBUSB: Found device 2 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 3 on bus 1
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: skipped 1 class/vendor specific interface descriptors
LIBUSB: Found device 4 on bus 1
PTPRO: USB read response failed - code= 0x1002 rc= 0x201e
ERROR: unable to open session

Also, any ptpro command that I run will give proper output, but -only- the first time it is run after the camera has been switched on, a second time it will give just an error.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Wed 21. Jan 2015, 22:47

1075380553 4159971 2015-01-15 19:25 DSC_0329.JPG
PTPRO: USB read response failed - code= 0x1003 rc= 0x2006
PTPRO: Could not close session.
The real problem appears to be the 0x2006 error. It means PTP_RC_ParameterNotSupported. This error code has been defined in source file ptprocodes.h but I can't find where it is actually reported in the code. I must be blind. It is a shame that everything works till the end and then it gets this error code that prevents any more proper operation. I wonder if ptpro.exe has a stack problem. Not that I know how to fix that...
Also, any ptpro command that I run will give proper output, but -only- the first time it is run after the camera has been switched on, a second time it will give just an error.
Once the session cannot be closed, the device refuses to open it again, saying that it is already opened. That is the error 0x201e which means PTP_RC_SessionAlreadyOpened. I'll have a look into the code again tomorrow.

Wim.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Wed 21. Jan 2015, 23:32

The real problem appears to be the 0x2006 error. It means PTP_RC_ParameterNotSupported.This error code has been defined in source file ptprocodes.h but I can't find where it is actually reported in the code. I must be blind.
O.K. I turned the light on and I suddenly saw what happens. This error code is actually coming from your camera. And the PTP_RC_ParameterNotSupported is returned because The CloseSession routine passes 1 parameter which it shouldn't. The camera15 application does not pass a parameter on closing a session. So try out if camera.exe does indeed work.

Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 00:57

Wimpie » Wed 21. Jan 2015, 23:32 wrote:
The real problem appears to be the 0x2006 error. It means PTP_RC_ParameterNotSupported.This error code has been defined in source file ptprocodes.h but I can't find where it is actually reported in the code. I must be blind.
O.K. I turned the light on and I suddenly saw what happens. This error code is actually coming from your camera. And the PTP_RC_ParameterNotSupported is returned because The CloseSession routine passes 1 parameter which it shouldn't. The camera15 application does not pass a parameter on closing a session. So try out if camera.exe does indeed work.

Wim.
Yes, with the "guzzi" set I just tested with camera.exe and that works!
Will your fix be implemented in the Arca Noae set too?
Scanning still does break off halfway, but I have already created a ticket about that on the AN website.
Thanks a lot, Wim!

P.S. Just to be complete, this is what scanimage.exe says after the data transmission that does go ok:

[sanei_usb] sanei_usb_read_bulk: trying to read 524288 bytes
[sanei_usb] sanei_usb_read_bulk: read failed: Other error
[pixma] IN T=32.582 len=-9
[pixma] ERROR: ETIMEDOUT
[pixma]
[sanei_usb] sanei_usb_write_bulk: trying to write 16 bytes
[sanei_usb] 000 EF 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 . ..............
[sanei_usb] sanei_usb_write_bulk: wanted 16 bytes, wrote 16 bytes
[pixma] OUT T=32.582 len=16
[pixma] 00000000:ef 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[pixma]
[sanei_usb] sanei_usb_read_bulk: trying to read 8 bytes
[sanei_usb] 000 06 06 00 00 00 00 00 00 ........
[sanei_usb] sanei_usb_read_bulk: wanted 8 bytes, got 8 bytes
[pixma] IN T=32.582 len=8
[pixma] 00000000:06 06 00 00 00 00 00 00
[pixma]
[pixma] pixma_read_image() failed EEOF
[pixma] Reader task terminated: EEOF
[pixma] BUG: unmapped error -14
[pixma] read_image():reader task closed the pipe:505296 bytes received, 1678578 bytes expected
scanimage: min/max graylevel value = 40/251
scanimage: sane_read: Error during device I/O
[pixma] pixma_close(): Canon PIXMA MP540
[sanei_usb] sanei_usb_close: closing device 0

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Thu 22. Jan 2015, 09:57

Yes, with the "guzzi" set I just tested with camera.exe and that works!
Will your fix be implemented in the Arca Noae set too?
Now that "guzzi" works, you'll still have to test camera.exe with the usbres02.zip drivers to confirm that these work too.

David Azarewicz is aware of "Changeset [1220]: USBCALLS: fix UsbBulkRead for PtPro110" so Arca Noae will pick it up.

PtPro110 need to be updated to fix its CloseSession routine to not pass 1 parameter which it shouldn't.
There is another place in PtPro110 that needs to be fixed too. The report size used by UsbQueryDeviceReport is only 1024 bytes. This needs to be increased to 4096 bytes to accommodate usb webcams with large compound descriptors like the logitech c250 camera. Otherwise no ptp camera will be found at all unless you disconnect that usb device which may not be possible because it is an integrated one. This needs to be fixed in the camera15 application too.

Regards, Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 12:28

Wimpie » Thu 22. Jan 2015, 09:57 wrote:

Now that "guzzi" works, you'll still have to test camera.exe with the usbres02.zip drivers to confirm that these work too.

David Azarewicz is aware of "Changeset [1220]: USBCALLS: fix UsbBulkRead for PtPro110" so Arca Noae will pick it up.

PtPro110 need to be updated to fix its CloseSession routine to not pass 1 parameter which it shouldn't.
There is another place in PtPro110 that needs to be fixed too. The report size used by UsbQueryDeviceReport is only 1024 bytes. This needs to be increased to 4096 bytes to accommodate usb webcams with large compound descriptors like the logitech c250 camera. Otherwise no ptp camera will be found at all unless you disconnect that usb device which may not be possible because it is an integrated one. This needs to be fixed in the camera15 application too.

Regards, Wim.
Tested with usbres02.zip, works.

I'm not a programmer and don't have a clue how to compile the sources but I had a look to see what needs to be changed.
I see in the camusb.c line 629 source compared to the prpro.usb line 401 source this difference :

cnr.length = CAMCNR_CALCSIZE(0);
cnr.length = CAMCNR_CALCSIZE(1);

Is this what needs to be changed in the CloseSession routine?

And camlibusb.c line 55 and os2.c line 311should be:
char report[4096];

Is that correct?

Will have to ask someone with the knowledge to do the compile but wiould be easier if I know what the changes should be.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 14:38

Diver has recompiled ptpro with the required changes. A testversion is at ftp://guest:guest@guzzi.demon.nl/ptpro.exe

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 15:05

Guzzi » Thu 22. Jan 2015, 14:38 wrote:Diver has recompiled ptpro with the required changes. A testversion is at ftp://guest:guest@guzzi.demon.nl/ptpro.exe

And camera,exe: ftp://guest:guest@guzzi.demon.nl/camera.exe

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Thu 22. Jan 2015, 15:41

I see in the camusb.c line 629 source compared to the prpro.usb line 401 source this difference :

cnr.length = CAMCNR_CALCSIZE(0);
cnr.length = CAMCNR_CALCSIZE(1);

Is this what needs to be changed in the CloseSession routine?
Yes. I would replace line 401 with line 628 and line 402 with line 629 to make CAMCNR_CALCSIZE(0); obvious.
And camlibusb.c line 55 and os2.c line 311should be:
char report[4096];

Is that correct?
Yes.
Diver has recompiled ptpro with the required changes. A testversion is at ftp://guest:guest@guzzi.demon.nl/ptpro.exe
And camera,exe: ftp://guest:guest@guzzi.demon.nl/camera.exe
Nice. Together we are a good team. I will download and test these then.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Thu 22. Jan 2015, 17:04

Diver has recompiled ptpro with the required changes. A testversion is at ftp://guest:guest@guzzi.demon.nl/ptpro.exe
And camera,exe: ftp://guest:guest@guzzi.demon.nl/camera.exe
Both work over here with the usbres02.zip drivers.
Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 17:14

Wimpie » Thu 22. Jan 2015, 17:04 wrote:
Diver has recompiled ptpro with the required changes. A testversion is at ftp://guest:guest@guzzi.demon.nl/ptpro.exe
And camera,exe: ftp://guest:guest@guzzi.demon.nl/camera.exe
Both work over here with the usbres02.zip drivers.
Wim.
Thanks, Wim.

I'll ask Martin I if he'll put the changed sources on github and will see to it that the complete zips get uploaded to Netlabs and/or Hobbes with reference to usbres02.zip.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Thu 22. Jan 2015, 17:45

Thanks, Wim.

I'll ask Martin I if he'll put the changed sources on github and will see to it that the complete zips get uploaded to Netlabs and/or Hobbes with reference to usbres02.zip.
Thanks to you too. I think we are done. I'll upload usbres02.zip to hobbes.
Thanks also for letting me use your camera. I'll send it back tomorrow.

Wim.

Guzzi
Posts: 93
Joined: Sat 20. Dec 2014, 00:26

Post by Guzzi » Thu 22. Jan 2015, 22:58

Wimpie » Thu 22. Jan 2015, 17:45 wrote:
Thanks, Wim.

I'll ask Martin I if he'll put the changed sources on github and will see to it that the complete zips get uploaded to Netlabs and/or Hobbes with reference to usbres02.zip.
Thanks to you too. I think we are done. I'll upload usbres02.zip to hobbes.
Thanks also for letting me use your camera. I'll send it back tomorrow.

Wim.
Wim, you said you don't have a ptp camera to test with. If you can actually use the camera i sent you. please keep it. I think I have found a solution to the low battery issue. NiZ batteries with a clammer tension of 1,6 volts. I have ordered a set. Let me know if you have an actual use for the camera.

User avatar
Wimpie
Posts: 54
Joined: Sat 10. Jan 2015, 21:58
Location: Uithoorn

Post by Wimpie » Fri 23. Jan 2015, 08:47

Wim, you said you don't have a ptp camera to test with. If you can actually use the camera i sent you. please keep it. I think I have found a solution to the low battery issue. NiZ batteries with a clammer tension of 1,6 volts. I have ordered a set. Let me know if you have an actual use for the camera.
That camera is wasted on me. I prefer to send it back. From experience I learned that I should keep it a few more weeks.

User avatar
Frank Wochatz
Posts: 977
Joined: Sun 22. Dec 2013, 22:04
Location: Berlin

Post by Frank Wochatz » Fri 23. Jan 2015, 11:58

Congratulation guys. Nice to follow your progress. :)