Function at 0x4bdac0
Capabilities:
Read file on windows

Disassembly:
push rbp
sub rsp, 0x350
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x2e0], rcx
mov dword [rbp + 0x2e8], edx
mov qword [rbp + 0x2f0], r8
mov rax, qword [rbp + 0x2f0]
lea rdx, [0x00504e08]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x2b8], rax
cmp qword [rbp + 0x2b8], 0
jne 0x4bdb73
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdb38
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdb38
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be2f5
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_load_firmware_
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be2f5
mov rax, qword [rbp + 0x2b8]
mov r8d, 2
mov edx, 0
mov rcx, rax
call sym.fseek
mov rax, qword [rbp + 0x2b8]
mov rcx, rax
call sym.ftell
mov dword [rbp + 0x2b4], eax
mov rax, qword [rbp + 0x2b8]
mov rcx, rax
call sym.rewind
mov eax, dword [rbp + 0x2b4]
movsxd rdx, eax
imul rdx, rdx, 0x214d0215
shr rdx, 0x20
sar edx, 5
sar eax, 0x1f
sub edx, eax
mov eax, edx
mov dword [rbp + 0x2cc], eax
mov edx, dword [rbp + 0x2b4]
movsxd rax, edx
imul rax, rax, 0x214d0215
shr rax, 0x20
mov ecx, eax
sar ecx, 5
mov eax, edx
sar eax, 0x1f
sub ecx, eax
mov eax, ecx
imul eax, eax, 0xf6
sub edx, eax
mov eax, edx
test eax, eax
jle 0x4bdc0c
add dword [rbp + 0x2cc], 1
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdc35
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdc35
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4bdc7f
lea rax, [rbp - 0x50]
mov edx, dword [rbp + 0x2cc]
mov dword [rsp + 0x28], edx
mov edx, dword [rbp + 0x2b4]
mov dword [rsp + 0x20], edx
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Loaded_firmware:__d_bytes____d_blocks.
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
lea rdx, [rbp + 0x1b0]
mov eax, dword [rbp + 0x2e8]
mov dword [rsp + 0x20], 0
mov r9, rdx
mov r8d, 0xff
mov edx, 0x1c
mov ecx, eax
call dbg.send_command
test eax, eax
jns 0x4bdd15
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdcda
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdcda
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be2f8
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_send_command:_START_CONFIG_
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be2f8
mov ecx, 1
call dbg.sleep
lea rdx, [rbp + 0x2af]
mov eax, dword [rbp + 0x2e8]
mov r8d, 1
mov ecx, eax
call sym.read
mov dword [rbp + 0x2b0], eax
cmp dword [rbp + 0x2b0], 0
jle 0x4bddb8
movzx eax, byte [rbp + 0x2af]
cmp al, 0x3c
jne 0x4bddb8
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdd80
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdd80
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4bde20
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Start_config...
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4bde20
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdde5
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdde5
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be2fb
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_receive_response:_START_CONFIG.
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be2fb
nop
mov byte [rbp + 0x2cb], 0
mov dword [rbp + 0x2c4], 0
jmp 0x4be125
mov eax, dword [rbp + 0x2cc]
sub eax, 1
cmp dword [rbp + 0x2c4], eax
jne 0x4bdec5
mov eax, dword [rbp + 0x2b4]
movsxd rdx, eax
imul rdx, rdx, 0x214d0215
shr rdx, 0x20
mov ecx, edx
sar ecx, 5
cdq
sub ecx, edx
mov edx, ecx
imul edx, edx, 0xf6
sub eax, edx
mov edx, eax
movsxd rdx, edx
mov rcx, qword [rbp + 0x2b8]
lea rax, [rbp + 0x1b0]
mov r9, rcx
mov r8, rdx
mov edx, 1
mov rcx, rax
call sym.fread
mov dword [rbp + 0x2c0], eax
mov eax, dword [rbp + 0x2c0]
sub eax, 1
cdqe
movzx eax, byte [rbp + rax + 0x1b0]
mov byte [rbp + 0x2cb], al
cmp dword [rbp + 0x2c0], 0
jle 0x4bdeef
sub dword [rbp + 0x2c0], 1
jmp 0x4bdeef
mov rdx, qword [rbp + 0x2b8]
lea rax, [rbp + 0x1b0]
mov r9, rdx
mov r8d, 0xf6
mov edx, 1
mov rcx, rax
call sym.fread
mov dword [rbp + 0x2c0], eax
mov eax, dword [rbp + 0x2c0]
movzx edx, al
lea rcx, [rbp + 0x1b0]
mov eax, dword [rbp + 0x2e8]
mov dword [rsp + 0x20], edx
mov r9, rcx
mov r8d, 0xff
mov edx, 0x16
mov ecx, eax
call dbg.send_command
test eax, eax
jns 0x4bdf97
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdf4f
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdf4f
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be2fe
mov eax, dword [rbp + 0x2c4]
lea edx, [rax + 1]
lea rax, [rbp - 0x50]
mov dword [rsp + 0x20], edx
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_send_command:_TRANSMIT_for_block:__d_
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be2fe
lea rdx, [rbp + 0x2af]
mov eax, dword [rbp + 0x2e8]
mov r8d, 1
mov ecx, eax
call sym.read
mov dword [rbp + 0x2b0], eax
cmp dword [rbp + 0x2b0], 0
jle 0x4bdfcf
movzx eax, byte [rbp + 0x2af]
cmp al, 0x1e
je 0x4be068
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4bdff8
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4bdff8
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be03b
mov eax, dword [rbp + 0x2c4]
lea edx, [rax + 1]
lea rax, [rbp - 0x50]
mov dword [rsp + 0x20], edx
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_receive_response_for_block:__d_
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
mov ecx, dword [rbp + 0x2c0]
mov edx, dword [rbp + 0x2c0]
lea rax, [rbp + 0x1b0]
mov r9d, ecx
mov r8d, edx
mov rdx, rax
lea rcx, str.Block_Content
call sym.logbyte2_23
jmp 0x4be305
cmp dword [rbp + 0x2c4], 0
jle 0x4be11e
mov eax, dword [rbp + 0x2c4]
lea edx, [rax + 1]
movsxd rax, edx
imul rax, rax, 0x68db8bad
shr rax, 0x20
mov ecx, eax
sar ecx, 0xc
mov eax, edx
sar eax, 0x1f
sub ecx, eax
mov eax, ecx
imul eax, eax, 0x2710
sub edx, eax
mov eax, edx
test eax, eax
jne 0x4be11e
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4be0d1
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4be0d1
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be11e
mov eax, dword [rbp + 0x2c4]
lea ecx, [rax + 1]
lea rax, [rbp - 0x50]
mov edx, dword [rbp + 0x2cc]
mov dword [rsp + 0x28], edx
mov dword [rsp + 0x20], ecx
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Successfully_transmitted__d__d...
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
add dword [rbp + 0x2c4], 1
mov eax, dword [rbp + 0x2c4]
cmp eax, dword [rbp + 0x2cc]
jl 0x4bde37
movzx eax, byte [rbp + 0x2cb]
mov byte [rbp + 0x1b0], al
lea rdx, [rbp + 0x1b0]
mov eax, dword [rbp + 0x2e8]
mov dword [rsp + 0x20], 1
mov r9, rdx
mov r8d, 0xff
mov edx, 0x19
mov ecx, eax
call dbg.send_command
test eax, eax
jns 0x4be1da
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4be19f
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4be19f
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be301
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_send_command:_TRANSMIT_for_last_block_
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be301
lea rdx, [rbp + 0x2af]
mov eax, dword [rbp + 0x2e8]
mov r8d, 1
mov ecx, eax
call sym.read
mov dword [rbp + 0x2b0], eax
cmp dword [rbp + 0x2b0], 0
jle 0x4be27d
movzx eax, byte [rbp + 0x2af]
cmp al, 0x20
jne 0x4be27d
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4be23b
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4be23b
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be2de
lea rax, [rbp - 0x50]
mov edx, dword [rbp + 0x2cc]
mov dword [rsp + 0x20], edx
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Configuration_completed_for__d_blocks.
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be2de
mov rax, qword [0x00514e80]
movzx eax, byte [rax]
test al, al
jne 0x4be2a6
mov rax, qword [0x00514ac0]
movzx eax, byte [rax]
test al, al
jne 0x4be2a6
mov rax, qword [0x00514ab0]
mov eax, dword [rax]
test eax, eax
js 0x4be304
lea rax, [rbp - 0x50]
mov r9, qword [rbp + 0x2e0]
lea r8, str._FPGA__s__Failed_to_receive_response_for_last_block.
mov edx, 0x200
mov rcx, rax
call sym.snprintf_19
lea rax, [rbp - 0x50]
mov r8d, 0
mov rdx, rax
mov ecx, 0
call dbg._applog
jmp 0x4be304
nop
mov rax, qword [rbp + 0x2b8]
mov rcx, rax
call sym.fclose
mov eax, 0
jmp 0x4be323
nop
jmp 0x4be305
nop
jmp 0x4be305
nop
jmp 0x4be305
nop
jmp 0x4be305
nop
jmp 0x4be305
nop
cmp qword [rbp + 0x2b8], 0
je 0x4be31e
mov rax, qword [rbp + 0x2b8]
mov rcx, rax
call sym.fclose
mov eax, 0xffffffff
add rsp, 0x350
pop rbp
ret