chdkptp - alternative ptp client - page 52 - General Discussion and Assistance - CHDK Forum

chdkptp - alternative ptp client

  • 1106 Replies
  • 517706 Views
Re: alternative ptp client
« Reply #510 on: 25 / January / 2014, 14:20:29 »
Advertisements
After I ran the test , I was wondering if it was possible to run the test from chkptp and how to do it. ( including the settings of the camera )
I don't know if you noticed,  but I replied to your post in the other testing thread.  You missed a couple of tests and it would be good to get those results too  :D
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline reyalp

  • ******
  • 14082
Re: alternative ptp client
« Reply #511 on: 25 / January / 2014, 14:58:24 »
I replaced the lua subfolder in my  chdkptp-r468-win32 folder with the new one from trunk.
The command
Code: [Select]
!require'extras/rsint'.init()appears to go through (no error message when running it at least). But the command rsint errors like this
Code: [Select]
ERROR: build does not support shoot hook
You need to use a recent CHDK 1.3 build from http://mighty-hoernsche.de/trunk/
Don't forget what the H stands for.

*

Offline poussin

  • *
  • 36
  • A2200
Re: alternative ptp client
« Reply #512 on: 25 / January / 2014, 17:47:33 »
After I ran the test , I was wondering if it was possible to run the test from chkptp and how to do it. ( including the settings of the camera )

Further to my question I ran into a problem
Here is the log of the command  loadfile("A/CHDK/SCRIPTS/MF_TEST.LUA")()
when I wanted to play the dump file to see the error message

> list
*1:Canon PowerShot A2200 b=bus-0 d=\\.\libusb0-0002--0x04a9-0x322a v=0x4a9 p=0x322a s=85046B2D98F043448BDDA65F6A2726ED
recording to chdk_322a_20140125_232304.lvdump
559168264 bytes recorded to chdk_322a_20140125_232304.lvdump
error getting frame: ptp error
recording to chdk_322a_20140125_232535.lvdump
113046424 bytes recorded to chdk_322a_20140125_232535.lvdump
recording to chdk_322a_20140125_232611.lvdump
>  .loadfile("A/CHDK/SCRIPTS/MF_TEST.LUA")()
67567984 bytes recorded to chdk_322a_20140125_232611.lvdump
playing \chdk_322a_20140125_232611.lvdump
loading dump ver 1.0
live timer update error
\chdkptp-r438-win32\lua\chdku.lua:1374: attempt to perform arithmetic on field 'margin_left' (a nil value)
stack traceback:
\chdkptp-r438-win32\lua\chdku.lua:1374: in function 'get_screen_width'
\chdkptp-r438-win32\lua\gui_live.lua:94: in function 'update_canvas_size'
\chdkptp-r438-win32\lua\gui_live.lua:401: in function <\chdkptp-r438-win32\lua\gui_live.lua:383>
   [C]: in function 'xpcall'
   \chdkptp-r438-win32\lua\gui_live.lua:424: in function <...s\doc tech\CANON\chdkptp-r438-win32\lua\gui_live.lua:422>
   (tail call): ?
   [C]: in function 'MainLoop'
   \chdkptp-r438-win32\lua\gui.lua:630: in function <\chdkptp-r438-win32\lua\gui.lua:616>
   (tail call): ?
   \chdkptp-r438-win32\lua\main.lua:231: in main chunk
   [C]: in function 'require'
   [string "require('main')"]:1: in main chunklive timer update error

note : the lvdump size is  85 Mbytes

Re: alternative ptp client
« Reply #513 on: 25 / January / 2014, 18:40:16 »
I hope to try a similar single instance "swap con" http://chdk.setepontos.com/index.php?topic=8769.msg91611#msg91611  version

Attached is that autoit proof of concept file.


*

Offline poussin

  • *
  • 36
  • A2200
Re: alternative ptp client
« Reply #514 on: 26 / January / 2014, 06:11:45 »
After I ran the test , I was wondering if it was possible to run the test from chkptp and how to do it. ( including the settings of the camera )

Further to my question I ran into a problem
Here is the log of the command  loadfile("A/CHDK/SCRIPTS/MF_TEST.LUA")()
when I wanted to play the dump file to see the error message

after a PC reboot and without the camera connected ,  I reran chdkptp|debug |play from file chdk_322a_20140125_232304.lvdump  and I was able to display the frames and to extract the error message from the frames
Attached is the error message from the run of  MF_TEST.LUA from chkptp.


Re: alternative ptp client
« Reply #515 on: 26 / January / 2014, 10:25:34 »
Attached is the error message from the run of  MF_TEST.LUA from chkptp.
That error would have originated from the fprintf() function call in line 188 of the script.  It's trying to print the various bits of informaion returned from calling get_buildinfo() and it looks like bi.platsub is being returned as "null" when you run the script from chdkptp.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline tpont

  • **
  • 81
Re: alternative ptp client
« Reply #516 on: 26 / January / 2014, 15:37:11 »
You need to use a recent CHDK 1.3 build from http://mighty-hoernsche.de/trunk/
Ok running it now. The A490 average cycle time when saving to PC using rsint is now down to 2.1 seconds :) . From around 5. And the rsint mode appears to be forgiving. Sending a "s" command while the previous one is still processing appears to cue the command and run it when it can. I will test drive this with two camera parallel shooting through a script that sends commands to two cmd windows in interactive mode. But this is looking super good so far.
« Last Edit: 26 / January / 2014, 15:39:29 by tpont »

*

Offline reyalp

  • ******
  • 14082
Re: alternative ptp client
« Reply #517 on: 26 / January / 2014, 16:17:27 »
Sending a "s" command while the previous one is still processing appears to cue the command and run it when it can. I will test drive this with two camera parallel shooting through a script that sends commands to two cmd windows in interactive mode. But this is looking super good so far.
Good to hear.

One note is that there is currently a hard coded timeout, if no "s" or "l" is received for 60 seconds, the script will end, probably with some errors.

Edit: Oops, above is incorrect. The actual timeout is currently 10 second, and the camera will continue shooting every 10 seconds but not downloading. I'll try to clean this up.

I'm not sure if there is a limit to how long the camera can be made to wait in the shoot hook.
« Last Edit: 26 / January / 2014, 17:23:02 by reyalp »
Don't forget what the H stands for.


*

Offline reyalp

  • ******
  • 14082
Re: alternative ptp client
« Reply #518 on: 26 / January / 2014, 16:21:28 »
After I ran the test , I was wondering if it was possible to run the test from chkptp and how to do it. ( including the settings of the camera )

Further to my question I ran into a problem
Here is the log of the command  loadfile("A/CHDK/SCRIPTS/MF_TEST.LUA")()
For this to work, you need to set the menu parameters (a, b, c etc) before calling the script. Anyway, waterwingz script isn't designed to work in ptp, so other things might go wrong too.

It's not obvious to me why playing the dump failed.
Don't forget what the H stands for.

*

Offline tpont

  • **
  • 81
Re: alternative ptp client
« Reply #519 on: 26 / January / 2014, 17:47:01 »
Edit: Oops, above is incorrect. The actual timeout is currently 10 second, and the camera will continue shooting every 10 seconds but not downloading. I'll try to clean this up.

I'm not sure if there is a limit to how long the camera can be made to wait in the shoot hook.
Ok, that explains one thing I noticed. On the A490 when entering rsint mode the led blinks all the time. After around 10 seconds the screen shows "busy" and the text stays until "s" is pressed. The a2300 does not blink the led at first but it starts blinking after the 10 seconds.

Anyway, it works with two cameras. Tested it for around 50 photos in a row without any issues.
I figured out that I can set a custom save folder by changing the command line folder to the desired location before starting interactive mode and rsint.

 

Related Topics