CHDK_DE Vorschauversion  Trunk Rev. 5255
 Alle Datenstrukturen Dateien Funktionen Variablen Typdefinitionen Aufzählungen Aufzählungswerte Makrodefinitionen
filewrite.c-Dateireferenz
#include "lolevel.h"
#include "platform.h"
#include "../../../generic/filewrite.c"
+ Include-Abhängigkeitsdiagramm für filewrite.c:

gehe zum Quellcode dieser Datei

Datenstrukturen

struct  cam_ptp_data_chunk
 
struct  fwt_data_struct
 

Makrodefinitionen

#define MAX_CHUNKS_FOR_JPEG   7
 
#define FWT_MUSTSEEK   0x40
 
#define FWT_SEEKMASK   0x40
 

Funktionen

void __attribute__ ((naked, noinline))
 *-------------------------------------------------------------------— Mehr ...
 

Makro-Dokumentation

#define FWT_MUSTSEEK   0x40

Definiert in Zeile 38 der Datei filewrite.c.

#define FWT_SEEKMASK   0x40

Definiert in Zeile 39 der Datei filewrite.c.

#define MAX_CHUNKS_FOR_JPEG   7

Definiert in Zeile 12 der Datei filewrite.c.

Dokumentation der Funktionen

void __attribute__ ( (naked, noinline)  )

*-------------------------------------------------------------------—

!!

IS_ERROR( hSoundHandle )

IS_ERROR( RetCode )

IS_ERROR( RetCode )

IS_ERROR( RetCode )

IS_ERROR( RetCode )

"MOV R3, #0\n" "STR R3, [R9]\n"

TODO! below is from sd400

"MOV R3, #0\n" "STR R3, [R9]\n"

TODO! below is from sd400

__MovieRecorder_c__100

__MovieRecorder_c__100

ASM1989 -> In sx200:FF857190 //"Mounter.c"

ASM1989 -> In sx200:FF81B284 // DebugAssert

Definiert in Zeile 45 der Datei filewrite.c.

45  {
46 asm volatile (
47 " STMFD SP!, {R1-R7,LR} \n"
48 " LDR R5, =0xE53C \n"
49 " MOV R6, #0 \n"
50 
51 "loc_FF3486E4:\n"
52 " LDR R0, [R5, #0x10] \n"
53 " MOV R2, #0 \n"
54 " ADD R1, SP, #8 \n"
55 " BL sub_006B84B8 /*_ReceiveMessageQueue*/ \n"
56 " CMP R0, #0 \n"
57 " LDRNE R2, =0x3F5 \n"
58 " LDRNE R1, =0xFF3488A4 /*'dwFWrite.c'*/ \n"
59 " MOVNE R0, #0 \n"
60 " BLNE _DebugAssert \n"
61 " LDR R0, [SP, #8] \n"
62 " LDR R1, [R0] \n"
63 " CMP R1, #0xD \n"
64 " ADDCC PC, PC, R1, LSL#2 \n"
65 " B loc_FF3486E4 \n"
66 " B loc_FF348870 \n"
67 " B loc_FF348870 \n"
68 " B loc_FF348870 \n"
69 " B loc_FF348870 \n"
70 " B loc_FF348870 \n"
71 " B loc_FF348870 \n"
72 " B loc_FF348870 \n"
73 " B loc_FF348878 \n"
74 " B loc_FF348750 \n"
75 " B loc_FF3487EC \n"
76 " B loc_FF34881C \n"
77 " B loc_FF3487B8 \n"
78 " B loc_FF3487E4 \n"
79 
80 "loc_FF348750:\n"
81 " MOV R4, R5 \n"
82 " STR R6, [SP] \n"
83 
84 "loc_FF348758:\n"
85 " LDR R0, [R4, #0x10] \n"
86 " MOV R1, SP \n"
87 " BL sub_006B8710 /*_GetNumberOfPostedMessages*/ \n"
88 " LDR R0, [SP] \n"
89 " CMP R0, #0 \n"
90 " BEQ loc_FF348784 \n"
91 " LDR R0, [R4, #0x10] \n"
92 " MOV R2, #0 \n"
93 " ADD R1, SP, #4 \n"
94 " BL sub_006B84B8 /*_ReceiveMessageQueue*/ \n"
95 " B loc_FF348758 \n"
96 
97 "loc_FF348784:\n"
98 " LDR R0, [R4, #4] \n"
99 " CMN R0, #1 \n"
100 " BEQ loc_FF3487AC \n"
101 " BL fwt_close \n" // --> Patched. Old value = _Close.
102 " MVN R0, #0 \n"
103 " STR R0, [R4, #4] \n"
104 " LDR R0, =0x125CCC \n"
105 " BL sub_FF010DA8 \n"
106 " MOV R1, #0 \n"
107 " BL sub_FF00EC58 \n"
108 
109 "loc_FF3487AC:\n"
110 " LDR R0, [R4, #0xC] \n"
111 " BL _GiveSemaphore \n"
112 " B loc_FF3486E4 \n"
113 
114 "loc_FF3487B8:\n"
115 " MOV R4, R0 \n"
116 " ADD R0, R0, #0x58 \n"
117 " BL sub_FF010DA8 \n"
118 " MOV R1, #0 \n"
119 " BL sub_FF00EB18 \n"
120 " LDR R0, [R4, #0xC] \n"
121 " BL sub_FF00D9D8 \n"
122 " ADD R0, R4, #0x58 \n"
123 
124 //mod start
125 " LDR R3, =ignore_current_write\n" // !!
126 " LDR R3, [R3]\n"
127 " CMP R3, #0\n"
128 " BNE loc_A\n" // skip creating directory
129 //mod end
130 " BL sub_FF007918 \n"
131 " ADD R0, R4, #0x58 \n"
132 " B loc_FF348850 \n"
133 
134 "loc_FF3487E4:\n"
135 " BL sub_FF3483B8_my \n" // --> Patched. Old value = 0xFF3483B8. Open stage
136 " B loc_FF3486E4 \n"
137 
138 "loc_FF3487EC:\n"
139 " LDR R1, [R0, #4] \n"
140 " MOV R4, R0 \n"
141 " LDR R0, [R5, #4] \n"
142 " MOV R2, #0 \n"
143 " BL fwt_lseek \n" // --> Patched. Old value = _lseek.
144 " CMN R0, #1 \n"
145 " LDREQ R0, =0x9200013 \n"
146 " MOVEQ R1, R4 \n"
147 " STREQ R0, [R4, #0x10] \n"
148 " MOVEQ R0, #7 \n"
149 " BLEQ sub_FF3482F8 \n"
150 " B loc_FF3486E4 \n"
151 
152 "loc_FF34881C:\n"
153 " MOV R4, R0 \n"
154 " LDRSB R0, [R0, #0x58] \n"
155 " CMP R0, #0 \n"
156 " BEQ loc_FF3486E4 \n"
157 " STRB R0, [SP, #4] \n"
158 " ADD R0, R4, #0x58 \n"
159 " STRB R6, [SP, #5] \n"
160 " BL sub_FF010DA8 \n"
161 " MOV R1, #0 \n"
162 " BL sub_FF00EB18 \n"
163 
164 //mod start
165 " LDR R3, =ignore_current_write\n" // !!
166 " LDR R3, [R3]\n"
167 " CMP R3, #0\n"
168 " BNE loc_B\n" // skip flushing the cache
169 //mod end
170 
171 " ADD R0, SP, #4 \n"
172 " BL sub_FF00D9F0 \n"
173 "loc_B:\n"
174 " ADD R0, R4, #0x58 \n"
175 
176 "loc_FF348850:\n"
177 "loc_A:\n"
178 " BL sub_FF010DA8 \n"
179 " LDR R1, [R5, #0x1C] \n"
180 " BL sub_FF00EC58 \n"
181 " LDR R1, [R5, #0x14] \n"
182 " CMP R1, #0 \n"
183 " LDRNE R0, [R4, #0x10] \n"
184 " BLXNE R1 \n"
185 " B loc_FF3486E4 \n"
186 
187 "loc_FF348870:\n"
188 " BL sub_FF348A98_my \n" // --> Patched. Old value = 0xFF348A98. Write stage
189 " B loc_FF3486E4 \n"
190 
191 "loc_FF348878:\n"
192 " BL sub_FF348550_my \n" // --> Patched. Old value = 0xFF348550. Close stage
193 " B loc_FF3486E4 \n"
194 );
195 }