root/platform/ixus30_sd200/sub/100k/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_FF936920_my
  5. sub_FF9382AC_my
  6. sub_FF93727C_my
  7. sub_FF936AC4_my
  8. sub_FF936570_my
  9. sub_FF9375B8_my

   1 
   2 
   3 #include "conf.h"
   4 
   5 int *video_quality = &conf.video_quality;
   6 int *video_mode    = &conf.video_mode;
   7 
   8 //long def_table1[56]={
   9 //0x10000,0xC000,0x5800, 0x2000, 0x1C6A, 0x1550,0x9C5,  0x38D,  0x3C45, 0x2D34, 0x14B8, 0x788,  0x5F60, 0x4788,
  10 //0x20C9, 0xBE1, 0x8661, 0x64C9, 0x2E31, 0x10CB,0xB21A, 0x8594, 0x3D39, 0x1642, 0xE249, 0xA9B8, 0x4DC9, 0x1C48,
  11 //0x117D2,0xD1DF,0x6030, 0x22F9, 0x153D5,0xFEE1,0x74D1, 0x2A79, 0x195F8,0x1307C,0x8B8D, 0x32AA, 0x1E01C,0x16817,
  12 //0xA509, 0x3C01,0x2328E,0x1A5ED,0xC160, 0x4637,0x28C99,0x1E975,0xE054, 0x5190, 0x2F08B,0x2346B,0x102AF,0x5E0E
  13 //};
  14 
  15 //long def_table2[12]={0xE666,0xACCD,0x4F33,0x1CCD,-0x170A,-0x1148,-0x7EB,-0x2E1,-0x2BC6,-0x20D5,-0xF0C,-0x579};
  16 
  17 //long table1[56], table2[12];
  18 
  19 void change_video_tables(int a, int b){
  20 // int i;
  21 // for (i=0;i<56;i++) table1[i]=(def_table1[i]*a)/b;
  22 // for (i=0;i<12;i++) table2[i]=(def_table2[i]*a)/b;
  23 }
  24 
  25 //long CompressionRateTable[]={0x60, 0x5D, 0x5A, 0x57, 0x54, 0x51, 0x4D, 0x48, 0x42, 0x3B, 0x32, 0x29, 0x22, 0x1D, 0x17, 0x14, 0x10, 0xE, 0xB, 9, 7, 6, 5, 4, 3, 2, 1};
  26 
  27 void __attribute__((naked,noinline)) set_quality(int *x){ // 0 highest; +14 lowest
  28  asm volatile("STMFD   SP!, {R0-R12,LR}\n");
  29  if (conf.video_mode) *x=14*(98-(conf.video_quality-1))/98;
  30  asm volatile("LDMFD   SP!, {R0-R12,PC}\n");
  31 }
  32 
  33 void __attribute__((naked,noinline)) movie_record_task(){
  34  asm volatile(
  35 "                STMFD   SP!, {R4,LR}\n"
  36 "                SUB     SP, SP, #4\n"
  37 "                MOV     R4, SP\n"
  38 "                B       loc_FF9362DC\n"
  39 "loc_FF936244:\n"
  40 "                LDR     R3, =0x67070\n"
  41 "                LDR     R2, [R3]\n"
  42 "                CMP     R2, #0\n"
  43 "                BNE     loc_FF9362C8\n"
  44 "                LDR     R3, [R0]\n"
  45 "                SUB     R3, R3, #1\n"
  46 "                CMP     R3, #7\n"
  47 "                LDRLS   PC, [PC,R3,LSL#2]\n"
  48 "                B       loc_FF9362C8\n"
  49 "                .long loc_FF936288\n"
  50 "                .long loc_FF936290\n"
  51 "                .long loc_FF9362A8\n"
  52 "                .long loc_FF936298\n"
  53 "                .long loc_FF9362B0\n"
  54 "                .long loc_FF9362A0\n"
  55 "                .long loc_FF9362C0\n"
  56 "                .long loc_FF9362B8\n"
  57 "loc_FF936288:\n"
  58 "                BL      sub_FF936358\n"
  59 "                B       loc_FF9362C4\n"
  60 "loc_FF936290:\n"
  61 // there's no unsetzoomformovie function in the firmware...
  62 //"                BL      unlock_optical_zoom\n" //just experimenting...
  63 "                BL      sub_FF936570_my\n" // -> to movie time limit override
  64 "                B       loc_FF9362C4\n"
  65 "loc_FF936298:\n"
  66 "                BL      sub_FF936920_my\n" // ->
  67 "                B       loc_FF9362C4\n"
  68 "loc_FF9362A0:\n"
  69 "                BL      sub_FF936CCC\n"
  70 "                B       loc_FF9362C4\n"
  71 "loc_FF9362A8:\n"
  72 "                BL      sub_FF936B74\n"
  73 "                B       loc_FF9362C4\n"
  74 "loc_FF9362B0:\n"
  75 "                BL      sub_FF936D84\n"
  76 "                B       loc_FF9362C4\n"
  77 "loc_FF9362B8:\n"
  78 "                BL      sub_FF936E20\n"
  79 "                B       loc_FF9362C4\n"
  80 "loc_FF9362C0:\n"
  81 "                BL      sub_FF936BC4\n"
  82 "loc_FF9362C4:\n"
  83 "                LDR     R1, [SP]\n"
  84 "loc_FF9362C8:\n"
  85 "                LDR     R3, =0x66FF4\n"
  86 "                MOV     R2, #0\n"
  87 "                STR     R2, [R1]\n"
  88 "                LDR     R0, [R3]\n"
  89 "                BL      sub_FF822738\n" //PostMessageQueue?
  90 "loc_FF9362DC:\n"
  91 "                LDR     R3, =0x66FF0\n"
  92 "                MOV     R1, R4\n"
  93 "                LDR     R0, [R3]\n"
  94 "                MOV     R2, #0\n"
  95 "                BL      sub_FF822320\n"
  96 "                LDR     R0, [SP]\n"
  97 "                CMP     R0, #0\n"
  98 "                MOV     R1, R0\n"
  99 "                BNE     loc_FF936244\n"
 100 "                LDR     R3, =0x66FEC\n"
 101 "                LDR     R0, [R3]\n"
 102 "                BL      sub_FF823144\n" //GiveSemaphore [0x66fec]
 103 "                BL      sub_FF823B44\n" //ExitTask
 104 "                ADD     SP, SP, #4\n"
 105 "                LDMFD   SP!, {R4,PC}\n"
 106  );
 107 }
 108 
 109 void __attribute__((naked,noinline)) sub_FF936920_my(){
 110  asm volatile(
 111 "                STMFD   SP!, {R4-R7,LR}\n"
 112 "                LDR     R4, =0x67088\n"
 113 "                SUB     SP, SP, #0x10\n"
 114 "                LDR     R3, [R4]\n"
 115 "                CMP     R3, #3\n"
 116 "                MOV     R5, R0\n"
 117 "                MOVEQ   R3, #4\n"
 118 "                STREQ   R3, [R4]\n"
 119 "                LDR     R3, =0x67108\n"
 120 "                MOV     LR, PC\n"
 121 "                LDR     PC, [R3]\n"
 122 "                LDR     R2, [R4]\n"
 123 "                CMP     R2, #4\n"
 124 "                BNE     loc_FF936A84\n"
 125 "                ADD     R0, SP, #0x24-0x18\n"
 126 "                BL      sub_FF9382AC_my\n" // ->
 127 "                CMP     R0, #0\n"
 128 "                BNE     loc_FF936990\n"
 129 "                LDR     R3, =0x67078\n"
 130 "                LDR     R2, [R3]\n"
 131 "                CMP     R2, #1\n"
 132 "                BNE     loc_FF9369AC\n"
 133 "                LDR     R2, =0x670B0\n"
 134 "                LDR     R1, =0x6708C\n"
 135 "                LDR     R12, [R2]\n"
 136 "                LDR     R3, [R1]\n"
 137 "                CMP     R12, R3\n"
 138 "                BCC     loc_FF9369AC\n"
 139 "loc_FF936990:\n"
 140 "                BL      sub_FF936AC4_my\n" // -> check sub_FF9382AC_my's return status & others (size limit for example)
 141 "                LDR     R3, =0x67104\n"
 142 "                LDR     R0, [R3]\n"
 143 "                BL      sub_FFA44760\n"
 144 "                MOV     R3, #5\n"
 145 "                STR     R3, [R4]\n"
 146 "                B       loc_FF936A84\n"
 147 "loc_FF9369AC:\n"
 148 "                LDR     R6, =0x670B8\n"
 149 "                LDR     R7, =0x6707C\n"
 150 "                LDR     R0, [R5,#4]\n"
 151 "                LDR     R1, [SP,#0x24-0x18]\n"
 152 "                ADD     R12, SP, #0x24-0x20\n"
 153 "                ADD     R3, SP, #0x24-0x1C\n"
 154 "                LDR     R2, [R6]\n"
 155 "                MOV     R4, #1\n"
 156 "                STR     R12, [SP,#0x24-0x24]\n"
 157 "                STR     R4, [R7]\n"
 158 "                BL      sub_FF8A03D8\n" //recording dies quickly when commented out
 159 "                LDR     R3, =0x66FEC\n"
 160 "                MOV     R1, #0x3E8\n" //1000 decimal -> timeout value
 161 "                LDR     R0, [R3]\n" //semaphore (id,...)
 162 "                BL      sub_FF822F5C\n" //TakeSemaphore [0x66fec], 1000
 163 "                CMP     R0, #9\n"
 164 "                BNE     loc_FF936A00\n" //not a timeout?
 165 "                BL      sub_FF9388E8\n"
 166 "                LDR     R3, =0x67088\n"
 167 "                LDR     R0, =0xFF936908\n" //Jpegtimeout
 168 "                B       loc_FF936A18\n"
 169 "loc_FF936A00:\n"
 170 "                LDR     R5, [SP,#0x24-0x20]\n"
 171 "                CMP     R5, #0\n"
 172 "                BEQ     loc_FF936A24\n"
 173 "                BL      sub_FF9388E8\n"
 174 "                LDR     R3, =0x67088\n"
 175 "                LDR     R0, =0xFF936914\n" //Jpegicerror
 176 "loc_FF936A18:\n"
 177 "                STR     R4, [R3]\n"
 178 "                BL      sub_FF94F7E8\n"
 179 "                B       loc_FF936A84\n"
 180 "loc_FF936A24:\n"
 181 "                BL      sub_FF8A0434\n"
 182 "                LDR     R0, [SP,#0x24-0x18]\n"
 183 "                LDR     R1, [SP,#0x24-0x1C]\n"
 184 "                BL      sub_FF938670\n"
 185 "                LDR     R4, =0x670B0\n"
 186 "                LDR     R3, [R4]\n"
 187 "                ADD     R3, R3, #1\n"
 188 "                LDR     R0, [SP,#0x24-0x1C]\n"
 189 "                MOV     R1, R6\n"
 190 "                STR     R3, [R4]\n"
 191 "                MOV     R2, R5\n"
 192 "                BL      sub_FF93727C_my\n" // ->
 193 "                LDR     R3, =0x67098\n"
 194 "                LDR     R4, [R4]\n"
 195 "                LDR     R1, [R3]\n"
 196 "                MOV     R0, R4\n"
 197 "                BL      sub_FFAB8184\n"
 198 "                CMP     R0, #0\n"
 199 "                BNE     loc_FF936A80\n"
 200 "                MOV     R0, R4\n"
 201 "                LDR     R3, =0x670E0\n"
 202 "                MOV     LR, PC\n"
 203 "                LDR     PC, [R3]\n"
 204 "loc_FF936A80:\n"
 205 "                STR     R5, [R7]\n"
 206 "loc_FF936A84:\n"
 207 "                ADD     SP, SP, #0x10\n"
 208 "                LDMFD   SP!, {R4-R7,PC}\n"
 209  );
 210 }
 211 
 212 void __attribute__((naked,noinline)) sub_FF9382AC_my(){
 213  asm volatile(
 214 "                STMFD   SP!, {R4-R11,LR}\n"
 215 "                LDR     R12, =0x673B4\n"
 216 "                LDR     R3, =0x673CC\n"
 217 "                SUB     SP, SP, #4\n"
 218 "                LDR     R2, [R12]\n"
 219 "                LDR     R1, [R3]\n"
 220 "                ADD     R7, R2, #1\n"
 221 "                LDR     R3, =0x67444\n"
 222 "                CMP     R7, R1\n"
 223 "                STR     R7, [R12]\n"
 224 "                MOV     R9, R0\n"
 225 "                LDR     R11, [R3]\n"
 226 "                MOVHI   R3, #0\n"
 227 "                STRHI   R3, [R9]\n"
 228 "                MOVHI   R0, #0x80000001\n"
 229 "                BHI     loc_FF9385E4\n"
 230 "                LDR     R3, =0x67428\n"
 231 "                LDR     R4, [R3]\n"
 232 "                MOV     R0, R7\n"
 233 "                MOV     R1, R4\n"
 234 "                BL      sub_FFAB8184\n"
 235 "                CMP     R0, #1\n"
 236 "                BNE     loc_FF9384A8\n"
 237 "                LDR     R1, =0x67454\n"
 238 "                LDR     R3, =0x67448\n"
 239 "                LDR     R2, [R1]\n"
 240 "                LDR     R1, =0x673A0\n"
 241 "                LDR     R8, [R3]\n"
 242 "                LDR     R5, [R1]\n"
 243 "                ADD     R2, R8, R2\n"
 244 "                CMP     R2, R5\n"
 245 "                BNE     loc_FF93834C\n"
 246 "                MOV     R1, R4\n"
 247 "                MOV     R0, R7\n"
 248 "                BL      sub_FFAB7AF4\n"
 249 "                LDR     R4, =0x673A8\n"
 250 "                ADD     R0, R0, #1\n"
 251 "                AND     R0, R0, #1\n"
 252 "                STR     R8, [R4,R0,LSL#2]\n"
 253 "                B       loc_FF938368\n"
 254 "loc_FF93834C:\n"
 255 "                MOV     R1, R4\n"
 256 "                MOV     R0, R7\n"
 257 "                BL      sub_FFAB7AF4\n"
 258 "                LDR     R4, =0x673A8\n"
 259 "                ADD     R0, R0, #1\n"
 260 "                AND     R0, R0, #1\n"
 261 "                STR     R5, [R4,R0,LSL#2]\n"
 262 "loc_FF938368:\n"
 263 "                LDR     R3, =0x673B4\n"
 264 "                LDR     R2, =0x67428\n"
 265 "                LDR     R0, [R3]\n"
 266 "                LDR     R1, [R2]\n"
 267 "                BL      sub_FFAB7AF4\n"
 268 "                LDR     R3, =0x673E8\n"
 269 "                ADD     R0, R0, #1\n"
 270 "                AND     R0, R0, #1\n"
 271 "                LDR     R1, =0x67448\n"
 272 "                LDR     R12, =0x67454\n"
 273 "                LDR     LR, [R4,R0,LSL#2]\n"
 274 "                LDR     R2, [R3]\n"
 275 "                LDR     R0, [R1]\n"
 276 "                LDR     R3, [R12]\n"
 277 "                ADD     R1, LR, R2\n"
 278 "                ADD     R2, R1, #8\n"
 279 "                ADD     LR, R0, R3\n"
 280 "                CMP     R2, LR\n"
 281 "                BLS     loc_FF9383CC\n"
 282 "                ADD     R3, R0, R1\n"
 283 "                RSB     R3, LR, R3\n"
 284 "                LDR     R2, =0x673A0\n"
 285 "                ADD     R3, R3, #8\n"
 286 "                STR     R3, [R2]\n"
 287 "                B       loc_FF9383D4\n"
 288 "loc_FF9383CC:\n"
 289 "                LDR     R3, =0x673A0\n"
 290 "                STR     R2, [R3]\n"
 291 "loc_FF9383D4:\n"
 292 "                LDR     R3, =0x673E8\n"
 293 "                LDR     R0, =0x67400\n"
 294 "                LDR     R2, [R3]\n"
 295 "                LDR     R3, [R0,#4]\n"
 296 "                ADD     R2, R2, #0x18\n"
 297 "                MOV     R1, R2\n"
 298 "                MOV     R2, #0\n"
 299 "                CMP     R2, R3\n"
 300 "                BHI     loc_FF938564\n"
 301 "                BNE     loc_FF938408\n"
 302 "                LDR     R3, [R0]\n"
 303 "                CMP     R1, R3\n"
 304 "                BHI     loc_FF938564\n"
 305 "loc_FF938408:\n"
 306 "                LDR     R3, =0x673E8\n"
 307 "                LDR     R10, =0x67400\n"
 308 "                LDR     R3, [R3]\n"
 309 "                LDMIA   R10, {R1,R2}\n"
 310 "                STR     R3, [SP]\n"
 311 "                LDR     R0, =0x673B4\n"
 312 "                LDR     R12, =0x67428\n"
 313 "                SUBS    R5, R1, R3\n"
 314 "                SBC     R6, R2, #0\n"
 315 "                LDR     R8, [R12]\n"
 316 "                MVN     R4, #0\n"
 317 "                MVN     R3, #0x17\n"
 318 "                LDR     R7, [R0]\n"
 319 "                ADDS    R5, R5, R3\n"
 320 "                ADC     R6, R6, R4\n"
 321 "                SUB     R0, R7, #1\n"
 322 "                MOV     R1, R8\n"
 323 "                STMIA   R10, {R5,R6}\n"
 324 "                BL      sub_FFAB7AF4\n"
 325 "                CMP     R7, #1\n"
 326 "                MLA     R0, R8, R0, R0\n"
 327 "                BEQ     loc_FF9384A8\n"
 328 "                SUB     R3, R0, #1\n"
 329 "                MOV     R3, R3,LSL#4\n"
 330 "                ADD     R4, R11, #0x10\n"
 331 "                ADD     R5, R11, #0x14\n"
 332 "                LDR     R1, [R5,R3]\n"
 333 "                LDR     R2, [R4,R3]\n"
 334 "                LDR     LR, =0x62773130\n"
 335 "                ADD     R2, R2, R1\n"
 336 "                MOV     R3, R0,LSL#4\n"
 337 "                ADD     R2, R2, #8\n"
 338 "                ADD     R12, R11, #0xC\n"
 339 "                ADD     R1, R11, #8\n"
 340 "                MOV     R0, #0\n"
 341 "                STR     LR, [R1,R3]\n"
 342 "                STR     R0, [R12,R3]\n"
 343 "                STR     R2, [R4,R3]\n"
 344 "                LDR     R2, [SP]\n"
 345 "                STR     R2, [R5,R3]\n"
 346 "loc_FF9384A8:\n"
 347 "                LDR     R1, =0x673A0\n"
 348 "                LDR     R3, =0x6739C\n"
 349 "                LDR     R2, [R1]\n"
 350 "                LDR     R1, [R3]\n"
 351 "                ADD     R2, R2, #8\n"
 352 "                CMP     R2, R1\n"
 353 "                STR     R2, [R9]\n"
 354 "                BHI     loc_FF9384E0\n"
 355 "                LDR     LR, =0x673F8\n"
 356 "                LDR     R3, [LR]\n"
 357 "                ADD     R3, R2, R3\n"
 358 "                CMP     R1, R3\n"
 359 "                BHI     loc_FF9384E4\n"
 360 "                B       loc_FF938524\n"
 361 "loc_FF9384E0:\n"
 362 "                LDR     LR, =0x673F8\n"
 363 "loc_FF9384E4:\n"
 364 "                LDR     R3, =0x67448\n"
 365 "                LDR     R2, =0x67454\n"
 366 "                LDR     R12, [R3]\n"
 367 "                LDR     R0, [R2]\n"
 368 "                LDR     R1, [R9]\n"
 369 "                LDR     R3, [LR]\n"
 370 "                ADD     R2, R1, R3\n"
 371 "                ADD     R1, R12, R0\n"
 372 "                CMP     R2, R1\n"
 373 "                BLS     loc_FF938534\n"
 374 "                LDR     R3, =0x6739C\n"
 375 "                RSB     R2, R1, R2\n"
 376 "                LDR     R1, [R3]\n"
 377 "                ADD     R2, R12, R2\n"
 378 "                CMP     R1, R2\n"
 379 "                BHI     loc_FF938534\n"
 380 "loc_FF938524:\n"
 381 "                MOV     R3, #0\n"
 382 "                STR     R3, [R9]\n"
 383 "                MOV     R0, #0x80000003\n"
 384 "                B       loc_FF9385E4\n"
 385 "loc_FF938534:\n"
 386 "                LDR     R3, [LR]\n"
 387 "                LDR     R12, =0x67400\n"
 388 "                ADD     R3, R3, #0x18\n"
 389 "                LDR     R2, [R12,#4]\n"
 390 "                MOV     R0, R3\n"
 391 "                MOV     R1, #0\n"
 392 "                CMP     R1, R2\n"
 393 "                BHI     loc_FF938564\n"
 394 "                BNE     loc_FF938574\n"
 395 "                LDR     R3, [R12]\n"
 396 "                CMP     R0, R3\n"
 397 "                BLS     loc_FF938574\n"
 398 "loc_FF938564:\n"
 399 "                MOV     R3, #0\n"
 400 "                STR     R3, [R9]\n"
 401 "                MOV     R0, #0x80000005\n"
 402 "                B       loc_FF9385E4\n"
 403 "loc_FF938574:\n"
 404 "                LDR     R1, =0x673E0\n"
 405 "                LDR     R0, =0x67428\n"
 406 "                LDR     R3, [R1]\n"
 407 "                LDR     R2, [R0]\n"
 408 "                ADD     R3, R3, R2,LSL#4\n"
 409 "                ADD     R3, R3, R3,LSL#2\n"
 410 "                LDR     R12, =0x67400\n"
 411 "                MOV     R3, R3,LSL#1\n"
 412 "                ADD     R3, R3, #0xA0\n"
 413 "                LDR     R2, [R12,#4]\n"
 414 "                MOV     R0, R3\n"
 415 "                MOV     R1, #0\n"
 416 "                CMP     R1, R2\n"
 417 "                BHI     loc_FF9385BC\n"
 418 "                BNE     loc_FF9385E0\n"
 419 "                LDR     R3, [R12]\n"
 420 "                CMP     R0, R3\n"
 421 "                BLS     loc_FF9385E0\n"
 422 "loc_FF9385BC:\n"
 423 "                LDR     R4, =0x67410\n"
 424 "                LDR     R1, [R4]\n"
 425 "                CMP     R1, #0\n"
 426 "                BNE     loc_FF9385E0\n"
 427 "                MOV     R0, #0x3140\n"
 428 "                ADD     R0, R0, #8\n"
 429 "                BL      sub_FF953894\n"
 430 "                MOV     R3, #1\n"
 431 "                STR     R3, [R4]\n"
 432 "loc_FF9385E0:\n"
 433 "                MOV     R0, #0\n"
 434 "loc_FF9385E4:\n"
 435 "                ADD     SP, SP, #4\n"
 436 "                LDMFD   SP!, {R4-R11,PC}\n"
 437  );
 438 }
 439 
 440 
 441 void __attribute__((naked,noinline)) sub_FF93727C_my(){ //this function doesn't return a value and is only referenced once
 442 /*
 443 [0x67120]: seems to specify which table (compression quality?) to use, 0(best)..14
 444 */
 445  asm volatile(
 446 "                STMFD   SP!, {R4-R7,LR}\n"
 447 "                LDR     R12, =0x67118\n"
 448 "                LDR     LR, [R12]\n" //[0x67118] -> lr
 449 "                CMP     LR, #0\n" 
 450 "                MOV     R5, R0\n" //param 0 -> r5 (caller passes a local variable here)
 451 "                MOV     R6, R1\n" //param 1 -> r6 (caller sets this to 0x670b8)
 452 "                BEQ     loc_FF9372AC\n" //if([0x67118]=0) then jump
 453 "                LDR     R1, =0x67124\n"
 454 "                LDR     R3, [R1]\n"
 455 "                CMP     R3, #1\n"
 456 "                BNE     loc_FF9372C4\n" //if([0x67124]!=1) then jump
 457 "                B       loc_FF9372B0\n"
 458 "loc_FF9372AC:\n"
 459 "                LDR     R1, =0x67124\n"
 460 "loc_FF9372B0:\n"
 461 "                MOV     R3, #0\n"
 462 "                STR     R3, [R1]\n" //0 -> [0x67124]
 463 "                LDR     R7, =0x67120\n"
 464 "                STR     R5, [R12]\n" //param 0 -> [0x67118]
 465 "                B       loc_FF9373A8\n"
 466 "loc_FF9372C4:\n"
 467 "                CMP     R2, #1\n"       //param 2, is it 1? (no, it can never be 1, it's always 0, see caller)
 468 "                LDREQ   R7, =0x67120\n" //param 2 is 1
 469 "                MOVEQ   R3, #0xA\n"     //param 2 is 1
 470 "                STREQ   R3, [R7]\n"     //param 2 is 1, 0xa -> [0x67120]
 471 "                BEQ     loc_FF9373A8\n" //param 2 is 1, go to end
 472 "                LDR     R3, =0x6711C\n"
 473 "                LDR     R2, [R3]\n" //[0x6711c] -> r2
 474 "                LDR     R12, =0x5744\n"
 475 "                MOV     R2, R2,LSL#2\n" //r2=r2*4 (for addressing)
 476 "                LDR     R1, =0x5824\n"
 477 "                LDR     R3, [R12,R2]\n" //[0x5744+r2] -> r3
 478 "                LDR     R0, [R1,R2]\n" //[0x5824+r2] -> r0
 479 "                SUBS    R4, LR, R3\n" //r4=lr-r3 (signed)
 480 "                RSB     R1, R0, LR\n" //r1=lr-r0
 481 "                BMI     loc_FF937348\n" //if(r4<0) then jump
 482 "                MOV     R0, #1\n"
 483 "                LDR     R7, =0x67120\n"
 484 "loc_FF937308:\n"
 485 "                CMP     R0, #3\n"
 486 "                LDR     LR, =0x6711C\n"
 487 "                LDR     R1, =0x5744\n"
 488 "                LDR     R12, =0x67120\n"
 489 "                BGT     loc_FF937394\n" //if(r0>3) then jump
 490 "                LDR     R3, [R12]\n" //[0x67120] -> r3
 491 "                CMP     R3, #0xD\n"
 492 "                ADD     R2, R3, #1\n"
 493 "                STRLS   R2, [R12]\n" //if (r3<=0xd) then r3+1 -> [0x67120]
 494 "                LDR     R3, [LR]\n" //[0x6711c] -> r3
 495 "                ADD     R3, R3, R0,LSL#2\n" //r3=r3+r0*4
 496 "                LDR     R2, [R1,R3,LSL#2]\n" //[0x5744+r3*4] -> r2
 497 "                CMP     R4, R2\n"
 498 "                ADD     R0, R0, #1\n" //r0=r0+1
 499 "                BGE     loc_FF937308\n" //if(r4>=r2) then loop back
 500 "                B       loc_FF937394\n"
 501 "loc_FF937348:\n"
 502 "                CMP     R1, #0\n"
 503 "                BGT     loc_FF9373A4\n" //if(r1>0) then jump
 504 "                MOV     R0, #1\n"
 505 "                LDR     R7, =0x67120\n"
 506 "loc_FF937358:\n"
 507 "                CMP     R0, #3\n"
 508 "                LDR     LR, =0x6711C\n"
 509 "                LDR     R4, =0x5824\n"
 510 "                LDR     R12, =0x67120\n"
 511 "                BGT     loc_FF937394\n" //if(r0>3) then jump
 512 "                LDR     R3, [R12]\n" //[0x67120] -> r3
 513 "                CMP     R3, #0\n"
 514 "                SUB     R2, R3, #1\n"
 515 "                STRNE   R2, [R12]\n" //if (r3!=0) then r3-1 -> [0x67120]
 516 "                LDR     R3, [LR]\n" //[0x6711c] -> r3
 517 "                ADD     R3, R3, R0,LSL#2\n" //r3=r3+r0*4
 518 "                LDR     R2, [R4,R3,LSL#2]\n" //[0x5824+r3*4] -> r2
 519 "                CMP     R1, R2\n"
 520 "                ADD     R0, R0, #1\n" //r0=r0+1
 521 "                BLE     loc_FF937358\n" //if(r1<=r2) then loop back
 522 "loc_FF937394:\n"
 523 "                LDR     R2, =0x67124\n"
 524 "                MOV     R3, #1\n"
 525 "                STR     R3, [R2]\n" //1 -> [0x67124]
 526 "                B       loc_FF9373A8\n"
 527 "loc_FF9373A4:\n"
 528 "                LDR     R7, =0x67120\n"
 529 "loc_FF9373A8:\n"
 530 "                LDR     R3, =0x67118\n"
 531 "                mov     r0, r7\n" //+
 532 "                bl      set_quality\n" //+
 533 "                MOV     R0, R6\n" //param 1 -> r0
 534 "                LDR     R1, [R7]\n" //[0x67120] -> r1
 535 "                STR     R5, [R3]\n" //param 0 -> [0x67118]
 536 "                LDMFD   SP!, {R4-R7,LR}\n"
 537 "                B       loc_FF89AC9C\n"
 538 "loc_FF89AC9C:\n"
 539 "                LDR     R3, =0xFF89A498\n" // a table (of quality parameters?) starts here
 540 "                ADD     R3, R3, R1,LSL#7\n" //r3=r3+r1*128
 541 "                STR     R3, [R0]\n" //r3 -> [param 1]
 542 "                MOV     PC, LR\n"
 543  );
 544 }
 545 
 546 void __attribute__((naked,noinline)) sub_FF936AC4_my(){
 547  asm volatile(
 548 "                CMP     R0, #0x80000001\n"
 549 "                BEQ     loc_FF936AFC\n"
 550 "                BHI     loc_FF936ADC\n"
 551 "                CMP     R0, #0\n"
 552 "                BEQ     loc_FF936AF0\n"
 553 "                B       loc_FF936B5C\n"
 554 "loc_FF936ADC:\n"
 555 "                CMP     R0, #0x80000003\n"
 556 "                BEQ     loc_FF936B0C\n"
 557 "                CMP     R0, #0x80000005\n"
 558 "                BEQ     loc_FF936B1C\n"
 559 "                B       loc_FF936B5C\n"
 560 "loc_FF936AF0:\n"
 561 "                LDR     R3, =0x670B4\n"
 562 "                STR     R0, [R3]\n"
 563 "                MOV     PC, LR\n"
 564 "loc_FF936AFC:\n"
 565 "                LDR     R2, =0x670B4\n"
 566 "                MOV     R3, #4\n"
 567 "                STR     R3, [R2]\n"
 568 "                MOV     PC, LR\n"
 569 "loc_FF936B0C:\n"
 570 "                LDR     R2, =0x670B4\n"
 571 "                MOV     R3, #1\n"
 572 "                STR     R3, [R2]\n"
 573 "                MOV     PC, LR\n"
 574 "loc_FF936B1C:\n"
 575 "                LDR     R2, =0x670D8\n"
 576 "                LDR     R3, [R2,#4]\n"
 577 "                CMP     R3, #0\n"
 578 "                BHI     loc_FF936B3C\n"
 579 "                BNE     loc_FF936B4C\n"
 580 "                LDR     R3, [R2]\n"
 581 "                CMP     R3, #0x40000000\n" //must be the 1G size limit check
 582 "                B       loc_FF936B4C\n" // changed BLS to B
 583 "loc_FF936B3C:\n"
 584 "                LDR     R2, =0x670B4\n"
 585 "                MOV     R3, #3\n"
 586 "                STR     R3, [R2]\n"
 587 "                MOV     PC, LR\n"
 588 "loc_FF936B4C:\n"
 589 "                LDR     R2, =0x670B4\n"
 590 "                MOV     R3, #2\n"
 591 "                STR     R3, [R2]\n"
 592 "                MOV     PC, LR\n"
 593 "loc_FF936B5C:\n"
 594 "                LDR     R2, =0x670B4\n"
 595 "                MOV     R3, #0\n"
 596 "                STR     R3, [R2]\n"
 597 "                MOV     PC, LR\n"
 598  );
 599 }
 600 
 601 //
 602 
 603 void __attribute__((naked,noinline)) sub_FF936570_my(){
 604  asm volatile(
 605 "                STMFD   SP!, {R4-R11,LR}\n"
 606 "                LDR     R3, =0x67098\n"
 607 "                SUB     SP, SP, #0x38\n"
 608 "                LDR     R4, [R3]\n"
 609 "                LDR     R5, =0x670D8\n"
 610 "                LDR     R3, =0x6708C\n"
 611 "                LDR     R12, =0x67078\n"
 612 "                STR     R4, [R3]\n"
 613 "                MOV     R11, #0\n"
 614 "                LDMIA   R5, {R3,R4}\n"
 615 "                LDR     LR, =0x6707C\n"
 616 "                STR     R11, [R12]\n"
 617 "                ADD     R12, SP, #0x5C-0x2C\n"
 618 "                STR     R11, [LR]\n"
 619 "                MOV     R0, #6\n"
 620 "                STMDB   R12, {R3,R4}\n"
 621 "                MOV     R1, R11\n"
 622 "                LDR     R2, =0x67110\n"
 623 "                BL      sub_FF813A1C\n"
 624 "                LDR     R3, [R5,#4]\n"
 625 "                CMP     R3, R11\n"
 626 "                BHI     loc_FF9365E8\n"
 627 "                BNE     loc_FF9365D8\n"
 628 "                LDR     R3, [R5]\n"
 629 "                CMP     R3, #0x40000000\n"
 630 "                BHI     loc_FF9365E8\n"
 631 "loc_FF9365D8:\n"
 632 "                LDR     R2, =0x670BC\n"
 633 "                LDR     R3, [R2]\n"
 634 "                CMP     R3, #0\n"
 635 "                BNE     loc_FF9365F8\n"
 636 "loc_FF9365E8:\n"
 637 "                MOV     R4, #0\n"
 638 "                MOV     R3, #0x40000000\n"
 639 "                ADD     R12, SP, #0x5C-0x2C\n"
 640 "                STMDB   R12, {R3,R4}\n"
 641 "loc_FF9365F8:\n"
 642 "                LDR     R3, =0x67098\n"
 643 "                LDR     R2, =0x88888889\n"
 644 "                LDR     R7, [R3]\n"
 645 "                UMULL   R3, R12, R2, R7\n"
 646 "                MOV     R12, R12,LSR#2\n"
 647 "                LDR     R8, =0x67080\n"
 648 "                BIC     R12, R12, #1\n"
 649 "                LDR     LR, =0x67110\n"
 650 "                LDR     R10, =0x67090\n"
 651 "                LDR     R2, =0x67094\n"
 652 "                MOV     R12, R12,LSL#16\n"
 653 "                LDR     R6, [R8]\n"
 654 "                MOV     R12, R12,LSR#16\n"
 655 "                MOV     R9, #0x2B00\n" // audio sample rate, first part
 656 "                LDR     R5, =0xFF936B98\n"
 657 "                LDR     R1, [LR,#4]\n"
 658 "                LDR     R3, [R2]\n"
 659 "                LDR     R0, [LR]\n"
 660 "                MOV     R4, #1\n" // audio channels?
 661 "                ADD     LR, SP, #0x5C-0x28\n"
 662 "                STR     R12, [SP,#0x5C-0x40]\n"
 663 "                LDR     R2, [R10]\n" //picture width
 664 "                MOV     R12, #8\n" // audio bit depth (setting it to 16 results in broken audio: 8bit samples - nothing - 8bit samples - etc, also breaks the avi)
 665 "                ADD     R9, R9, #0x10\n" // 0x2b00+0x10 (11024dec, canon's usual audio sample rate) -> 22050 causes crash
 666 "                STR     R6, [SP,#0x5C-0x58]\n"
 667 "                STR     R12, [SP,#0x5C-0x48]\n"
 668 "                STR     R5, [SP,#0x5C-0x3C]\n"
 669 "                STR     LR, [SP,#0x5C-0x38]\n"
 670 "                STR     R7, [SP,#0x5C-0x5C]\n"
 671 "                STR     R9, [SP,#0x5C-0x54]\n"
 672 "                STR     R9, [SP,#0x5C-0x50]\n"
 673 "                STR     R4, [SP,#0x5C-0x4C]\n"
 674 "                STR     R4, [SP,#0x5C-0x44]\n"
 675 "                BL      sub_FF9375B8_my\n" // ->
 676 "                ADD     R3, SP, #0x5C-0x2C\n"
 677 "                LDR     R12, =0x670C0\n"
 678 "                LDMDB   R3, {R1,R2}\n"
 679 "                LDR     R3, =0x670BC\n"
 680 "                LDR     R0, [R3]\n"
 681 "                LDR     R3, [R12]\n"
 682 "                BL      sub_FF937834\n"
 683 "                LDR     R3, [R8]\n"
 684 "                LDR     R1, =0x670B8\n"
 685 "                MOV     R2, #0\n"
 686 "                LDR     R0, [R10]\n"
 687 "                BL      sub_FF9371C8\n"
 688 "                BL      sub_FF936890\n"
 689 "                MOV     R2, R4\n"
 690 "                MOV     R1, R0\n"
 691 "                LDR     R0, [SP,#0x5C-0x28]\n"
 692 "                BL      sub_FF8A0398\n"
 693 "                LDR     R0, =0xFF9368F0\n"
 694 "                MOV     R1, #0\n"
 695 "                BL      sub_FF8A0440\n"
 696 "                LDR     R0, =0xFF93651C\n" //SoundDeviceIn
 697 "                MOV     R1, #0\n"
 698 "                BL      sub_FFA44698\n"
 699 "                LDR     R6, =0x67104\n"
 700 "                TST     R0, #1\n"
 701 "                STR     R0, [R6]\n"
 702 "                BEQ     loc_FF936700\n"
 703 "                MOV     R2, #0x1EC\n"
 704 "                LDR     R0, =0xFF93652C\n" //!IS_ERROR( hSoundHandle )
 705 "                LDR     R1, =0xFF936548\n" //MovieRecorder.c
 706 "                ADD     R2, R2, #2\n"
 707 "                BL      sub_FF814C10\n"
 708 "loc_FF936700:\n"
 709 "                MOV     R4, #0\n"
 710 "                LDR     R0, [R6]\n"
 711 "                MOV     R3, #8\n"
 712 "                MOV     R1, R4\n"
 713 "                MOV     R2, R9\n"
 714 "                STR     R11, [SP,#0x5C-0x5C]\n"
 715 "                STR     R4, [SP,#0x5C-0x58]\n"
 716 "                BL      sub_FFA448E8\n"
 717 "                TST     R0, #1\n"
 718 "                BEQ     loc_FF93673C\n"
 719 "                MOV     R2, #0x1F0\n"
 720 "                LDR     R0, =0xFF936558\n" //!IS_ERROR( RetCode )
 721 "                LDR     R1, =0xFF936548\n" //MovieRecorder.c
 722 "                ADD     R2, R2, #1\n"
 723 "                BL      sub_FF814C10\n"
 724 "loc_FF93673C:\n"
 725 "                LDR     R0, [R6]\n"
 726 "                LDR     R1, =0xFF936CB4\n"
 727 "                MOV     R2, R4\n"
 728 "                BL      sub_FFA447E4\n"
 729 "                TST     R0, #1\n"
 730 "                BEQ     loc_FF936768\n"
 731 "                MOV     R2, #0x1F0\n"
 732 "                LDR     R0, =0xFF936558\n" //!IS_ERROR( RetCode )
 733 "                LDR     R1, =0xFF936548\n" //MovieRecorder.c
 734 "                ADD     R2, R2, #3\n"
 735 "                BL      sub_FF814C10\n"
 736 "loc_FF936768:\n"
 737 "                LDR     R3, =0x66FEC\n"
 738 "                MOV     R1, R4\n"
 739 "                LDR     R0, [R3]\n"
 740 "                BL      sub_FF822F5C\n" //TakeSemaphore [0x66fec], NO_WAIT
 741 "                ADD     R5, SP, #0x5C-0x2C\n"
 742 "                MOV     R0, R5\n"
 743 "                BL      sub_FF9380D4\n"
 744 "                LDR     R7, =0xFF936D54\n"
 745 "                LDR     R0, [R6]\n"
 746 "                LDR     R1, [SP,#0x5C-0x2C]\n"
 747 "                MOV     R2, R9\n"
 748 "                MOV     R3, R7\n"
 749 "                STR     R4, [SP,#0x5C-0x5C]\n"
 750 "                BL      sub_FFA44798\n"
 751 "                TST     R0, #1\n"
 752 "                BEQ     loc_FF9367BC\n"
 753 "                MOV     R2, #0x1F8\n"
 754 "                LDR     R0, =0xFF936558\n" //!IS_ERROR( RetCode )
 755 "                LDR     R1, =0xFF936548\n" //MovieRecorder.c
 756 "                ADD     R2, R2, #1\n"
 757 "                BL      sub_FF814C10\n"
 758 "loc_FF9367BC:\n"
 759 "                MOV     R0, R5\n"
 760 "                BL      sub_FF9380D4\n"
 761 "                LDR     R0, [R6]\n"
 762 "                LDR     R1, [SP,#0x5C-0x2C]\n"
 763 "                MOV     R2, R9\n"
 764 "                MOV     R3, R7\n"
 765 "                STR     R4, [SP,#0x5C-0x5C]\n"
 766 "                BL      sub_FFA44798\n"
 767 "                TST     R0, #1\n"
 768 "                BEQ     loc_FF9367F8\n"
 769 "                MOV     R2, #0x1FC\n"
 770 "                LDR     R0, =0xFF936558\n" //!IS_ERROR( RetCode )
 771 "                LDR     R1, =0xFF936548\n" //MovieRecorder.c
 772 "                ADD     R2, R2, #2\n"
 773 "                BL      sub_FF814C10\n"
 774 "loc_FF9367F8:\n"
 775 "                LDR     R0, =0x670B0\n"
 776 "                LDR     R12, =0x67108\n"
 777 "                LDR     R2, =0xFF936C60\n"
 778 "                LDR     R1, =0x67088\n"
 779 "                MOV     R3, #2\n"
 780 "                STR     R4, [R0]\n"
 781 "                STR     R2, [R12]\n"
 782 "                STR     R3, [R1]\n"
 783 "                ADD     SP, SP, #0x38\n"
 784 "                LDMFD   SP!, {R4-R11,PC}\n"
 785  );
 786 }
 787 
 788 
 789 void __attribute__((naked,noinline)) sub_FF9375B8_my(){
 790  asm volatile(
 791 "                STMFD   SP!, {R4-R11,LR}\n"
 792 "                MOV     R10, R2\n"
 793 "                LDR     R2, =0x67424\n"
 794 "                SUB     SP, SP, #4\n"
 795 "                LDRSH   R7, [SP,#0x28+0x18]\n" //1
 796 "                LDRSH   R6, [SP,#0x28+0x1C]\n"
 797 "                LDR     R11, [SP,#0x28+0x0]\n"
 798 "                LDRSH   R9, [SP,#0x28+0x10]\n" //1
 799 "                LDRSH   R8, [SP,#0x28+0x14]\n" //audio bit depth
 800 "                STR     R3, [R2]\n"
 801 "                LDR     R2, [SP,#0x28+0x4]\n"
 802 "                LDR     R3, =0x6742C\n"
 803 "                STR     R2, [R3]\n"
 804 "                LDR     R3, [SP,#0x28+0x8]\n" //audio sr
 805 "                LDR     R12, =0x67430\n"
 806 "                STR     R3, [R12]\n" //audio sr -> [0x67430]
 807 "                LDR     R2, [SP,#0x28+0xC]\n" //audio sr
 808 "                LDR     LR, =0x67434\n"
 809 "                LDR     R3, =0x6743C\n"
 810 "                STR     R2, [LR]\n" //audio sr -> [0x67434]
 811 "                LDR     R4, =0x67438\n"
 812 "                LDR     R2, =0x6743E\n"
 813 "                LDR     R5, =0x6743A\n"
 814 "                STRH    R9, [R4]\n"
 815 "                STRH    R8, [R5]\n"
 816 "                STRH    R7, [R3]\n"
 817 "                STRH    R6, [R2]\n"
 818 "                LDR     R2, [SP,#0x28+0x20]\n" //0xff936b98
 819 "                LDR     R3, =0x67460\n"
 820 "                STR     R2, [R3]\n"
 821 "                LDR     R3, =0x67420\n"
 822 "                LDR     R2, =0x67428\n"
 823 "                CMP     R10, #0x280\n" //640x480?
 824 "                STR     R10, [R3]\n"
 825 "                MOV     R7, R0\n"
 826 "                STR     R11, [R2]\n"
 827 "                MOV     R6, R1\n"
 828 "                BNE     loc_FF93767C\n"
 829 "                RSB     R2, R11, R11,LSL#4\n"
 830 "                MOV     R3, #0xE100\n"
 831 "                RSB     R2, R2, R2,LSL#4\n"
 832 "                ADD     R3, R3, #8\n"
 833 "                LDR     R5, =0x673F8\n"
 834 "                LDR     R12, =0x673CC\n"
 835 "                MOV     R1, #0x40000\n"
 836 "                MOV     R0, R2,LSL#4\n"
 837 "                ADD     R4, R3, R2,LSL#8\n"
 838 "                MOV     R3, #2\n"
 839 "                B       loc_FF9376F8\n"
 840 "loc_FF93767C:\n" //320x240
 841 "                CMP     R10, #0x140\n"
 842 "                BNE     loc_FF9376D0\n"
 843 "                RSB     R12, R11, R11,LSL#4\n"
 844 "                LDR     R5, =0x673F8\n"
 845 "                RSB     R0, R12, R12,LSL#4\n"
 846 "                MOV     R2, #0x20000\n"
 847 "                LDR     LR, =0x673CC\n"
 848 "                MOV     R3, #0xE100\n"
 849 "                STR     R2, [R5]\n"
 850 "                MOV     R1, R0,LSL#4\n"
 851 "                ADD     R3, R3, #8\n"
 852 "                MOV     R2, #1\n"
 853 "                CMP     R11, #0x3C\n" //60fps?
 854 "                STR     R1, [LR]\n"
 855 "                ADD     R4, R3, R0,LSL#8\n"
 856 "                STR     R2, [SP,#0x28-0x28]\n"
 857 "                MOVEQ   R3, R12,LSL#2\n"
 858 "                MOVEQ   R4, #0xE400\n"
 859 "                STREQ   R3, [LR]\n"
 860 "                ADDEQ   R4, R4, #0xC8\n"
 861 "                B       loc_FF937704\n"
 862 "loc_FF9376D0:\n" //160x120
 863 "                ADD     R2, R11, R11,LSL#1\n"
 864 "                MOV     R3, #0xB40\n"
 865 "                RSB     R2, R2, R2,LSL#4\n"
 866 "                ADD     R3, R3, #8\n"
 867 "                LDR     R5, =0x673F8\n"
 868 "                LDR     R12, =0x673CC\n"
 869 "                MOV     R1, #0x10000\n"
 870 "                MOV     R0, R2,LSL#2\n"
 871 "                ADD     R4, R3, R2,LSL#6\n"
 872 "                MOV     R3, #0\n"
 873 "loc_FF9376F8:\n"
 874 "                STR     R1, [R5]\n"
 875 "                STR     R0, [R12]\n"
 876 "                STR     R3, [SP,#0x28-0x28]\n"
 877 "loc_FF937704:\n"
 878 "                LDR     R3, [SP,#0x28+0x24]\n"
 879 "                LDR     R0, [R5]\n"
 880 "                LDR     R2, =0x6742C\n"
 881 "                LDR     R12, =0x6743A\n"
 882 "                LDR     R1, [R2]\n"
 883 "                STR     R0, [R3]\n"
 884 "                LDR     R2, =0x67430\n"
 885 "                LDRH    R3, [R12]\n"
 886 "                LDR     R0, [R2]\n"
 887 "                MOV     R3, R3,LSR#3\n"
 888 "                MUL     LR, R3, R0\n"
 889 "                LDR     R2, =0x6743C\n"
 890 "                LDRH    R3, [R2]\n"
 891 "                MUL     R11, R3, LR\n"
 892 "                RSB     R12, R4, R6\n"
 893 "                SUB     R12, R12, R11,LSL#1\n"
 894 "                SUB     R12, R12, #0x3E800\n"
 895 "                ADD     LR, R7, #3\n"
 896 "                SUB     R12, R12, #0x10\n"
 897 "                BIC     LR, LR, #3\n"
 898 "                BIC     R12, R12, #0x7F00\n"
 899 "                ADD     R4, LR, R4\n"
 900 "                BIC     R12, R12, #0xFF\n"
 901 "                ADD     R9, R4, R12\n"
 902 "                LDR     R5, =0x67450\n"
 903 "                ADD     R3, R9, #0x3E800\n"
 904 "                LDR     R0, [SP,#0x28-0x28]\n"
 905 "                STR     R3, [R5]\n"
 906 "                LDR     R3, =0x673A8\n"
 907 "                LDR     R2, =0x67428\n"
 908 "                STR     R4, [R3,#4]\n"
 909 "                LDR     R3, =0x67454\n"
 910 "                LDR     R2, [R2]\n"
 911 "                STR     R12, [R3]\n"
 912 "                LDR     R3, =0x67444\n"
 913 "                STR     LR, [R3]\n"
 914 "                LDR     R3, =0x67448\n"
 915 "                STR     R4, [R3]\n"
 916 "                LDR     R3, =0x6744C\n"
 917 "                STR     R9, [R3]\n"
 918 "                LDR     R3, =0x673E8\n"
 919 "                STR     R11, [R3]\n"
 920 "                LDR     R3, =0x673A8\n"
 921 "                SUBS    R1, R1, #0\n"
 922 "                MOVNE   R1, #1\n"
 923 "                STR     R4, [R3]\n"
 924 "                BL      sub_FF91A3CC\n"
 925 "                LDR     R2, =0x673E8\n"
 926 "                LDR     R3, [R2]\n"
 927 "                LDR     R2, =0x673E0\n"
 928 "                ADD     R0, R0, R3\n"
 929 "                STR     R0, [R2]\n"
 930 "                ADD     SP, SP, #4\n"
 931 "                LDMFD   SP!, {R4-R11,PC}\n"
 932  );

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