root/platform/s95/sub/100e/movie_rec.c

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

DEFINITIONS

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

   1 #include "conf.h"
   2 
   3 int *video_quality = &conf.video_quality;
   4 int *video_mode    = &conf.video_mode;
   5 
   6 
   7 /*----------------------------------------------------------------------
   8         set_quality()
   9 -----------------------------------------------------------------------*/
  10 // TODO - check this
  11 void  set_quality (int *x)  // -17 highest; +12 lowest
  12 {
  13         if (conf.video_mode)
  14                 *x = 12 - ((conf.video_quality-1) * (12+17) / (99-1));
  15 }
  16 
  17 
  18 /*----------------------------------------------------------------------
  19         change_video_tables()
  20 -----------------------------------------------------------------------*/
  21 void change_video_tables(int a, int b)
  22 {
  23 }
  24 
  25 
  26 /*----------------------------------------------------------------------
  27         movie_record_task()
  28 -----------------------------------------------------------------------*/
  29 void __attribute__((naked,noinline)) movie_record_task()
  30 {
  31         asm volatile (
  32 "               STMFD   SP!, {R2-R10,LR} \n"
  33 "               LDR     R9, =0x5EE \n"
  34 "               LDR     R8, =0x2710 \n"
  35 "               LDR     R4, =0x7128 \n"
  36 "               MOV     R7, #1 \n"
  37 "               LDR     R6, =0xFF986128 \n"                     // nullsub_322
  38 "               MOV     R5, #0 \n"
  39 "loc_FF98643C: \n"
  40 "               LDR     R0, [R4,#0x24] \n"
  41 "               MOV     R2, #0 \n"
  42 "               ADD     R1, SP, #4 \n"
  43 "               BL      sub_FF83A2F8 \n"
  44 "               LDR     R0, [R4,#0x2C] \n"
  45 "               CMP     R0, #0 \n"
  46 "               LDRNE   R0, [R4,#0xC] \n"
  47 "               CMPNE   R0, #2 \n"
  48 "               LDRNE   R0, [R4,#0x44] \n"
  49 "               CMPNE   R0, #6 \n"
  50 "               BNE     loc_FF986554 \n"
  51 "               LDR     R0, [SP,#0x4] \n"
  52 "               LDR     R1, [R0] \n"
  53 "               SUB     R1, R1, #2 \n"
  54 "               CMP     R1, #0xA \n"
  55 "               ADDLS   PC, PC, R1,LSL#2 \n"
  56 "               B       loc_FF986554 \n"
  57 "loc_FF986480: \n"
  58 "               B       loc_FF986508 \n"
  59 "loc_FF986484: \n"
  60 "               B       loc_FF986528 \n"
  61 "loc_FF986488: \n"
  62 "               B       loc_FF986538 \n"
  63 "loc_FF98648C: \n"
  64 "               B       loc_FF986540 \n"
  65 "loc_FF986490: \n"
  66 "               B       loc_FF986510 \n"
  67 "loc_FF986494: \n"
  68 "               B       loc_FF986548 \n"
  69 "loc_FF986498: \n"
  70 "               B       loc_FF986518 \n"
  71 "loc_FF98649C: \n"
  72 "               B       loc_FF986554 \n"
  73 "loc_FF9864A0: \n"
  74 "               B       loc_FF986550 \n"
  75 "loc_FF9864A4: \n"
  76 "               B       loc_FF9864D8 \n"
  77 "loc_FF9864A8: \n"
  78 "               B       loc_FF9864AC \n"
  79 
  80 "loc_FF9864AC: \n"
  81 // jumptable FF986478 entry 10
  82 "               STR     R5, [R4,#0x40] \n"
  83 "               STR     R5, [R4,#0x30] \n"
  84 "               STR     R5, [R4,#0x34] \n"
  85 "               STRH    R5, [R4,#6] \n"
  86 "               STR     R6, [R4,#0xB4] \n"
  87 "               LDR     R0, [R4,#0xC] \n"
  88 "               ADD     R0, R0, #1 \n"
  89 "               STR     R0, [R4,#0xC] \n"
  90 "               MOV     R0, #6 \n"
  91 "               STR     R0, [R4,#0x44] \n"
  92 "               B       loc_FF9864F4 \n"
  93 
  94 "loc_FF9864D8: \n"
  95 // jumptable FF986478 entry 9
  96 "               STR     R5, [R4,#0x40] \n"
  97 "               STR     R5, [R4,#0x30] \n"
  98 "               STR     R6, [R4,#0xB4] \n"
  99 "               LDR     R0, [R4,#0xC] \n"
 100 "               ADD     R0, R0, #1 \n"
 101 "               STR     R0, [R4,#0xC] \n"
 102 "               STR     R7, [R4,#0x44] \n"
 103 "loc_FF9864F4: \n"
 104 "               LDR     R2, =0xFF98533C \n"
 105 "               LDR     R1, =0xB45D0 \n"
 106 
 107 //"             LDR     R0, =sub_FF985438 \n"
 108 "               LDR     R0, =0xFF985438 \n"
 109 
 110 "               BL      sub_FF8530D0 \n"
 111 "               B       loc_FF986554 \n"
 112 
 113 "loc_FF986508: \n"
 114 // jumptable FF986478 entry 0
 115 
 116 "               BL      unlock_optical_zoom\n"                  // added to unlock the zoom
 117 
 118 "               BL      sub_FF986238 \n"
 119 "               B       loc_FF986554 \n"
 120 
 121 "loc_FF986510: \n"
 122 // jumptable FF986478 entry 4
 123 
 124 //"             BL      sub_FF985B90 \n"
 125 "               BL      sub_FF985B90_my \n"                             // patched
 126 
 127 "               B       loc_FF986554 \n"
 128 
 129 "loc_FF986518: \n"
 130 // jumptable FF986478 entry 6
 131 "               LDR     R1, [R0,#0x18] \n"
 132 "               LDR     R0, [R0,#4] \n"
 133 "               BL      sub_FFAF2974 \n"
 134 "               B       loc_FF986554 \n"
 135 
 136 "loc_FF986528: \n"
 137 // jumptable FF986478 entry 1
 138 "               LDR     R0, [R4,#0x44] \n"
 139 "               CMP     R0, #5 \n"
 140 "               STRNE   R7, [R4,#0x34] \n"
 141 "               B       loc_FF986554 \n"
 142 
 143 "loc_FF986538: \n"
 144 // jumptable FF986478 entry 2
 145 "               BL      sub_FF9857D8 \n"
 146 "               B       loc_FF986554 \n"
 147 
 148 "loc_FF986540: \n"
 149 // jumptable FF986478 entry 3
 150 "               BL      sub_FF985484 \n"
 151 "               B       loc_FF986554 \n"
 152 
 153 "loc_FF986548: \n"
 154 // jumptable FF986478 entry 5
 155 "               BL      sub_FF9852C8 \n"
 156 "               B       loc_FF986554 \n"
 157 
 158 "loc_FF986550: \n"
 159 // jumptable FF986478 entry 8
 160 "               BL      sub_FF98697C \n"
 161 
 162 "loc_FF986554: \n"
 163 // jumptable FF986478 default entry
 164 // jumptable FF986478 entry 7
 165 "               LDR     R1, [SP,#0x4] \n"
 166 "               STR     R5, [R1] \n"
 167 "               LDR     R3, =0xFF985124 \n"                     // MovieRecorder.c
 168 "               MOV     R2, R8 \n"
 169 "               STR     R9, [SP,#0x0] \n"
 170 "               LDR     R0, [R4,#0x28] \n"
 171 "               BL      sub_FF83AC4C \n"
 172 "               B       loc_FF98643C \n"
 173         );
 174 }
 175 
 176 
 177 /*----------------------------------------------------------------------
 178         sub_FF985B90_my()
 179 -----------------------------------------------------------------------*/
 180 void __attribute__((naked,noinline)) sub_FF985B90_my()
 181 {
 182         asm volatile (
 183 "               STMFD   SP!, {R4-R11,LR} \n"
 184 "               SUB     SP, SP, #0x64 \n"
 185 "               MOV     R8, #0 \n"
 186 "               LDR     R6, =0x7128 \n"
 187 "               MOV     R4, R0 \n"
 188 "               STR     R8, [SP,#0x54] \n"
 189 "               STR     R8, [SP,#0x4c] \n"
 190 "               LDR     R0, [R6,#0x44] \n"
 191 "               MOV     R11, #4 \n"
 192 "               CMP     R0, #3 \n"
 193 "               STREQ   R11, [R6,#0x44] \n"
 194 "               LDR     R0, [R6,#0xB4] \n"
 195 "               MOV     R9, #0 \n"
 196 "               MOV     R7, #0 \n"
 197 "               MOV     R5, #1 \n"
 198 "               BLX     R0 \n"
 199 "               LDR     R0, [R6,#0x44] \n"
 200 "               CMP     R0, #6 \n"
 201 "               BEQ     loc_FF985BF0 \n"
 202 "               LDR     R1, [R6,#0xC] \n"
 203 "               CMP     R1, #2 \n"
 204 "               BNE     loc_FF985C10 \n"
 205 "               CMP     R0, #5 \n"
 206 "               BEQ     loc_FF985C88 \n"
 207 "loc_FF985BF0: \n"
 208 "               LDR     R0, =0xFF985124 \n"                             // Movierecorder.c
 209 "               MOV     R7, #1 \n"
 210 "               MOV     R1, #0x7F0 \n"
 211 "               BL      sub_FF81EB78 \n"                                // DebugAssert
 212 "               LDR     R0, [R6,#0x44] \n"
 213 "               CMP     R0, #4 \n"
 214 "               MOVNE   R5, #0 \n"
 215 "               B       loc_FF985C18 \n"
 216 "loc_FF985C10: \n"
 217 "               CMP     R0, #4 \n"
 218 "               BNE     loc_FF985C88 \n"
 219 "loc_FF985C18: \n"
 220 "               LDRH    R0, [R6,#6] \n"
 221 "               CMP     R0, #1 \n"
 222 "               LDREQ   R1, =0x807 \n"
 223 "               LDREQ   R0, =0xFF985124 \n"                     // Movierecorder.c
 224 "               BLEQ    sub_FF81EB78 \n"                        // DebugAssert
 225 "               LDRH    R0, [R6,#6] \n"
 226 "               CMP     R0, #3 \n"
 227 "               BNE     loc_FF985C4C \n"
 228 "               LDR     R0, [R6,#0x6C] \n"
 229 "               LDR     R1, [R6,#0xB8] \n"
 230 "               BL      sub_FFBA16EC \n"
 231 "               CMP     R1, #0 \n"
 232 "               MOVNE   R5, #0 \n"
 233 "loc_FF985C4C: \n"
 234 "               LDR     R0, [R6,#0x44] \n"
 235 "               CMP     R0, #6 \n"
 236 "               CMPNE   R0, #1 \n"
 237 "               CMPNE   R0, #3 \n"
 238 "               BNE     loc_FF985C90 \n"
 239 "               CMP     R7, #1 \n"
 240 "               CMPEQ   R5, #0 \n"
 241 "               BNE     loc_FF985C90 \n"
 242 "               LDR     R0, [R6,#0x18] \n"
 243 "               MOV     R1, #0x3E8 \n"
 244 "               BL      sub_FF83A714 \n"                        // eventproc_export_TakeSemaphore
 245 "               CMP     R0, #9 \n"
 246 "               BNE     loc_FF9860B0 \n"
 247 "               MOV     R0, #0x90000 \n"
 248 "               BL      sub_FF89D31C \n"                        // eventproc_export_HardwareDefect
 249 "loc_FF985C88: \n"
 250 "               ADD     SP, SP, #0x64 \n"
 251 "               LDMFD   SP!, {R4-R11,PC} \n"
 252 "loc_FF985C90: \n"
 253 "               CMP     R5, #1 \n"
 254 "               MOV     R10, #1 \n"
 255 "               BNE     loc_FF985CB8 \n"
 256 "               ADD     R3, SP, #0x4c \n"
 257 "               ADD     R2, SP, #0x50 \n"
 258 "               ADD     R1, SP, #0x54 \n"
 259 "               ADD     R0, SP, #0x58 \n"
 260 "               BL      sub_FFAF2A34 \n"
 261 "               MOVS    R9, R0 \n"
 262 "               BNE     loc_FF985CD4 \n"
 263 "loc_FF985CB8: \n"
 264 "               LDR     R0, [R6,#0x34] \n"
 265 "               CMP     R0, #1 \n"
 266 "               BNE     loc_FF985E30 \n"
 267 "               LDR     R0, [R6,#0x6C] \n"
 268 "               LDR     R1, [R6,#0x48] \n"
 269 "               CMP     R0, R1 \n"
 270 "               BCC     loc_FF985E30 \n"
 271 "loc_FF985CD4: \n"
 272 "               CMP     R9, #0x80000001 \n"
 273 "               STREQ   R11, [R6,#0x70] \n"
 274 "               BEQ     loc_FF985D0C \n"
 275 "               CMP     R9, #0x80000003 \n"
 276 "               STREQ   R10, [R6,#0x70] \n"
 277 "               BEQ     loc_FF985D0C \n"
 278 "               CMP     R9, #0x80000005 \n"
 279 "               MOVEQ   R0, #2 \n"
 280 "               BEQ     loc_FF985D08 \n"
 281 "               CMP     R9, #0x80000007 \n"
 282 "               STRNE   R8, [R6,#0x70] \n"
 283 "               BNE     loc_FF985D0C \n"
 284 "               MOV     R0, #3 \n"
 285 "loc_FF985D08: \n"
 286 "               STR     R0, [R6,#0x70] \n"
 287 "loc_FF985D0C: \n"
 288 "               LDR     R0, [R6,#0xC] \n"
 289 "               CMP     R0, #2 \n"
 290 "               BNE     loc_FF985D74 \n"
 291 "               MOV     R1, #0 \n"
 292 "               LDR     R0, =0xFF985B84 \n"
 293 "               BL      sub_FFAAD404 \n"
 294 "               LDR     R2, [R6,#0x64] \n"
 295 "               ADD     R3, SP, #0x5c \n"
 296 "               STRD    R2, [SP,#0x28] \n"
 297 "               MOV     R2, #0x18 \n"
 298 "               ADD     R1, SP, #0x34 \n"
 299 "               ADD     R0, SP, #0x10 \n"
 300 "               BL      sub_FFB9F08C \n"
 301 "               LDR     R1, [R6,#0x84] \n"
 302 "               LDR     R2, [R6,#0x88] \n"
 303 "               MVN     R3, #1 \n"
 304 "               ADD     R0, SP, #0x60 \n"
 305 "               STMEA   SP, {R0-R3} \n"
 306 "               LDR     R0, =0xB4618 \n"
 307 "               MOV     R3, #0 \n"
 308 "               MOV     R2, #0 \n"
 309 "               MOV     R1, #0x40 \n"
 310 "               BL      sub_FFAAD35C \n"
 311 "               B       loc_FF985DC8 \n"
 312 "loc_FF985D6C: \n"
 313 "               MOV     R1, #1 \n"
 314 "               B       loc_FF98603C \n"
 315 "loc_FF985D74: \n"
 316 "               BL      loc_FF986A28 \n"
 317 "               LDR     R2, [R6,#0x64] \n"
 318 "               ADD     R3, SP, #0x5c \n"
 319 "               MVN     R1, #1 \n"
 320 "               MOV     R0, #0 \n"
 321 "               ADD     R5, SP, #0x1c \n"
 322 "               STMIA   R5, {R0-R3} \n"
 323 "               LDR     R3, [R4,#0x1C] \n"
 324 "               LDR     R1, [R6,#0x84] \n"
 325 "               LDR     R2, [R6,#0x88] \n"
 326 "               ADD     R4, SP, #0x0c \n"
 327 "               ADD     R0, SP, #0x60 \n"
 328 "               STMIA   R4, {R0-R3} \n"
 329 "               MOV     R3, #0 \n"
 330 "               MOV     R1, #0x40 \n"
 331 "               MOV     R2, #0 \n"
 332 "               STMEA   SP, {R1-R3} \n"
 333 "               LDR     R3, =0xB4618 \n"
 334 "               MOV     R1, #0 \n"
 335 "               MOV     R0, #0 \n"
 336 "               BL      sub_FFAAC1CC \n"
 337 "loc_FF985DC8: \n"
 338 "               LDR     R0, [R6,#0x18] \n"
 339 "               LDR     R1, [R6,#0x60] \n"
 340 "               BL      sub_FF83A714 \n"                        // eventproc_export_TakeSemaphore
 341 "               CMP     R0, #9 \n"
 342 "               BEQ     loc_FF985D6C \n"
 343 "               LDR     R0, [SP,#0x5c] \n"
 344 "               CMP     R0, #0 \n"
 345 "               BEQ     loc_FF985DF0 \n"
 346 "loc_FF985DE8: \n"
 347 "               MOV     R1, #1 \n"
 348 "               B       loc_FF986054 \n"
 349 "loc_FF985DF0: \n"
 350 "               LDR     R0, [R6,#0xC] \n"
 351 "               MOV     R4, #5 \n"
 352 "               CMP     R0, #2 \n"
 353 "               MOV     R0, #1 \n"
 354 "               BNE     loc_FF985E1C \n"
 355 "               BL      sub_FFAAD3C4 \n"
 356 "               BL      sub_FFAAD3EC \n"
 357 "               STR     R4, [R6,#0x44] \n"
 358 "               BL      loc_FF986A28 \n"
 359 "               STR     R10, [R6,#0x44] \n"
 360 "               B       loc_FF985E28 \n"
 361 "loc_FF985E1C: \n"
 362 "               BL      sub_FFAAC280 \n"
 363 "               BL      sub_FFAAC2E0 \n"
 364 "               STR     R4, [R6,#0x44] \n"
 365 "loc_FF985E28: \n"
 366 "               STR     R8, [R6,#0x34] \n"
 367 "               B       loc_FF985C88 \n"
 368 "loc_FF985E30: \n"
 369 "               CMP     R5, #1 \n"
 370 "               BNE     loc_FF9860B0 \n"
 371 "               STR     R10, [R6,#0x38] \n"
 372 "               LDR     R0, [R6,#0x6C] \n"
 373 "               LDR     R11, [R4,#0xC] \n"
 374 "               CMP     R0, #0 \n"
 375 "               LDRNE   R9, [SP,#0x58] \n"
 376 "               LDRNE   R10, [SP,#0x54] \n"
 377 "               BNE     loc_FF985F78 \n"
 378 "               LDR     R0, [R6,#0xC] \n"
 379 "               CMP     R0, #2 \n"
 380 "               BNE     loc_FF985ED4 \n"
 381 "               MOV     R1, #0 \n"
 382 "               LDR     R0, =0xFF985B84 \n"
 383 "               BL      sub_FFAAD404 \n"
 384 "               LDR     R2, [R6,#0x64] \n"
 385 "               ADD     R3, SP, #0x5c \n"
 386 "               STRD    R2, [SP,#0x28] \n"
 387 "               MOV     R2, #0x18 \n"
 388 "               ADD     R1, SP, #0x34 \n"
 389 "               ADD     R0, SP, #0x10 \n"
 390 "               BL      sub_FFB9F08C \n"
 391 "               LDR     R1, [R6,#0x84] \n"
 392 "               LDR     R2, [R6,#0x88] \n"
 393 "               MVN     R3, #0 \n"
 394 "               ADD     R0, SP, #0x60 \n"
 395 "               STMEA   SP, {R0-R3} \n"
 396 "               LDR     R0, [SP,#0x58] \n"
 397 "               LDR     R1, [SP,#0x54] \n"
 398 "               LDR     R2, [SP,#0x50] \n"
 399 "               LDR     R3, [SP,#0x4c] \n"
 400 "               BL      sub_FFAAD35C \n"
 401 "               LDR     R0, [R6,#0x18] \n"
 402 "               LDR     R1, [R6,#0x60] \n"
 403 "               BL      sub_FF83A714 \n"                        // eventproc_export_TakeSemaphore
 404 "               CMP     R0, #9 \n"
 405 "               BEQ     loc_FF985D6C \n"
 406 "               MOV     R1, #0 \n"
 407 "               LDR     R0, =0xFF985B78 \n"
 408 "               BL      sub_FFAAD404 \n"
 409 "               B       loc_FF985F3C \n"
 410 "loc_FF985ED4: \n"
 411 "               LDR     R0, [R4,#0x20] \n"
 412 "               LDR     R2, [R6,#0x64] \n"
 413 "               ADD     R3, SP, #0x5c \n"
 414 "               MVN     R1, #0 \n"
 415 "               ADD     R9, SP, #0x1c \n"
 416 "               STMIA   R9, {R0-R3} \n"
 417 "               LDR     R3, [R4,#0x1C] \n"
 418 "               LDR     R1, [R6,#0x84] \n"
 419 "               LDR     R2, [R6,#0x88] \n"
 420 "               ADD     R0, SP, #0x60 \n"
 421 "               ADD     R9, SP, #0x0c \n"
 422 "               STMIA   R9, {R0-R3} \n"
 423 "               LDR     R1, [SP,#0x50] \n"
 424 "               LDR     R2, [SP,#0x54] \n"
 425 "               LDR     R3, [SP,#0x4c] \n"
 426 "               STMFA   SP, {R1,R3} \n"
 427 "               STR     R2, [SP,#0x0] \n"
 428 "               LDMIB   R4, {R0,R1} \n"
 429 "               LDR     R3, [SP,#0x58] \n"
 430 "               MOV     R2, R11 \n"
 431 "               BL      sub_FFAAC1CC \n"
 432 "               LDR     R0, [R6,#0x18] \n"
 433 "               LDR     R1, [R6,#0x60] \n"
 434 "               BL      sub_FF83A714 \n"                        // eventproc_export_TakeSemaphore
 435 "               CMP     R0, #9 \n"
 436 "               BEQ     loc_FF985D6C \n"
 437 "loc_FF985F3C: \n"
 438 "               LDR     R0, [SP,#0x5c] \n"
 439 "               CMP     R0, #0 \n"
 440 "               BNE     loc_FF985DE8 \n"
 441 "               LDR     R0, [R6,#0xC] \n"
 442 "               CMP     R0, #2 \n"
 443 "               MOV     R0, #1 \n"
 444 "               BNE     loc_FF985F60 \n"
 445 "               BL      sub_FFAAD3C4 \n"
 446 "               B       loc_FF985F64 \n"
 447 "loc_FF985F60: \n"
 448 "               BL      sub_FFAAC280 \n"
 449 "loc_FF985F64: \n"
 450 "               LDR     R0, [SP,#0x60] \n"
 451 "               LDR     R1, [SP,#0x58] \n"
 452 "               ADD     R9, R1, R0 \n"
 453 "               LDR     R1, [SP,#0x54] \n"
 454 "               SUB     R10, R1, R0 \n"
 455 "loc_FF985F78: \n"
 456 "               LDR     R0, [R6,#0xC] \n"
 457 "               LDR     R2, [R6,#0x64] \n"
 458 "               CMP     R0, #2 \n"
 459 "               ADD     R3, SP, #0x5c \n"
 460 "               BNE     loc_FF985FCC \n"
 461 "               STRD    R2, [SP,#0x28] \n"
 462 "               MOV     R2, #0x18 \n"
 463 "               ADD     R1, SP, #0x34 \n"
 464 "               ADD     R0, SP, #0x10 \n"
 465 "               BL      sub_FFB9F08C \n"
 466 "               LDR     R1, [R6,#0x84] \n"
 467 "               LDR     R2, [R6,#0x88] \n"
 468 "               LDR     R3, [R6,#0x68] \n"
 469 "               ADD     R0, SP, #0x60 \n"
 470 "               STMEA   SP, {R0-R3} \n"
 471 "               LDR     R2, [SP,#0x50] \n"
 472 "               LDR     R3, [SP,#0x4c] \n"
 473 "               MOV     R1, R10 \n"
 474 "               MOV     R0, R9 \n"
 475 "               BL      sub_FFAAD35C \n"
 476 "               B       loc_FF986024 \n"
 477 "loc_FF985FCC: \n"
 478 "               LDR     R1, [R6,#0x68] \n"
 479 "               LDR     R0, [R4,#0x20] \n"
 480 "               STR     R1, [SP,#0x20] \n"
 481 "               STR     R0, [SP,#0x1c] \n"
 482 "               STR     R2, [SP,#0x24] \n"
 483 "               STR     R3, [SP,#0x28] \n"
 484 "               LDR     R3, [R4,#0x1C] \n"
 485 "               LDR     R1, [R6,#0x84] \n"
 486 "               LDR     R2, [R6,#0x88] \n"
 487 "               ADD     R0, SP, #0x60 \n"
 488 "               STR     R2, [SP,#0x14] \n"
 489 "               LDR     R2, [SP,#0x50] \n"
 490 "               STR     R1, [SP,#0x10] \n"
 491 "               STR     R3, [SP,#0x18] \n"
 492 "               LDR     R3, [SP,#0x4c] \n"
 493 "               STR     R0, [SP,#0x0c] \n"
 494 "               STMFA   SP, {R2,R3} \n"
 495 "               STR     R10, [SP,#0x0] \n"
 496 "               LDMIB   R4, {R0,R1} \n"
 497 "               MOV     R3, R9 \n"
 498 "               MOV     R2, R11 \n"
 499 "               BL      sub_FFAAC1CC \n"
 500 "loc_FF986024: \n"
 501 "               LDR     R0, [R6,#0x18] \n"
 502 "               LDR     R1, [R6,#0x60] \n"
 503 "               BL      sub_FF83A714 \n"                        // eventproc_export_TakeSemaphore
 504 "               CMP     R0, #9 \n"
 505 "               BNE     loc_FF986044 \n"
 506 "               MOV     R1, #0 \n"
 507 "loc_FF98603C: \n"
 508 "               MOV     R0, #0x90000 \n"
 509 "               B       loc_FF986058 \n"
 510 "loc_FF986044: \n"
 511 "               LDR     R0, [SP,#0x5c] \n"
 512 "               CMP     R0, #0 \n"
 513 "               BEQ     loc_FF986060 \n"
 514 "               MOV     R1, #0 \n"
 515 "loc_FF986054: \n"
 516 "               MOV     R0, #0xA0000 \n"
 517 "loc_FF986058: \n"
 518 "               BL      sub_FF985B18 \n"
 519 "               B       loc_FF985C88 \n"
 520 "loc_FF986060: \n"
 521 "               LDR     R0, [R6,#0xC] \n"
 522 "               CMP     R0, #2 \n"
 523 "               MOV     R0, #0 \n"
 524 "               BNE     loc_FF986078 \n"
 525 "               BL      sub_FFAAD3C4 \n"
 526 "               B       loc_FF98607C \n"
 527 "loc_FF986078: \n"
 528 "               BL      sub_FFAAC280 \n"
 529 "loc_FF98607C: \n"
 530 "               LDR     R0, [SP,#0x58] \n"
 531 "               LDR     R1, [SP,#0x60] \n"
 532 "               BL      sub_FFAF2C6C \n"
 533 "               LDR     R0, [R6,#0x68] \n"
 534 
 535 "               LDR     R3, =0x71B0 \n"                         // 71b0
 536 "               ADD     R1, R0, #1 \n"
 537 "               STR     R1, [R6,#0x68] \n"
 538 "               STR     R3, [SP,#0x0] \n"
 539 "               LDR     R0, [R6,#0x64] \n"
 540 "               SUB     R3, R3, #4 \n"                          // 4
 541 "               AND     R2, R0, #0xFF \n"
 542 "               LDR     R0, [SP,#0x60] \n"
 543 "               BL      sub_FFAF0958 \n"
 544 
 545 "               LDR R0, =0x71AC \n"                             // added  (71b0 - 4)
 546 "               BL              set_quality \n"                 // added
 547 
 548 "loc_FF9860B0: \n"
 549 "               CMP     R5, #1 \n"
 550 "               LDRNEH  R0, [R6,#6] \n"
 551 "               CMPNE   R0, #3 \n"
 552 "               BNE     loc_FF985C88 \n"
 553 "               LDR     R0, [R6,#0x6C] \n"
 554 "               ADD     R0, R0, #1 \n"
 555 "               STR     R0, [R6,#0x6C] \n"
 556 "               LDRH    R1, [R6,#6] \n"
 557 "               CMP     R1, #3 \n"
 558 "               LDRNE   R1, [R6,#0x54] \n"
 559 "               LDREQ   R1, =0x3E9 \n"
 560 "               MUL     R0, R1, R0 \n"
 561 "               LDREQ   R1, =0x1770 \n"
 562 "               LDRNE   R1, [R6,#0x50] \n"
 563 "               BL      sub_FFBA16EC \n"
 564 "               MOV     R4, R0 \n"
 565 "               BL      sub_FFAF2FEC \n"
 566 "               LDR     R0, [R6,#0x8C] \n"
 567 "               CMP     R0, R4 \n"
 568 "               BNE     loc_FF98610C \n"
 569 "               LDR     R0, [R6,#0x3C] \n"
 570 "               CMP     R0, #1 \n"
 571 "               BNE     loc_FF986120 \n"
 572 "loc_FF98610C: \n"
 573 "               LDR     R1, [R6,#0x98] \n"
 574 "               MOV     R0, R4 \n"
 575 "               BLX     R1 \n"
 576 "               STR     R4, [R6,#0x8C] \n"
 577 "               STR     R8, [R6,#0x3C] \n"
 578 "loc_FF986120: \n"
 579 "               STR     R8, [R6,#0x38] \n"
 580 "               B       loc_FF985C88 \n"
 581 
 582 "loc_FF986A28: \n"
 583 "               B       sub_FF986A28 \n"
 584         );
 585 }

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