Function at 0x100219f0
Capabilities:
Contain obfuscated stackstrings
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x1011ce6b
mov eax, dword fs:[0]
push eax
mov eax, 0x11e8
call fcn.100dc600
mov eax, dword [0x10157de0]
xor eax, esp
mov dword [esp + 0x11e0], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x10157de0]
xor eax, esp
push eax
lea eax, [esp + 0x11fc]
mov dword fs:[0], eax
mov eax, dword [esp + 0x120c]
sub esp, 0x1c
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x122c]
mov dword [esp + 0x54], esp
mov dword [esp + 0x40], eax
mov eax, esp
push 0x1012b9e4
push str.1027
push str.__line:
sub esp, 0x1c
mov dword [esp + 0x78], ecx
mov ecx, esp
mov dword [esp + 0x70], esp
xor ebx, ebx
push 0x1c
mov ebp, 0xf
mov dword [ecx + 0x18], ebp
mov dword [ecx + 0x14], ebx
push str.._adaptor_cflashtool_api.cpp
mov dword [esp + 0x64], edx
mov edi, 1
mov byte [ecx + 4], bl
mov dword [esp + 0x68], eax
call fcn.10007180
lea esi, [esp + 0x220]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
mov dword [esp + 0x122c], ebx
push 3
push 0x1012ba0c
lea ecx, [esp + 0x16c]
mov dword [esp + 0x184], ebp
mov dword [esp + 0x180], ebx
mov byte [esp + 0x170], bl
call fcn.10007180
push esi
lea ecx, [esp + 0x168]
push ecx
lea edx, [esp + 0x228]
push edx
mov byte [esp + 0x1238], 1
call fcn.1000a2c0
add esp, 0xc
push eax
lea eax, [esp + 0x1ec]
push eax
mov byte [esp + 0x1234], 2
call fcn.1000a370
add esp, 0xc
push eax
lea ecx, [esp + 0x23c]
push ecx
mov byte [esp + 0x1230], 3
call fcn.1000a370
add esp, 0xc
push eax
mov byte [esp + 0x1228], 4
mov eax, dword [esp + 0x40]
push eax
call fcn.1000a370
sub esp, 0x10
mov byte [esp + 0x123c], 5
mov ecx, esp
mov dword [esp + 0x64], esp
push 0x29
mov dword [ecx + 0x18], ebp
mov dword [ecx + 0x14], ebx
push str.cflashtool_api::FlashTool_Connect_BROM_Ex
mov byte [ecx + 4], bl
call fcn.10007180
mov byte [esp + 0x123c], 4
mov ecx, edi
lea ebx, [esp + 0x360]
call fcn.10054c60
mov ebp, 0x10
cmp dword [esp + 0x22c], ebp
jb 0x10021b93
mov edx, dword [esp + 0x218]
push edx
call fcn.100d41ba
add esp, 4
xor ebx, ebx
mov esi, 0xf
mov dword [esp + 0x22c], esi
mov dword [esp + 0x228], ebx
mov byte [esp + 0x218], bl
cmp dword [esp + 0x1d8], ebp
jb 0x10021bc8
mov eax, dword [esp + 0x1c4]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x1d8], esi
mov dword [esp + 0x1d4], ebx
mov byte [esp + 0x1c4], bl
cmp dword [esp + 0x210], ebp
jb 0x10021bf6
mov ecx, dword [esp + 0x1fc]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x210], esi
mov dword [esp + 0x20c], ebx
mov byte [esp + 0x1fc], bl
cmp dword [esp + 0x154], ebp
jb 0x10021c24
mov edx, dword [esp + 0x140]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x154], esi
mov dword [esp + 0x150], ebx
mov byte [esp + 0x140], bl
mov byte [esp + 0x1204], 0xb
cmp dword [esp + 0x1f4], ebp
jb 0x10021c5a
mov eax, dword [esp + 0x1e0]
push eax
call fcn.100d41ba
add esp, 4
push 0x1ff
lea ecx, [esp + 0xff9]
push ebx
push ecx
mov dword [esp + 0x200], esi
mov dword [esp + 0x1fc], ebx
mov byte [esp + 0x1ec], bl
mov byte [esp + 0x1000], bl
call fcn.100d9c40
mov ecx, dword [esp + 0x2c]
mov eax, dword [ecx]
add esp, 0xc
sub eax, ebx
mov dword [esp + 0x28], ebx
je 0x10021fa1
sub eax, 1
je 0x10021cba
sub eax, 1
jne 0x10021fbb
mov edx, dword [ecx + 4]
push edx
push 0x1012c61c
jmp 0x10021fab
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], 4
mov dword [esp + 0x24], ecx
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x24]
push edx
lea ecx, [esp + 0x20]
push ecx
mov esi, eax
call fcn.1000a440
mov edx, dword [eax]
mov dword [esp + 0x18], edx
mov dword [eax], ebx
mov byte [esp + 0x1204], 0xc
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x10021d07
push eax
call fcn.10073310
add esp, 4
mov dword [esp + 0x1c], ebx
mov eax, dword [esp + 0x18]
cmp eax, ebx
je 0x10021f66
jmp 0x10021d20
push 0x1012b9e4
push str.1041
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x60], esp
push 0x1c
mov edi, 0xf
mov dword [ecx + 0x18], edi
mov dword [ecx + 0x14], ebx
push str.._adaptor_cflashtool_api.cpp
mov byte [ecx + 4], bl
call fcn.10007180
lea esi, [esp + 0xb8]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
mov byte [esp + 0x1210], 0xd
push 3
push 0x1012ba0c
lea ecx, [esp + 0x50]
mov dword [esp + 0x68], edi
mov dword [esp + 0x64], ebx
mov byte [esp + 0x54], bl
call fcn.10007180
push esi
lea eax, [esp + 0x4c]
push eax
lea ecx, [esp + 0x6c]
push ecx
mov byte [esp + 0x121c], 0xe
call fcn.1000a2c0
add esp, 0xc
push eax
lea edx, [esp + 0x84]
push edx
mov byte [esp + 0x1218], 0xf
call fcn.1000a370
add esp, 0xc
push eax
lea eax, [esp + 0xbc]
push eax
mov byte [esp + 0x1214], 0x10
call fcn.1000a370
add esp, 0xc
push eax
lea ecx, [esp + 0xec]
push ecx
mov byte [esp + 0x1210], 0x11
call fcn.1000a370
add esp, 0xc
mov edi, eax
mov byte [esp + 0x1204], 0x12
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x18]
push edx
push eax
lea eax, [esp + 0xd4]
push eax
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x13
mov esi, dword [eax + 4]
push 0x1c
add esi, 4
push str.not_support_handle_type_port
mov ecx, esi
call fcn.100087c0
mov eax, dword [edi + 0x14]
cmp dword [edi + 0x18], ebp
jb 0x10021e3d
mov edi, dword [edi + 4]
jmp 0x10021e40
add edi, 4
push eax
push edi
mov ecx, esi
call fcn.100087c0
lea ecx, [esp + 0xcc]
mov byte [esp + 0x1204], 0x12
call fcn.10006d40
cmp dword [esp + 0xfc], ebp
jb 0x10021e76
mov ecx, dword [esp + 0xe8]
push ecx
call fcn.100d41ba
add esp, 4
mov esi, 0xf
mov dword [esp + 0xfc], esi
mov dword [esp + 0xf8], ebx
mov byte [esp + 0xe8], bl
cmp dword [esp + 0xc8], ebp
jb 0x10021ea9
mov edx, dword [esp + 0xb4]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0xc8], esi
mov dword [esp + 0xc4], ebx
mov byte [esp + 0xb4], bl
cmp dword [esp + 0x8c], ebp
jb 0x10021ed4
mov eax, dword [esp + 0x78]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x8c], esi
mov dword [esp + 0x88], ebx
mov byte [esp + 0x78], bl
cmp dword [esp + 0x70], ebp
jb 0x10021ef9
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x70], esi
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
cmp dword [esp + 0x54], ebp
jb 0x10021f18
mov edx, dword [esp + 0x40]
push edx
call fcn.100d41ba
add esp, 4
mov byte [esp + 0x1204], 0xc
mov dword [esp + 0x54], esi
mov dword [esp + 0x50], ebx
mov byte [esp + 0x40], bl
cmp dword [esp + 0xa8], ebp
jb 0x10021f45
mov eax, dword [esp + 0x94]
push eax
call fcn.100d41ba
add esp, 4
mov eax, dword [esp + 0x18]
mov dword [esp + 0xa8], esi
mov dword [esp + 0xa4], ebx
mov byte [esp + 0x94], bl
cmp eax, ebx
jne 0x10021d20
mov byte [esp + 0x1204], 0xb
cmp eax, ebx
je 0x10021f7f
push eax
call fcn.10073310
add esp, 4
mov dword [esp + 0x18], ebx
lea ecx, [esp + 0x328]
push ecx
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
mov eax, 0xc0030007
jmp 0x100232f0
movzx edx, word [ecx + 4]
push edx
push str.COM_d
lea eax, [esp + 0xffc]
push eax
call fcn.100d334d
add esp, 0xc
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp dword [esp + 0x1214], ebx
je 0x10021ffa
mov eax, dword [0x1015d9ec]
cmp eax, ebx
je 0x10021ffa
push 0x101301fc
push eax
call edi
cmp eax, ebx
je 0x10021ffa
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x18]
mov esi, dword [esp + 0x34]
push ecx
push edx
push esi
lea ecx, [esp + 0x1000]
push ecx
call eax
jmp 0x10021ffe
mov esi, dword [esp + 0x34]
mov edx, dword [esp + 0x18]
mov eax, dword [edx]
push eax
call dword [sym.imp.FlashtoollibEx.dll_flashtool_create_session_with_handle]
mov dword [esp + 0x30], eax
cmp eax, ebx
jne 0x10022035
lea ecx, [esp + 0x328]
push ecx
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
mov eax, 0xc001000a
jmp 0x100232f0
mov edx, dword [esp + 0x24]
mov eax, dword [esi + 0x44]
mov ecx, dword [esi + 0x4c]
mov dword [esp + 0x11c], edx
mov edx, dword [esi + 0x48]
push 0x42c
mov dword [esp + 0x138], ebx
mov dword [esp + 0x138], edx
mov dword [esp + 0x130], ebx
mov dword [esp + 0x134], ebx
mov dword [esp + 0x130], eax
mov eax, dword [esi + 0x50]
mov dword [esp + 0x134], ecx
mov ecx, dword [esi + 0x3c]
lea edx, [esp + 0xbb4]
push ebx
mov dword [esp + 0x140], ebx
push edx
mov dword [esp + 0x12c], ebx
mov dword [esp + 0x130], ebx
mov dword [esp + 0x134], 0x100219d0
mov dword [esp + 0x144], eax
mov dword [esp + 0x30], ecx
mov dword [esp + 0xbb8], ebx
call fcn.100d9c40
mov eax, dword [0x1015d9ec]
add esp, 0xc
cmp eax, ebx
je 0x100220ed
push 0x10130030
push eax
call edi
cmp eax, ebx
je 0x100220ed
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0xbac]
push ecx
push edx
call eax
mov edi, eax
mov dword [esp + 0x1c], eax
jmp 0x100220f6
mov edi, 0xc001000c
mov dword [esp + 0x1c], edi
push 0x218
lea eax, [esp + 0x568]
push ebx
push eax
call fcn.100d9c40
add esp, 0xc
cmp edi, ebx
jne 0x1002219d
mov eax, dword [esp + 0xbb0]
mov dword [esp + 0x564], eax
cmp eax, ebx
je 0x1002214e
cmp eax, 2
je 0x1002214e
cmp eax, 1
jne 0x1002219d
mov ecx, dword [esp + 0xdb4]
mov edx, dword [esp + 0xdb8]
mov dword [esp + 0x774], ecx
mov dword [esp + 0x778], edx
jmp 0x1002219d
xor eax, eax
mov cl, byte [esp + eax + 0xbb4]
mov byte [esp + eax + 0x568], cl
inc eax
cmp cl, bl
jne 0x10022150
lea edi, [esp + 0x568]
call fcn.10055b50
test al, al
je 0x10022195
mov edi, dword [esp + 0x24]
mov dword [esp + 0x564], 2
call fcn.1001c6d0
mov dword [esp + 0x768], eax
mov dword [esp + 0x76c], edx
mov esi, dword [esp + 0x34]
mov edi, dword [esp + 0x1c]
mov esi, dword [esi + 0x40]
push 0x42c
lea eax, [esp + 0x784]
push ebx
push eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x788], ebx
call fcn.100d9c40
add esp, 0xc
cmp dword [0x1015d9ec], ebx
je 0x100221ee
mov ecx, dword [0x1015d9ec]
push 0x101300ac
push ecx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x100221ee
lea edx, [esp + 0x77c]
push edx
push esi
call eax
mov esi, eax
jmp 0x100221f3
mov esi, 0xc001000c
push 0x218
lea eax, [esp + 0x350]
push ebx
push eax
call fcn.100d9c40
add esp, 0xc
cmp esi, ebx
jne 0x10022299
mov eax, dword [esp + 0x780]
mov dword [esp + 0x34c], eax
cmp eax, ebx
je 0x1002224b
cmp eax, 2
je 0x1002224b
cmp eax, 1
jne 0x10022299
mov ecx, dword [esp + 0x984]
mov edx, dword [esp + 0x988]
mov dword [esp + 0x55c], ecx
mov dword [esp + 0x560], edx
jmp 0x10022299
xor eax, eax
lea ecx, [ecx]
mov cl, byte [esp + eax + 0x784]
mov byte [esp + eax + 0x350], cl
inc eax
cmp cl, bl
jne 0x10022250
lea edi, [esp + 0x350]
call fcn.10055b50
test al, al
je 0x10022295
mov edi, dword [esp + 0x20]
mov dword [esp + 0x34c], 2
call fcn.1001c750
mov dword [esp + 0x550], eax
mov dword [esp + 0x554], edx
mov edi, dword [esp + 0x1c]
cmp dword [esp + 0x1214], ebx
je 0x100222df
neg esi
sbb esi, esi
lea ecx, [esp + 0x34c]
not esi
and esi, ecx
mov ecx, dword [esp + 0x30]
neg edi
sbb edi, edi
lea eax, [esp + 0x11c]
push eax
push esi
lea edx, [esp + 0x56c]
not edi
and edi, edx
push edi
lea eax, [esp + 0x1000]
push eax
push ecx
call dword [sym.imp.FlashtoollibEx.dll_flashtool_connect_brom]
jmp 0x1002231a
neg esi
sbb esi, esi
lea eax, [esp + 0x34c]
not esi
and esi, eax
mov eax, dword [esp + 0x30]
neg edi
sbb edi, edi
lea edx, [esp + 0x11c]
push edx
push esi
lea ecx, [esp + 0x56c]
not edi
and edi, ecx
push edi
lea edx, [esp + 0x1000]
push edx
push eax
call dword [sym.imp.FlashtoollibEx.dll__flashtool_connect_brom_with_handle_20]
mov dword [esp + 0x28], eax
mov dword [esp + 0xac], ebx
mov byte [esp + 0xfe8], bl
mov dword [esp + 0xfe9], ebx
mov dword [esp + 0xfed], ebx
mov byte [esp + 0xff1], bl
mov byte [esp + 0xfdc], bl
mov dword [esp + 0xfdd], ebx
mov dword [esp + 0xfe1], ebx
mov byte [esp + 0xfe5], bl
cmp eax, ebx
jne 0x100227b2
mov edx, dword [esp + 0x18]
mov eax, dword [edx]
lea ecx, [esp + 0x1b8]
push ecx
push eax
call fcn.10039800
mov dword [esp + 0x28], eax
cmp eax, ebx
je 0x100226da
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], 3
mov dword [esp + 0x2c], ecx
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x2c]
push edx
lea ecx, [esp + 0x28]
push ecx
mov esi, eax
call fcn.1000a440
mov edx, dword [eax]
mov dword [esp + 0x1c], edx
mov dword [eax], ebx
mov byte [esp + 0x1204], 0x14
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x100223d2
push eax
call fcn.10073310
add esp, 4
mov dword [esp + 0x24], ebx
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x100226c5
lea eax, [esp + 0x28]
mov dword [esp + 0xcc], eax
mov dword [esp + 0xd0], 0x1003fae0
mov dword [esp + 0xd4], 0x1003faf0
nop
push 0x1012b9e4
push str.1148
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x60], esp
push 0x1c
mov edi, 0xf
mov dword [ecx + 0x18], edi
mov dword [ecx + 0x14], ebx
push str.._adaptor_cflashtool_api.cpp
mov byte [ecx + 4], bl
call fcn.10007180
lea esi, [esp + 0x128]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
mov byte [esp + 0x1210], 0x15
push 3
push 0x1012ba0c
lea ecx, [esp + 0x50]
mov dword [esp + 0x68], edi
mov dword [esp + 0x64], ebx
mov byte [esp + 0x54], bl
call fcn.10007180
push esi
lea ecx, [esp + 0x4c]
push ecx
lea edx, [esp + 0xf8]
push edx
mov byte [esp + 0x121c], 0x16
call fcn.1000a2c0
add esp, 0xc
push eax
lea eax, [esp + 0xc0]
push eax
mov byte [esp + 0x1218], 0x17
call fcn.1000a370
add esp, 0xc
push eax
lea ecx, [esp + 0x80]
push ecx
mov byte [esp + 0x1214], 0x18
call fcn.1000a370
add esp, 0xc
push eax
lea edx, [esp + 0x60]
push edx
mov byte [esp + 0x1210], 0x19
call fcn.1000a370
add esp, 0xc
mov ebp, eax
push str.Get_support_Modem_fail:_0x_x
lea eax, [esp + 0x26c]
push eax
mov byte [esp + 0x120c], 0x1a
call fcn.10009e20
lea ecx, [esp + 0xcc]
push ecx
mov byte [esp + 0x1208], 0x1b
call fcn.10011e10
add esp, 4
lea edx, [esp + 0x90]
mov ecx, eax
call fcn.10009f20
mov edi, eax
mov byte [esp + 0x1204], 0x1c
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x1c]
push edx
push eax
lea eax, [esp + 0xe0]
push eax
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x1d
mov esi, dword [eax + 4]
mov eax, dword [edi + 0x14]
add esi, 4
cmp dword [edi + 0x18], 0x10
jb 0x10022552
mov edi, dword [edi + 4]
jmp 0x10022555
add edi, 4
push eax
push edi
mov ecx, esi
call fcn.100087c0
mov eax, dword [ebp + 0x14]
mov edi, 0x10
cmp dword [ebp + 0x18], edi
jb 0x10022570
mov ebp, dword [ebp + 4]
jmp 0x10022573
add ebp, 4
push eax
push ebp
mov ecx, esi
call fcn.100087c0
lea ecx, [esp + 0xd8]
mov byte [esp + 0x1204], 0x1c
call fcn.10006d40
cmp dword [esp + 0xa8], edi
jb 0x100225a9
mov ecx, dword [esp + 0x94]
push ecx
call fcn.100d41ba
add esp, 4
mov ebp, 0xf
lea edi, [esp + 0x268]
mov dword [esp + 0xa8], ebp
mov dword [esp + 0xa4], ebx
mov byte [esp + 0x94], bl
call fcn.10003aa0
mov esi, 0x10
cmp dword [esp + 0x70], esi
jb 0x100225e7
mov edx, dword [esp + 0x5c]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x70], ebp
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
cmp dword [esp + 0x8c], esi
jb 0x10022609
mov eax, dword [esp + 0x78]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x8c], ebp
mov dword [esp + 0x88], ebx
mov byte [esp + 0x78], bl
cmp dword [esp + 0xc8], esi
jb 0x10022634
mov ecx, dword [esp + 0xb4]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0xc8], ebp
mov dword [esp + 0xc4], ebx
mov byte [esp + 0xb4], bl
cmp dword [esp + 0xfc], esi
jb 0x10022662
mov edx, dword [esp + 0xe8]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0xfc], ebp
mov dword [esp + 0xf8], ebx
mov byte [esp + 0xe8], bl
cmp dword [esp + 0x54], esi
jb 0x1002268a
mov eax, dword [esp + 0x40]
push eax
call fcn.100d41ba
add esp, 4
mov byte [esp + 0x1204], 0x14
mov dword [esp + 0x54], ebp
mov dword [esp + 0x50], ebx
mov byte [esp + 0x40], bl
cmp dword [esp + 0x118], esi
jb 0x100226b7
mov ecx, dword [esp + 0x104]
push ecx
call fcn.100d41ba
add esp, 4
mov eax, dword [esp + 0x1c]
cmp eax, ebx
jne 0x10022400
mov ebp, esi
mov byte [esp + 0x1204], 0xb
cmp eax, ebx
je 0x100226da
push eax
call fcn.10073310
add esp, 4
cmp dword [esp + 0x1214], ebx
je 0x100227e0
mov ecx, dword [esp + 0x30]
lea edx, [esp + 0x1bc]
push edx
push 0xc
lea eax, [esp + 0x160]
push eax
push ebx
push ebx
push 1
push ecx
call dword [sym.imp.FlashtoollibEx.dll_flashtool_device_control]
mov dword [esp + 0x28], eax
cmp eax, ebx
jne 0x100227b2
mov eax, dword [esp + 0x18]
mov ecx, dword [eax]
lea edx, [esp + 0xac]
push edx
push ecx
call sym.Flashtoollib.dll_FlashTool_GetDLHandle
mov dword [esp + 0x28], eax
cmp eax, ebx
jne 0x100227b2
mov eax, dword [esp + 0xac]
lea edx, [esp + 0xfe8]
push edx
push eax
call sym.Flashtoollib.dll_DL_Get_PlatformName
mov dword [esp + 0x28], eax
cmp eax, ebx
jne 0x100227b2
mov edx, dword [esp + 0xac]
lea ecx, [esp + 0xfdc]
push ecx
push edx
call sym.Flashtoollib.dll_DL_Get_ChipVersion
mov dword [esp + 0x28], eax
cmp eax, ebx
jne 0x100227b2
mov edx, dword [esp + 0x158]
lea eax, [esp + 0xfdc]
push eax
lea ecx, [esp + 0xfec]
push ecx
mov ecx, dword [esp + 0x164]
sub esp, 0xc
mov eax, esp
mov dword [eax], edx
mov edx, dword [esp + 0x174]
mov dword [eax + 4], ecx
mov dword [eax + 8], edx
call dword [sym.imp.FlashtoollibEx.dll__flashtool_is_chiptype_match_20]
test al, al
jne 0x100227e0
mov dword [esp + 0x28], 0xc003000f
mov eax, dword [esp + 0x30]
push eax
call dword [sym.imp.FlashtoollibEx.dll_flashtool_destroy_session]
mov esi, dword [esp + 0x28]
lea ecx, [esp + 0x328]
push ecx
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
mov eax, esi
jmp 0x100232f0
mov edx, dword [esp + 0x34]
cmp dword [edx + 0x24], ebx
je 0x10022d6e
lea eax, [esp + 0x2c]
mov dword [esp + 0x2c], 1
mov dword [esp + 0x20], eax
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x28]
push edx
mov esi, eax
call fcn.1000a440
mov ecx, dword [eax]
mov dword [esp + 0x1c], ecx
mov dword [eax], ebx
mov byte [esp + 0x1204], 0x1e
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x1002283a
push eax
call fcn.10073310
add esp, 4
mov dword [esp + 0x24], ebx
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x10022a81
jmp 0x10022850
push 0x1012b9e4
push str.1186
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x48], esp
push 0x1c
mov edi, 0xf
mov dword [ecx + 0x18], edi
mov dword [ecx + 0x14], ebx
push str.._adaptor_cflashtool_api.cpp
mov byte [ecx + 4], bl
call fcn.10007180
lea esi, [esp + 0x128]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
mov byte [esp + 0x1210], 0x1f
push 3
push 0x1012ba0c
lea ecx, [esp + 0x50]
mov dword [esp + 0x68], edi
mov dword [esp + 0x64], ebx
mov byte [esp + 0x54], bl
call fcn.10007180
push esi
lea edx, [esp + 0x4c]
push edx
lea eax, [esp + 0xc4]
push eax
mov byte [esp + 0x121c], 0x20
call fcn.1000a2c0
add esp, 0xc
push eax
lea ecx, [esp + 0x84]
push ecx
mov byte [esp + 0x1218], 0x21
call fcn.1000a370
add esp, 0xc
push eax
lea edx, [esp + 0x64]
push edx
mov byte [esp + 0x1214], 0x22
call fcn.1000a370
add esp, 0xc
push eax
lea eax, [esp + 0x98]
push eax
mov byte [esp + 0x1210], 0x23
call fcn.1000a370
add esp, 0xc
mov edi, eax
mov byte [esp + 0x1204], 0x24
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x1c]
push ecx
push eax
lea edx, [esp + 0xe0]
push edx
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x25
mov esi, dword [eax + 4]
push 0x16
add esi, 4
push str.callback_in_brom_stage
mov ecx, esi
call fcn.100087c0
mov eax, dword [edi + 0x14]
cmp dword [edi + 0x18], ebp
jb 0x1002296d
mov edi, dword [edi + 4]
jmp 0x10022970
add edi, 4
push eax
push edi
mov ecx, esi
call fcn.100087c0
lea ecx, [esp + 0xd8]
mov byte [esp + 0x1204], 0x24
call fcn.10006d40
cmp dword [esp + 0xa8], ebp
jb 0x100229a6
mov eax, dword [esp + 0x94]
push eax
call fcn.100d41ba
add esp, 4
mov esi, 0xf
mov dword [esp + 0xa8], esi
mov dword [esp + 0xa4], ebx
mov byte [esp + 0x94], bl
cmp dword [esp + 0x70], ebp
jb 0x100229d3
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x70], esi
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
cmp dword [esp + 0x8c], ebp
jb 0x100229f5
mov edx, dword [esp + 0x78]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x8c], esi
mov dword [esp + 0x88], ebx
mov byte [esp + 0x78], bl
cmp dword [esp + 0xc8], ebp
jb 0x10022a20
mov eax, dword [esp + 0xb4]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0xc8], esi
mov dword [esp + 0xc4], ebx
mov byte [esp + 0xb4], bl
cmp dword [esp + 0x54], ebp
jb 0x10022a48
mov ecx, dword [esp + 0x40]
push ecx
call fcn.100d41ba
add esp, 4
mov byte [esp + 0x1204], 0x1e
mov dword [esp + 0x54], esi
mov dword [esp + 0x50], ebx
mov byte [esp + 0x40], bl
cmp dword [esp + 0x118], ebp
jb 0x10022a75
mov edx, dword [esp + 0x104]
push edx
call fcn.100d41ba
add esp, 4
mov eax, dword [esp + 0x1c]
cmp eax, ebx
jne 0x10022850
mov byte [esp + 0x1204], 0xb
cmp eax, ebx
je 0x10022a9a
push eax
call fcn.10073310
add esp, 4
mov dword [esp + 0x1c], ebx
mov ecx, dword [esp + 0x30]
lea eax, [esp + 0x38]
push eax
push ecx
call dword [sym.imp.FlashtoollibEx.dll_flashtool_get_com_handle]
mov dword [esp + 0x28], eax
cmp eax, ebx
je 0x10022ad3
lea edx, [esp + 0x328]
push edx
mov esi, eax
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
mov eax, esi
jmp 0x100232f0
mov eax, dword [esp + 0x34]
mov ecx, dword [eax + 0x28]
mov edx, dword [esp + 0x38]
mov eax, dword [eax + 0x24]
push ecx
mov ecx, dword [esp + 0x1c]
push edx
mov edx, dword [ecx]
push edx
call eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], 1
cmp eax, ebx
jne 0x10022ec8
lea ecx, [esp + 0x2c]
mov dword [esp + 0x20], ecx
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x20]
push edx
lea ecx, [esp + 0x28]
push ecx
mov esi, eax
call fcn.1000a440
mov edx, dword [eax]
mov dword [esp + 0x18], edx
mov dword [eax], ebx
lea ecx, [esp + 0x24]
mov byte [esp + 0x1204], 0x26
call fcn.10002f90
cmp dword [esp + 0x18], ebx
je 0x10022d5d
jmp 0x10022b50
push 0x1012b9e4
push str.1194
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x48], esp
push str.._adaptor_cflashtool_api.cpp
call fcn.10006340
lea esi, [esp + 0x128]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
push 0x1012ba0c
lea ecx, [esp + 0xf4]
mov byte [esp + 0x1214], 0x27
call fcn.10006340
push esi
push eax
lea eax, [esp + 0xc4]
push eax
mov byte [esp + 0x121c], 0x28
call fcn.1000a2c0
add esp, 0xc
push eax
lea ecx, [esp + 0x84]
push ecx
mov byte [esp + 0x1218], 0x29
call fcn.1000a370
add esp, 0xc
push eax
lea edx, [esp + 0x64]
push edx
mov byte [esp + 0x1214], 0x2a
call fcn.1000a370
add esp, 0xc
push eax
lea eax, [esp + 0x98]
push eax
mov byte [esp + 0x1210], 0x2b
call fcn.1000a370
add esp, 0xc
mov edi, eax
mov byte [esp + 0x1204], 0x2c
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x18]
push ecx
push eax
lea edx, [esp + 0xe0]
push edx
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x2d
mov esi, dword [eax + 4]
push 0x1e
add esi, 4
push str.m_cb_in_brom_stage_run_success
mov ecx, esi
call fcn.100087c0
mov eax, edi
call fcn.1000a600
lea ecx, [esp + 0xd8]
mov byte [esp + 0x1204], 0x2c
call fcn.10006d40
cmp dword [esp + 0xa8], ebp
jb 0x10022c75
mov eax, dword [esp + 0x94]
push eax
call fcn.100d41ba
add esp, 4
mov esi, 0xf
mov dword [esp + 0xa8], esi
mov dword [esp + 0xa4], ebx
mov byte [esp + 0x94], bl
cmp dword [esp + 0x70], ebp
jb 0x10022ca2
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x70], esi
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
cmp dword [esp + 0x8c], ebp
jb 0x10022cc4
mov edx, dword [esp + 0x78]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x8c], esi
mov dword [esp + 0x88], ebx
mov byte [esp + 0x78], bl
cmp dword [esp + 0xc8], ebp
jb 0x10022cef
mov eax, dword [esp + 0xb4]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0xc8], esi
mov dword [esp + 0xc4], ebx
mov byte [esp + 0xb4], bl
cmp dword [esp + 0xfc], ebp
jb 0x10022d1d
mov ecx, dword [esp + 0xe8]
push ecx
call fcn.100d41ba
add esp, 4
mov byte [esp + 0x1204], 0x26
mov dword [esp + 0xfc], esi
mov dword [esp + 0xf8], ebx
mov byte [esp + 0xe8], bl
cmp dword [esp + 0x118], ebp
jb 0x10022d53
mov edx, dword [esp + 0x104]
push edx
call fcn.100d41ba
add esp, 4
cmp dword [esp + 0x18], ebx
jne 0x10022b50
lea ecx, [esp + 0x18]
mov byte [esp + 0x1204], 0xb
call fcn.10002f90
lea ecx, [esp + 0x38]
mov dword [esp + 0x38], 1
mov dword [esp + 0x2c], ecx
call fcn.1005bc20
mov eax, dword [eax]
lea edx, [esp + 0x2c]
push edx
lea ecx, [esp + 0x24]
push ecx
mov esi, eax
call fcn.1000a440
mov edx, dword [eax]
mov dword [esp + 0x30], edx
mov dword [eax], ebx
lea ecx, [esp + 0x20]
mov byte [esp + 0x1204], 0x38
call fcn.10002f90
cmp dword [esp + 0x30], ebx
je 0x100232c5
lea esp, [esp]
push 0x1012b9e4
push str.1200
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x54], esp
push str.._adaptor_cflashtool_api.cpp
call fcn.10006340
lea esi, [esp + 0x128]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
push 0x1012ba0c
lea ecx, [esp + 0x190]
mov byte [esp + 0x1214], 0x39
call fcn.10006340
push esi
push eax
lea eax, [esp + 0x178]
push eax
mov byte [esp + 0x121c], 0x3a
call fcn.1000a2c0
add esp, 0xc
push eax
lea ecx, [esp + 0x1ac]
push ecx
mov byte [esp + 0x1218], 0x3b
call fcn.1000a370
add esp, 0xc
push eax
lea edx, [esp + 0x23c]
push edx
mov byte [esp + 0x1214], 0x3c
call fcn.1000a370
add esp, 0xc
push eax
lea eax, [esp + 0x254]
push eax
mov byte [esp + 0x1210], 0x3d
call fcn.1000a370
add esp, 0xc
mov edi, eax
mov byte [esp + 0x1204], 0x3e
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x30]
push ecx
push eax
lea edx, [esp + 0xe0]
push edx
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x3f
mov esi, dword [eax + 4]
push 0x12
add esi, 4
push str.connect_brom_ex_OK
mov ecx, esi
call fcn.100087c0
mov eax, dword [edi + 0x14]
cmp dword [edi + 0x18], ebp
jb 0x1002317a
mov edi, dword [edi + 4]
jmp 0x1002317d
lea eax, [esp + 0x2c]
mov dword [esp + 0x20], eax
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x28]
push edx
mov esi, eax
call fcn.1000a440
mov ecx, dword [eax]
mov dword [esp + 0x18], ecx
mov dword [eax], ebx
lea ecx, [esp + 0x24]
mov byte [esp + 0x1204], 0x2e
call fcn.10002f90
cmp dword [esp + 0x18], ebx
je 0x10023147
lea edx, [esp + 0x28]
mov dword [esp + 0xcc], edx
mov dword [esp + 0xd0], 0x1003fae0
mov dword [esp + 0xd4], 0x1003faf0
lea esp, [esp]
push 0x1012b9e4
push str.1196
push str.__line:
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x48], esp
push str.._adaptor_cflashtool_api.cpp
call fcn.10006340
lea esi, [esp + 0x1c4]
call fcn.1001a7c0
add esp, 0x1c
mov esi, eax
push 0x1012ba0c
lea ecx, [esp + 0x174]
mov byte [esp + 0x1214], 0x2f
call fcn.10006340
push esi
push eax
lea eax, [esp + 0x194]
push eax
mov byte [esp + 0x121c], 0x30
call fcn.1000a2c0
add esp, 0xc
push eax
lea ecx, [esp + 0x110]
push ecx
mov byte [esp + 0x1218], 0x31
call fcn.1000a370
add esp, 0xc
push eax
lea edx, [esp + 0x80]
push edx
mov byte [esp + 0x1214], 0x32
call fcn.1000a370
add esp, 0xc
push eax
lea eax, [esp + 0x60]
push eax
mov byte [esp + 0x1210], 0x33
call fcn.1000a370
add esp, 0xc
mov edi, eax
push str.m_cb_in_brom_stage_fail__ret__0x_x
lea ecx, [esp + 0x26c]
push ecx
mov byte [esp + 0x120c], 0x34
call fcn.10009e20
lea edx, [esp + 0xcc]
push edx
mov byte [esp + 0x1208], 0x35
call fcn.10011e10
add esp, 4
lea edx, [esp + 0x90]
mov ecx, eax
call fcn.10009f20
mov ebp, eax
mov byte [esp + 0x1204], 0x36
call fcn.1005bc20
mov eax, dword [eax]
lea ecx, [esp + 0x18]
push ecx
push eax
lea edx, [esp + 0xe0]
push edx
call fcn.1000a4f0
add esp, 0xc
mov byte [esp + 0x1204], 0x37
mov esi, dword [eax + 4]
add esi, 4
mov eax, ebp
call fcn.1000a600
mov esi, eax
mov eax, edi
call fcn.1000a600
lea ecx, [esp + 0xd8]
mov byte [esp + 0x1204], 0x36
call fcn.10006d40
cmp dword [esp + 0xa8], 0x10
jb 0x10023093
mov eax, dword [esp + 0x94]
push eax
call fcn.100d41ba
add esp, 4
mov esi, 0xf
lea edi, [esp + 0x268]
mov dword [esp + 0xa8], esi
mov dword [esp + 0xa4], ebx
mov byte [esp + 0x94], bl
call fcn.10003aa0
mov edi, 0x10
cmp dword [esp + 0x70], edi
jb 0x100230d1
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x70], esi
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
cmp dword [esp + 0x8c], edi
jb 0x100230f3
mov edx, dword [esp + 0x78]
push edx
call fcn.100d41ba
add esp, 4
lea ecx, [esp + 0x100]
mov dword [esp + 0x8c], esi
mov dword [esp + 0x88], ebx
mov byte [esp + 0x78], bl
call fcn.100063b0
lea ecx, [esp + 0x180]
call fcn.100063b0
lea ecx, [esp + 0x164]
call fcn.100063b0
lea ecx, [esp + 0x19c]
mov byte [esp + 0x1204], 0x2e
call fcn.100063b0
cmp dword [esp + 0x18], ebx
jne 0x10022f30
lea ecx, [esp + 0x18]
mov byte [esp + 0x1204], 0xb
call fcn.10002f90
lea eax, [esp + 0x328]
push eax
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
mov eax, 0xc0060006
jmp 0x100232f0
add edi, 4
push eax
push edi
mov ecx, esi
call fcn.100087c0
lea ecx, [esp + 0xd8]
mov byte [esp + 0x1204], 0x3e
call fcn.10006d40
cmp dword [esp + 0x264], ebp
jb 0x100231b3
mov eax, dword [esp + 0x250]
push eax
call fcn.100d41ba
add esp, 4
mov esi, 0xf
mov dword [esp + 0x264], esi
mov dword [esp + 0x260], ebx
mov byte [esp + 0x250], bl
cmp dword [esp + 0x248], ebp
jb 0x100231e6
mov ecx, dword [esp + 0x234]
push ecx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x248], esi
mov dword [esp + 0x244], ebx
mov byte [esp + 0x234], bl
cmp dword [esp + 0x1b4], ebp
jb 0x10023214
mov edx, dword [esp + 0x1a0]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x1b4], esi
mov dword [esp + 0x1b0], ebx
mov byte [esp + 0x1a0], bl
cmp dword [esp + 0x17c], ebp
jb 0x10023242
mov eax, dword [esp + 0x168]
push eax
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x17c], esi
mov dword [esp + 0x178], ebx
mov byte [esp + 0x168], bl
cmp dword [esp + 0x198], ebp
jb 0x10023270
mov ecx, dword [esp + 0x184]
push ecx
call fcn.100d41ba
add esp, 4
mov byte [esp + 0x1204], 0x38
mov dword [esp + 0x198], esi
mov dword [esp + 0x194], ebx
mov byte [esp + 0x184], bl
cmp dword [esp + 0x118], ebp
jb 0x100232a6
mov edx, dword [esp + 0x104]
push edx
call fcn.100d41ba
add esp, 4
mov dword [esp + 0x118], esi
mov dword [esp + 0x114], ebx
mov byte [esp + 0x104], bl
cmp dword [esp + 0x30], ebx
jne 0x10022dc0
lea ecx, [esp + 0x30]
mov byte [esp + 0x1204], 0xb
call fcn.10002f90
lea eax, [esp + 0x328]
push eax
mov dword [esp + 0x1208], 0xffffffff
call fcn.10054f00
xor eax, eax
mov ecx, dword [esp + 0x11fc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x11e0]
xor ecx, esp
call fcn.100d32e1
add esp, 0x11f4
ret 0xc