Not sure if it's the right place or not to post a bug report on the A2200 build or I should be starting a new thread but here goes...
I'm trying to use chdkptp (r658) to trigger a shot but it's crashing the camera.
Hi,
the porting thread is a good place for camera-specific bugreports. This specific issue has already been noted (at least I think it is the same issue that you can find in the first post of this thread). If you just want to shoot, try the workaround (1st post).
edit: I think "mode 1" is rec mode, "mode 0" is playback mode, but I can be wrong.
If you'd like to investigate instead, here's what you could do (addresses are from 100b):
- The assert is due to [0x2d24 + 8] not being 0x14. 0x14 seems to be the total number of exmem types. Exmem is a memory allocation system used by the camera for various operations that require a big memory area (playing/shooting movies, compressing stills, etc.). The assert is in the internal allocator routine (sub_FF8853B8, appears to be similar to sub_FF813884 in ixus30 100k), the ixus30 assert text is "m_TopAllocType == MAX_NUM_OF_EXMEMORY_TYPE".
- Try dumping (or observing) that memory area
- in playback and rec mode without using PTP
- in playback mode before connecting PTP
- in playback mode after connecting PTP
- after issuing "rec" in chdkptp
- ...
... and see when (and how) does that piece of memory change
A few notes:
- The assert happens in a task that CHDK does not influence.
- PTP itself allocates a chunk of exmem (usually ~1MB) when a PTP connection is active.
- The a2200 100d CHDK port
places CHDK in exmem area, the 100b port does not (and the error you're getting is not affected by this difference).
- This camera does not officially support an active USB connection while in rec mode, so this scenario is likely not tested by the manufacturer (but it does work on a majority of CHDK cameras).
- Some ports show various strange symptoms which might be the result of some RAM corruption by either the Canon firmware or CHDK.
- You can find lots of function addresses in funcs_by_address.csv files.