Function at 0x439134
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffcc
cmp dword [0x45ac94], 2
jne 0x439154
cmp dword [0x45aca8], 0
je 0x439154
push 1
call fcn.0042a02c
pop ecx
cmp dword [0x45d844], 0
jne 0x439167
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d844], eax
cmp dword [0x45d844], 0
jne 0x43917a
mov dword [0x45d844], 1
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d848], eax
cmp dword [0x45d848], 0
jne 0x439197
mov dword [0x45d848], 1
cmp dword [0x44f8f4], 0
jne 0x439204
call sub.KERNEL32.DLL_GetTickCount
sub eax, dword [0x45d844]
cmp eax, 0x1388
jbe 0x439204
cmp dword [0x45aca0], 0
jne 0x439204
cmp dword [0x45aca8], 0
jne 0x439204
call fcn.0043fe64
push 0x1f4
call fcn.00404bf0
pop ecx
push 0
push dword [0x44fff4]
push dword [ebp + 8]
call fcn.00429ec0
add esp, 0xc
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d844], eax
cmp dword [0x45d844], 0
jne 0x439204
mov dword [0x45d844], 1
cmp dword [0x45c3d4], 0
jne 0x439215
or eax, 0xffffffff
jmp 0x4397e4
xor edx, edx
mov dword [ebp - 4], edx
lea ecx, [ebp - 0x34]
push ecx
lea eax, [ebp - 0x20]
push eax
mov edx, dword [0x45c3d4]
push dword [edx]
call sub.KERNEL32.DLL_ClearCommError
test eax, eax
je 0x439239
cmp dword [ebp - 0x20], 0
je 0x439242
inc dword [ebp - 4]
cmp dword [ebp - 4], 0x14
jl 0x43921a
cmp dword [0x44f8f4], 0
jne 0x4392b4
cmp dword [ebp - 0x2c], 0
ja 0x439297
cmp dword [0x45ac90], 0
jne 0x439297
call sub.KERNEL32.DLL_GetTickCount
sub eax, dword [0x45d848]
cmp eax, 0x7d0
jbe 0x4392b4
push 0xffffffffffffffff
push 0x461b0c
call fcn.0043fd18
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d848], eax
cmp dword [0x45d848], 0
jne 0x4392b4
mov dword [0x45d848], 1
jmp 0x4392b4
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d848], eax
cmp dword [0x45d848], 0
jne 0x4392b4
mov dword [0x45d848], 1
call sub.KERNEL32.DLL_GetTickCount
mov dword [ebp - 0x1c], eax
jmp 0x4397ce
push 1
mov ecx, 0x187beac
add ecx, dword [0x45d84c]
push ecx
call fcn.0043fbbc
dec eax
jne 0x4397e1
mov eax, dword [0x45d84c]
xor edx, edx
mov dl, byte [eax + 0x187beac]
mov dword [ebp - 0xc], edx
mov cl, byte [ebp - 0xc]
mov eax, dword [0x45d858]
mov byte [eax + 0x187c040], cl
inc dword [0x45d858]
cmp dword [0x45d858], 3
jg 0x439390
mov edx, dword [0x45d858]
movsx ecx, byte [edx + 0x187c03f]
mov dword [ebp - 0x24], ecx
push dword [ebp - 0x24]
call fcn.00447c30
pop ecx
mov edx, dword [0x45d858]
movsx ecx, byte [edx + 0x45d7ea]
cmp eax, ecx
je 0x439390
mov eax, dword [0x45d858]
mov al, byte [eax + 0x187c03f]
mov edx, dword [0x45d858]
cmp al, byte [edx + 0x45d7f6]
je 0x439390
push str.M5R_31__sync_r_n
call fcn.0040391c
pop ecx
xor ecx, ecx
mov dword [0x45d858], ecx
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x28], eax
push dword [ebp - 0x28]
call fcn.00447c30
pop ecx
movsx edx, byte [0x45d7eb]
cmp eax, edx
jne 0x439390
mov cl, byte [ebp - 0xc]
mov eax, dword [0x45d858]
mov byte [eax + 0x187c040], cl
inc dword [0x45d858]
cmp dword [0x45d858], 0
setg dl
and edx, 1
mov dword [ebp - 0x10], edx
cmp dword [ebp - 0x10], 0
jne 0x4393d0
cmp dword [ebp - 0xc], 0
je 0x4393c0
push dword [ebp - 0xc]
push str._n_r0123456789ABCDEFGH:____my_DIRL
call fcn.004416f1
add esp, 8
test eax, eax
jne 0x4393d0
push str.M5R_31__no_char_r_n
call fcn.0040391c
pop ecx
jmp 0x4397ce
inc dword [0x45d84c]
cmp dword [0x45d858], 3
jl 0x439459
push 0x45d7f3
call fcn.004415f8
pop ecx
push eax
push 0x45d7f3
push 0x187c040
call fcn.004416c4
add esp, 0xc
test eax, eax
jne 0x43940a
mov dword [ebp - 0x18], 0x29
jmp 0x43943c
push 0x45d7f7
call fcn.004415f8
pop ecx
push eax
push 0x45d7f7
push 0x187c040
call fcn.004416c4
add esp, 0xc
test eax, eax
jne 0x439435
mov dword [ebp - 0x18], 0x31
jmp 0x43943c
mov dword [ebp - 0x18], 0x21
mov ecx, dword [0x45d858]
cmp ecx, dword [ebp - 0x18]
jl 0x439459
push str.M5R_31__new_pack___len_r_n
call fcn.0040391c
pop ecx
xor eax, eax
mov dword [0x45d858], eax
cmp dword [0x45d84c], 0x64
jne 0x439482
mov edx, dword [0x45d84c]
dec edx
push edx
push 0x187bead
push 0x187beac
call fcn.004413d8
add esp, 0xc
dec dword [0x45d84c]
cmp dword [ebp - 0x10], 0
je 0x439491
cmp dword [0x45d858], 0
je 0x4394b1
cmp dword [ebp - 0x10], 0
jne 0x4397ce
mov ecx, dword [0x45d84c]
movsx eax, byte [ecx + 0x187beab]
cmp eax, 0xa
jne 0x4397ce
mov edx, dword [0x45d84c]
mov byte [edx + 0x187beac], 0
push 0x187bf11
push 0x187beac
call fcn.00434790
add esp, 8
mov dword [ebp - 8], eax
xor ecx, ecx
mov dword [0x45d84c], ecx
cmp dword [ebp - 8], 0
jge 0x4394f1
push str.M5R_31__not_found_r_n
call fcn.0040391c
pop ecx
jmp 0x4397ce
call sub.KERNEL32.DLL_GetTickCount
mov dword [0x45d844], eax
cmp dword [0x45d844], 0
jne 0x43950e
mov dword [0x45d844], 1
mov eax, dword [ebp - 8]
cmp eax, dword [0x45d854]
je 0x439521
xor edx, edx
mov dword [0x45d850], edx
mov ecx, dword [ebp - 8]
mov dword [0x45d854], ecx
cmp dword [0x45d854], 0
jne 0x4396de
push str.M5R_31__1_phase_r_n
call fcn.0040391c
pop ecx
push 0x45d56c
push 0x187badc
call fcn.004417dc
add esp, 8
test eax, eax
je 0x43957e
push 0x45d56c
call fcn.004415f8
pop ecx
push eax
push 0x187bf11
push 0x187badc
call fcn.00441874
add esp, 0xc
test eax, eax
jne 0x4397ce
cmp dword [0x45d850], 0
jne 0x4395b3
push str.M5R_1_r_n
call fcn.0040391c
pop ecx
push 0x187bf11
push 0x187bf76
call fcn.004415c8
add esp, 8
mov dword [0x45d850], 1
jmp 0x4397ce
cmp dword [0x45d850], 1
jne 0x439615
push 0x187bf11
push 0x187bf76
call fcn.0044157c
add esp, 8
test eax, eax
jne 0x4395e9
push str.M5R_2_r_n
call fcn.0040391c
pop ecx
xor eax, eax
mov dword [0x45d850], eax
jmp 0x439694
push str.M5R_3_r_n
call fcn.0040391c
pop ecx
push 0x187bf11
push 0x187bfdb
call fcn.004415c8
add esp, 8
mov dword [0x45d850], 2
jmp 0x4397ce
push 0x187bf11
push 0x187bf76
call fcn.0044157c
add esp, 8
test eax, eax
je 0x439641
push 0x187bf11
push 0x187bfdb
call fcn.0044157c
add esp, 8
test eax, eax
jne 0x439656
push str.M5R_4_r_n
call fcn.0040391c
pop ecx
xor edx, edx
mov dword [0x45d850], edx
jmp 0x439694
push str.M5R_5_r_n
call fcn.0040391c
pop ecx
push 0x187bfdb
push 0x187bf76
call fcn.004415c8
add esp, 8
push 0x187bf11
push 0x187bfdb
call fcn.004415c8
add esp, 8
mov dword [0x45d850], 2
jmp 0x4397ce
push str.M5R_6_r_n
call fcn.0040391c
pop ecx
xor ecx, ecx
mov dword [0x45d850], ecx
mov dword [0x45d84c], ecx
push 0
call fcn.00429b70
pop ecx
cmp dword [ebp + 0xc], 0
je 0x4396c3
or eax, 0xffffffff
jmp 0x4397e4
push 0x187bf11
push dword [ebp + 8]
call fcn.00434c04
add esp, 8
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
jmp 0x4397e4
push str.M5R_31__3_phase_r_n
call fcn.0040391c
pop ecx
cmp dword [0x45d854], 1
jne 0x439707
mov dx, word [0x187beaf]
and edx, 0xfff
movzx ecx, dx
mov dword [ebp - 0x14], ecx
jmp 0x439756
cmp dword [0x45d854], 2
jne 0x439723
mov ax, word [0x187beb1]
and eax, 0xfff
movzx edx, ax
mov dword [ebp - 0x14], edx
jmp 0x439756
cmp dword [0x45d854], 3
jne 0x439741
mov cx, word [0x187beb1]
and ecx, 0xfff
movzx eax, cx
mov dword [ebp - 0x14], eax
jmp 0x439756
push dword [0x45d854]
push str.M5R_31__hdr_format_d__r_n
call fcn.0040391c
add esp, 8
jmp 0x4397ce
cmp dword [0x187bea4], 0xffffffff
je 0x439782
mov edx, dword [0x187bea4]
cmp edx, dword [ebp - 0x14]
je 0x439782
push dword [ebp - 0x14]
push dword [0x187bea4]
push str.M5R_31__hdr___M5a_Hdr3_d__sn3_d__r_n
call fcn.0040391c
add esp, 0xc
jmp 0x4397ce
push str.M5R_31__hdr_OK_r_n
call fcn.0040391c
pop ecx
xor ecx, ecx
mov dword [0x45d850], ecx
mov dword [0x45d84c], ecx
push 0
call fcn.00429b70
pop ecx
push dword [ebp + 0xc]
push 0x187bf11
push dword [ebp + 8]
call fcn.00435384
add esp, 0xc
mov dword [ebp - 8], eax
push dword [ebp - 8]
push str.M5R_AnalyzeMieleData3___d_r_n
call fcn.0040391c
add esp, 8
mov eax, dword [ebp - 8]
jmp 0x4397e4
call sub.KERNEL32.DLL_GetTickCount
sub eax, dword [ebp - 0x1c]
cmp eax, 0xbb8
jb 0x4392c1
or eax, 0xffffffff
mov esp, ebp
pop ebp
ret