root/platform/ixus1000_sd4500/sub/100d/movie_rec.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. change_video_tables
  2. set_quality
  3. movie_record_task
  4. sub_FF986044_my

   1 #include "conf.h"
   2 #include "lolevel.h"
   3 #include "platform.h"
   4 #include "core.h"
   5 #include "dryos31.h"
   6 
   7 void change_video_tables(int a, int b){
   8 }
   9 
  10 
  11 void  set_quality(int *x){ // -17 highest; +12 lowest
  12  if (conf.video_mode) *x=12-((conf.video_quality-1)*(12+17)/(99-1));
  13 }
  14 
  15 // ASM1989, rereview 19.09.10 FF986650
  16 void __attribute__((naked,noinline)) movie_record_task(){
  17  asm volatile(
  18 "               STMFD   SP!, {R2-R10,LR}\n"
  19 "               LDR     R10, =0x5EE\n" // not in 100F
  20 "               LDR     R9, =0x2710\n"
  21 "               LDR     R7, =0xFF98580C\n" //nullsub_357
  22 
  23 
  24 //looks like it is the one to work with?
  25 //"             LDR     R6, =0xFF986044\n" //__MovieRecorder.c__0 ;     LOCATION: MovieRecorder.c:0
  26 "               LDR     R6, =sub_FF986044_my\n" //__MovieRecorder.c__0 ;        LOCATION: MovieRecorder.c:0
  27 
  28 "               LDR     R4, =0x7898\n" //diferent order in 100F
  29 "               MOV     R8, #1\n"  //diferent order in 100F
  30 "               MOV     R5, #0\n"
  31 "loc_FF986670:\n"
  32 "               LDR     R0, [R4,#0x24]\n"
  33 "               MOV     R2, #0\n"
  34 "               ADD     R1, SP, #0x4\n"
  35 "               BL      sub_FF83AE20\n"  //__KerQueue.c__0 ; LOCATION: KerQueue.c:0
  36 "               LDR     R0, [R4,#0x2C]\n"
  37 "               CMP     R0, #0\n"
  38 "               LDRNE   R0, [R4,#0xC]\n"
  39 "               CMPNE   R0, #2\n"
  40 "               LDRNE   R0, [R4,#0x44]\n"
  41 "               CMPNE   R0, #6\n"
  42 "               BNE     loc_FF986794\n"
  43 "               LDR     R0, [SP,#0x4]\n"
  44 "               LDR     R1, [R0]\n"
  45 "               SUB     R1, R1, #2\n"
  46 "               CMP     R1, #0xA\n"
  47 "               ADDLS   PC, PC, R1,LSL#2\n"
  48 "               B       loc_FF986794\n"
  49 "loc_FF9866B4:\n"
  50 "               B       loc_FF986744\n"
  51 "loc_FF9866B8:\n"
  52 "               B       loc_FF986768\n"
  53 "loc_FF9866BC:\n"
  54 "               B       loc_FF986778\n"
  55 "loc_FF9866C0:\n"
  56 "               B       loc_FF986780\n"
  57 "loc_FF9866C4:\n"
  58 "               B       loc_FF98674C\n"
  59 "loc_FF9866C8:\n"
  60 "               B       loc_FF986788\n"
  61 "loc_FF9866CC:\n"
  62 "               B       loc_FF986758\n"
  63 "loc_FF9866D0:\n"
  64 "               B       loc_FF986794\n"
  65 "loc_FF9866D4:\n"
  66 "               B       loc_FF986790\n"
  67 "loc_FF9866D8:\n"
  68 "               B       loc_FF986710\n"
  69 "loc_FF9866DC:\n"
  70 "               B       loc_FF9866E0\n"
  71 "loc_FF9866E0:\n"
  72 "               STR     R5, [R4,#0x40]\n"
  73 "               STR     R5, [R4,#0x30]\n"
  74 "               STR     R5, [R4,#0x34]\n"
  75 "               STRH    R5, [R4,#6]\n"
  76 "               STR     R6, [R4,#0xCC]\n"
  77 "               STR     R7, [R4,#0xB4]\n"
  78 "               LDR     R0, [R4,#0xC]\n"
  79 "               ADD     R0, R0, #1\n"
  80 "               STR     R0, [R4,#0xC]\n"
  81 "               MOV     R0, #6\n"
  82 "               STR     R0, [R4,#0x44]\n"
  83 "               B       loc_FF986730\n"
  84 "loc_FF986710:\n"
  85 "               STR     R5, [R4,#0x40]\n"
  86 "               STR     R5, [R4,#0x30]\n"
  87 "               STR     R6, [R4,#0xCC]\n"
  88 "               STR     R7, [R4,#0xB4]\n"
  89 "               LDR     R0, [R4,#0xC]\n"
  90 "               ADD     R0, R0, #1\n"
  91 "               STR     R0, [R4,#0xC]\n"
  92 "               STR     R8, [R4,#0x44]\n"
  93 "loc_FF986730:\n"
  94 "               LDR     R2, =0xFF984FE0\n"
  95 "               LDR     R1, =0xB0300\n"
  96 "               LDR     R0, =0xFF9850F4\n"
  97 "               BL      sub_FF853088\n"
  98 "               B       loc_FF986794\n"
  99 "loc_FF986744:\n"
 100   //     "BL      unlock_optical_zoom\n"                  -----------> inserted to unlock the zoom, dont need in sx210
 101 "               BL      sub_FF985D20\n" //__MovieRecorder.c__0
 102 "               B       loc_FF986794\n"
 103 "loc_FF98674C:\n"
 104 "               LDR     R1, [R4,#0xCC]\n"
 105 "               BLX     R1\n"
 106 "               B       loc_FF986794\n"
 107 "loc_FF986758:\n"
 108 "               LDR     R1, [R0,#0x18]\n"
 109 "               LDR     R0, [R0,#4]\n"
 110 "               BL      sub_FFAD9B40\n" //__MovWriter.c__0 ;    LOCATION: MovWriter.c:0
 111 "               B       loc_FF986794\n"
 112 "loc_FF986768:\n"
 113 "               LDR     R0, [R4,#0x44]\n"
 114 "               CMP     R0, #5\n"
 115 "               STRNE   R8, [R4,#0x34]\n"
 116 "               B       loc_FF986794\n"
 117 "loc_FF986778:\n"
 118 "               BL      sub_FF9854B8\n"  //__MovieRecorder.c__1000
 119 "               B       loc_FF986794\n"
 120 "loc_FF986780:\n"
 121 "               BL      sub_FF985140\n"  //__MovieRecorder.c__0
 122 "               B       loc_FF986794\n"
 123 "loc_FF986788:\n"
 124 "               BL      sub_FF984F6C\n"  //__MovieRecorder.c__100
 125 "               B       loc_FF986794\n"
 126 "loc_FF986790:\n"
 127 "               BL      sub_FF986B90\n"  //__MovieRecorder.c__100
 128 "loc_FF986794:\n"
 129 "               LDR     R1, [SP,#0x4]\n"
 130 "               LDR     R3, =0xFF984C34\n"  //aMovierecorder_c  ,changed order in 100D
 131 //"             MOV     R3, #0x5F0\n"  //Not present in 100D
 132 "               STR     R5, [R1]\n"
 133 "               STR     R3, [SP]\n"
 134 "               LDR     R0, [R4,#0x28]\n"
 135 "               MOV     R2, R9\n"
 136 "               BL      sub_FF83B774\n"
 137 "               B       loc_FF986670\n"
 138 
 139  );
 140 }  //asm1989 14.11.10 done
 141 
 142 void __attribute__((naked,noinline)) sub_FF986044_my(){      // in sx200:sub_FF937C70_my
 143  asm volatile(
 144 "               STMFD   SP!, {R4-R11,LR}\n"
 145 "               SUB     SP, SP, #0x64\n"
 146 "               MOV     R8, #0\n"
 147 "               LDR     R7, =0x7898\n"
 148 "               STR     R8, [SP,#0x54]\n"
 149 "               STR     R8, [SP,#0x4C]\n"
 150 "               STR     R8, [R7,#0xB8]\n"
 151 "               STR     R8, [R7,#0xBC]\n"
 152 "               STR     R8, [R7,#0xC0]\n"
 153 "               MOV     R4, R0\n"
 154 "               STR     R8, [R7,#0xC4]\n"
 155 "               LDR     R0, [R7,#0x44]\n"
 156 "               MOV     R9, #0\n"
 157 "               CMP     R0, #3\n"
 158 "               MOVEQ   R0, #4\n"
 159 "               STREQ   R0, [R7,#0x44]\n"
 160 "               LDR     R0, [R7,#0xB4]\n"
 161 "               MOV     R6, #0\n"
 162 "               MOV     R5, #1\n"
 163 "               BLX     R0\n"
 164 "               LDR     R0, [R7,#0x44]\n"
 165 "               CMP     R0, #6\n"
 166 "               BEQ     loc_FF9860B4\n"
 167 //ASM_SAFE("BL blink\n")
 168 "               LDR     R1, [R7,#0xC]\n"
 169 "               CMP     R1, #2\n"
 170 "               BNE     loc_FF9860DC\n"
 171 "               CMP     R0, #5\n"
 172 "               BEQ     loc_FF9860EC\n"
 173 "loc_FF9860B4:\n"
 174 "               MOV     R6, #1\n"
 175 "               ADD     R3, SP, #0x34\n"
 176 "               LDR     R2, =0xFF985F24\n"  //"         ADR     R2, sub_FF985F24\n"
 177 "               LDR     R1, =0xFF985F84\n"
 178 "               LDR     R0, =0xFF985FE4\n"
 179 "               BL      sub_FF853E48\n"
 180 "               LDR     R0, [R7,#0x44]\n"
 181 "               CMP     R0, #4\n"
 182 "               MOVNE   R5, #0\n"
 183 "               B       loc_FF9860FC\n"
 184 "loc_FF9860DC:\n"
 185 "               CMP     R0, #4\n"
 186 "               BEQ     loc_FF9860FC\n"
 187 "               CMP     R1, #2\n"
 188 "               BNE     loc_FF9860F4\n"
 189 "loc_FF9860EC:\n"
 190 "               MOV     R0, #0\n"
 191 "               BL      sub_FF853E54\n"
 192 "loc_FF9860F4:\n"
 193 "               ADD     SP, SP, #0x64\n"
 194 "               LDMFD   SP!, {R4-R11,PC}\n"
 195 "loc_FF9860FC:\n"
 196 "               LDRH    R0, [R7,#6]\n"
 197 "               CMP     R0, #1\n"
 198 "               LDREQ   R1, =0x807\n"  // 100f  809
 199 "               LDREQ   R0, =0xFF984C34\n" //aMovierecorder_c
 200 "               BLEQ    sub_FF81EB78\n" //DebugAssert
 201 "               LDRH    R0, [R7,#6]\n"
 202 "               CMP     R0, #3\n"
 203 "               BNE     loc_FF986130\n"
 204 "               LDR     R0, [R7,#0x6C]\n"
 205 "               LDR     R1, [R7,#0xC8]\n"
 206 "               BL      sub_FFB89AB8\n"
 207 "               CMP     R1, #0\n"
 208 "               MOVNE   R5, #0\n"
 209 "loc_FF986130:\n"
 210 "               LDR     R0, [R7,#0x44]\n"
 211 "               CMP     R0, #6\n"
 212 "               CMPNE   R0, #1\n"
 213 "               CMPNE   R0, #3\n"
 214 "               BNE     loc_FF986174\n"
 215 "               CMP     R6, #1\n"
 216 "               CMPEQ   R5, #0\n"
 217 "               BNE     loc_FF986174\n"
 218 "               BL      sub_FF853E4C\n"
 219 "               LDR     R0, [R7,#0x18]\n"
 220 "               MOV     R1, #0x3E8\n"
 221 "               BL      sub_FF83B23C\n" //TakeSemaphore
 222 "               CMP     R0, #9\n"
 223 "               BNE     loc_FF986584\n"
 224 "               MOV     R0, #0x90000\n"
 225 "               BL      sub_FF89C95C\n" //HardwareDefect
 226 "               B       loc_FF9860F4\n"
 227 "loc_FF986174:\n"
 228 "               CMP     R5, #1\n"
 229 "               MOV     R10, #1\n"
 230 "               BNE     loc_FF98619C\n"
 231 "               ADD     R3, SP, #0x4C\n"
 232 "               ADD     R2, SP, #0x50\n"
 233 "               ADD     R1, SP, #0x54\n"
 234 "               ADD     R0, SP, #0x58\n"
 235 "               BL      sub_FFAD9C68\n"  //__MovWriter.c__0 ;   LOCATION: MovWriter.c:0
 236 "               MOVS    R9, R0\n"
 237 "               BNE     loc_FF9861B8\n"
 238 "loc_FF98619C:\n"
 239 "               LDR     R0, [R7,#0x34]\n"
 240 "               CMP     R0, #1\n"
 241 "               BNE     loc_FF9862F4\n"
 242 "               LDR     R0, [R7,#0x6C]\n"
 243 "               LDR     R1, [R7,#0x48]\n"
 244 "               CMP     R0, R1\n"
 245 "               BCC     loc_FF9862F4\n"
 246 "loc_FF9861B8:\n"
 247 "               MOV     R0, R9\n"
 248 "               BL      sub_FF9859AC\n"
 249 "               LDR     R0, [R7,#0xC]\n"
 250 "               CMP     R0, #2\n"
 251 
 252 //TESTING GOING BACK TO FIRMWARE HERE
 253 //"B sub_FF9861C8\n"
 254 
 255 "               BNE     loc_FF986228\n"
 256 "               MOV     R1, #0\n"
 257 "               LDR     R0, =0xFF985F18\n" //"          ADR     R0, =0xFF985F18\n"
 258 "               BL      sub_FFA8E1B0\n"
 259 "               LDR     R2, [R7,#0x64]\n"
 260 "               ADD     R3, SP, #0x5C\n"
 261 "               STRD    R2, [SP,#0x28]\n"
 262 "               MOV     R2, #0x18\n"
 263 "               ADD     R1, SP, #0x34\n"
 264 "               ADD     R0, SP, #0x10\n"
 265 "               BL      sub_FFB87458\n"
 266 "               LDR     R1, [R7,#0x84]\n"
 267 "               LDR     R2, [R7,#0x88]\n"
 268 //"             MVN     R3, #0xFFFFFFFE\n"  //"         MOVL    R3, 0xFFFFFFFE\n"
 269 "               MVN     R3, #01\n"  //"         MOVL    R3, 0xFFFFFFFE\n"
 270 "               ADD     R0, SP, #0x60\n"
 271 "               STMEA   SP, {R0-R3}\n"
 272 "               LDR     R0, =0xB0348\n"
 273 "               MOV     R3, #0\n"
 274 "               MOV     R2, #0\n"
 275 "               MOV     R1, #0x40\n"
 276 "               BL      sub_FFA8E108\n"
 277 "               B       loc_FF98627C\n"
 278 "loc_FF986220:\n"
 279 "               MOV     R1, #1\n"
 280 "               B       loc_FF986508\n"
 281 "loc_FF986228:\n"
 282 "               BL      loc_FF986C60\n"
 283 "               LDR     R2, [R7,#0x64]\n"
 284 "               ADD     R3, SP, #0x5C\n"
 285 //"             MVN     R1, #0xFFFFFFFE\n"  // "                MOVL    R1, 0xFFFFFFFE\n"
 286 "               MVN     R1, #01\n"  //"         MOVL    R3, 0xFFFFFFFE\n"
 287 "               MOV     R0, #0\n"
 288 "               ADD     R5, SP, #0x1C\n"
 289 "               STMIA   R5, {R0-R3}\n"
 290 "               LDR     R3, [R4,#0x1C]\n"
 291 "               LDR     R1, [R7,#0x84]\n"
 292 "               LDR     R2, [R7,#0x88]\n"
 293 "               ADD     R4, SP, #0xC\n"
 294 "               ADD     R0, SP, #0x60\n"
 295 "               STMIA   R4, {R0-R3}\n"
 296 "               MOV     R3, #0\n"
 297 "               MOV     R1, #0x40\n"
 298 "               MOV     R2, #0\n"
 299 "               STMEA   SP, {R1-R3}\n"
 300 "               LDR     R3, =0xB0348\n"
 301 "               MOV     R1, #0\n"
 302 "               MOV     R0, #0\n"
 303 "               BL      sub_FFA8CBB8\n"
 304 
 305 "loc_FF98627C:\n"
 306 "               LDR     R0, [R7,#0x18]\n"
 307 "               LDR     R1, [R7,#0x60]\n"
 308 "               BL      sub_FF83B23C\n" //TakeSemaphore
 309 "               CMP     R0, #9\n"
 310 "               BEQ     loc_FF986220\n"
 311 "               LDR     R0, [SP,#0x5C]\n"
 312 "               CMP     R0, #0\n"
 313 "               BEQ     loc_FF9862A4\n"
 314 
 315 "loc_FF98629C:\n"
 316 "               MOV     R1, #1\n"
 317 "               B       loc_FF986520\n"
 318 
 319 "loc_FF9862A4:\n"
 320 "               LDR     R0, [R7,#0xC]\n"
 321 "               MOV     R4, #5\n"
 322 "               CMP     R0, #2\n"
 323 "               MOV     R0, #1\n"
 324 "               BNE     loc_FF9862E0\n"
 325 "               BL      sub_FFA8E170\n"
 326 "               BL      sub_FFA8E198\n"
 327 "               MOV     R0, #0\n"
 328 "               BL      sub_FF853E54\n"
 329 "               BL      sub_FF853E64\n"
 330 "               STR     R4, [R7,#0x44]\n"
 331 "               BL      loc_FF986C60\n"
 332 "               BL      sub_FF853EC0\n"
 333 "               STR     R10, [R7,#0x44]\n"
 334 "               B       loc_FF9862EC\n"
 335 "loc_FF9862E0:\n"
 336 "               BL      sub_FFA8CC6C\n"
 337 "               BL      sub_FFA8CCCC\n"
 338 "               STR     R4, [R7,#0x44]\n"
 339 "loc_FF9862EC:\n"
 340 "               STR     R8, [R7,#0x34]\n"
 341 "               B       loc_FF9860F4\n"
 342 "loc_FF9862F4:\n"
 343 "               CMP     R5, #1\n"
 344 "               BNE     loc_FF98657C\n"
 345 "               STR     R10, [R7,#0x38]\n"
 346 "               LDR     R0, [R7,#0x6C]\n"
 347 "               LDR     R11, [R4,#0xC]\n"
 348 "               CMP     R0, #0\n"
 349 "               LDRNE   R9, [SP,#0x58]\n"
 350 "               LDRNE   R10, [SP,#0x54]\n"
 351 "               BNE     loc_FF986440\n"
 352 "               LDR     R0, [R7,#0xC]\n"
 353 "               CMP     R0, #2\n"
 354 "               BNE     loc_FF986398\n"
 355 "               LDR     R0, =0xFF985F18\n"
 356 "               MOV     R1, #0\n"
 357 "               BL      sub_FFA8E1B0\n"
 358 "               LDR     R2, [R7,#0x64]\n"
 359 "               ADD     R3, SP, #0x5C\n"
 360 "               STRD    R2, [SP,#0x28]\n"
 361 "               MOV     R2, #0x18\n"
 362 "               ADD     R1, SP, #0x34\n"
 363 "               ADD     R0, SP, #0x10\n"
 364 "               BL      sub_FFB87458\n"
 365 "               LDR     R1, [R7,#0x84]\n"
 366 "               LDR     R2, [R7,#0x88]\n"
 367 "               MVN     R3, #0\n"  // "         MOVL    R3, 0xFFFFFFFF\n"
 368 "               ADD     R0, SP, #0x60\n"
 369 "               STMEA   SP, {R0-R3}\n"
 370 "               LDR     R0, [SP,#0x58]\n"
 371 "               LDR     R1, [SP,#0x54]\n"
 372 "               LDR     R2, [SP,#0x50]\n"
 373 "               LDR     R3, [SP,#0x4C]\n"
 374 "               BL      sub_FFA8E10C\n"
 375 "               LDR     R0, [R7,#0x18]\n"
 376 "               LDR     R1, [R7,#0x60]\n"
 377 "               BL      sub_FF83B23C\n" //TakeSemaphore
 378 "               CMP     R0, #9\n"
 379 "               BEQ     loc_FF986220\n"
 380 "               LDR     R0, =0xFF9858E8\n"
 381 "               MOV     R1, #0\n"
 382 "               BL      sub_FFA8E1B0\n"
 383 "               B       loc_FF986400\n"
 384 "loc_FF986398:\n"
 385 "               LDR     R0, [R4,#0x20]\n"
 386 "               LDR     R2, [R7,#0x64]\n"
 387 "               ADD     R3, SP, #0x5C\n"
 388 "               MVN     R1, #0\n"  // "         MOVL    R1, 0xFFFFFFFF\n"
 389 "               ADD     R9, SP, #0x1C\n"
 390 "               STMIA   R9, {R0-R3}\n"
 391 "               LDR     R3, [R4,#0x1C]\n"
 392 "               LDR     R1, [R7,#0x84]\n"
 393 "               LDR     R2, [R7,#0x88]\n"
 394 "               ADD     R0, SP, #0x60\n"
 395 "               ADD     R9, SP, #0xC\n"
 396 "               STMIA   R9, {R0-R3}\n"
 397 "               LDR     R1, [SP,#0x50]\n"
 398 "               LDR     R2, [SP,#0x54]\n"
 399 "               LDR     R3, [SP,#0x4C]\n"
 400 "               STMFA   SP, {R1,R3}\n"
 401 "               STR     R2, [SP]\n"
 402 "               LDMIB   R4, {R0,R1}\n"
 403 "               LDR     R3, [SP,#0x58]\n"
 404 "               MOV     R2, R11\n"
 405 "               BL      sub_FFA8CBB8\n"
 406 "               LDR     R0, [R7,#0x18]\n"
 407 "               LDR     R1, [R7,#0x60]\n"
 408 "               BL      sub_FF83B23C\n" //TakeSemaphore
 409 "               CMP     R0, #9\n"
 410 "               BEQ     loc_FF986220\n"
 411 "loc_FF986400:\n"
 412 "               LDR     R0, [SP,#0x5C]\n"
 413 "               CMP     R0, #0\n"
 414 "               BNE     loc_FF98629C\n"
 415 "               LDR     R0, [R7,#0xC]\n"
 416 "               CMP     R0, #2\n"
 417 "               MOV     R0, #1\n"
 418 "               BNE     loc_FF986424\n"
 419 "               BL      sub_FFA8E170\n"
 420 "               B       loc_FF986428\n"
 421 "loc_FF986424:\n"
 422 "               BL      sub_FFA8CC6C\n"
 423 "loc_FF986428:\n"
 424 "               STR     R8, [R7,#0xC4]\n"
 425 "               LDR     R0, [SP,#0x60]\n"
 426 "               LDR     R1, [SP,#0x58]\n"
 427 "               ADD     R9, R1, R0\n"
 428 "               LDR     R1, [SP,#0x54]\n"
 429 "               SUB     R10, R1, R0\n"
 430 "loc_FF986440:\n"
 431 "               LDR     R0, [R7,#0xC]\n"
 432 "               LDR     R2, [R7,#0x64]\n"
 433 "               CMP     R0, #2\n"
 434 "               ADD     R3, SP, #0x5C\n"
 435 "               BNE     loc_FF986498\n"
 436 "               STRD    R2, [SP,#0x28]\n"
 437 "               MOV     R2, #0x18\n"
 438 "               ADD     R1, SP, #0x34\n"
 439 "               ADD     R0, SP, #0x10\n"
 440 "               BL      sub_FFB87458\n"
 441 "               LDR     R1, [R7,#0x84]\n"
 442 "               LDR     R2, [R7,#0x88]\n"
 443 "               LDR     R3, [R7,#0x68]\n"
 444 "               ADD     R0, SP, #0x60\n"
 445 "               STMEA   SP, {R0-R3}\n"
 446 "               LDR     R2, [SP,#0x50]\n"
 447 "               LDR     R3, [SP,#0x4C]\n"
 448 "               MOV     R1, R10\n"
 449 "               MOV     R0, R9\n"
 450 "               BL      sub_FFA8E108\n"
 451 "               BL      sub_FF853E4C\n"
 452 "               B       loc_FF9864F0\n"
 453 "loc_FF986498:\n"
 454 "               LDR     R1, [R7,#0x68]\n"
 455 "               LDR     R0, [R4,#0x20]\n"
 456 "               STR     R1, [SP,#0x20]\n"
 457 "               STR     R0, [SP,#0x1C]\n"
 458 "               STR     R2, [SP,#0x24]\n"
 459 "               STR     R3, [SP,#0x28]\n"
 460 "               LDR     R3, [R4,#0x1C]\n"
 461 "               LDR     R1, [R7,#0x84]\n"
 462 "               LDR     R2, [R7,#0x88]\n"
 463 "               ADD     R0, SP, #0x60\n"
 464 "               STR     R2, [SP,#0x14]\n"
 465 "               LDR     R2, [SP,#0x50]\n"
 466 "               STR     R1, [SP,#0x10]\n"
 467 "               STR     R3, [SP,#0x18]\n"
 468 "               LDR     R3, [SP,#0x4C]\n"
 469 "               STR     R0, [SP,#0xC]\n"
 470 "               STMFA   SP, {R2,R3}\n"
 471 "               STR     R10, [SP]\n"
 472 "               LDMIB   R4, {R0,R1}\n"
 473 "               MOV     R3, R9\n"
 474 "               MOV     R2, R11\n"
 475 "               BL      sub_FFA8CBB8\n"
 476 "loc_FF9864F0:\n"
 477 "               LDR     R0, [R7,#0x18]\n"
 478 "               LDR     R1, [R7,#0x60]\n"
 479 "               BL      sub_FF83B23C\n" //TakeSemaphore
 480 "               CMP     R0, #9\n"
 481 "               BNE     loc_FF986510\n"
 482 "               MOV     R1, #0\n"
 483 "loc_FF986508:\n"
 484 "               MOV     R0, #0x90000\n"
 485 "               B       loc_FF986524\n"
 486 "loc_FF986510:\n"
 487 "               LDR     R0, [SP,#0x5C]\n"
 488 "               CMP     R0, #0\n"
 489 "               BEQ     loc_FF98652C\n"
 490 "               MOV     R1, #0\n"
 491 "loc_FF986520:\n"
 492 "               MOV     R0, #0xA0000\n"
 493 "loc_FF986524:\n"
 494 "               BL      sub_FF985930\n"
 495 "               B       loc_FF9860F4\n"
 496 "loc_FF98652C:\n"
 497 "               LDR     R0, [R7,#0xC]\n"
 498 "               CMP     R0, #2\n"
 499 "               MOV     R0, #0\n"
 500 "               BNE     loc_FF986544\n"
 501 "               BL      sub_FFA8E170\n"
 502 "               B       loc_FF986548\n"
 503 "loc_FF986544:\n"
 504 "               BL      sub_FFA8CC6C\n"
 505 
 506 // I think the patch shoud be here
 507 
 508 "loc_FF986548:\n"
 509 "               LDR     R0, [SP,#0x58]\n"
 510 "               LDR     R1, [SP,#0x60]\n"
 511 "               BL      sub_FFAD9EA0\n"  //__MovWriter.c__0 ;   LOCATION: MovWriter.c:0
 512 "               LDR     R0, [R7,#0x68]\n"
 513 "               LDR     R3, =0x7920\n"          // ---> -
 514 "               ADD     R1, R0, #1\n"           //       |
 515 "               STR     R1, [R7,#0x68]\n"       //       |
 516 "               STR     R3, [SP]\n"                     //       |
 517 "               LDR     R0, [R7,#0x64]\n"       //       |
 518 "               SUB     R3, R3, #4\n"           // ---> -
 519 "               AND     R2, R0, #0xFF\n"        //       |
 520 "               LDR     R0, [SP,#0x60]\n"       //       |
 521 "               BL      sub_FFAD7A98\n"         //       |
 522                                                                 //       |
 523  "LDR     R0, =0x7920-4\n"      // -<---     // +
 524  "BL      set_quality\n"                     // +
 525 
 526 "loc_FF98657C:\n"
 527 "               CMP     R6, #1\n"
 528 "               BNE     loc_FF986590\n"
 529 
 530 "loc_FF986584:\n"
 531 "               BL      sub_FF853E50\n"
 532 "               MOV     R0, #1\n"
 533 "               BL      sub_FF853E54\n"
 534 
 535 "loc_FF986590:\n"
 536 "               CMP     R5, #1\n"
 537 "               LDRNEH  R0, [R7,#6]\n"
 538 "               CMPNE   R0, #3\n"
 539 "               BNE     loc_FF9860F4\n"
 540 "               LDR     R0, [R7,#0x6C]\n"
 541 "               ADD     R0, R0, #1\n"
 542 "               STR     R0, [R7,#0x6C]\n"
 543 "               LDRH    R1, [R7,#6]\n"
 544 "               CMP     R1, #3\n"
 545 "               LDRNE   R1, [R7,#0x54]\n"
 546 "               LDREQ   R1, =0x3E9\n"
 547 "               MUL     R0, R1, R0\n"
 548 "               LDREQ   R1, =0x1770\n"
 549 "               LDRNE   R1, [R7,#0x50]\n"
 550 "               BL      sub_FFB89AB8\n"
 551 "               MOV     R4, R0\n"
 552 "               BL      sub_FFADA554\n"
 553 "               LDR     R0, [R7,#0x8C]\n"
 554 "               CMP     R0, R4\n"
 555 "               BNE     loc_FF9865EC\n"
 556 "               LDR     R0, [R7,#0x3C]\n"
 557 "               CMP     R0, #1\n"
 558 "               BNE     loc_FF986600\n"
 559 "loc_FF9865EC:\n"
 560 "               LDR     R1, [R7,#0x98]\n"
 561 "               MOV     R0, R4\n"
 562 "               BLX     R1\n"
 563 "               STR     R4, [R7,#0x8C]\n"
 564 "               STR     R8, [R7,#0x3C]\n"
 565 "loc_FF986600:\n"
 566 "               STR     R8, [R7,#0x38]\n"
 567 "               B       loc_FF9860F4\n"
 568 
 569 //Other stuff??? was at the end
 570 "loc_FF986C60:\n"
 571 "LDR     R0, =0xB0330\n"
 572 "LDR     R0, [R0,#8]\n"
 573 "CMP     R0, #0\n"
 574 "BEQ     sub_FF984F6C\n" //__MovieRecorder.c__100
 575 "BNE     sub_FF866E24\n"
 576 
 577 
 578 
 579  );
 580 }
 581 
 582 
 583 
 584 
 585 
 586 
 587 
 588 
 589 
 590 
 591 
 592 

/* [<][>][^][v][top][bottom][index][help] */