root/platform/ixus850_sd800/sub/100e/capt_seq.c

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

DEFINITIONS

This source file includes following definitions.
  1. sub_FF99BA84_my
  2. sub_FF998960_my
  3. sub_FF998A50_my
  4. capt_seq_task
  5. exp_drv_task
  6. sub_FF9291A8_my
  7. sub_FF8C6DBC_my

   1 #include "lolevel.h"
   2 #include "platform.h"
   3 #include "core.h"
   4 
   5 static long *nrflag = (long*)0x6ACC;
   6 
   7 #include "../../../generic/capt_seq.c"
   8 
   9 void __attribute__((naked,noinline)) sub_FF99BA84_my(long p)
  10 {
  11     asm volatile (
  12                 "STMFD   SP!, {R4,LR}\n"
  13                 "MOV     R4, R0\n"
  14                 "SUB     SP, SP, #0xC\n"
  15                 "BL      sub_FF99C48C\n"
  16 //                "MOVL    R1, 0xFFFFFFFF\n"
  17                                 "MVN     R1, #0\n"
  18                 "BL      sub_FF820FC8\n" // ClearEventFlag
  19                 "MOV     R0, #0x120\n" // MOV R0, #0x122 --> MOV #0x120 + ADD #0x2
  20                 "ADD     R0, R0, #0x2\n"
  21                 "ADD     R1, SP, #4\n"
  22                 "MOV     R2, #4\n"
  23                 "BL      sub_FF825A14\n" // GetPropertyCase
  24                 "TST     R0, #1\n"
  25                 "BEQ     loc_FF99BAC4\n"
  26                 "MOV     R1, #0x1D0\n"
  27                 "LDR     R0, =0xFF99B900\n" // aCaptureseq_c
  28                 "BL      sub_FF813E84\n" // DebugAssert
  29  "loc_FF99BAC4:\n"
  30                 "LDR     R3, =0xB7CA0\n"
  31                 "LDR     R2, =0xB7D60\n"
  32                 "LDR     R0, [R3,#0x84]\n"
  33                 "LDRSH   R1, [R2,#0xE]\n"
  34                 "BL      sub_FF8B0144\n"
  35                 "MOV     R0, R4\n"
  36                 "BL      sub_FF99B884\n"
  37                 "BL      wait_until_remote_button_is_released\n"
  38                                 "BL      capt_seq_hook_set_nr\n" // +
  39                 "LDR     R3, =0x6AD0\n"
  40                 "LDR     R0, [R3]\n"
  41 
  42                 "B       sub_FF99BAE8\n"  // ---> jump to end of function in ROM
  43     );
  44 }
  45 
  46 void __attribute__((naked,noinline)) sub_FF998960_my(long p)
  47 {
  48     asm volatile (
  49                 "STMFD   SP!, {R4,R5,LR}\n"
  50                 "LDR     R3, =0xB7CA0\n"
  51                 "LDR     R4, [R0,#0xC]\n"
  52                 "LDR     R1, [R3,#0x28]\n"
  53                 "LDR     R2, [R4,#8]\n"
  54                 "CMP     R1, #0\n"
  55                 "ORR     R2, R2, #1\n"
  56                 "STR     R2, [R4,#8]\n"
  57                 "BNE     loc_FF9989B4\n"
  58                 "MOV     R0, #0xC\n"
  59                 "BL      sub_FF9A2710\n"
  60                 "TST     R0, #1\n"
  61                 "BEQ     loc_FF9989B4\n"
  62                 "LDR     R3, [R4,#8]\n"
  63                 "MOV     R0, #1\n"
  64                 "ORR     R3, R3, #0x40000000\n"
  65                 "STR     R3, [R4,#8]\n"
  66  "loc_FF9989A4:\n"
  67                 "MOV     R2, R4\n"
  68                 "MOV     R1, #1\n"
  69                 "LDMFD   SP!, {R4,R5,LR}\n"
  70                 "B       sub_FF9971EC\n"
  71  "loc_FF9989B4:\n"
  72                 "LDR     R5, =0xB7CA0\n"
  73                 "LDR     R3, [R5,#0x28]\n"
  74                 "CMP     R3, #0\n"
  75                 "BNE     loc_FF9989CC\n"
  76                 "MOV     R0, #2\n"
  77                 "BL      sub_FFB0628C\n"
  78  "loc_FF9989CC:\n"
  79                 "BL      sub_FF999480\n" // Set_CMD25Write_26
  80                 "LDR     R3, [R5,#0x28]\n"
  81                 "CMP     R3, #0\n"
  82                 "BNE     loc_FF998A10\n"
  83                 "MOV     R0, R4\n"
  84                 "BL      sub_FF99A608\n"
  85                 "TST     R0, #1\n"
  86                 "BNE     loc_FF9989A4\n"
  87                 "BL      sub_FF9DA8C8\n"
  88                 "BL      sub_FF825C10\n"
  89                 "STR     R0, [R4,#0x14]\n"
  90                 "MOV     R0, R4\n"
  91                 "BL      sub_FF99B96C\n"
  92                 "BL      sub_FF99C318\n"
  93                 "MOV     R0, R4\n"
  94                 "BL      sub_FF99BA84_my\n"  //---------->
  95                 "BL      capt_seq_hook_raw_here\n"  // +
  96                 "B       loc_FF998A24\n"
  97  "loc_FF998A10:\n"
  98                 "LDR     R3, =0x6AB0\n"
  99                 "LDR     R2, [R3]\n"
 100                 "CMP     R2, #0\n"
 101                 "MOVNE   R0, #0x1D\n"
 102                 "MOVEQ   R0, #0\n"
 103  "loc_FF998A24:\n"
 104                 "MOV     R1, #1\n"
 105                 "MOV     R2, R4\n"
 106                 "BL      sub_FF9971EC\n"
 107                 "BL      sub_FF99BE04\n"
 108                 "CMP     R0, #0\n"
 109                 "LDRNE   R3, [R4,#8]\n"
 110                 "ORRNE   R3, R3, #0x2000\n"
 111                 "STRNE   R3, [R4,#8]\n"
 112                 "LDMFD   SP!, {R4,R5,PC}\n"
 113     );
 114 }
 115 
 116 
 117 void __attribute__((naked,noinline)) sub_FF998A50_my(){
 118     asm volatile (
 119                  "STMFD   SP!, {R4,LR}\n"
 120                  "BL      sub_FF9985E8\n"
 121                  "LDR     R3, =0xB7CA0\n"
 122                  "LDR     R2, [R3,#0x28]\n"
 123                  "CMP     R2, #0\n"
 124                  "MOV     R4, R0\n"
 125                  "MOV     R0, #0xC\n"
 126                  "BEQ     loc_FF998A98\n"
 127                  "BL      sub_FF9A2710\n"
 128                  "TST     R0, #1\n"
 129                  "BEQ     loc_FF998A98\n"
 130                  "LDR     R3, [R4,#8]\n"
 131                  "LDR     R2, =0x6AB0\n"
 132                  "ORR     R3, R3, #0x40000000\n"
 133                  "MOV     R1, #1\n"
 134                  "STR     R1, [R2]\n"
 135                  "STR     R3, [R4,#8]\n"
 136                  "LDMFD   SP!, {R4,PC}\n"
 137  "loc_FF998A98:\n"
 138                  "BL      sub_FF9DA8C8\n"
 139                  "BL      sub_FF825C10\n"
 140                  "STR     R0, [R4,#0x14]\n"
 141                  "MOV     R0, R4\n"
 142                  "BL      sub_FF99BA84_my\n"  //--------->
 143                  "BL      capt_seq_hook_raw_here\n"  // +
 144                  "TST     R0, #1\n"
 145                  "LDRNE   R3, =0x6AB0\n"
 146                  "MOVNE   R2, #1\n"
 147                  "STRNE   R2, [R3]\n"
 148                  "LDMFD   SP!, {R4,PC}\n"
 149  );
 150 }
 151 
 152 
 153 void __attribute__((naked,noinline)) capt_seq_task()
 154 {
 155         asm volatile (
 156                 "STMFD   SP!, {R4,LR}\n"
 157                 "SUB     SP, SP, #4\n"
 158                 "MOV     R4, SP\n"
 159                 "B       loc_FF998FA8\n"
 160  "loc_FF998E2C:\n"
 161                 "LDR     R2, [SP]\n"
 162                 "LDR     R3, [R2]\n"
 163                 "MOV     R0, R2\n"
 164                 "CMP     R3, #0x15\n"
 165                 "LDRLS   PC, [PC,R3,LSL#2]\n"
 166                 "B       loc_FF998F7C\n"
 167                 ".long loc_FF998E9C\n"
 168                 ".long loc_FF998EBC\n"
 169                 ".long loc_FF998ED0\n"
 170                 ".long loc_FF998EE4\n"
 171                 ".long loc_FF998EDC\n"
 172                 ".long loc_FF998EEC\n"
 173                 ".long loc_FF998EF4\n"
 174                 ".long loc_FF998F00\n"
 175                 ".long loc_FF998F08\n"
 176                 ".long loc_FF998F14\n"
 177                 ".long loc_FF998F1C\n"
 178                 ".long loc_FF998F24\n"
 179                 ".long loc_FF998F2C\n"
 180                 ".long loc_FF998F34\n"
 181                 ".long loc_FF998F3C\n"
 182                 ".long loc_FF998F48\n"
 183                 ".long loc_FF998F50\n"
 184                 ".long loc_FF998F58\n"
 185                 ".long loc_FF998F60\n"
 186                 ".long loc_FF998F6C\n"
 187                 ".long loc_FF998F74\n"
 188                 ".long loc_FF998F90\n"
 189  "loc_FF998E9C:\n"
 190                                 "BL      sub_FF9994A8\n" // ; jumptable FF998E3C case 0
 191 // only do quick press hack if overrides are active
 192 "                BL      captseq_hack_override_active\n" // returns 1 if tv or sv override in effect
 193 "                STR     R0,[SP,#-4]!\n" // push return value
 194                                 "BL      shooting_expo_param_override\n"   // +
 195                                 "BL      sub_FF996C88\n"
 196                                 "LDR     R3, =0xB7CA0\n"
 197 "                LDR     R0,[SP],#4\n" // pop override hack
 198 "                CMP     R0, #1\n"     // +
 199 "                MOVEQ   R0, #0\n"     // +
 200 "                STREQ   R0, [R3,#0x28]\n"  // fixes overrides behavior at short shutter press
 201 "                LDRNE   R0, [R3,#0x28]\n" // modified NE
 202 "                CMPNE   R0, #0\n"         // modified NE
 203                                 "BEQ     loc_FF998F8C\n"
 204                                 "BL      sub_FF998A50_my\n"  //--------->
 205                                 "B       loc_FF998F8C\n"
 206  "loc_FF998EBC:\n"
 207                                         
 208                                 "BL      sub_FF998960_my\n" //----------> ; jumptable FF998E3C case 1
 209 
 210  "loc_FF998EC0:\n"
 211                                 "LDR     R2, =0xB7CA0\n"
 212                 "MOV     R3, #0\n"
 213                                 "STR     R3, [R2,#0x28]\n"
 214                                 "B       loc_FF998F8C\n"
 215  "loc_FF998ED0:\n"
 216                                 "MOV     R0, #1\n"       // ; jumptable FF998E3C case 2
 217                                 "BL      sub_FF9996E8\n"
 218                                 "B       loc_FF998F8C\n"
 219  "loc_FF998EDC:\n"
 220                                 "BL      sub_FF9990A0\n" //; jumptable FF998E3C case 4
 221                                 "B       loc_FF998EC0\n"
 222  "loc_FF998EE4:\n"
 223                                 "BL      sub_FF999460\n" // BackLightDrv_LcdBackLightOff_4 ; jumptable FF998E3C case 3
 224                                 "B       loc_FF998EC0\n"
 225  "loc_FF998EEC:\n"
 226                                 "BL      sub_FF999470\n" // ; jumptable FF998E3C case 5
 227                                 "B       loc_FF998F8C\n"
 228  "loc_FF998EF4:\n"
 229                                 "BL      sub_FF9995C8\n" //; jumptable FF998E3C case 6
 230                                 "BL      sub_FF996C88\n"
 231                                 "B       loc_FF998F8C\n"
 232  "loc_FF998F00:\n"
 233                                 "BL      sub_FF998B2C\n" //; jumptable FF998E3C case 7
 234                                 "B       loc_FF998F8C\n"
 235  "loc_FF998F08:\n"
 236                                 "BL      sub_FF99963C\n" // ; jumptable FF998E3C case 8
 237                                 "BL      sub_FF996C88\n"
 238                                 "B       loc_FF998F8C\n"
 239  "loc_FF998F14:\n"
 240                                 "BL      sub_FF999460\n" // BackLightDrv_LcdBackLightOff_4 ; jumptable FF998E3C case 9
 241                                 "B       loc_FF998F8C\n"
 242  "loc_FF998F1C:\n"
 243                                 "BL      sub_FF99AD1C\n" //; jumptable FF998E3C case 10
 244                                 "B       loc_FF998F8C\n"
 245  "loc_FF998F24:\n"
 246                                 "BL      sub_FF99AEF0\n" // ; jumptable FF998E3C case 11
 247                                 "B       loc_FF998F8C\n"
 248  "loc_FF998F2C:\n"
 249                                 "BL      sub_FF99AF84\n" // ; jumptable FF998E3C case 12
 250                                 "B       loc_FF998F8C\n"
 251  "loc_FF998F34:\n"
 252                                 "BL      sub_FF99B020\n" //  ; jumptable FF998E3C case 13
 253                                 "B       loc_FF998F8C\n"
 254  "loc_FF998F3C:\n"
 255                                 "MOV     R0, #0\n"       // ; jumptable FF998E3C case 14
 256                                 "BL      sub_FF99B28C\n"
 257                                 "B       loc_FF998F8C\n"
 258  "loc_FF998F48:\n"
 259                                 "BL      sub_FF99B460\n" // ; jumptable FF998E3C case 15
 260                                 "B       loc_FF998F8C\n"
 261  "loc_FF998F50:\n"
 262                                 "BL      sub_FF99B4F8\n" // ; jumptable FF998E3C case 16
 263                                 "B       loc_FF998F8C\n"
 264  "loc_FF998F58:\n"
 265                                 "BL      sub_FF99B5B4\n" // ; jumptable FF998E3C case 17
 266                                 "B       loc_FF998F8C\n"
 267  "loc_FF998F60:\n"
 268                                 "BL      sub_FF999830\n" // ; jumptable FF998E3C case 18
 269                                 "BL      sub_FF998884\n"
 270                                 "B       loc_FF998F8C\n"
 271  "loc_FF998F6C:\n"
 272                                 "BL      sub_FF99B160\n" // ; jumptable FF998E3C case 19
 273                                 "B       loc_FF998F8C\n"
 274  "loc_FF998F74:\n"
 275                                 "BL      sub_FF99B1B8\n" // ; jumptable FF998E3C case 20
 276                                 "B       loc_FF998F8C\n"
 277  "loc_FF998F7C:\n"
 278                                 "MOV     R1, #0x4E0\n" // ; default
 279                                 "LDR     R0, =0xFF9986E0\n" // aShoottask_c
 280                                 "ADD     R1, R1, #7\n"
 281                                 "BL      sub_FF813E84\n" // DebugAssert
 282  "loc_FF998F8C:\n"
 283                                 "LDR     R2, [SP]\n"
 284  "loc_FF998F90:\n"
 285                                 "LDR     R3, =0x8C424\n" // ; jumptable FF998E3C case 21
 286                                 "LDR     R1, [R2,#4]\n"
 287                                 "LDR     R0, [R3]\n"
 288                                 "BL      sub_FF820E2C\n" // SetEventFlag
 289                                 "LDR     R0, [SP]\n"
 290                                 "BL      sub_FF99875C\n"
 291  "loc_FF998FA8:\n"
 292                                 "LDR     R3, =0x8C428\n"
 293                                 "MOV     R1, R4\n"
 294                                 "LDR     R0, [R3]\n"
 295                                 "MOV     R2, #0\n"
 296                                 "BL      sub_FF821544\n" // ReceiveMessageQueue
 297                                 "TST     R0, #1\n"
 298                                 "BEQ     loc_FF998E2C\n"
 299                                 "LDR     R0, =0xFF9986E0\n" // aShoottask_c
 300                                 "MOV     R1, #0x410\n"
 301                                 "ADD     R1, R1, #9\n"
 302                                 "BL      sub_FF813E84\n" // DebugAssert
 303                                 "BL      sub_FF822AA0\n" // ExitTask
 304                 "ADD     SP, SP, #4\n"
 305                 "LDMFD   SP!, {R4,PC}\n"
 306         );
 307 }
 308 
 309 /*************************************************************/
 310 //** exp_drv_task @ 0xFF92BF50 - 0xFF92C450, length=321
 311 void __attribute__((naked,noinline)) exp_drv_task() {
 312 asm volatile (
 313 "    STMFD   SP!, {R4-R8,LR} \n"
 314 "    SUB     SP, SP, #0x20 \n"
 315 "    ADD     R7, SP, #4 \n"
 316 "    B       loc_FF92C40C \n"
 317 
 318 "loc_FF92BF60:\n"
 319 "    CMP     R2, #0x22 \n"
 320 "    BNE     loc_FF92BF78 \n"
 321 "    LDR     R0, [R12, #0x8C] \n"
 322 "    MOV     LR, PC \n"
 323 "    LDR     PC, [R12, #0x88] \n"
 324 "    B       loc_FF92BFDC \n"
 325 
 326 "loc_FF92BF78:\n"
 327 "    CMP     R2, #0x1D \n"
 328 "    BNE     loc_FF92BF8C \n"
 329 "    MOV     R0, R12 \n"
 330 "    BL      sub_FF92BE20 \n"
 331 "    B       loc_FF92BFCC \n"
 332 
 333 "loc_FF92BF8C:\n"
 334 "    CMP     R2, #0x1E \n"
 335 "    BNE     loc_FF92BFA0 \n"
 336 "    MOV     R0, R12 \n"
 337 "    BL      sub_FF92BE7C \n"
 338 "    B       loc_FF92BFCC \n"
 339 
 340 "loc_FF92BFA0:\n"
 341 "    SUB     R3, R2, #0x1F \n"
 342 "    CMP     R3, #1 \n"
 343 "    BHI     loc_FF92BFB8 \n"
 344 "    MOV     R0, R12 \n"
 345 "    BL      sub_FF92BED8 \n"
 346 "    B       loc_FF92BFCC \n"
 347 
 348 "loc_FF92BFB8:\n"
 349 "    CMP     R2, #0x21 \n"
 350 "    BNE     loc_FF92BFE8 \n"
 351 "    BL      sub_FF8C7134 \n"
 352 "    BL      sub_FF8CA228 \n"
 353 "    BL      sub_FF8C9460 \n"
 354 
 355 "loc_FF92BFCC:\n"
 356 "    LDR     R3, [SP, #4] \n"
 357 "    LDR     R0, [R3, #0x8C] \n"
 358 "    MOV     LR, PC \n"
 359 "    LDR     PC, [R3, #0x88] \n"
 360 
 361 "loc_FF92BFDC:\n"
 362 "    LDR     R0, [SP, #4] \n"
 363 "    BL      sub_FF927C84 \n"
 364 "    B       loc_FF92C40C \n"
 365 
 366 "loc_FF92BFE8:\n"
 367 "    CMP     R2, #0xD \n"
 368 "    MOV     R8, #1 \n"
 369 "    BNE     loc_FF92C058 \n"
 370 "    LDR     R1, [R12, #0x7C] \n"
 371 "    ADD     R1, R1, R1, LSL#1 \n"
 372 "    ADD     R1, R12, R1, LSL#2 \n"
 373 "    ADD     R6, SP, #0x14 \n"
 374 "    SUB     R1, R1, #8 \n"
 375 "    MOV     R2, #0xC \n"
 376 "    MOV     R0, R6 \n"
 377 "    BL      sub_FFB5980C /*_memcpy_FW*/ \n"
 378 "    LDR     R0, [SP, #4] \n"
 379 "    BL      sub_FF92A680 \n"
 380 "    LDR     R3, [SP, #4] \n"
 381 "    LDR     R1, [R3, #0x7C] \n"
 382 "    LDR     R2, [R3, #0x8C] \n"
 383 "    ADD     R0, R3, #4 \n"
 384 "    MOV     LR, PC \n"
 385 "    LDR     PC, [R3, #0x88] \n"
 386 "    LDR     R0, [SP, #4] \n"
 387 "    BL      sub_FF92A950 \n"
 388 "    LDR     R3, [SP, #4] \n"
 389 "    ADD     R0, R3, #4 \n"
 390 "    LDR     R1, [R3, #0x7C] \n"
 391 "    LDR     R2, [R3, #0x94] \n"
 392 "    MOV     LR, PC \n"
 393 "    LDR     PC, [R3, #0x90] \n"
 394 "    B       loc_FF92C3A8 \n"
 395 
 396 "loc_FF92C058:\n"
 397 "    SUB     R3, R2, #0xE \n"
 398 "    CMP     R3, #1 \n"
 399 "    BHI     loc_FF92C114 \n"
 400 "    ADD     R6, SP, #0x14 \n"
 401 "    ADD     R5, SP, #8 \n"
 402 "    MOV     R0, R12 \n"
 403 "    MOV     R1, R6 \n"
 404 "    MOV     R2, R5 \n"
 405 "    BL      sub_FF92AA44 \n"
 406 "    MOV     R4, R0 \n"
 407 "    CMP     R4, #5 \n"
 408 "    CMPNE   R4, #1 \n"
 409 "    BNE     loc_FF92C0AC \n"
 410 "    LDR     R12, [SP, #4] \n"
 411 "    MOV     R0, R5 \n"
 412 "    LDR     R1, [R12, #0x7C] \n"
 413 "    MOV     R2, R4 \n"
 414 "    LDR     R3, [R12, #0x8C] \n"
 415 "    MOV     LR, PC \n"
 416 "    LDR     PC, [R12, #0x88] \n"
 417 "    B       loc_FF92C0E4 \n"
 418 
 419 "loc_FF92C0AC:\n"
 420 "    CMP     R4, #6 \n"
 421 "    CMPNE   R4, #2 \n"
 422 "    BNE     loc_FF92C0F4 \n"
 423 "    LDR     R12, [SP, #4] \n"
 424 "    MOV     R0, R5 \n"
 425 "    MOV     R1, R8 \n"
 426 "    MOV     R2, R4 \n"
 427 "    LDR     R3, [R12, #0x8C] \n"
 428 "    MOV     LR, PC \n"
 429 "    LDR     PC, [R12, #0x88] \n"
 430 "    MOV     R1, R6 \n"
 431 "    LDR     R0, [SP, #4] \n"
 432 "    MOV     R2, R5 \n"
 433 "    BL      sub_FF92BA8C \n"
 434 
 435 "loc_FF92C0E4:\n"
 436 "    MOV     R1, R4 \n"
 437 "    LDR     R0, [SP, #4] \n"
 438 "    BL      sub_FF92BDB4 \n"
 439 "    B       loc_FF92C3A8 \n"
 440 
 441 "loc_FF92C0F4:\n"
 442 "    LDR     R12, [SP, #4] \n"
 443 "    MOV     R2, R4 \n"
 444 "    ADD     R0, R12, #4 \n"
 445 "    LDR     R1, [R12, #0x7C] \n"
 446 "    LDR     R3, [R12, #0x8C] \n"
 447 "    MOV     LR, PC \n"
 448 "    LDR     PC, [R12, #0x88] \n"
 449 "    B       loc_FF92C3A8 \n"
 450 
 451 "loc_FF92C114:\n"
 452 "    SUB     R3, R2, #0x19 \n"
 453 "    CMP     R3, #1 \n"
 454 "    BHI     loc_FF92C16C \n"
 455 "    LDR     R1, [R12, #0x7C] \n"
 456 "    ADD     R1, R1, R1, LSL#1 \n"
 457 "    ADD     R1, R12, R1, LSL#2 \n"
 458 "    ADD     R6, SP, #0x14 \n"
 459 "    SUB     R1, R1, #8 \n"
 460 "    MOV     R2, #0xC \n"
 461 "    MOV     R0, R6 \n"
 462 "    BL      sub_FFB5980C /*_memcpy_FW*/ \n"
 463 "    LDR     R0, [SP, #4] \n"
 464 "    BL      sub_FF929B34 \n"
 465 "    LDR     R3, [SP, #4] \n"
 466 "    ADD     R0, R3, #4 \n"
 467 "    LDR     R1, [R3, #0x7C] \n"
 468 "    LDR     R2, [R3, #0x8C] \n"
 469 "    MOV     LR, PC \n"
 470 "    LDR     PC, [R3, #0x88] \n"
 471 "    LDR     R0, [SP, #4] \n"
 472 "    BL      sub_FF929E54 \n"
 473 "    B       loc_FF92C3A8 \n"
 474 
 475 "loc_FF92C16C:\n"
 476 "    ADD     R6, SP, #0x14 \n"
 477 "    ADD     R1, R12, #4 \n"
 478 "    MOV     R2, #0xC \n"
 479 "    MOV     R0, R6 \n"
 480 "    BL      sub_FFB5980C /*_memcpy_FW*/ \n"
 481 "    LDR     R12, [SP, #4] \n"
 482 "    LDR     R3, [R12] \n"
 483 "    MOV     R2, R12 \n"
 484 "    CMP     R3, #0x1C \n"
 485 "    LDRLS   PC, [PC, R3, LSL#2] \n"
 486 "    B       loc_FF92C394 \n"
 487 "    .long   loc_FF92C20C \n"
 488 "    .long   loc_FF92C218 \n"
 489 "    .long   loc_FF92C224 \n"
 490 "    .long   loc_FF92C224 \n"
 491 "    .long   loc_FF92C20C \n"
 492 "    .long   loc_FF92C218 \n"
 493 "    .long   loc_FF92C224 \n"
 494 "    .long   loc_FF92C224 \n"
 495 "    .long   loc_FF92C248 \n"
 496 "    .long   loc_FF92C248 \n"
 497 "    .long   loc_FF92C368 \n"
 498 "    .long   loc_FF92C374 \n"
 499 "    .long   loc_FF92C384 \n"
 500 "    .long   loc_FF92C394 \n"
 501 "    .long   loc_FF92C394 \n"
 502 "    .long   loc_FF92C394 \n"
 503 "    .long   loc_FF92C230 \n"
 504 "    .long   loc_FF92C23C \n"
 505 "    .long   loc_FF92C258 \n"
 506 "    .long   loc_FF92C264 \n"
 507 "    .long   loc_FF92C29C \n"
 508 "    .long   loc_FF92C2D4 \n"
 509 "    .long   loc_FF92C30C \n"
 510 "    .long   loc_FF92C344 \n"
 511 "    .long   loc_FF92C344 \n"
 512 "    .long   loc_FF92C394 \n"
 513 "    .long   loc_FF92C394 \n"
 514 "    .long   loc_FF92C350 \n"
 515 "    .long   loc_FF92C35C \n"
 516 
 517 "loc_FF92C20C:\n"
 518 "    MOV     R0, R2 \n"
 519 "    BL      sub_FF928534 \n"
 520 "    B       loc_FF92C390 \n"
 521 
 522 "loc_FF92C218:\n"
 523 "    MOV     R0, R2 \n"
 524 "    BL      sub_FF9287D8 \n"
 525 "    B       loc_FF92C390 \n"
 526 
 527 "loc_FF92C224:\n"
 528 "    MOV     R0, R2 \n"
 529 "    BL      sub_FF928A4C \n"
 530 "    B       loc_FF92C390 \n"
 531 
 532 "loc_FF92C230:\n"
 533 "    MOV     R0, R2 \n"
 534 "    BL      sub_FF928D48 \n"
 535 "    B       loc_FF92C390 \n"
 536 
 537 "loc_FF92C23C:\n"
 538 "    MOV     R0, R2 \n"
 539 "    BL      sub_FF928FAC \n"
 540 "    B       loc_FF92C390 \n"
 541 
 542 "loc_FF92C248:\n"
 543 "    MOV     R0, R2 \n"
 544 "    BL      sub_FF9291A8_my \n"  // --> Patched. Old value = 0xFF9291A8.
 545 "    MOV     R8, #0 \n"
 546 "    B       loc_FF92C390 \n"
 547 
 548 "loc_FF92C258:\n"
 549 "    MOV     R0, R2 \n"
 550 "    BL      sub_FF929304 \n"
 551 "    B       loc_FF92C390 \n"
 552 
 553 "loc_FF92C264:\n"
 554 "    LDRH    R1, [R2, #4] \n"
 555 "    LDR     R3, =0x66830 \n"
 556 "    STRH    R1, [SP, #0x14] \n"
 557 "    LDRH    R1, [R3, #6] \n"
 558 "    STRH    R1, [SP, #0x1A] \n"
 559 "    LDRH    R1, [R3, #2] \n"
 560 "    STRH    R1, [SP, #0x16] \n"
 561 "    LDRH    R3, [R3, #4] \n"
 562 "    STRH    R3, [SP, #0x18] \n"
 563 "    MOV     R0, R2 \n"
 564 "    LDRH    R2, [R2, #0xC] \n"
 565 "    STRH    R2, [SP, #0x1C] \n"
 566 "    BL      sub_FF929600 \n"
 567 "    B       loc_FF92C390 \n"
 568 
 569 "loc_FF92C29C:\n"
 570 "    MOV     R0, R2 \n"
 571 "    LDRH    R2, [R2, #4] \n"
 572 "    LDR     R3, =0x66830 \n"
 573 "    STRH    R2, [SP, #0x14] \n"
 574 "    LDRH    R2, [R3, #8] \n"
 575 "    STRH    R2, [SP, #0x1C] \n"
 576 "    LDRH    R1, [R3, #2] \n"
 577 "    STRH    R1, [SP, #0x16] \n"
 578 "    LDRH    R2, [R3, #4] \n"
 579 "    STRH    R2, [SP, #0x18] \n"
 580 "    LDRH    R3, [R3, #6] \n"
 581 "    STRH    R3, [SP, #0x1A] \n"
 582 "    BL      sub_FF929728 \n"
 583 "    B       loc_FF92C390 \n"
 584 
 585 "loc_FF92C2D4:\n"
 586 "    LDR     R3, =0x66830 \n"
 587 "    LDRH    R1, [R3] \n"
 588 "    STRH    R1, [SP, #0x14] \n"
 589 "    MOV     R0, R2 \n"
 590 "    LDRH    R2, [R2, #6] \n"
 591 "    STRH    R2, [SP, #0x16] \n"
 592 "    LDRH    R2, [R3, #8] \n"
 593 "    STRH    R2, [SP, #0x1C] \n"
 594 "    LDRH    R1, [R3, #4] \n"
 595 "    STRH    R1, [SP, #0x18] \n"
 596 "    LDRH    R3, [R3, #6] \n"
 597 "    STRH    R3, [SP, #0x1A] \n"
 598 "    BL      sub_FF9297EC \n"
 599 "    B       loc_FF92C390 \n"
 600 
 601 "loc_FF92C30C:\n"
 602 "    LDR     R3, =0x66830 \n"
 603 "    LDRH    R1, [R3, #6] \n"
 604 "    STRH    R1, [SP, #0x1A] \n"
 605 "    LDRH    R1, [R3] \n"
 606 "    STRH    R1, [SP, #0x14] \n"
 607 "    LDRH    R1, [R3, #2] \n"
 608 "    STRH    R1, [SP, #0x16] \n"
 609 "    LDRH    R3, [R3, #4] \n"
 610 "    STRH    R3, [SP, #0x18] \n"
 611 "    MOV     R0, R2 \n"
 612 "    LDRH    R2, [R2, #0xC] \n"
 613 "    STRH    R2, [SP, #0x1C] \n"
 614 "    BL      sub_FF9298A4 \n"
 615 "    B       loc_FF92C390 \n"
 616 
 617 "loc_FF92C344:\n"
 618 "    MOV     R0, R2 \n"
 619 "    BL      sub_FF929954 \n"
 620 "    B       loc_FF92C390 \n"
 621 
 622 "loc_FF92C350:\n"
 623 "    MOV     R0, R2 \n"
 624 "    BL      sub_FF929FA4 \n"
 625 "    B       loc_FF92C390 \n"
 626 
 627 "loc_FF92C35C:\n"
 628 "    MOV     R0, R2 \n"
 629 "    BL      sub_FF92A1A0 \n"
 630 "    B       loc_FF92C390 \n"
 631 
 632 "loc_FF92C368:\n"
 633 "    MOV     R0, R2 \n"
 634 "    BL      sub_FF92A35C \n"
 635 "    B       loc_FF92C390 \n"
 636 
 637 "loc_FF92C374:\n"
 638 "    MOV     R0, R2 \n"
 639 "    MOV     R1, #0 \n"
 640 "    BL      sub_FF92A540 \n"
 641 "    B       loc_FF92C390 \n"
 642 
 643 "loc_FF92C384:\n"
 644 "    MOV     R0, R2 \n"
 645 "    MOV     R1, #1 \n"
 646 "    BL      sub_FF92A540 \n"
 647 
 648 "loc_FF92C390:\n"
 649 "    LDR     R12, [SP, #4] \n"
 650 
 651 "loc_FF92C394:\n"
 652 "    ADD     R0, R12, #4 \n"
 653 "    LDR     R1, [R12, #0x7C] \n"
 654 "    LDR     R2, [R12, #0x8C] \n"
 655 "    MOV     LR, PC \n"
 656 "    LDR     PC, [R12, #0x88] \n"
 657 
 658 "loc_FF92C3A8:\n"
 659 "    CMP     R8, #1 \n"
 660 "    BNE     loc_FF92C3D0 \n"
 661 "    LDR     R1, [SP, #4] \n"
 662 "    LDR     R3, [R1, #0x7C] \n"
 663 "    ADD     R3, R3, R3, LSL#1 \n"
 664 "    ADD     R1, R1, R3, LSL#2 \n"
 665 "    MOV     R0, R6 \n"
 666 "    SUB     R1, R1, #8 \n"
 667 "    BL      sub_FF928298 \n"
 668 "    B       loc_FF92C404 \n"
 669 
 670 "loc_FF92C3D0:\n"
 671 "    MOV     R4, #1 \n"
 672 "    MOV     R0, R4 \n"
 673 "    MOV     R1, R4 \n"
 674 "    MOV     R2, R4 \n"
 675 "    MOV     R3, R4 \n"
 676 "    STR     R4, [SP] \n"
 677 "    BL      sub_FF9281EC \n"
 678 "    MOV     R0, R4 \n"
 679 "    MOV     R1, R0 \n"
 680 "    MOV     R2, R0 \n"
 681 "    MOV     R3, R0 \n"
 682 "    STR     R4, [SP] \n"
 683 "    BL      sub_FF928370 \n"
 684 
 685 "loc_FF92C404:\n"
 686 "    LDR     R0, [SP, #4] \n"
 687 "    BL      sub_FF927C84 \n"
 688 
 689 "loc_FF92C40C:\n"
 690 "    LDR     R3, =0x66828 \n"
 691 "    MOV     R2, #0 \n"
 692 "    LDR     R0, [R3] \n"
 693 "    MOV     R1, R7 \n"
 694 "    BL      sub_FF821544 /*_ReceiveMessageQueue*/ \n"
 695 "    LDR     R12, [SP, #4] \n"
 696 "    LDR     R2, [R12] \n"
 697 "    CMP     R2, #0x23 \n"
 698 "    BNE     loc_FF92BF60 \n"
 699 "    MOV     R0, R12 \n"
 700 "    BL      sub_FF927C84 \n"
 701 "    LDR     R3, =0x66824 \n"
 702 "    MOV     R1, #1 \n"
 703 "    LDR     R0, [R3] \n"
 704 "    BL      sub_FF820E2C /*_SetEventFlag*/ \n"
 705 "    BL      sub_FF822AA0 /*_ExitTask_FW*/ \n"
 706 "    ADD     SP, SP, #0x20 \n"
 707 "    LDMFD   SP!, {R4-R8,PC} \n"
 708 );
 709 }
 710 
 711 /*************************************************************/
 712 //** sub_FF9291A8_my @ 0xFF9291A8 - 0xFF9292EC, length=82
 713 void __attribute__((naked,noinline)) sub_FF9291A8_my() {
 714 asm volatile (
 715 "    STMFD   SP!, {R4-R6,LR} \n"
 716 "    LDR     R3, =0x66824 \n"
 717 "    MOV     R4, R0 \n"
 718 "    MOV     R1, #0x3E \n"
 719 "    LDR     R0, [R3] \n"
 720 "    BL      sub_FF820FC8 /*_ClearEventFlag*/ \n"
 721 "    MOV     R1, #0 \n"
 722 "    LDRSH   R0, [R4, #4] \n"
 723 "    BL      sub_FF927DB8 \n"
 724 "    MOV     R6, R0 \n"
 725 "    LDRSH   R0, [R4, #6] \n"
 726 "    BL      sub_FF927F2C \n"
 727 "    LDRSH   R0, [R4, #8] \n"
 728 "    BL      sub_FF927FC8 \n"
 729 "    LDRSH   R0, [R4, #0xA] \n"
 730 "    BL      sub_FF928064 \n"
 731 "    LDRSH   R0, [R4, #0xC] \n"
 732 "    BL      sub_FF928100 \n"
 733 "    LDR     R3, [R4] \n"
 734 "    CMP     R3, #9 \n"
 735 "    MOV     R5, R0 \n"
 736 "    MOVEQ   R5, #0 \n"
 737 "    MOVEQ   R6, R5 \n"
 738 "    CMP     R6, #1 \n"
 739 "    BNE     loc_FF92922C \n"
 740 "    MOV     R2, #2 \n"
 741 "    LDRSH   R0, [R4, #4] \n"
 742 "    LDR     R1, =0xFF927CD8 \n"
 743 "    BL      sub_FFAF9810 \n"
 744 "    LDR     R2, =0x66864 \n"
 745 "    MOV     R3, #0 \n"
 746 "    STR     R3, [R2] \n"
 747 "    B       loc_FF929230 \n"
 748 
 749 "loc_FF92922C:\n"
 750 "    BL      sub_FF92819C \n"
 751 
 752 "loc_FF929230:\n"
 753 "    STRH    R0, [R4, #4] \n"
 754 "    CMP     R5, #1 \n"
 755 "    BNE     loc_FF929250 \n"
 756 "    LDRSH   R0, [R4, #0xC] \n"
 757 "    LDR     R1, =0xFF927D9C \n"
 758 "    MOV     R2, #0x20 \n"
 759 "    BL      sub_FF9284D4 \n"
 760 "    B       loc_FF929254 \n"
 761 
 762 "loc_FF929250:\n"
 763 "    BL      sub_FF9281DC \n"
 764 
 765 "loc_FF929254:\n"
 766 "    STRH    R0, [R4, #0xC] \n"
 767 "    LDRSH   R0, [R4, #6] \n"
 768 "    BL      sub_FF8C6DBC_my \n"  // --> Patched. Old value = 0xFF8C6DBC.
 769 "    LDRSH   R0, [R4, #8] \n"
 770 "    MOV     R1, #1 \n"
 771 "    BL      sub_FF8C9020 \n"
 772 "    ADD     R0, R4, #8 \n"
 773 "    MOV     R1, #0 \n"
 774 "    BL      sub_FF8C90E0 \n"
 775 "    LDRSH   R0, [R4, #0xE] \n"
 776 "    BL      sub_FF9158B4 \n"
 777 "    CMP     R6, #1 \n"
 778 "    BNE     loc_FF9292B8 \n"
 779 "    LDR     R3, =0x66824 \n"
 780 "    MOV     R2, #0xBB0 \n"
 781 "    LDR     R0, [R3] \n"
 782 "    MOV     R1, #2 \n"
 783 "    ADD     R2, R2, #8 \n"
 784 "    BL      sub_FF820E1C /*_WaitForAllEventFlag*/ \n"
 785 "    TST     R0, #1 \n"
 786 "    BEQ     loc_FF9292B8 \n"
 787 "    MOV     R1, #0x440 \n"
 788 "    LDR     R0, =0xFF927C30 \n"
 789 "    ADD     R1, R1, #0xB \n"
 790 "    BL      sub_FF813E84 /*_DebugAssert*/ \n"
 791 
 792 "loc_FF9292B8:\n"
 793 "    CMP     R5, #1 \n"
 794 "    LDMNEFD SP!, {R4-R6,PC} \n"
 795 "    LDR     R3, =0x66824 \n"
 796 "    MOV     R2, #0xBB0 \n"
 797 "    LDR     R0, [R3] \n"
 798 "    MOV     R1, #0x20 \n"
 799 "    ADD     R2, R2, #8 \n"
 800 "    BL      sub_FF820E1C /*_WaitForAllEventFlag*/ \n"
 801 "    TST     R0, #1 \n"
 802 "    LDMEQFD SP!, {R4-R6,PC} \n"
 803 "    LDR     R0, =0xFF927C30 \n"
 804 "    MOV     R1, #0x450 \n"
 805 "    LDMFD   SP!, {R4-R6,LR} \n"
 806 "    B       sub_FF813E84 /*_DebugAssert*/ \n"
 807 );
 808 }
 809 
 810 /*************************************************************/
 811 //** sub_FF8C6DBC_my @ 0xFF8C6DBC - 0xFF8C6E18, length=24
 812 void __attribute__((naked,noinline)) sub_FF8C6DBC_my() {
 813 asm volatile (
 814 "    STMFD   SP!, {R4,LR} \n"
 815 "    LDR     R3, =0x560C \n"
 816 "    LDR     R2, [R3] \n"
 817 "    MOV     R1, #0x150 \n"
 818 "    MOV     R3, R0, LSL#16 \n"
 819 "    CMP     R2, #1 \n"
 820 "    ADD     R1, R1, #1 \n"
 821 "    LDR     R0, =0xFF8C65F8 \n"
 822 "    MOV     R4, R3, ASR#16 \n"
 823 "    BEQ     loc_FF8C6DE8 \n"
 824 "    BL      sub_FF813E84 /*_DebugAssert*/ \n"
 825 
 826 "loc_FF8C6DE8:\n"
 827 "    MOV     R1, #0x154 \n"
 828 "    CMN     R4, #0xC00 \n"
 829 "    LDR     R3, =0x4B24E \n"
 830 "    LDR     R0, =0xFF8C65F8 \n"
 831 "    ADD     R1, R1, #3 \n"
 832 "    LDREQSH R4, [R3] \n"
 833 "    LDRNE   R3, =0x4B24E \n"
 834 "    CMN     R4, #0xC00 \n"
 835 "    STRH    R4, [R3] \n"
 836 "    BNE     loc_FF8C6E14 \n"
 837 "    BL      sub_FF813E84 /*_DebugAssert*/ \n"
 838 
 839 "loc_FF8C6E14:\n"
 840 "    MOV     R0, R4 \n"
 841 "    BL      apex2us \n"  // --> Patched. Old value = _apex2us.
 842 "    LDR     PC, =0xFF8C6E1C \n"  // Continue in firmware
 843 );
 844 }

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