Crash on lua shoot() - General Discussion and Assistance - CHDK Forum supplierdeeply

Crash on lua shoot()

  • 4 Replies
  • 3829 Views
Crash on lua shoot()
« on: 16 / October / 2011, 14:46:59 »
Advertisements
I'm having trouble issuing the lua shoot() command with ptpcamgui or with the .NET sample code posted in the CHDK PTP Interface thread.  The camera shuts down every time I issue the shoot() command.  All other camera commands seem to work (switching to Record mode, zoom, live view, downloading files).  I'm using a Canon SX130 running rev 1361.

Here are the rom logs of the crash:  https://rapidshare.com/files/1186587333/crash_romlogs.zip

What next steps can I take to resolve this issue?  Has anyone else experienced problems with the lua shoot() command over PTP?

-Sgtrum

Re: Crash on lua shoot()
« Reply #1 on: 16 / October / 2011, 15:29:47 »
What next steps can I take to resolve this issue?  Has anyone else experienced problems with the lua shoot() command over PTP?
Works fine for me on both my cameras ( G10 & SD940 ).   I seem to recall that I needed to be in "Record" mode when I issue the command though ?
Ported :   A1200    SD940   G10    Powershot N    G16

Re: Crash on lua shoot()
« Reply #2 on: 16 / October / 2011, 17:03:37 »
I did indeed set the camera in record mode (lens opened when command was issued).  What is strange is that running the lua shoot script on the camera itself works.  It's only when the command is issued via PTP does the camera crash.

Re: Crash on lua shoot()
« Reply #3 on: 16 / October / 2011, 22:07:10 »
I just discovered that if I enter Record mode, switch to Playback mode and then switch back to Record mode the shoot() command works.  Is this a bug in the PTP Record mode command (something not being set and requires Playback mode to be set first)?


*

Offline reyalp

  • ******
  • 14111
Re: Crash on lua shoot()
« Reply #4 on: 18 / October / 2011, 23:18:11 »
I just discovered that if I enter Record mode, switch to Playback mode and then switch back to Record mode the shoot() command works.
Good observation. You might try sending the levent mentioned here http://chdk.setepontos.com/index.php?topic=4338.msg63795#msg63795 and see if that helps.
Quote
  Is this a bug in the PTP Record mode command (something not being set and requires Playback mode to be set first)?
It could be a bug, or it could be that what CHDK normally does is "correctly" implemented but doesn't have the desired effect on that camera. Mode switching under PTP is seriously hacky even by CHDK standards (we call some random functions where the firmware probably never expected them to be called), so this kind of thing is not unexpected.
Don't forget what the H stands for.

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal