Function at 0x4013f0
Capabilities:
Create directory
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x18
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x18]
push eax
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
mov ecx, esi
call fcn.00401210
mov ecx, dword [0x4244bc]
xor ebx, ebx
xor eax, eax
cmp ecx, ebx
jle 0x40144d
nop
mov edx, dword [esi + 0x1520]
cmp byte [eax + edx], 0x2b
jne 0x401446
mov ecx, dword [esi + 0x154c]
mov dword [esi + ecx*4 + 0x1528], eax
add dword [esi + 0x154c], 1
mov ecx, dword [0x4244bc]
add eax, 1
cmp eax, ecx
jl 0x401420
cmp dword [esi + 0x154c], ebx
je 0x40187a
xor eax, eax
cmp ecx, ebx
jle 0x40147f
mov edx, dword [esi + 0x1524]
cmp byte [edx + eax], 0x2b
jne 0x401478
add dword [esi + 0x1548], 1
mov ecx, dword [0x4244bc]
add eax, 1
cmp eax, ecx
jl 0x401465
cmp dword [esi + 0x1548], ebx
je 0x40187a
lea eax, [esi + 4]
push str.ADCLABFFS
push eax
mov ecx, esi
call fcn.004013b0
lea eax, [esi + 0x24]
push str.SAMPLES_FORMAT
push eax
mov ecx, esi
mov dword [esi + 0x1c], ebx
mov dword [esi + 0x20], ebx
call fcn.004013b0
fld dword [esi + 0x1580]
mov edx, dword [esi + 0x1548]
fstp qword [esi + 0x4c]
lea eax, [esi + 0x354]
push str.SD_FORMAT
push eax
mov ecx, esi
mov dword [esi + 0x3c], 0x14
mov dword [esi + 0x40], ebx
mov dword [esi + 0x44], 7
mov dword [esi + 0x48], edx
mov byte [esi + 0x54], 6
mov byte [esi + 0x55], bl
mov byte [esi + 0x56], bl
call fcn.004013b0
mov al, byte [esi + 0x1548]
mov byte [esi + 0x379], al
lea eax, [esi + 0x3ba]
push 0x41d384
push eax
mov ecx, esi
mov dword [esi + 0x36c], 0x46
mov dword [esi + 0x370], ebx
mov byte [esi + 0x378], bl
call fcn.004013b0
fld dword [0x41d380]
fstp dword [esi + 0x458]
mov dword [esi + 0x3d2], 0x106
mov dword [esi + 0x3d6], ebx
xor eax, eax
cmp dword [0x4244bc], ebx
jle 0x4015d7
lea ecx, [esi + 0xb0]
lea edi, [esi + 0x3e4]
lea edx, [esi + 0x37a]
mov ebp, dword [esi + 0x1524]
cmp byte [eax + ebp], 0x2b
jne 0x4015cc
cmp eax, 4
mov ebp, eax
jge 0x401580
imul ebp, ebp, 0x101
add ebp, 1
jmp 0x40158c
imul ebp, ebp, 0x801
sub ebp, 0x1fff
mov word [edx], bp
add word [edx], 0xffff
lea ebp, [eax + 1]
and ebp, 0x80000003
jns 0x4015a3
dec ebp
or ebp, 0xfffffffc
inc ebp
mov dword [edi], ebp
mov dword [ecx - 4], eax
mov ebp, dword [esi + 0x1578]
fld dword [ebp + eax*4]
add edx, 2
fchs
add edi, 4
fstp qword [ecx]
mov ebp, dword [esi + 0x1578]
fld dword [ebp + eax*4]
add ecx, 0x14
fstp qword [ecx - 0xc]
add eax, 1
cmp eax, dword [0x4244bc]
jl 0x401562
fldz
mov edi, 0xfffffc14
fld qword [0x41d378]
mov ebp, 0xfffffc08
xor ecx, ecx
sub edi, esi
lea eax, [esi + 0x3f8]
sub ebp, esi
jmp 0x4015f9
fxch st(1)
xor edx, edx
fxch st(1)
cmp ecx, ebx
fst dword [eax]
setne dl
cmp ecx, ebx
mov dword [eax - 0x14], edx
je 0x40161c
mov edx, dword [esi + 0x1578]
add edx, ebp
fld dword [edx + eax - 4]
fdivr st(2)
fstp dword [eax + 0x14]
cmp ecx, ebx
fst dword [eax + 0x28]
je 0x401633
mov edx, dword [esi + 0x1578]
add edx, edi
fld dword [edx + eax]
fdivr st(2)
fstp dword [eax + 0x3c]
add ecx, 1
add eax, 4
cmp ecx, 5
jl 0x4015f7
movzx eax, byte [esp + 0x24]
fstp st(0)
movzx ecx, byte [esp + 0x22]
fstp st(0)
movzx edx, byte [esp + 0x20]
mov byte [esi + 0x4da], al
movzx eax, byte [esp + 0x1e]
mov byte [esi + 0x4db], cl
movzx ecx, byte [esp + 0x1a]
mov byte [esi + 0x4dc], dl
movzx edx, byte [esp + 0x18]
mov byte [esi + 0x4dd], al
lea eax, [esi + 0x4e0]
push str.SAMPLES_RECORD
mov byte [esi + 0x4de], cl
add dl, 0x30
push eax
mov ecx, esi
mov byte [esi + 0x4df], dl
call fcn.004013b0
or eax, 0xffffffff
push ebx
lea edi, [esi + 0x17c4]
mov dword [esi + 0x4f8], eax
push edi
mov dword [esi + 0x4fc], eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
movzx eax, word [esp + 0x24]
movzx ecx, word [esp + 0x22]
movzx edx, word [esp + 0x20]
push eax
movzx eax, word [esp + 0x22]
push ecx
movzx ecx, word [esp + 0x22]
push edx
movzx edx, word [esp + 0x24]
push eax
push ecx
mov ecx, dword [0x4244ac]
sub edx, 0x7d0
push edx
lea eax, [esi + 0x1584]
push eax
add ecx, 0x214
push ecx
push edi
lea ebp, [esi + 0x15c4]
push str._s_s__s__02d_02d_02d__02d_02d_02d.alf
push ebp
call fcn.0040a5fa
add esp, 0x2c
push ebx
push 0x20
push 2
push ebx
push ebx
push 0x40000000
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [esi + 0x1504], eax
je 0x40187a
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
lea edx, [esp + 0x18]
push edx
push 0x20
lea ecx, [esi + 4]
push ecx
push eax
call edi
mov ecx, dword [esi + 0x1504]
push ebx
lea eax, [esp + 0x18]
push eax
push 0x34
lea eax, [esi + 0x24]
push eax
push ecx
call edi
push ebx
lea edx, [esp + 0x18]
push edx
push 0x66
lea eax, [esi + 0x354]
push eax
mov eax, dword [esi + 0x1504]
push eax
call edi
mov edx, dword [esi + 0x1504]
push ebx
lea ecx, [esp + 0x18]
push ecx
push 0x126
lea eax, [esi + 0x3ba]
push eax
push edx
call edi
mov ecx, dword [str.ADCBLOCK]
mov dword [esi + 0x500], ecx
mov edx, dword [0x41d334]
lea eax, [esi + 0x500]
mov dword [eax + 4], edx
mov dword [esi + 0x508], 2
mov dword [esi + 0x50c], ebx
xor ecx, ecx
xor edx, edx
cmp dword [0x4244bc], ebx
jle 0x4017ff
mov ebp, 0xa10
jmp 0x4017d0
mov ebx, dword [esi + 0x1524]
cmp byte [edx + ebx], 0x2b
jne 0x4017ef
mov ebx, dword [0x4244ac]
mov ebx, dword [ebx + ebp]
mov dword [esi + ecx*4 + 0x510], ebx
add ecx, 1
add edx, 1
add ebp, 4
cmp edx, dword [0x4244bc]
jl 0x4017d0
xor ebx, ebx
push ebx
lea edx, [esp + 0x18]
push edx
mov edx, dword [esi + 0x1504]
lea ecx, [ecx*4 + 0x10]
push ecx
push eax
push edx
call edi
mov ecx, dword [esi + 0x1504]
push ebx
lea eax, [esp + 0x18]
push eax
push 0x20
lea eax, [esi + 0x4e0]
push eax
push ecx
call edi
mov edx, dword [esi + 0x1504]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
call edi
push ebx
push 0x20
push 3
push ebx
push ebx
push Ordinal_1
lea eax, [esi + 0x15c4]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push ebx
push eax
mov dword [esi + 0x1504], eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esi + 0x19c8], eax
mov eax, dword [esi + 0x1504]
push eax
mov dword [esi + 0x19cc], ebx
call edi
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret