I upload the files you ask here.My version is 100D
http://www.zshare.net/download/880201570256d3e8/
thanks that you take a closer look on the files, i think problem can happen on all camera depend on SD Card and exposure time.
The crash is happening on the 'open' call for the RAW file in raw_savefile.
After re-reading the other posts I suspect this is a timing problem (like at startup) where another task is closing a file just before raw_savefile calls 'open'. Possibly the camera is offloading the save of the JPEG file to another task and if things happen in just the right (or wrong) way then you get the crash. All the fixes you talk about involved changing the timing in some way - including changing SD cards.
Adding sleep calls or moving the call to capt_seq_hook_raw_here may help; but if it's a timing problem you will never know when it will resurface.
I think the solution is the custom / modified version of '_Open' like I posted earlier.
I've created a version of this code from the 1.00d IXUS 1000 firmware.
Add this to boot.c:
int fsionotify_compfail = 0; // count of number of times the file handle was already in the array
int fsionotify_success = 0; // count of number of times the code succeeded
int __attribute__((naked,noinline)) _Open(const char *name, int flags, int mode) {
asm volatile (
"STMFD SP!, {R4-R8,LR} \n"
"MOV R6, R0 \n"
"LDRB R0, [R0] \n"
"MOV R7, R2 \n"
"MOV R4, R1 \n"
"BL sub_FF874504 \n"
"MOV R8, R0 \n"
"MOV R0, #1 \n"
"BIC R5, R0, R4,LSR#12 \n"
"BIC R4, R4, #0x9000 \n"
"MOV R0, R8 \n"
"MOV R1, #1 \n"
"BL sub_FF875894 \n"
"MOV R2, R7 \n"
"MOV R1, R4 \n"
"MOV R0, R6 \n"
"BL _open \n"
"CMP R5, #0 \n"
"MOV R7, R0 \n"
"MOVNE R0, R7 \n"
"MOVNE R2, R4 \n"
"MOVNE R1, R6 \n"
"BLNE sub_FF872470_my \n"
"MOV R0, R8 \n"
"BL sub_FF87590C \n"
"MOV R0, R7 \n"
"LDMFD SP!, {R4-R8,PC} \n"
);
return 0; // stop compiler warning
}
void __attribute__((naked,noinline)) sub_FF872470_my() {
asm volatile (
"STMFD SP!, {R4-R8,LR} \n"
"MOV R5, R0 \n"
"LDR R0, =0x31B8 \n"
"MOV R7, R1 \n"
"LDR R0, [R0,#4] \n"
"MOV R6, R2 \n"
"CMP R0, #0 \n"
"LDMEQFD SP!, {R4-R8,PC} \n"
"CMP R5, #0 \n"
"LDMLTFD SP!, {R4-R8,PC} \n"
"MOV R4, #0 \n"
"LDR R2, =0x38EA8 \n"
"MOV R0, #0 \n"
"loc_FF8724A4: \n"
"ADD R1, R0, R0,LSL#1 \n"
"LDR R1, [R2,R1,LSL#5] \n"
"CMN R1, #1 \n"
"ADDEQ R0, R0, R0,LSL#1 \n"
"ADDEQ R4, R2, R0,LSL#5 \n"
"BEQ loc_FF8724CC\n"
"CMP R1, R5 \n"
"BEQ loc_2 \n" // + // branch if found entry matching new file handle
"ADDNE R0, R0, #1 \n"
"CMPNE R0, #0xA \n"
"BLT loc_FF8724A4 \n"
"loc_FF8724CC: \n"
"CMP R4, #0 \n"
"LDREQ R1, =0x1C9 \n"
"LDREQ R0, =0xFF8723B8 \n" //aFsionotify_c
"BLEQ sub_FF81EB78 \n" //_DebugAssert
"LDR R1, =fsionotify_success \n" // + // increment counter
"LDR R0, [R1] \n" // + // of successful calls
"ADD R0, R0, #1 \n" // +
"STR R0, [R1] \n" // +
"MOV R0, #0 \n" // original code - save handle in array
"STR R0, [R4,#0x58] \n"
"STR R5, [R4] \n"
"MOV R0, R4 \n"
"MOV R1, R7 \n"
"STR R6, [R4,#0x24] \n"
"BL sub_FF872238 \n"
"ADD R1, R4, #0x28 \n"
"MOV R0, R7 \n"
"LDMFD SP!, {R4-R8,LR} \n"
"B sub_FF8381C4 \n"
"loc_2: \n" // + // Handle case when new file handle returned from _open is already in array
"LDR R1, =fsionotify_compfail \n" // + // increment counter then return rather than throw exception
"LDR R0, [R1] \n" // + // equivalent to calling _open rather than _Open
"ADD R0, R0, #1 \n" // +
"STR R0, [R1] \n" // +
"LDMFD SP!, {R4-R8,PC} \n" // +
);
}
Add this to gui.c (at the start of gui_draw_debug_vals_osd):
extern int fsionotify_compfail, fsionotify_success;
sprintf(osd_buf, "%d,%d", fsionotify_compfail,fsionotify_success);
draw_txt_string(34, 14, osd_buf, conf.osd_color);
And comment out the Open stub in stubs_entry_2.s if present.
This will show on screen the number of times the custom _Open code hits the problem (and the number of times it does not).
Phil.