Function at 0x40beb0
Capabilities:
Write file on windows

Disassembly:
push edi
push esi
xor eax, eax
push ebx
mov ecx, 0x41
sub esp, 0x380
lea edi, [esp + 0x88]
lea edx, [esp + 0x37]
mov dword [esp + 0x83], 0
mov dword [esp + 0x87], 0
mov dword [esp + 0x188], 0
lea ebx, [esp + 0x83]
rep stosd dword es:[edi], eax
lea edi, [esp + 0x38]
mov ecx, edx
mov dword [esp + 0x7f], 0
sub ecx, edi
add ecx, 0x4c
shr ecx, 2
rep stosd dword es:[edi], eax
mov dword [esp], edx
mov dword [esp + 0x37], 0x4c
mov dword [esp + 0x43], str.Archivo_CalData__.cdt_
mov dword [esp + 0x53], ebx
mov eax, dword [0x428e98]
mov dword [esp + 0x57], 0x104
mov dword [esp + 0x6b], 0x80004
mov dword [esp + 0x73], 0x421b74
mov dword [esp + 0x3b], eax
call sub.COMDLG32.DLL_GetSaveFileNameA
sub esp, 4
test eax, eax
jne 0x40bf60
add esp, 0x380
pop ebx
pop esi
pop edi
ret
lea eax, [esp + 0x26]
mov dword [esp], eax
call sub.KERNEL32.dll_GetLocalTime
sub esp, 4
mov dword [esp + 4], 0x421b78
mov dword [esp], ebx
call sub.msvcrt.dll_fopen
test eax, eax
mov edi, eax
je 0x40c1f0
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x39
lea esi, [esp + 0x18c]
mov dword [esp + 4], 1
mov dword [esp], 0x421a08
mov ebx, 0x422520
call sub.msvcrt.dll_fwrite
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x24
mov dword [esp + 4], 1
mov dword [esp], str.__PRO3_Calibration_data_collection__n
call sub.msvcrt.dll_fwrite
mov dword [esp + 0xc], edi
mov dword [esp + 8], 3
mov dword [esp + 4], 1
mov dword [esp], 0x421af8
call sub.msvcrt.dll_fwrite
movzx eax, word [esp + 0x32]
mov dword [esp + 4], 0x421bbd
mov dword [esp], edi
mov dword [esp + 0x1c], eax
movzx eax, word [esp + 0x30]
mov dword [esp + 0x18], eax
movzx eax, word [esp + 0x2e]
mov dword [esp + 0x14], eax
movzx eax, word [esp + 0x26]
mov dword [esp + 0x10], eax
movzx eax, word [esp + 0x28]
mov dword [esp + 0xc], eax
movzx eax, word [esp + 0x2c]
mov dword [esp + 8], eax
call sub.msvcrt.dll_fprintf
mov dword [esp + 0xc], edi
mov dword [esp + 8], 3
mov dword [esp + 4], 1
mov dword [esp], 0x421af8
call sub.msvcrt.dll_fwrite
mov eax, dword [0x428e98]
mov dword [esp + 0xc], 0xc8
mov dword [esp + 8], esi
mov dword [esp + 4], 0x12f
mov dword [esp], eax
call sub.USER32.dll_GetDlgItemTextA
sub esp, 0x10
mov dword [esp + 8], esi
mov dword [esp + 4], str.__Current_signature:__s_n
mov dword [esp], edi
call sub.msvcrt.dll_fprintf
mov eax, dword [0x428e98]
mov dword [esp + 0xc], 0xc8
mov dword [esp + 8], esi
mov dword [esp + 4], 0x130
mov dword [esp], eax
call sub.USER32.dll_GetDlgItemTextA
sub esp, 0x10
mov dword [esp + 8], esi
mov dword [esp + 4], str.__Current_calibration_timestamp:__s_n
mov dword [esp], edi
call sub.msvcrt.dll_fprintf
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x3a
mov dword [esp + 4], 1
mov dword [esp], str.__n_n
call sub.msvcrt.dll_fwrite
mov eax, 0x12c
jmp 0x40c116
mov dword [esp + 0xc], esi
mov eax, dword [ebx]
add ebx, 8
mov dword [esp + 4], str._s____s__n
mov dword [esp], edi
mov dword [esp + 8], eax
call sub.msvcrt.dll_fprintf
mov eax, dword [ebx + 4]
test eax, eax
je 0x40c173
mov dword [esp + 4], eax
mov eax, dword [0x428e98]
mov dword [esp + 0xc], 0xc8
mov dword [esp + 8], esi
mov dword [esp], eax
call sub.USER32.dll_GetDlgItemTextA
sub esp, 0x10
test eax, eax
jne 0x40c0f2
mov dword [esp + 0xc], 0x10
mov dword [esp + 8], 0x421b90
mov dword [esp + 4], str.Error_in_the_List
mov dword [esp], 0
call sub.USER32.dll_MessageBoxA
sub esp, 0x10
mov dword [esp], edi
call sub.msvcrt.dll_fclose
add esp, 0x380
pop ebx
pop esi
pop edi
ret
mov eax, edi
call fcn.0040bd30
test al, al
jne 0x40c161
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x39
mov dword [esp + 4], 1
mov dword [esp], 0x421a08
call sub.msvcrt.dll_fwrite
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x39
mov dword [esp + 4], 1
mov dword [esp], str._______________END_OF_THE_DATA_COLLECTION________________n
call sub.msvcrt.dll_fwrite
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x38
mov dword [esp + 4], 1
mov dword [esp], 0x421c74
call sub.msvcrt.dll_fwrite
mov dword [esp], edi
call sub.msvcrt.dll_fclose
jmp 0x40bf51
mov dword [esp + 8], ebx
lea ebx, [esp + 0x18c]
mov dword [esp + 4], str.Cannot_create_file__s
mov dword [esp], ebx
call sub.msvcrt.dll_sprintf
mov dword [esp + 0xc], 0x10
mov dword [esp + 8], 0x421b90
mov dword [esp + 4], ebx
mov dword [esp], 0
call sub.USER32.dll_MessageBoxA
sub esp, 0x10
jmp 0x40bf51