Function at 0x4025f0
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53c376
mov eax, dword fs:[0]
push eax
sub esp, 0x12c
mov eax, dword [0x58fa50]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [edi + 4]
test eax, eax
jne 0x402d55
push eax
lea ecx, [edi + 0x190]
push 0x5680fe
mov dword [ebp - 0x12c], ecx
call fcn.00403aa0
mov eax, dword [edi + 8]
push eax
push 0
call dword [sym.imp.dtccm2.dll_SetSoftPinPullUp]
push 0x27
lea ecx, [ebp - 0x37]
push 0
push ecx
call fcn.00516de0
add esp, 0x14
cmp byte [edi + 0x7b], 0
mov ebx, 0x14
mov dword [ebp - 0x34], 0x6050403
mov dword [ebp - 0x30], 0x14090807
mov dword [ebp - 0x2c], 0x140c0b0a
jne 0x40269b
mov dword [ebp - 0x38], 0x1020014
mov dword [ebp - 0x28], 0xe0f0d14
mov dword [ebp - 0x24], 0x10141213
mov word [ebp - 0x20], 0x1414
jmp 0x4026b6
mov dword [ebp - 0x38], 0x1020010
mov dword [ebp - 0x28], 0x14141414
mov dword [ebp - 0x24], 0xf0e140d
mov word [ebp - 0x20], 0x1312
mov edx, dword [edi + 8]
push edx
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.dtccm2.dll_SetSoftPin]
mov ecx, dword [edi + 8]
push ecx
push 1
call dword [sym.imp.dtccm2.dll_EnableSoftPin]
mov edx, dword [edi + 8]
push edx
push 1
call dword [sym.imp.dtccm2.dll_EnableGpio]
add esp, 0x18
cmp dword [edi + 4], 0
jne 0x4026f6
mov eax, dword [edi + 8]
push eax
push 1
push 3
call dword [sym.imp.dtccm2.dll_SensorEnable]
add esp, 0xc
fld dword [edi + 0x174]
mov eax, 1
fld qword [0x56a0a8]
xor ecx, ecx
fmul st(1), st(0)
mov esi, 0x12c
fxch st(1)
mov dword [ebp - 0x74], 0
mov dword [ebp - 0xec], esi
mov dword [ebp - 0xc4], eax
mov dword [ebp - 0x4c], ecx
mov dword [ebp - 0x9c], ecx
mov dword [ebp - 0x70], eax
call fcn.0051a1b0
fld dword [edi + 0x178]
fmul st(1)
mov dword [ebp - 0x98], eax
mov dword [ebp - 0xe8], esi
mov dword [ebp - 0xc0], 1
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x6c], 2
call fcn.0051a1b0
fmul dword [edi + 0x17c]
mov dword [ebp - 0x94], eax
mov dword [ebp - 0xe4], esi
mov dword [ebp - 0xbc], 1
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x68], 3
call fcn.0051a1b0
mov ecx, 1
mov dword [ebp - 0xb8], ecx
mov dword [ebp - 0xb4], ecx
mov ecx, dword [edi + 8]
push ecx
mov dword [ebp - 0x90], eax
xor eax, eax
push 5
lea edx, [ebp - 0x114]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x8c], eax
mov dword [ebp - 0x3c], eax
push edx
lea eax, [ebp - 0x74]
mov dword [ebp - 0xe0], esi
mov dword [ebp - 0xdc], esi
mov dword [ebp - 0x114], esi
mov dword [ebp - 0x110], esi
mov dword [ebp - 0x10c], esi
mov dword [ebp - 0x108], esi
mov dword [ebp - 0x104], esi
mov esi, dword [sym.imp.dtccm2.dll_PmuSetOcpCurrentLimit]
push eax
mov dword [ebp - 0x64], 4
call esi
mov ecx, dword [edi + 8]
push ecx
push 5
lea edx, [ebp - 0x9c]
push edx
lea eax, [ebp - 0x74]
push eax
call dword [sym.imp.dtccm2.dll_PmuSetVoltage]
add esp, 0x20
cmp eax, 1
je 0x402839
push 0
push 0
push str.Set_Voltage_Failed_
call fcn.00417747
xor eax, eax
jmp 0x403076
mov ecx, dword [edi + 8]
push ecx
call dword [sym.imp.dtccm2.dll_GetKitType]
add esp, 4
cmp eax, 0x10
je 0x4028aa
mov edx, dword [edi + 8]
push edx
push 5
lea eax, [ebp - 0xc4]
push eax
lea ecx, [ebp - 0x74]
push ecx
call dword [sym.imp.dtccm2.dll_PmuSetOnOff]
add esp, 0x10
cmp eax, 1
je 0x402878
push 0
push 0
push str.Open_Voltage_Failed_
call fcn.00417747
mov edx, dword [edi + 8]
push edx
push 5
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x74]
push ecx
call dword [sym.imp.dtccm2.dll_PmuSetCurrentRange]
mov edx, dword [edi + 8]
push edx
push 5
lea eax, [ebp - 0xec]
push eax
lea ecx, [ebp - 0x74]
push ecx
call esi
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
add esp, 0x20
jmp 0x4028b4
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0xa
call esi
fld dword [edi + 0x170]
fmul qword [0x56a0a8]
call fcn.0051a1b0
mov edx, dword [edi + 8]
push edx
mov dword [ebp - 0x9c], eax
push 5
lea eax, [ebp - 0x9c]
push eax
lea ecx, [ebp - 0x74]
push ecx
call dword [sym.imp.dtccm2.dll_PmuSetVoltage]
add esp, 0x10
cmp eax, 1
jne 0x402824
push 0x64
call esi
fild dword [edi + 0x74]
mov edx, dword [edi + 8]
fnstcw word [ebp - 0x116]
movzx eax, word [ebp - 0x116]
fstp dword [ebp - 0x124]
fld dword [ebp - 0x124]
or eax, 0xc00
fmul qword [0x56a0c8]
mov dword [ebp - 0x124], eax
push edx
fldcw word [ebp - 0x124]
fistp dword [ebp - 0x124]
mov ax, word [ebp - 0x124]
movzx ecx, ax
push ecx
fldcw word [ebp - 0x116]
push 1
call dword [sym.imp.dtccm2.dll_SetSensorClock]
add esp, 0xc
cmp eax, 1
je 0x402965
push 0
push 0
push str.Set_Mclk_Failed_
call fcn.00417747
xor eax, eax
jmp 0x403076
mov edx, dword [edi + 8]
push edx
push 1
call dword [sym.imp.dtccm2.dll_SetSoftPinPullUp]
mov eax, dword [edi + 8]
push eax
push 0
call dword [sym.imp.dtccm2.dll_SetSensorI2cRate]
mov ecx, dword [edi + 8]
push ecx
push 0
call dword [sym.imp.dtccm2.dll_SetSensorI2cRapid]
mov edx, dword [edi + 8]
push edx
push 0
call dword [sym.imp.dtccm2.dll_SetI2CInterval]
add esp, 0x20
push ebx
call esi
mov eax, dword [edi + 8]
movzx ecx, byte [edi + 0x15]
push eax
push 1
push ecx
call dword [sym.imp.dtccm2.dll_SensorEnable]
mov al, byte [edi + 0x15]
mov edx, dword [edi + 8]
xor al, 2
push edx
movzx ecx, al
push 1
push ecx
call dword [sym.imp.dtccm2.dll_SensorEnable]
add esp, 0x18
push ebx
call esi
mov edx, dword [edi + 8]
movzx eax, byte [edi + 0x15]
push edx
push 1
push eax
call dword [sym.imp.dtccm2.dll_SensorEnable]
add esp, 0xc
push 0x1e
call esi
mov ecx, dword [edi + 8]
push ecx
xor esi, esi
push esi
lea eax, [edi + 0x10]
push 1
push eax
call dword [sym.imp.dtccm2.dll_SensorIsMe]
add esp, 0x10
cmp eax, 1
je 0x402a1a
cmp dword [edi + 0xb50], 1
jne 0x402a1a
mov ecx, dword [ebp - 0x12c]
push str.Find_Sensor_Failed_
call fcn.00403b80
xor eax, eax
jmp 0x403076
lea ecx, [ebp - 0x11c]
call fcn.004013a0
xor edx, edx
mov dword [ebp - 4], esi
cmp dx, word [edi + 0x68]
jae 0x402bc9
mov eax, dword [edi + 0x64]
movzx ecx, word [eax + esi*2]
lea eax, [eax + esi*2]
mov edx, 0xffff
cmp cx, dx
je 0x402baf
mov edx, 0xff
cmp cx, dx
je 0x402baf
movzx edx, byte [edi + 0x17]
movzx eax, word [eax + 2]
mov ebx, dword [sym.imp.dtccm2.dll_WriteSensorReg]
push 0
push edx
push eax
push ecx
movzx ecx, byte [edi + 0x16]
push ecx
call ebx
add esp, 0x14
cmp esi, 3
jle 0x402bba
cmp dword [edi + 0xb50], 1
jne 0x402bba
mov edx, dword [edi + 0x64]
movzx ecx, byte [edi + 0x17]
lea eax, [edx + esi*2]
movzx edx, word [eax + 2]
movzx eax, word [eax]
push 0
push ecx
movzx ecx, byte [edi + 0x16]
push edx
push eax
push ecx
call ebx
movzx edx, byte [edi + 0x17]
mov ecx, dword [edi + 0x64]
xor ebx, ebx
push ebx
push edx
movzx edx, word [ecx + esi*2]
lea eax, [ebp - 0x118]
push eax
movzx eax, byte [edi + 0x16]
push edx
push eax
call dword [sym.imp.dtccm2.dll_ReadSensorReg]
mov ecx, dword [edi + 0x64]
mov ax, word [ebp - 0x118]
add esp, 0x28
cmp ax, word [ecx + esi*2 + 2]
je 0x402b4a
cmp ebx, 0xc8
jge 0x402b4a
mov edx, dword [edi + 0x64]
movzx ecx, byte [edi + 0x17]
lea eax, [edx + esi*2]
movzx edx, word [eax + 2]
movzx eax, word [eax]
push 0
push ecx
movzx ecx, byte [edi + 0x16]
push edx
push eax
push ecx
call dword [sym.imp.dtccm2.dll_WriteSensorReg]
add esp, 0x14
push 5
call dword [sym.imp.KERNEL32.dll_Sleep]
movzx edx, byte [edi + 0x17]
mov ecx, dword [edi + 0x64]
push 0
push edx
movzx edx, word [ecx + esi*2]
lea eax, [ebp - 0x118]
push eax
movzx eax, byte [edi + 0x16]
push edx
push eax
call dword [sym.imp.dtccm2.dll_ReadSensorReg]
mov ecx, dword [edi + 0x64]
mov ax, word [ebp - 0x118]
add esp, 0x14
inc ebx
cmp ax, word [ecx + esi*2 + 2]
jne 0x402ae0
mov edx, dword [edi + 0x64]
cmp ax, word [edx + esi*2 + 2]
je 0x402bba
movzx eax, word [edx + esi*2]
push eax
lea ecx, [ebp - 0x11c]
push str.0x_x
push ecx
call fcn.00401650
mov esi, dword [ebp - 0x12c]
add esp, 0xc
push str.Init_Sensor_Failed_
mov ecx, esi
call fcn.00403b80
push 0x5680fc
mov ecx, esi
call fcn.004037d0
mov eax, dword [ebp - 0x11c]
mov edx, dword [eax - 0xc]
push edx
push eax
mov ecx, esi
call fcn.004036d0
lea ecx, [ebp - 0x11c]
call fcn.004013d0
xor eax, eax
jmp 0x403076
movzx eax, word [eax + 2]
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
movzx ecx, word [edi + 0x68]
add esi, 2
cmp esi, ecx
jl 0x402a34
lea ecx, [ebp - 0x11c]
call fcn.004013d0
mov eax, dword [edi + 8]
push eax
push 2
lea ecx, [ebp - 0x128]
push ecx
push 0x80
xor esi, esi
push 0xba
mov dword [ebp - 0x128], esi
call dword [sym.imp.dtccm2.dll_ReadSensorReg]
mov edx, 0x5150
add esp, 0x14
cmp word [ebp - 0x128], dx
jne 0x402c0f
mov esi, 1
mov al, byte [edi + 0x14]
cmp al, 2
je 0x402c2f
cmp al, 5
je 0x402c2f
cmp al, 8
je 0x402c2f
mov eax, dword [edi + 8]
movzx ecx, byte [edi + 0x72]
push eax
push ecx
call dword [sym.imp.dtccm2.dll_SetRawFormat]
jmp 0x402c3e
mov edx, dword [edi + 8]
movzx eax, byte [edi + 0x72]
push edx
push eax
call dword [sym.imp.dtccm2.dll_SetYUV422Format]
mov ecx, dword [edi + 8]
movzx edx, word [edi + 0x12]
movzx eax, word [edi + 0x10]
add esp, 8
push ecx
movzx ecx, byte [edi + 0x7b]
push edx
push eax
push ecx
call dword [sym.imp.dtccm2.dll_SetSensorPort]
movzx eax, word [edi + 0x12]
add esp, 0x10
test esi, esi
je 0x402c67
shr eax, 1
mov edx, dword [edi + 8]
movzx ecx, byte [edi + 0x14]
push edx
movzx edx, word [edi + 0x10]
push 1
push ecx
push 1
push 1
push 0
push 0
push eax
push edx
push 0
push 0
call dword [sym.imp.dtccm2.dll_InitRoi]
mov eax, dword [edi + 8]
push eax
push 0
call dword [sym.imp.dtccm2.dll_SetMipiClkPhase]
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
add esp, 0x34
push 0xa
call ebx
mov ecx, dword [edi + 8]
push ecx
lea esi, [edi + 0xc]
push esi
call dword [sym.imp.dtccm2.dll_CalculateGrabSize]
mov edx, dword [edi + 8]
mov eax, dword [esi]
push edx
push eax
call dword [sym.imp.dtccm2.dll_OpenVideo]
mov eax, dword [edi]
add esp, 0x10
test eax, eax
je 0x402cca
mov eax, dword [eax + 0x20]
mov ecx, dword [edi + 8]
movzx edx, word [edi + 0x12]
push ecx
movzx ecx, word [edi + 0x10]
push 0
push 1
push 0
push edx
push ecx
push eax
call dword [sym.imp.dtccm2.dll_InitDisplay]
add esp, 0x1c
push 0x64
call ebx
mov edx, dword [edi + 8]
movzx eax, word [edi + 0x12]
movzx ecx, word [edi + 0x10]
push edx
push 1
push 0
push eax
push ecx
call dword [sym.imp.dtccm2.dll_InitIsp]
add esp, 0x14
push 0x64
call ebx
mov edx, dword [edi + 8]
push edx
push 0x64
call dword [sym.imp.dtccm2.dll_SetGamma]
push 0
push 0x64
call dword [sym.imp.dtccm2.dll_SetContrast]
mov eax, dword [edi + 8]
push eax
push 0x80
call dword [sym.imp.dtccm2.dll_SetSaturation]
fld1
mov ecx, dword [edi + 8]
add esp, 0x18
push ecx
sub esp, 0xc
fst dword [esp + 8]
fst dword [esp + 4]
fstp dword [esp]
call dword [sym.imp.dtccm2.dll_SetDigitalGain]
add esp, 0x10
jmp 0x403071
cmp eax, 1
jne 0x403071
call fcn.004023c0
mov bx, word [edi + 0x12]
push 1
call fcn.004031d0
cmp byte [edi + 0x14], 2
push 2
jne 0x402d7f
movzx ebx, word [edi + 0x10]
add bx, bx
jmp 0x402d83
mov bx, word [edi + 0x10]
call fcn.004031d0
call fcn.00418851
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x402da2
push 0x80004005
call fcn.00401580
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x11c], eax
mov dword [ebp - 4], 1
xor esi, esi
xor ecx, ecx
mov dword [ebp - 0x118], esi
cmp cx, word [edi + 0x68]
jae 0x403012
nop
mov edx, dword [edi + 0x64]
movzx ecx, word [edx + esi*2]
lea eax, [edx + esi*2]
mov edx, 0xffff
cmp cx, dx
je 0x402ff2
mov edx, 0xff
cmp cx, dx
je 0x402ff2
movzx ebx, word [eax + 2]
mov dl, byte [edi + 0x17]
mov eax, ecx
mov cl, byte [edi + 0x16]
mov byte [ebp - 0x128], cl
mov ecx, dword [edi + 4]
mov byte [ebp - 0x138], dl
test ecx, ecx
jne 0x402e34
mov edx, dword [edi + 8]
mov ecx, dword [ebp - 0x138]
push edx
mov edx, dword [ebp - 0x128]
push ecx
push ebx
push eax
push edx
call dword [sym.imp.dtccm2.dll_WriteSensorReg]
add esp, 0x14
jmp 0x402e49
cmp ecx, 1
jne 0x402e4e
push ecx
push 2
push eax
mov eax, dword [ebp - 0x128]
push eax
call fcn.004032f0
cmp eax, 1
je 0x402eb8
movzx ecx, byte [edi + 0x17]
mov edx, dword [edi + 0x64]
movzx ebx, word [edx + esi*2 + 2]
mov byte [ebp - 0x130], cl
movzx ecx, byte [edi + 0x16]
lea eax, [edx + esi*2]
movzx eax, word [eax]
mov byte [ebp - 0x12c], cl
mov ecx, dword [edi + 4]
test ecx, ecx
jne 0x402e96
mov edx, dword [edi + 8]
mov ecx, dword [ebp - 0x130]
push edx
mov edx, dword [ebp - 0x12c]
push ecx
push ebx
push eax
push edx
call dword [sym.imp.dtccm2.dll_WriteSensorReg]
add esp, 0x14
jmp 0x402eaf
cmp ecx, 1
jne 0x403092
push ecx
push 2
push eax
mov eax, dword [ebp - 0x12c]
push eax
call fcn.004032f0
cmp eax, 1
jne 0x403092
mov al, byte [edi + 0x16]
mov cl, byte [edi + 0x17]
mov edx, dword [edi + 0x64]
mov byte [ebp - 0x124], al
mov eax, dword [edi + 4]
mov byte [ebp - 0x134], cl
movzx ecx, word [edx + esi*2]
test eax, eax
jne 0x402efd
mov edx, dword [edi + 8]
mov eax, dword [ebp - 0x134]
push edx
push eax
mov eax, dword [ebp - 0x124]
lea edx, [ebp - 0x120]
push edx
push ecx
push eax
call dword [sym.imp.dtccm2.dll_ReadSensorReg]
add esp, 0x14
jmp 0x402f1d
cmp eax, 1
jne 0x402f1d
push eax
mov eax, dword [ebp - 0x124]
lea edx, [ebp - 0x120]
push edx
push eax
mov eax, 2
mov edx, edi
call fcn.00403420
mov ecx, dword [edi + 0x64]
mov dx, word [ebp - 0x120]
cmp dx, word [ecx + esi*2 + 2]
je 0x402ffd
cmp esi, 3
jle 0x402ffd
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x32
call ebx
movzx edx, byte [edi + 0x17]
mov eax, dword [edi + 0x64]
lea ecx, [eax + esi*2]
mov ax, word [ecx + 2]
mov cx, word [ecx]
push edx
mov dl, byte [edi + 0x16]
push edi
call fcn.004033d0
push 0xa
call ebx
movzx eax, byte [edi + 0x17]
movzx edx, byte [edi + 0x16]
mov ecx, dword [edi + 0x64]
mov ebx, dword [ebp - 0x118]
mov cx, word [ecx + ebx*2]
push eax
push edx
lea esi, [ebp - 0x120]
mov edx, edi
call fcn.00403500
mov eax, dword [edi + 0x64]
movzx ecx, word [ebp - 0x120]
cmp cx, word [eax + ebx*2 + 2]
lea eax, [eax + ebx*2]
je 0x402fea
movzx edx, word [eax]
push edx
lea eax, [ebp - 0x11c]
push str.0x_x
push eax
call fcn.00401650
add esp, 0xc
push str.Init_Sensor_Failed_
lea ecx, [edi + 0x190]
call fcn.00403b80
push 0x5680fc
lea ecx, [edi + 0x190]
call fcn.004037d0
mov ecx, dword [ebp - 0x11c]
mov eax, dword [ecx - 0xc]
push eax
push ecx
lea ecx, [edi + 0x190]
call fcn.004036d0
mov esi, dword [ebp - 0x118]
jmp 0x402ffd
movzx ecx, word [eax + 2]
push ecx
call dword [sym.imp.KERNEL32.dll_Sleep]
movzx edx, word [edi + 0x68]
add esi, 2
mov dword [ebp - 0x118], esi
cmp esi, edx
jl 0x402dd0
movzx ecx, word [edi + 0x10]
movzx eax, word [edi + 0x12]
imul eax, ecx
mov cl, byte [edi + 0x14]
mov dword [edi + 0xc], eax
cmp cl, 2
je 0x40303b
cmp cl, 3
je 0x40303b
cmp cl, 6
je 0x40303b
cmp cl, 7
je 0x40303b
test cl, cl
jne 0x403041
lea edx, [eax + eax]
mov dword [edi + 0xc], edx
mov esi, edi
call fcn.00402040
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x11c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x403071
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005149e7
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x64]
movzx ecx, word [eax + esi*2]
push ecx
lea edx, [ebp - 0x11c]
push str.0x_x
push edx
call fcn.00401650
add esp, 0xc
push 0x13
lea esi, [edi + 0x190]
push str.Init_Sensor_Failed_
mov ecx, esi
call fcn.00403aa0
push 1
push 0x5680fc
mov ecx, esi
call fcn.004036d0
mov edi, dword [ebp - 0x11c]
mov eax, dword [edi - 0xc]
push eax
push edi
mov ecx, esi
call fcn.004036d0
lea eax, [edi - 0x10]
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x403105
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
jmp 0x403076