root/platform/m10/sub/110f/capt_seq.c

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

DEFINITIONS

This source file includes following definitions.
  1. log_capt_seq
  2. log_capt_seq2
  3. log_capt_seq_override
  4. log_remote_hook
  5. log_remote_hook2
  6. log_rh
  7. capt_seq_task
  8. sub_fc0dd248_my
  9. sub_fc0dd0dc_my
  10. sub_fc116fa2_my

   1 #include "lolevel.h"
   2 #include "platform.h"
   3 #include "core.h"
   4 
   5 //#define CAPTSEQ_DEBUG 1
   6 #undef CAPTSEQ_DEBUG
   7 
   8 #define USE_STUBS_NRFLAG 1
   9 #define NR_AUTO (0)                 // have to explictly reset value back to 0 to enable auto
  10 
  11 extern int active_raw_buffer;
  12 // debug
  13 extern void _LogCameraEvent(int id,const char *fmt,...);
  14 
  15 extern char *hook_raw_image_addr(void);
  16 
  17 #ifdef CAPTSEQ_DEBUG
  18 void log_capt_seq(int m)
  19 {
  20     _LogCameraEvent(0x60,"cs m:%d arb:%d rb:0x%08x i:%04d",
  21                     m,
  22                     active_raw_buffer,
  23                     hook_raw_image_addr(),
  24                     get_exposure_counter());
  25 }
  26 void log_capt_seq2(int m)
  27 {
  28     _LogCameraEvent(0x60,"cs end m:%d arb:%d rb:0x%08x i:%04d",
  29                     m,
  30                     active_raw_buffer,
  31                     hook_raw_image_addr(),
  32                     get_exposure_counter());
  33 }
  34 void log_capt_seq_override(void)
  35 {
  36     _LogCameraEvent(0x60,"cs override arb:%d rb:0x%08x i:%04d",
  37                     active_raw_buffer,
  38                     hook_raw_image_addr(),
  39                     get_exposure_counter());
  40 }
  41 void log_remote_hook(void) {
  42     _LogCameraEvent(0x60,"remote hook1 %d", *(unsigned*)0xc0242014);
  43 }
  44 void log_remote_hook2(void) {
  45     _LogCameraEvent(0x60,"remote hook2 %d", *(unsigned*)0xc0242014);
  46 }
  47 void log_rh(void) {
  48     _LogCameraEvent(0x60,"raw hook");
  49 }
  50 #endif
  51 
  52 #include "../../../generic/capt_seq.c"
  53 
  54 void __attribute__((naked,noinline)) capt_seq_task() {
  55     asm volatile ( //  capdis -stubs -f=chdk -s=task_CaptSeqTask -c=179 PRIMARY.BIN 0xfc000000
  56 // task_CaptSeqTask 0xfc0bce67
  57 "    push    {r3, r4, r5, r6, r7, lr}\n"
  58 "    ldr     r4, =0x0005dd60\n"
  59 "    movs    r6, #0\n"
  60 "    ldr     r5, =0x0000b1f8\n"
  61 "loc_fc0bce6e:\n"
  62 "    movs    r2, #0\n"
  63 "    mov     r1, sp\n"
  64 "    ldr     r0, [r5, #8]\n"
  65 "    blx     sub_fc314cb0\n" // j_ReceiveMessageQueue
  66 "    lsls    r0, r0, #0x1f\n"
  67 "    beq     loc_fc0bce90\n"
  68 "    movw    r2, #0x455\n"
  69 "    ldr     r1, =0xfc0bca88\n" //  *"SsShootTask.c"
  70 "    movs    r0, #0\n"
  71 "    blx     sub_fc314e20\n" // j_DebugAssert
  72 "    blx     sub_fc314cd8\n" // -> ExitTask_FW
  73 "    pop     {r3, r4, r5, r6, r7, pc}\n"
  74 "loc_fc0bce90:\n"
  75 "    ldr     r0, [sp]\n"
  76 "    ldr     r0, [r0]\n"
  77 "    cmp     r0, #1\n"
  78 "    beq     loc_fc0bcea8\n"
  79 "    cmp     r0, #0x27\n"
  80 "    beq     loc_fc0bcea8\n"
  81 "    cmp     r0, #0x1c\n"
  82 "    beq     loc_fc0bcea8\n"
  83 "    cmp     r0, #0x1f\n"
  84 "    beq     loc_fc0bcea8\n"
  85 "    bl      sub_fc18c164\n"
  86 "loc_fc0bcea8:\n"
  87 #ifdef CAPTSEQ_DEBUG
  88 "ldr     r0, [sp]\n"
  89 "ldr     r0, [r0]\n"
  90 "bl log_capt_seq\n"
  91 #endif
  92 "    ldr     r0, [sp]\n"
  93 "    ldr     r1, [r0]\n"
  94 "    cmp     r1, #0x2e\n"
  95 "    bhs     loc_fc0bcf6a\n"
  96 "    tbb     [pc, r1]\n" // (jumptable r1 46 elements)
  97 "branchtable_fc0bceb4:\n"
  98 "    .byte((loc_fc0bcee2 - branchtable_fc0bceb4) / 2)\n" // (case 0)
  99 "    .byte((loc_fc0bcef8 - branchtable_fc0bceb4) / 2)\n" // (case 1)
 100 "    .byte((loc_fc0bcf00 - branchtable_fc0bceb4) / 2)\n" // (case 2)
 101 "    .byte((loc_fc0bcf0e - branchtable_fc0bceb4) / 2)\n" // (case 3)
 102 "    .byte((loc_fc0bcf08 - branchtable_fc0bceb4) / 2)\n" // (case 4)
 103 "    .byte((loc_fc0bcf18 - branchtable_fc0bceb4) / 2)\n" // (case 5)
 104 "    .byte((loc_fc0bcf1e - branchtable_fc0bceb4) / 2)\n" // (case 6)
 105 "    .byte((loc_fc0bcf5c - branchtable_fc0bceb4) / 2)\n" // (case 7)
 106 "    .byte((loc_fc0bcf2e - branchtable_fc0bceb4) / 2)\n" // (case 8)
 107 "    .byte((loc_fc0bcf36 - branchtable_fc0bceb4) / 2)\n" // (case 9)
 108 "    .byte((loc_fc0bcf3c - branchtable_fc0bceb4) / 2)\n" // (case 10)
 109 "    .byte((loc_fc0bcf44 - branchtable_fc0bceb4) / 2)\n" // (case 11)
 110 "    .byte((loc_fc0bcf4a - branchtable_fc0bceb4) / 2)\n" // (case 12)
 111 "    .byte((loc_fc0bcf50 - branchtable_fc0bceb4) / 2)\n" // (case 13)
 112 "    .byte((loc_fc0bcf56 - branchtable_fc0bceb4) / 2)\n" // (case 14)
 113 "    .byte((loc_fc0bcf64 - branchtable_fc0bceb4) / 2)\n" // (case 15)
 114 "    .byte((loc_fc0bcf78 - branchtable_fc0bceb4) / 2)\n" // (case 16)
 115 "    .byte((loc_fc0bcf7e - branchtable_fc0bceb4) / 2)\n" // (case 17)
 116 "    .byte((loc_fc0bcf84 - branchtable_fc0bceb4) / 2)\n" // (case 18)
 117 "    .byte((loc_fc0bcf8a - branchtable_fc0bceb4) / 2)\n" // (case 19)
 118 "    .byte((loc_fc0bcf8e - branchtable_fc0bceb4) / 2)\n" // (case 20)
 119 "    .byte((loc_fc0bcf94 - branchtable_fc0bceb4) / 2)\n" // (case 21)
 120 "    .byte((loc_fc0bcf9a - branchtable_fc0bceb4) / 2)\n" // (case 22)
 121 "    .byte((loc_fc0bcfa0 - branchtable_fc0bceb4) / 2)\n" // (case 23)
 122 "    .byte((loc_fc0bcfa6 - branchtable_fc0bceb4) / 2)\n" // (case 24)
 123 "    .byte((loc_fc0bcfac - branchtable_fc0bceb4) / 2)\n" // (case 25)
 124 "    .byte((loc_fc0bcfb4 - branchtable_fc0bceb4) / 2)\n" // (case 26)
 125 "    .byte((loc_fc0bcfba - branchtable_fc0bceb4) / 2)\n" // (case 27)
 126 "    .byte((loc_fc0bcfbe - branchtable_fc0bceb4) / 2)\n" // (case 28)
 127 "    .byte((loc_fc0bcfc6 - branchtable_fc0bceb4) / 2)\n" // (case 29)
 128 "    .byte((loc_fc0bcfcc - branchtable_fc0bceb4) / 2)\n" // (case 30)
 129 "    .byte((loc_fc0bcfd2 - branchtable_fc0bceb4) / 2)\n" // (case 31)
 130 "    .byte((loc_fc0bcfd8 - branchtable_fc0bceb4) / 2)\n" // (case 32)
 131 "    .byte((loc_fc0bcfde - branchtable_fc0bceb4) / 2)\n" // (case 33)
 132 "    .byte((loc_fc0bcfe4 - branchtable_fc0bceb4) / 2)\n" // (case 34)
 133 "    .byte((loc_fc0bcfea - branchtable_fc0bceb4) / 2)\n" // (case 35)
 134 "    .byte((loc_fc0bcff2 - branchtable_fc0bceb4) / 2)\n" // (case 36)
 135 "    .byte((loc_fc0bcff8 - branchtable_fc0bceb4) / 2)\n" // (case 37)
 136 "    .byte((loc_fc0bd01c - branchtable_fc0bceb4) / 2)\n" // (case 38)
 137 "    .byte((loc_fc0bd022 - branchtable_fc0bceb4) / 2)\n" // (case 39)
 138 "    .byte((loc_fc0bd05a - branchtable_fc0bceb4) / 2)\n" // (case 40)
 139 "    .byte((loc_fc0bd02e - branchtable_fc0bceb4) / 2)\n" // (case 41)
 140 "    .byte((loc_fc0bd034 - branchtable_fc0bceb4) / 2)\n" // (case 42)
 141 "    .byte((loc_fc0bd03a - branchtable_fc0bceb4) / 2)\n" // (case 43)
 142 "    .byte((loc_fc0bd040 - branchtable_fc0bceb4) / 2)\n" // (case 44)
 143 "    .byte((loc_fc0bd046 - branchtable_fc0bceb4) / 2)\n" // (case 45)
 144 ".align 1\n"
 145 "loc_fc0bcee2:\n"
 146 "    ldr     r0, [r0, #0xc]\n"
 147 "    bl      sub_fc0d4f20\n"
 148 #ifdef CAPTSEQ_DEBUG
 149 "bl log_capt_seq_override\n" // debug
 150 #endif
 151 "    bl      shooting_expo_param_override\n" // +
 152 "    bl      sub_fc101d70\n"
 153 "    ldr     r0, [r4, #0x28]\n"
 154 "    cmp     r0, #0\n"
 155 "    beq     loc_fc0bcef6\n"
 156 "    bl      sub_fc0dd248_my\n"             // ->
 157 "loc_fc0bcef6:\n"
 158 "    b       loc_fc0bd05a\n"
 159 "loc_fc0bcef8:\n"
 160 "    ldr     r0, [r0, #0x10]\n"
 161 "    bl      sub_fc0dd0dc_my\n"             // ->
 162 "    b       loc_fc0bd05a\n"
 163 "loc_fc0bcf00:\n"
 164 "    movs    r0, #1\n"
 165 "    bl      sub_fc0d51b0\n"
 166 "    b       loc_fc0bd05a\n"
 167 "loc_fc0bcf08:\n"
 168 "    bl      sub_fc0d4c64\n"
 169 "    b       loc_fc0bcf14\n"
 170 "loc_fc0bcf0e:\n"
 171 "    ldr     r0, [r0, #0xc]\n"
 172 "    bl      sub_fc0d4f08\n"
 173 "loc_fc0bcf14:\n"
 174 "    str     r6, [r4, #0x28]\n"
 175 "    b       loc_fc0bd05a\n"
 176 "loc_fc0bcf18:\n"
 177 "    bl      sub_fc0d4f0e\n"
 178 "    b       loc_fc0bd05a\n"
 179 "loc_fc0bcf1e:\n"
 180 "    bl      sub_fc0d5152\n"
 181 "    bl      sub_fc101d70\n"
 182 "    movs    r0, #0\n"
 183 "    bl      sub_fc2a507a\n"
 184 "    b       loc_fc0bd05a\n"
 185 "loc_fc0bcf2e:\n"
 186 "    ldr     r0, [r4, #0x54]\n"
 187 "    bl      sub_fc0d5756\n"
 188 "    b       loc_fc0bd05a\n"
 189 "loc_fc0bcf36:\n"
 190 "    bl      sub_fc0d59e2\n"
 191 "    b       loc_fc0bd05a\n"
 192 "loc_fc0bcf3c:\n"
 193 "    ldr     r0, [r0, #0xc]\n"
 194 "    bl      sub_fc0d5a2e\n"
 195 "    b       loc_fc0bd05a\n"
 196 "loc_fc0bcf44:\n"
 197 "    bl      sub_fc0d5bf4\n"
 198 "    b       loc_fc0bd05a\n"
 199 "loc_fc0bcf4a:\n"
 200 "    bl      sub_fc0d5c52\n"
 201 "    b       loc_fc0bd05a\n"
 202 "loc_fc0bcf50:\n"
 203 "    bl      sub_fc0d6008\n"
 204 "    b       loc_fc0bd05a\n"
 205 "loc_fc0bcf56:\n"
 206 "    bl      sub_fc0d609e\n"
 207 "    b       loc_fc0bd05a\n"
 208 "loc_fc0bcf5c:\n"
 209 "    ldr     r0, [r0, #0xc]\n"
 210 "    bl      sub_fc0d4f08\n"
 211 "    b       loc_fc0bd05a\n"
 212 "loc_fc0bcf64:\n"
 213 "    bl      sub_fc0dc83c\n"
 214 "    b       loc_fc0bd05a\n"
 215 "loc_fc0bcf6a:\n"
 216 "    b       loc_fc0bd04c\n"
 217 // - literal pool removed
 218 ".ltorg\n"
 219 "loc_fc0bcf78:\n"
 220 "    bl      sub_fc0dc9f4\n"
 221 "    b       loc_fc0bd05a\n"
 222 "loc_fc0bcf7e:\n"
 223 "    bl      sub_fc0dca98\n"
 224 "    b       loc_fc0bd05a\n"
 225 "loc_fc0bcf84:\n"
 226 "    bl      sub_fc0dcb2a\n"
 227 "    b       loc_fc0bd05a\n"
 228 "loc_fc0bcf8a:\n"
 229 "    movs    r0, #0\n"
 230 "    b       loc_fc0bcfae\n"
 231 "loc_fc0bcf8e:\n"
 232 "    bl      sub_fc0dce20\n"
 233 "    b       loc_fc0bd05a\n"
 234 "loc_fc0bcf94:\n"
 235 "    bl      sub_fc0dce80\n"
 236 "    b       loc_fc0bd05a\n"
 237 "loc_fc0bcf9a:\n"
 238 "    bl      sub_fc0dce84\n"
 239 "    b       loc_fc0bd05a\n"
 240 "loc_fc0bcfa0:\n"
 241 "    bl      sub_fc0dce94\n"
 242 "    b       loc_fc0bd05a\n"
 243 "loc_fc0bcfa6:\n"
 244 "    bl      sub_fc0dcf28\n"
 245 "    b       loc_fc0bd05a\n"
 246 "loc_fc0bcfac:\n"
 247 "    movs    r0, #1\n"
 248 "loc_fc0bcfae:\n"
 249 "    bl      sub_fc0dcd00\n"
 250 "    b       loc_fc0bd05a\n"
 251 "loc_fc0bcfb4:\n"
 252 "    bl      sub_fc0d5276\n"
 253 "    b       loc_fc0bd05a\n"
 254 "loc_fc0bcfba:\n"
 255 "    movs    r0, #0\n"
 256 "    b       loc_fc0bcfc0\n"
 257 "loc_fc0bcfbe:\n"
 258 "    ldr     r0, [r0, #0xc]\n"
 259 "loc_fc0bcfc0:\n"
 260 "    bl      sub_fc0d52a8\n"
 261 "    b       loc_fc0bd05a\n"
 262 "loc_fc0bcfc6:\n"
 263 "    bl      sub_fc0dcc46\n"
 264 "    b       loc_fc0bd05a\n"
 265 "loc_fc0bcfcc:\n"
 266 "    bl      sub_fc0dccb2\n"
 267 "    b       loc_fc0bd05a\n"
 268 "loc_fc0bcfd2:\n"
 269 "    bl      sub_fc10fd1c\n"
 270 "    b       loc_fc0bd05a\n"
 271 "loc_fc0bcfd8:\n"
 272 "    bl      sub_fc10256c\n"
 273 "    b       loc_fc0bd05a\n"
 274 "loc_fc0bcfde:\n"
 275 "    bl      sub_fc0d67ca\n"
 276 "    b       loc_fc0bd05a\n"
 277 "loc_fc0bcfe4:\n"
 278 "    bl      sub_fc0d6884\n"
 279 "    b       loc_fc0bd05a\n"
 280 "loc_fc0bcfea:\n"
 281 "    ldr     r0, [r0, #0xc]\n"
 282 "    bl      sub_fc0dd008\n"
 283 "    b       loc_fc0bd05a\n"
 284 "loc_fc0bcff2:\n"
 285 "    bl      sub_fc0dd05a\n"
 286 "    b       loc_fc0bd05a\n"
 287 "loc_fc0bcff8:\n"
 288 "    bl      sub_fc0d71b8\n"
 289 "    bl      sub_fc0d7ffe\n"
 290 "    ldrh.w  r0, [r4, #0x1a4]\n"
 291 "    cmp     r0, #4\n"
 292 "    beq     loc_fc0bd012\n"
 293 "    ldrh    r0, [r4]\n"
 294 "    sub.w   r1, r0, #0x8200\n"
 295 "    subs    r1, #0x36\n"
 296 "    bne     loc_fc0bd05a\n"
 297 "loc_fc0bd012:\n"
 298 "    bl      sub_fc0d6884\n"
 299 "    bl      sub_fc0d6c06\n"
 300 "    b       loc_fc0bd05a\n"
 301 "loc_fc0bd01c:\n"
 302 "    movs    r2, #0\n"
 303 "    movs    r1, #0x11\n"
 304 "    b       loc_fc0bd026\n"
 305 "loc_fc0bd022:\n"
 306 "    movs    r2, #0\n"
 307 "    movs    r1, #0x10\n"
 308 "loc_fc0bd026:\n"
 309 "    movs    r0, #0\n"
 310 "    bl      sub_fc1026fa\n"
 311 "    b       loc_fc0bd05a\n"
 312 "loc_fc0bd02e:\n"
 313 "    bl      sub_fc110468\n"
 314 "    b       loc_fc0bd05a\n"
 315 "loc_fc0bd034:\n"
 316 "    bl      sub_fc1104e4\n"
 317 "    b       loc_fc0bd05a\n"
 318 "loc_fc0bd03a:\n"
 319 "    bl      sub_fc110524\n"
 320 "    b       loc_fc0bd05a\n"
 321 "loc_fc0bd040:\n"
 322 "    bl      sub_fc1103ac\n"
 323 "    b       loc_fc0bd05a\n"
 324 "loc_fc0bd046:\n"
 325 "    bl      sub_fc1103ae\n"
 326 "    b       loc_fc0bd05a\n"
 327 "loc_fc0bd04c:\n"
 328 "    movw    r2, #0x588\n"
 329 "    ldr     r1, =0xfc0bca88\n" //  *"SsShootTask.c"
 330 "    movs    r0, #0\n"
 331 "    blx     sub_fc314e20\n" // j_DebugAssert
 332 "loc_fc0bd05a:\n"
 333 #ifdef CAPTSEQ_DEBUG
 334 // debug after message handled
 335 "ldr     r0, [sp]\n"
 336 "ldr     r0, [r0]\n"
 337 "bl log_capt_seq2\n"
 338 #endif
 339 "    ldr     r0, [sp]\n"
 340 "    ldr     r1, [r0, #4]\n"
 341 "    ldr     r0, [r5, #4]\n"
 342 "    blx     sub_fc314cc8\n" // j_SetEventFlag
 343 "    ldr     r7, [sp]\n"
 344 "    ldr     r0, [r7, #8]\n"
 345 "    cbnz    r0, loc_fc0bd078\n"
 346 "    movw    r2, #0x12b\n"
 347 "    ldr     r1, =0xfc0bca88\n" //  *"SsShootTask.c"
 348 "    movs    r0, #0\n"
 349 "    blx     sub_fc314e20\n" // j_DebugAssert
 350 "loc_fc0bd078:\n"
 351 "    str     r6, [r7, #8]\n"
 352 "    b       loc_fc0bce6e\n"
 353 ".ltorg\n"
 354     );
 355 }
 356 
 357 void __attribute__((naked,noinline)) sub_fc0dd248_my() {
 358     asm volatile ( // capdis -stubs -f=chdk -s=0xfc0dd249 -c=34 PRIMARY.BIN 0xfc000000
 359 "    push    {r4, lr}\n"
 360 "    bl      sub_fc102c38\n"
 361 "    mov     r4, r0\n"
 362 "    bl      sub_fc0d4f14\n"
 363 "    bl      sub_fc137bd8\n"
 364 "    mov     r1, r4\n"
 365 "    bl      sub_fc137c26\n"
 366 "    movs    r2, #4\n"
 367 "    movw    r0, #0x118\n"
 368 "    add.w   r1, r4, #0x34\n"
 369 "    bl      sub_fc38810c\n" // SetPropertyCase
 370 "    movs    r2, #4\n"
 371 "    movs    r0, #0x32\n"
 372 "    add.w   r1, r4, #0x38\n"
 373 "    bl      sub_fc38810c\n" // SetPropertyCase
 374 "    movs    r2, #4\n"
 375 "    movs    r0, #0x46\n"
 376 "    add.w   r1, r4, #8\n"
 377 "    bl      sub_fc38810c\n" // SetPropertyCase
 378 "    bl      sub_fc18bc92\n"
 379 "    mvn     r1, #0x1000\n"
 380 "    blx     sub_fc314d70\n" // j_ClearEventFlag
 381 "    mov     r0, r4\n"
 382 "    bl      sub_fc18b978\n"
 383 "    bl      sub_fc2494d4\n"
 384 "    bl      sub_fc2a6a52\n"
 385 "    mov     r0, r4\n"
 386 "    bl      sub_fc116fa2_my\n" // ->
 387 "    lsls    r0, r0, #0x1f\n"
 388 "    beq     loc_fc0dd2ae\n"
 389 "    ldr     r1, =0x00012db4\n"
 390 "    movs    r0, #1\n"
 391 "    str     r0, [r1]\n"
 392 "loc_fc0dd2ae:\n"
 393 "    pop     {r4, pc}\n"
 394 ".ltorg\n"
 395     );
 396 }
 397 
 398 void __attribute__((naked,noinline)) sub_fc0dd0dc_my() {
 399     asm volatile ( // capdis -stubs -f=chdk -s=0xfc0dd0dd -c=136 PRIMARY.BIN 0xfc000000
 400 "    push    {r3, r4, r5, r6, r7, lr}\n"
 401 "    ldr     r6, =0x0005dd60\n"
 402 "    mov     r5, r0\n"
 403 "    movs    r4, #0\n"
 404 "    ldr     r0, [r6, #0x28]\n"
 405 "    cbz     r0, loc_fc0dd104\n"
 406 "    ldr     r0, =0x00012db4\n"
 407 "    ldr     r0, [r0]\n"
 408 "    cbz     r0, loc_fc0dd0f0\n"
 409 "    movs    r4, #0x1d\n"
 410 "loc_fc0dd0f0:\n"
 411 "    mov     r2, r5\n"
 412 "    movs    r1, #2\n"
 413 "    mov     r0, r4\n"
 414 "    bl      sub_fc1026fa\n"
 415 "    mov     r1, r4\n"
 416 "    mov     r0, r5\n"
 417 "    bl      sub_fc18bff0\n"
 418 "    b       loc_fc0dd23e\n"
 419 "loc_fc0dd104:\n"
 420 "    bl      sub_fc137bd8\n"
 421 "    mov     r1, r5\n"
 422 "    bl      sub_fc137c26\n"
 423 "    movs    r2, #4\n"
 424 "    movw    r0, #0x118\n"
 425 "    add.w   r1, r5, #0x34\n"
 426 "    bl      sub_fc38810c\n" // SetPropertyCase
 427 "    movs    r2, #4\n"
 428 "    movs    r0, #0x32\n"
 429 "    add.w   r1, r5, #0x38\n"
 430 "    bl      sub_fc38810c\n" // SetPropertyCase
 431 "    ldr.w   r0, [r6, #0x10c]\n"
 432 "    cbnz    r0, loc_fc0dd13e\n"
 433 "    ldrh.w  r0, [r6, #0x1a2]\n"
 434 "    cmp     r0, #3\n"
 435 "    beq     loc_fc0dd144\n"
 436 "    ldr     r0, [r5, #8]\n"
 437 "    cmp     r0, #1\n"
 438 "    bhi     loc_fc0dd154\n"
 439 "    b       loc_fc0dd144\n"
 440 "loc_fc0dd13e:\n"
 441 "    ldr     r0, [r5, #0xc]\n"
 442 "    cmp     r0, #1\n"
 443 "    bne     loc_fc0dd154\n"
 444 "loc_fc0dd144:\n"
 445 "    movs    r0, #0xc\n"
 446 "    bl      sub_fc33e0fc\n"
 447 "    lsls    r0, r0, #0x1f\n"
 448 "    beq     loc_fc0dd154\n"
 449 "    bl      sub_fc102562\n"
 450 "    movs    r4, #1\n"
 451 "loc_fc0dd154:\n"
 452 "    lsls    r0, r4, #0x1f\n"
 453 "    bne     loc_fc0dd22c\n"
 454 "    ldr.w   r0, [r6, #0xec]\n"
 455 "    cbz     r0, loc_fc0dd178\n"
 456 "    ldrh.w  r0, [r6, #0x1a2]\n"
 457 "    cmp     r0, #3\n"
 458 "    beq     loc_fc0dd16c\n"
 459 "    ldr     r0, [r5, #8]\n"
 460 "    cmp     r0, #1\n"
 461 "    bhi     loc_fc0dd1be\n"
 462 "loc_fc0dd16c:\n"
 463 "    ldr.w   r0, [r6, #0x10c]\n"
 464 "    cbz     r0, loc_fc0dd178\n"
 465 "    ldr     r0, [r5, #0xc]\n"
 466 "    cmp     r0, #1\n"
 467 "    bhi     loc_fc0dd1be\n"
 468 "loc_fc0dd178:\n"
 469 "    bl      sub_fc1105c8\n"
 470 "    cbnz    r0, loc_fc0dd1be\n"
 471 "    movs    r2, #2\n"
 472 "    mov     r1, sp\n"
 473 "    movw    r0, #0x112\n"
 474 "    bl      sub_fc38825e\n" // GetPropertyCase
 475 "    lsls    r0, r0, #0x1f\n"
 476 "    beq     loc_fc0dd198\n"
 477 "    movs    r2, #0xcb\n"
 478 "    movs    r0, #0\n"
 479 "    ldr     r1, =0xfc0dd2bc\n" //  *"SsCaptureCtrl.c"
 480 "    blx     sub_fc314e20\n" // j_DebugAssert
 481 "loc_fc0dd198:\n"
 482 "    ldrsh.w r0, [sp]\n"
 483 "    bl      sub_fc1271a6\n"
 484 "    bl      sub_fc127068\n"
 485 "    cmp     r0, #1\n"
 486 "    bls     loc_fc0dd1b0\n"
 487 "    movs    r0, #0\n"
 488 "    bl      sub_fc127130\n"
 489 "    b       loc_fc0dd1be\n"
 490 "loc_fc0dd1b0:\n"
 491 "    bl      sub_fc102562\n"
 492 "    bl      sub_fc33e13c\n"
 493 "    movs    r4, #1\n"
 494 "    lsls    r0, r4, #0x1f\n"
 495 "    bne     loc_fc0dd22c\n"
 496 "loc_fc0dd1be:\n"
 497 "    mov     r0, r5\n"
 498 "    bl      sub_fc10fd82\n"
 499 "    mov     r4, r0\n"
 500 "    lsls    r0, r0, #0x1f\n"
 501 "    bne     loc_fc0dd22c\n"
 502 "    bl      sub_fc18bc92\n"
 503 "    mvn     r1, #0x1000\n"
 504 "    blx     sub_fc314d70\n" // j_ClearEventFlag
 505 "    bl      sub_fc2494d4\n"
 506 "    bl      sub_fc2a6a52\n"
 507 "    mov     r0, r5\n"
 508 "    bl      sub_fc116cec\n"
 509 "    mov     r4, r0\n"
 510 "    lsls    r0, r0, #0x1f\n"
 511 "    bne     loc_fc0dd22c\n"
 512 "    bl      sub_fc0d4f14\n"
 513 "    mov     r0, r5\n"
 514 "    bl      sub_fc18b978\n"
 515 "    movs    r0, #2\n"
 516 "    bl      sub_fc0d7a2e\n"
 517 "    ldr.w   r0, [r6, #0xb0]\n"
 518 "    cbz     r0, loc_fc0dd208\n"
 519 "    mov     r0, r5\n"
 520 "    bl      sub_fc1175a8\n"
 521 "    b       loc_fc0dd23e\n"
 522 "loc_fc0dd208:\n"
 523 "    ldr.w   r0, [r6, #0xb4]\n"
 524 "    cbz     r0, loc_fc0dd216\n"
 525 "    mov     r0, r5\n"
 526 "    bl      sub_fc11721e\n"
 527 "    b       loc_fc0dd23e\n"
 528 "loc_fc0dd216:\n"
 529 "    ldr.w   r0, [r6, #0xb8]\n"
 530 "    cmp     r0, #0\n"
 531 "    mov     r0, r5\n"
 532 "    beq     loc_fc0dd226\n"
 533 "    bl      sub_fc1178a4\n"
 534 "    b       loc_fc0dd23e\n"
 535 "loc_fc0dd226:\n"
 536 "    bl      sub_fc116fa2_my\n" // ->
 537 "    b       loc_fc0dd23e\n"
 538 "loc_fc0dd22c:\n"
 539 "    movs    r1, #2\n"
 540 "    mov     r2, r5\n"
 541 "    mov     r0, r4\n"
 542 "    bl      sub_fc1026fa\n"
 543 "    mov     r1, r4\n"
 544 "    mov     r0, r5\n"
 545 "    bl      sub_fc18c126\n"
 546 "loc_fc0dd23e:\n"
 547 "    bl      sub_fc0d5c44\n"
 548 "    movs    r0, #0\n"
 549 "    str     r0, [r6, #0x28]\n"
 550 "    pop     {r3, r4, r5, r6, r7, pc}\n"
 551 ".ltorg\n"
 552     );
 553 }
 554 
 555 
 556 void __attribute__((naked,noinline)) sub_fc116fa2_my() {
 557     asm volatile ( // capdis -stubs -f=chdk -s=0xfc116fa3 -c=207 PRIMARY.BIN 0xfc000000
 558 "    push.w  {r1, r2, r3, r4, r5, r6, r7, r8, sb, lr}\n"
 559 "    ldr     r6, =0xfc116f7d\n"
 560 "    mov     r5, r0\n"
 561 "    bl      sub_fc18b90e\n"
 562 "    bl      sub_fc0dd712\n"
 563 "    ldr     r7, =0x0005dd60\n"
 564 "    ldr.w   r0, [r7, #0xa4]\n"
 565 "    cbnz    r0, loc_fc116fd0\n"
 566 "    ldrh.w  r0, [r7, #0x1a2]\n"
 567 "    cmp     r0, #3\n"
 568 "    beq     loc_fc116fc8\n"
 569 "    ldr     r0, [r5, #8]\n"
 570 "    cmp     r0, #1\n"
 571 "    bhi     loc_fc116fd0\n"
 572 "loc_fc116fc8:\n"
 573 "    bl      sub_fc0d5298\n"
 574 "    bl      sub_fc0dd2de\n"
 575 "loc_fc116fd0:\n"
 576 "    movs    r2, #4\n"
 577 "    movw    r0, #0x139\n"
 578 "    add     r1, sp, #8\n"
 579 "    bl      sub_fc38825e\n" // GetPropertyCase
 580 "    lsls    r0, r0, #0x1f\n"
 581 "    beq     loc_fc116fec\n"
 582 "    movs    r0, #0\n"
 583 "    movw    r2, #0x150\n"
 584 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 585 "    blx     sub_fc314e20\n" // j_DebugAssert
 586 "loc_fc116fec:\n"
 587 #ifdef CAPTSEQ_DEBUG
 588 // Ant's remote hook location
 589 "bl log_remote_hook\n"
 590 #endif
 591 "    ldr     r0, [sp, #8]\n"
 592 "    ubfx    r0, r0, #8, #8\n"
 593 "    cmp     r0, #6\n"
 594 "    bne     loc_fc116ffc\n"
 595 "    ldr     r0, =0xfc116f7d\n"
 596 "    movs    r1, #0\n"
 597 "    b       loc_fc117000\n"
 598 "loc_fc116ffc:\n"
 599 "    ldr     r0, =0xfc18b687\n"
 600 "    mov     r1, r5\n"
 601 "loc_fc117000:\n"
 602 "    bl      sub_fc144f10\n"
 603 "    movs    r2, #2\n"
 604 "    movw    r0, #0x114\n"
 605 "    add     r1, sp, #4\n"
 606 "    bl      sub_fc38825e\n" // GetPropertyCase
 607 "    lsls    r0, r0, #0x1f\n"
 608 "    beq     loc_fc117020\n"
 609 "    movs    r0, #0\n"
 610 "    movw    r2, #0x159\n"
 611 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 612 "    blx     sub_fc314e20\n" // j_DebugAssert
 613 "loc_fc117020:\n"
 614 "    ldr.w   r0, [r7, #0x18c]\n"
 615 "    cbz     r0, loc_fc11702a\n"
 616 "    bl      sub_fc18b7e2\n"
 617 "loc_fc11702a:\n"
 618 "    movs    r0, #0\n"
 619 "    bl      sub_fc0bd154\n"
 620 "    bl      sub_fc110676\n"
 621 "    ldr.w   r8, =0xfc116f7d\n"
 622 "    mov     r4, r0\n"
 623 "    lsls    r0, r0, #0x1f\n"
 624 "    bne     loc_fc11713c\n"
 625 
 626 #ifdef CAPTSEQ_DEBUG
 627 "bl log_remote_hook2\n"
 628 #endif
 629 "    BL      wait_until_remote_button_is_released\n" // + remote hook
 630 "    BL      capt_seq_hook_set_nr\n" // +
 631 
 632 "    mov     r0, r5\n"
 633 "    bl      sub_fc18ba76\n" // NR evaluation and more
 634 "    mov     r0, r5\n"
 635 "    bl      sub_fc110580\n"
 636 "    ldr     r1, =0x0002f888\n"
 637 "    movs    r2, #4\n"
 638 "    movs    r0, #0x92\n"
 639 "    bl      sub_fc38825e\n" // GetPropertyCase
 640 "    lsls    r0, r0, #0x1f\n"
 641 "    beq     loc_fc117064\n"
 642 "    movs    r0, #0\n"
 643 "    movw    r2, #0x16e\n"
 644 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 645 "    blx     sub_fc314e20\n" // j_DebugAssert
 646 "loc_fc117064:\n"
 647 "    bl      sub_fc0bd288\n"
 648 "    bl      sub_fc18bb08\n"
 649 "    movs    r1, #0\n"
 650 "    mov     r0, r5\n"
 651 "    bl      sub_fc116f7e\n"
 652 "    mov     r6, r0\n"
 653 "    ldr     r0, [sp, #8]\n"
 654 "    ubfx    r0, r0, #8, #8\n"
 655 "    cmp     r0, #6\n"
 656 "    bne     loc_fc117084\n"
 657 "    ldr     r2, =0xfc18b7ad\n"
 658 "    b       loc_fc117086\n"
 659 "loc_fc117084:\n"
 660 "    ldr     r2, =0xfc18b7c3\n"
 661 "loc_fc117086:\n"
 662 "    ldrh    r0, [r5, #0x18]\n"
 663 "    ldr     r4, =0x0002f888\n"
 664 "    cbz     r0, loc_fc117094\n"
 665 "    cmp     r0, #1\n"
 666 "    beq     loc_fc1170aa\n"
 667 "    cmp     r0, #4\n"
 668 "    bne     loc_fc1170fa\n"
 669 "loc_fc117094:\n"
 670 "    str     r6, [sp]\n"
 671 "    mov     r3, r2\n"
 672 "    ldr     r1, [r5, #0x38]\n"
 673 "    mov     r0, r5\n"
 674 "    ldr     r2, [r4]\n"
 675 "    bl      sub_fc18b4b2\n"
 676 "    mov     r4, r0\n"
 677 "    bl      sub_fc2cd166\n"
 678 "    b       loc_fc117108\n"
 679 "loc_fc1170aa:\n"
 680 "    str     r6, [sp]\n"
 681 "    mov     r3, r2\n"
 682 "    ldr     r1, [r5, #0x38]\n"
 683 "    mov     sb, r4\n"
 684 "    ldr     r2, [r4]\n"
 685 "    mov     r0, r5\n"
 686 "    bl      sub_fc18b51c\n"
 687 "    movs    r2, #1\n"
 688 "    mov     r4, r0\n"
 689 "    movs    r1, #0\n"
 690 "    movs    r0, #0x45\n"
 691 "    bl      sub_fc2a6bec\n"
 692 "    lsls    r0, r4, #0x1f\n"
 693 "    bne     loc_fc117108\n"
 694 "    ldr     r0, =0xfc116f7d\n"
 695 "    movs    r1, #0\n"
 696 "    bl      sub_fc144f10\n"
 697 "    movs    r1, #1\n"
 698 "    mov     r0, r5\n"
 699 "    bl      sub_fc116f7e\n"
 700 "    mov     r6, r0\n"
 701 "    ldr.w   r0, [sb]\n"
 702 "    mov     r4, sb\n"
 703 "    bl      sub_fc18b8b0\n"
 704 "    ldr     r1, [r5, #0x38]\n"
 705 "    mov     r3, r6\n"
 706 "    ldr     r2, [r4]\n"
 707 "    mov     r0, r5\n"
 708 "    bl      sub_fc18b594\n"
 709 "    mov     r4, r0\n"
 710 "    bl      sub_fc18b45a\n"
 711 "    b       loc_fc117108\n"
 712 "loc_fc1170fa:\n"
 713 "    movs    r0, #0\n"
 714 "    movw    r2, #0x1a7\n"
 715 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 716 "    blx     sub_fc314e20\n" // j_DebugAssert
 717 "    movs    r4, #0x1d\n"
 718 "loc_fc117108:\n"
 719 "    bl      sub_fc18bb0c\n"
 720 "    lsls    r0, r4, #0x1f\n"
 721 "    bne     loc_fc117172\n"
 722 "    mov     r0, r5\n"
 723 "    bl      sub_fc18bb22\n"
 724 "    ldr.w   r0, [r7, #0x108]\n"
 725 "    cbnz    r0, loc_fc11713a\n"
 726 "    mov     r0, r5\n"
 727 "    bl      sub_fc1105c2\n"
 728 "    cbnz    r0, loc_fc11713a\n"
 729 "    mov     r0, r5\n"
 730 "    bl      sub_fc18c262\n"
 731 "    lsls    r0, r0, #0x1f\n"
 732 "    beq     loc_fc11713a\n"
 733 "    movs    r0, #0\n"
 734 "    movw    r2, #0x1c8\n"
 735 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 736 "    blx     sub_fc314e20\n" // j_DebugAssert
 737 "loc_fc11713a:\n"
 738 "    b       loc_fc11713e\n"
 739 "loc_fc11713c:\n"
 740 "    b       loc_fc117172\n"
 741 "loc_fc11713e:\n"
 742 #ifdef CAPTSEQ_DEBUG
 743 "bl log_rh\n"
 744 #endif
 745 "    bl      capt_seq_hook_raw_here\n" //----------------------------------- ???? ----------
 746 "    mov     r0, r5\n"
 747 "    bl      sub_fc18baf8\n"
 748 "    mov     r0, r5\n"
 749 "    bl      sub_fc18bacc\n"
 750 "    cmp     r6, r8\n"
 751 "    beq     loc_fc117172\n"
 752 "    bl      sub_fc18bc92\n"
 753 "    movs    r1, #4\n"
 754 "    movw    sb, #0x1d5\n"
 755 "    ldr     r3, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 756 "    movw    r2, #0x3a98\n"
 757 "    str.w   sb, [sp]\n"
 758 "    bl      sub_fc33e2b4\n"
 759 "    cbz     r0, loc_fc117172\n"
 760 "    movs    r0, #0\n"
 761 "    mov     r2, sb\n"
 762 "    ldr     r1, =0xfc1171c8\n" //  *"SsStandardCaptureSeq.c"
 763 "    blx     sub_fc314e20\n" // j_DebugAssert
 764 "loc_fc117172:\n"
 765 "    ldr.w   r0, [r7, #0x18c]\n"
 766 "    cbz     r0, loc_fc117182\n"
 767 "    movs    r2, #1\n"
 768 "    movs    r1, #0\n"
 769 "    movs    r0, #0x46\n"
 770 "    bl      sub_fc2a6bec\n"
 771 "loc_fc117182:\n"
 772 "    movs    r1, #2\n"
 773 "    mov     r2, r5\n"
 774 "    mov     r0, r4\n"
 775 "    bl      sub_fc1026fa\n"
 776 "    ldr     r0, [r7, #0x28]\n"
 777 "    cmp     r0, #0\n"
 778 "    mov     r0, r8\n"
 779 "    beq     loc_fc1171a8\n"
 780 "    cmp     r6, r0\n"
 781 "    beq     loc_fc11719c\n"
 782 "    movs    r1, #1\n"
 783 "    b       loc_fc11719e\n"
 784 "loc_fc11719c:\n"
 785 "    movs    r1, #0\n"
 786 "loc_fc11719e:\n"
 787 "    mov     r2, r4\n"
 788 "    mov     r0, r5\n"
 789 "    bl      sub_fc18bfae\n"
 790 "    b       loc_fc1171ba\n"
 791 "loc_fc1171a8:\n"
 792 "    cmp     r6, r0\n"
 793 "    beq     loc_fc1171b0\n"
 794 "    movs    r1, #1\n"
 795 "    b       loc_fc1171b2\n"
 796 "loc_fc1171b0:\n"
 797 "    movs    r1, #0\n"
 798 "loc_fc1171b2:\n"
 799 "    mov     r2, r4\n"
 800 "    mov     r0, r5\n"
 801 "    bl      sub_fc18bf68\n"
 802 "loc_fc1171ba:\n"
 803 "    mov     r0, r4\n"
 804 "    pop.w   {r1, r2, r3, r4, r5, r6, r7, r8, sb, pc}\n"
 805 ".ltorg\n"
 806     );
 807 }
 808 
 809 
 810 

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