Okay, so I've tested it again, without flash and it crashed again..
Thanks.
Next try, with delay increased to 300 and trusting the sigfinder on zoom_status and recreview_hold.
If the CHDK overlay has problems using this build (disappears when it should not), let me know.
Still crashing..
ASSERT!! AFScanDriver.c Line 1228
Occured Time 2019:08:24 13:29:05
Task ID: 25362485
Task name: AFTask
SP: 0x0035BDE0
StackDump:
0x00000000
0xFF8DE8F4
0x000004CC
0x00089034
0x00008000
0x00000000
0xFF970D84
0x00000400
0x00000000
0x00000001
0x19980218
0xFF8DED04
0x00089938
0xFF8E53C0
0x00036060
0x00000001
0x00001F5C
0x0000014B
0x19980218
0x19980218
0x19980218
0xFF84A59C
0x00036020
0xFF84A534
0x00036060
0x003336C8
0x19980218
0x19980218
0x19980218
0xFF816AEC
0x19980218
0x19980218
0x00001008
ShootConDump:
0c 0b 00 00 01 02 07 08 09 0a
CameraConDump:
01 0a 02 0d 09 01 10 0a 02 0d
00056300: UI:ScreenLock
00056340: SS:NextAvail(7),ReviewAvail(4)
00056350: UI:PB.DrawI
00056350: UI:_EnableReviewHold:IsPressSwTwo:0
00056350: UI:_EnableReviewHold:IsAvailableShots:1
00056660: UI:LogicalEvent:0x3203:adr:0,Para:0
00056660: UI:PB.IHist
00056670: UI:PB.DcdCBR
00056670: UI:PB.RfrsI
00056690: UI:ScreenUnLock
00056710: UI:DispSwCon_MuteOffPhysicalScreen
00056710: UI:MuteOffPhysicalScreen
00057150: UI:DSIC:48,0
00058350: UI:LogicalEvent:0x311e:adr:0,Para:0
00058350: UI:_EntryPrepareRecreviewOff
00058350: UI:ShootState:0xB
00058350: UI:ShtCon_StopReview
00058350: UI:StopRecReviewController
00058350: UI:PB.StopR
00058350: UI:DispSwCon_MuteOnPhysicalScreen
00058350: UI:MuteOnPhysicalScreen
00058350: UI:ScreenLock
00058360: UI:ScreenUnLock
00058370: UI:LogicalEvent:0x3120:adr:0,Para:0
00058370: UI:ScreenLock
00058370: UI:ScreenUnLock
00058380: UI:_ExitSequence
00058380: UI:Sht_CancelStrobeChargeTimer
00058380: UI:DSIC:4c,0
00058380: UI:_ExitActionReview
00058380: SS:CancelPre
00058440: UI:ScreenLock
00058440: UI:ScreenUnLock
00059190: UI:DispSwCon_MuteOffPhysicalScreen
00059190: UI:MuteOffPhysicalScreen
00059190: UI:ShootState:0x0
00059190: UI:ShtCon_Deactivate
00059190: UI:ChangePopupStrobe:Open
00059200: SS:StrbModChg
00059210: UI:Strobe:Open
00059210: UI:DSIC:14,0
00059210: UI:DSIC:60,0
00059210: UI:DispSwCon_TurnOnDisplayDevice
00059210: UI:ScreenLock
00059220: UI:DSIC:c5,262144
00059330: UI:Display_CaptInfo
00059380: UI:ScreenUnLock
00059400: UI:DispSw: Unlock
00059400: UI:DispSwCon:Unlock
00059400: UI:TerminateDeliverToZoomController
00059410: UI:OPTICAL_ZOOM_POS
00059410: UI:UnpressZoomLever
00059410: UI:_EntryIdleShoot
00059410: UI:ShootState:0x0
00059970: UI:ScreenLock
00059970: UI:ScreenUnLock
00060090: UI:ScreenLock
00060090: UI:ScreenUnLock
00060300: SS:ChargeComplete
00064740: SS:OptAt=0 0
00064770: UI:ScreenLock
00064770: UI:ScreenUnLock
00064860: UI:ScreenLock
00064860: UI:ScreenUnLock
00067050: UI:ScreenLock
00067050: UI:ScreenUnLock
00067210: UI:Button:0x000009A1:PressSwOne
00067210: SS:PreBuf
00067210: UI:ShootState:0x1
00067210: UI:ShtCon_Activate
00067210: UI:DispSw: Lock
00067210: UI:ShtCon_PrepareCapture
00067210: UI:DSIC:61,0
00067210: UI:ScreenLock
00067220: UI:DSIC:e,0
00067220: UI:ScreenUnLock
00067230: UI:ScreenLock
00067230: UI:ScreenUnLock
00067230: UI:LogicalEvent:0x3135:adr:0,Para:0
00067230: UI:DSIC:e,0
00067230: SS:LoadTest:10
00067230: SS:PreCapt
00067230: UI:ShootState:0x2
00067240: UI:ClearEventComp
00067240: UI:ScreenLock
00067240: UI:ScreenUnLock
\00\00\00
Edit:
But it seems to be better, it crashes after I've run the script 3-5 times.
I tested it without the "click 'shoot_half'" and without flash.
Edit²:
Sometimes (more frequently with bad light and max zoom) it seems that the shoot is triggered before the AF process finished.
Maybe this has something to do with this crash?
Edit³:
Because with the flash activated it seems to be taking the AF process "more serious" and it waits till it really focused the given object. And with flash enabled the camera didn't crash yet.
Edit⁴:
Maybe also good to know is, that the crash happens, when the set_zoom(0) finished (from the previous run, the set_zoom(125) was still set) and it is about to take the photo; but it doesn't seems like the AF process aka half shot already happened; it's about to begin I guess.
In the previous build the crash happened when the set_zoom(125) was finished and the camera was about to take the photo (AF seemed mostly done)
BUT maybe this is because of the different lightning now, than at noon (now its 00:21)