	TITLE	tlp3scr.c
	.386P
include listing.inc
if @Version gt 510
.model FLAT
else
_TEXT	SEGMENT PARA USE32 PUBLIC 'CODE'
_TEXT	ENDS
_DATA	SEGMENT DWORD USE32 PUBLIC 'DATA'
_DATA	ENDS
CONST	SEGMENT DWORD USE32 PUBLIC 'CONST'
CONST	ENDS
_BSS	SEGMENT DWORD USE32 PUBLIC 'BSS'
_BSS	ENDS
_TLS	SEGMENT DWORD USE32 PUBLIC 'TLS'
_TLS	ENDS
PNP	SEGMENT PARA USE32 PUBLIC 'PNPCODE'
PNP	ENDS
_PDATA	SEGMENT DWORD USE32 PUBLIC 'PDATA'
_PDATA	ENDS
_LDATA	SEGMENT DWORD USE32 PUBLIC 'LCODE'
_LDATA	ENDS
_LTEXT	SEGMENT PARA USE32 PUBLIC 'LCODE'
_LTEXT	ENDS
FLAT	GROUP _DATA, CONST, _BSS, _PDATA, _LDATA
	ASSUME	CS: FLAT, DS: FLAT, SS: FLAT
endif
_DATA	SEGMENT
COMM	_DriverData:BYTE:040H
_DATA	ENDS
_PDATA	SEGMENT
_NumDevices DD	00H
_?dataRatesSupported@?1??TLP3SetupSmartcardExtension@@9@9 DD 02580H
	DD	04b00H
	DD	09600H
	DD	0e100H
	DD	01c200H
_PDATA	ENDS
PUBLIC	_TLP3SysDynamicDeviceInit@4
EXTRN	_SysFillMemory@12:NEAR
PNP	SEGMENT
_TLP3SysDynamicDeviceInit@4 PROC NEAR
; File tlp3scr.c
; Line 44
	push	ebp
	mov	ebp, esp
	push	ecx
; Line 54
	push	64					; 00000040H
	push	0
	push	OFFSET FLAT:_DriverData
	call	_SysFillMemory@12
; Line 62
	mov	eax, 1
; Line 63
	mov	esp, ebp
	pop	ebp
	ret	4
_TLP3SysDynamicDeviceInit@4 ENDP
PNP	ENDS
PUBLIC	_TLP3SysDynamicDeviceExit@4
PNP	SEGMENT
_TLP3SysDynamicDeviceExit@4 PROC NEAR
; Line 82
	push	ebp
	mov	ebp, esp
; Line 89
	mov	eax, 1
; Line 90
	pop	ebp
	ret	4
_TLP3SysDynamicDeviceExit@4 ENDP
PNP	ENDS
PUBLIC	_TLP3Configure
PUBLIC	_TLP3PnPNewDevnode@8
EXTRN	_CCODE__CONFIGMG_Register_Device_Driver:NEAR
PNP	SEGMENT
_CRStatus$ = -4
_DevNode$ = 8
_LoadType$ = 12
_TLP3PnPNewDevnode@8 PROC NEAR
; Line 115
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 116
	mov	DWORD PTR _CRStatus$[ebp], 0
; Line 125
	mov	eax, DWORD PTR _LoadType$[ebp]
	mov	DWORD PTR -8+[ebp], eax
	cmp	DWORD PTR -8+[ebp], 1
	je	SHORT $L19462
	jmp	SHORT $L19463
$L19462:
; Line 133
	push	3
	push	0
	push	OFFSET FLAT:_TLP3Configure
	mov	ecx, DWORD PTR _DevNode$[ebp]
	push	ecx
	call	_CCODE__CONFIGMG_Register_Device_Driver
	add	esp, 16					; 00000010H
	mov	DWORD PTR _CRStatus$[ebp], eax
; Line 134
	jmp	SHORT $L19459
$L19463:
; Line 137
	mov	DWORD PTR _CRStatus$[ebp], 1
$L19459:
; Line 149
	mov	eax, DWORD PTR _CRStatus$[ebp]
; Line 150
	mov	esp, ebp
	pop	ebp
	ret	8
_TLP3PnPNewDevnode@8 ENDP
PNP	ENDS
PUBLIC	_TLP3StartDevice
PUBLIC	_TLP3StopDevice
PNP	SEGMENT
_ConfigFct$ = 8
_DeviceNode$ = 16
_CRStatus$ = -4
_TLP3Configure PROC NEAR
; Line 180
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 181
	mov	DWORD PTR _CRStatus$[ebp], 0
; Line 191
	mov	eax, DWORD PTR _ConfigFct$[ebp]
	mov	DWORD PTR -8+[ebp], eax
	cmp	DWORD PTR -8+[ebp], 1
	je	SHORT $L19480
	cmp	DWORD PTR -8+[ebp], 2
	je	SHORT $L19481
	cmp	DWORD PTR -8+[ebp], 4
	je	SHORT $L19481
	jmp	SHORT $L19482
$L19480:
; Line 196
	mov	ecx, DWORD PTR _DeviceNode$[ebp]
	push	ecx
	call	_TLP3StartDevice
	add	esp, 4
	push	eax
	call	_MapNtStatusToWinError
	add	esp, 4
	mov	DWORD PTR _CRStatus$[ebp], eax
; Line 197
	jmp	SHORT $L19477
$L19481:
; Line 204
	mov	edx, DWORD PTR _DeviceNode$[ebp]
	push	edx
	call	_TLP3StopDevice
	add	esp, 4
	push	eax
	call	_MapNtStatusToWinError
	add	esp, 4
	mov	DWORD PTR _CRStatus$[ebp], eax
; Line 205
	jmp	SHORT $L19477
$L19482:
; Line 208
	mov	DWORD PTR _CRStatus$[ebp], 1
$L19477:
; Line 218
	mov	eax, DWORD PTR _CRStatus$[ebp]
; Line 219
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3Configure ENDP
PNP	ENDS
_LTEXT	SEGMENT
_status$ = 8
_MapNtStatusToWinError PROC NEAR
; File ..\..\inc\smclib.h
; Line 1133
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 1134
	push	DWORD PTR _status$[ebp]
; Line 1135
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	16					; 00000010H
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 1136
	add	sp, 4
; Line 1137
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_MapNtStatusToWinError ENDP
_LTEXT	ENDS
PUBLIC	_TLP3InitSingleDevice
PUBLIC	_TLP3DeleteDevice@4
EXTRN	_CCODE__Sprintf:NEAR
EXTRN	_CCODE__CONFIGMG_Get_DDBs:NEAR
EXTRN	_TLP3ControlProcedure:NEAR
_PDATA	SEGMENT
$SG19504 DB	'BULLTLP3.VXD', 00H
	ORG $+3
$SG19508 DB	'TLP3SCR%d', 00H
_PDATA	ENDS
PNP	SEGMENT
_DeviceNode$ = 8
_NTStatus$ = -12
_DeviceData$ = -8
_DeviceNo$ = -4
_DeviceName$19497 = -32
_pDeviceDDB$19498 = -16
_cfFunctionRet$19501 = -44
_pppDDB$19502 = -40
_ulCount$19503 = -36
_TLP3StartDevice PROC NEAR
; File tlp3scr.c
; Line 238
	push	ebp
	mov	ebp, esp
	sub	esp, 44					; 0000002cH
; Line 239
	mov	DWORD PTR _NTStatus$[ebp], 0
; Line 240
	mov	DWORD PTR _DeviceData$[ebp], 0
; Line 241
	mov	DWORD PTR _DeviceNo$[ebp], 0
$L19491:
; Line 254
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	cmp	DWORD PTR _DriverData[eax+12], 0
	jne	SHORT $L19494
; Line 256
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	add	ecx, OFFSET FLAT:_DriverData
	mov	DWORD PTR _DeviceData$[ebp], ecx
; Line 257
	jmp	SHORT $L19493
$L19494:
; Line 260
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	add	edx, 1
	mov	DWORD PTR _DeviceNo$[ebp], edx
	cmp	DWORD PTR _DeviceNo$[ebp], 4
	jb	SHORT $L19491
$L19493:
; Line 265
	cmp	DWORD PTR _DeviceData$[ebp], 0
	je	$L19514
; Line 268
	mov	DWORD PTR _pDeviceDDB$19498[ebp], 0
; Line 270
	mov	eax, DWORD PTR _DeviceData$[ebp]
	mov	ecx, DWORD PTR _DeviceNode$[ebp]
	mov	DWORD PTR [eax+12], ecx
; Line 272
	cmp	DWORD PTR _DeviceNo$[ebp], 0
	jne	SHORT $L19500
; Line 274
	mov	DWORD PTR _cfFunctionRet$19501[ebp], 0
; Line 282
	push	OFFSET FLAT:$SG19504
	lea	edx, DWORD PTR _DeviceName$19497[ebp]
	push	edx
	call	_CCODE__Sprintf
	add	esp, 8
; Line 290
	push	0
	mov	eax, DWORD PTR _DeviceNode$[ebp]
	push	eax
	push	2
	lea	ecx, DWORD PTR _ulCount$19503[ebp]
	push	ecx
	mov	edx, DWORD PTR _pppDDB$19502[ebp]
	push	edx
	call	_CCODE__CONFIGMG_Get_DDBs
	add	esp, 20					; 00000014H
	mov	DWORD PTR _cfFunctionRet$19501[ebp], eax
; Line 292
	cmp	DWORD PTR _cfFunctionRet$19501[ebp], 0
	je	SHORT $L19505
; Line 301
	jmp	SHORT $L19506
$L19505:
; Line 303
	mov	eax, DWORD PTR _pppDDB$19502[ebp]
	mov	ecx, DWORD PTR [eax]
	mov	edx, DWORD PTR [ecx]
	mov	DWORD PTR _pDeviceDDB$19498[ebp], edx
$L19506:
; Line 306
	jmp	SHORT $L19507
$L19500:
; Line 311
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	push	OFFSET FLAT:$SG19508
	lea	ecx, DWORD PTR _DeviceName$19497[ebp]
	push	ecx
	call	_CCODE__Sprintf
	add	esp, 12					; 0000000cH
$L19507:
; Line 314
	cmp	DWORD PTR _DeviceNo$[ebp], 0
	je	SHORT $L19509
; Line 319
	push	OFFSET FLAT:_TLP3ControlProcedure
	lea	edx, DWORD PTR _DeviceName$19497[ebp]
	push	edx
	call	_VxD_CreateDevice
	add	esp, 8
	mov	DWORD PTR _pDeviceDDB$19498[ebp], eax
$L19509:
; Line 322
	cmp	DWORD PTR _DeviceNo$[ebp], 0
	je	SHORT $L19511
	cmp	DWORD PTR _pDeviceDDB$19498[ebp], 0
	jne	SHORT $L19511
; Line 324
	mov	DWORD PTR _NTStatus$[ebp], -1073741823	; c0000001H
$L19511:
; Line 327
	cmp	DWORD PTR _NTStatus$[ebp], 0
	jne	SHORT $L19514
; Line 336
	mov	eax, DWORD PTR _pDeviceDDB$19498[ebp]
	push	eax
	lea	ecx, DWORD PTR _DeviceName$19497[ebp]
	push	ecx
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	push	edx
	call	_TLP3InitSingleDevice
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _NTStatus$[ebp], eax
$L19514:
; Line 343
	cmp	DWORD PTR _NTStatus$[ebp], 0
	je	SHORT $L19516
; Line 345
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	call	_TLP3DeleteDevice@4
; Line 347
	jmp	SHORT $L19517
$L19516:
; Line 350
	mov	ecx, DWORD PTR _NumDevices
	add	ecx, 1
	mov	DWORD PTR _NumDevices, ecx
$L19517:
; Line 360
	mov	eax, DWORD PTR _NTStatus$[ebp]
; Line 361
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3StartDevice ENDP
PNP	ENDS
_LTEXT	SEGMENT
_Device$ = 8
_ControlProc$ = 12
_VxD_CreateDevice PROC NEAR
; File ..\..\inc\smclib.h
; Line 907
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 908
	push	DWORD PTR _ControlProc$[ebp]
; Line 909
	push	DWORD PTR _Device$[ebp]
; Line 910
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	18					; 00000012H
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 911
	add	sp, 8
; Line 912
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_VxD_CreateDevice ENDP
_LTEXT	ENDS
PUBLIC	_TLP3GetComPort
PUBLIC	_TLP3SetupSmartcardExtension@4
PUBLIC	_TLP3InitCommPort
PUBLIC	_TLP3StartSerialEventTracking
EXTRN	_CCODE__HeapAllocate:NEAR
EXTRN	_CCODE__HeapFree:NEAR
PNP	SEGMENT
_DeviceNo$ = 8
_DeviceName$ = 12
_DeviceDDB$ = 16
_status$ = -8
_pReaderExtension$ = -4
_TLP3InitSingleDevice PROC NEAR
; File tlp3scr.c
; Line 385
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 386
	mov	DWORD PTR _status$[ebp], -1073741670	; c000009aH
; Line 402
	push	1
	push	892					; 0000037cH
	call	_CCODE__HeapAllocate
	add	esp, 8
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	mov	DWORD PTR _DriverData[ecx+8], eax
; Line 410
	push	1
	push	744					; 000002e8H
	call	_CCODE__HeapAllocate
	add	esp, 8
	mov	DWORD PTR _pReaderExtension$[ebp], eax
; Line 415
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	cmp	DWORD PTR _DriverData[edx+8], 0
	je	SHORT $L19532
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19532
; Line 417
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	edx, DWORD PTR _pReaderExtension$[ebp]
	mov	DWORD PTR [ecx+708], edx
; Line 418
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	DWORD PTR [ecx], 336			; 00000150H
; Line 419
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DeviceDDB$[ebp]
	mov	DWORD PTR _DriverData[edx], eax
; Line 421
	jmp	SHORT $L19533
$L19532:
; Line 423
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	cmp	DWORD PTR _DriverData[ecx+8], 0
	je	SHORT $L19534
; Line 425
	push	0
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_CCODE__HeapFree
	add	esp, 8
$L19534:
; Line 427
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19535
; Line 429
	push	0
	mov	ecx, DWORD PTR _pReaderExtension$[ebp]
	push	ecx
	call	_CCODE__HeapFree
	add	esp, 8
$L19535:
; Line 431
	mov	eax, -1073741670			; c000009aH
	jmp	$L19524
$L19533:
; Line 437
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+12]
	push	eax
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	mov	edx, DWORD PTR _DriverData[ecx+8]
	push	edx
	call	_TLP3GetComPort
	add	esp, 8
	mov	DWORD PTR _status$[ebp], eax
; Line 439
	cmp	DWORD PTR _status$[ebp], 0
	je	SHORT $L19538
; Line 441
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	cmp	DWORD PTR _DriverData[eax+8], 0
	je	SHORT $L19539
; Line 443
	push	0
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	mov	edx, DWORD PTR _DriverData[ecx+8]
	push	edx
	call	_CCODE__HeapFree
	add	esp, 8
$L19539:
; Line 445
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19540
; Line 447
	push	0
	mov	eax, DWORD PTR _pReaderExtension$[ebp]
	push	eax
	call	_CCODE__HeapFree
	add	esp, 8
$L19540:
; Line 449
	mov	eax, DWORD PTR _status$[ebp]
	jmp	$L19524
$L19538:
; Line 455
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	push	ecx
	call	_TLP3SetupSmartcardExtension@4
; Line 459
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_SmartcardInitialize
	add	esp, 4
	mov	DWORD PTR _status$[ebp], eax
; Line 461
	cmp	DWORD PTR _status$[ebp], 0
	je	SHORT $L19542
; Line 463
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	cmp	DWORD PTR _DriverData[ecx+8], 0
	je	SHORT $L19543
; Line 465
	push	0
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_CCODE__HeapFree
	add	esp, 8
$L19543:
; Line 467
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19544
; Line 469
	push	0
	mov	ecx, DWORD PTR _pReaderExtension$[ebp]
	push	ecx
	call	_CCODE__HeapFree
	add	esp, 8
$L19544:
; Line 471
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_SmartcardExit
	add	esp, 4
; Line 472
	mov	eax, -1073741670			; c000009aH
	jmp	$L19524
$L19542:
; Line 478
	mov	ecx, DWORD PTR _DeviceName$[ebp]
	push	ecx
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	mov	ecx, DWORD PTR [eax+708]
	add	ecx, 21					; 00000015H
	push	ecx
	call	_SmartcardCreateLink
	add	esp, 8
	mov	DWORD PTR _status$[ebp], eax
; Line 480
	cmp	DWORD PTR _status$[ebp], 0
	je	$L19547
; Line 482
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	mov	ecx, DWORD PTR [eax+708]
	xor	edx, edx
	mov	dl, BYTE PTR [ecx+21]
	test	edx, edx
	je	SHORT $L19548
; Line 486
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	edx, DWORD PTR [ecx+708]
	add	edx, 21					; 00000015H
	push	edx
	call	_SmartcardDeleteLink
	add	esp, 4
	mov	DWORD PTR _status$[ebp], eax
$L19548:
; Line 488
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	push	ecx
	call	_SmartcardExit
	add	esp, 4
; Line 489
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	cmp	DWORD PTR _DriverData[edx+8], 0
	je	SHORT $L19549
; Line 491
	push	0
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	push	ecx
	call	_CCODE__HeapFree
	add	esp, 8
$L19549:
; Line 493
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19550
; Line 495
	push	0
	mov	edx, DWORD PTR _pReaderExtension$[ebp]
	push	edx
	call	_CCODE__HeapFree
	add	esp, 8
$L19550:
; Line 497
	mov	eax, -1073741670			; c000009aH
	jmp	$L19524
$L19547:
; Line 503
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	push	ecx
	call	_TLP3InitCommPort
	add	esp, 4
	cmp	eax, 1
	je	$L19552
; Line 505
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	mov	ecx, DWORD PTR [eax+708]
	xor	edx, edx
	mov	dl, BYTE PTR [ecx+21]
	test	edx, edx
	je	SHORT $L19553
; Line 509
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	edx, DWORD PTR [ecx+708]
	add	edx, 21					; 00000015H
	push	edx
	call	_SmartcardDeleteLink
	add	esp, 4
$L19553:
; Line 511
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	push	ecx
	call	_SmartcardExit
	add	esp, 4
; Line 512
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	cmp	DWORD PTR _DriverData[edx+8], 0
	je	SHORT $L19554
; Line 514
	push	0
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	push	ecx
	call	_CCODE__HeapFree
	add	esp, 8
$L19554:
; Line 516
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19555
; Line 518
	push	0
	mov	edx, DWORD PTR _pReaderExtension$[ebp]
	push	edx
	call	_CCODE__HeapFree
	add	esp, 8
$L19555:
; Line 520
	mov	eax, -1073741670			; c000009aH
	jmp	$L19524
$L19552:
; Line 526
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	call	_TLP3StartSerialEventTracking
	add	esp, 4
	mov	DWORD PTR _status$[ebp], eax
; Line 527
	cmp	DWORD PTR _status$[ebp], 0
	je	$L19558
; Line 529
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	mov	edx, DWORD PTR _DriverData[ecx+8]
	mov	eax, DWORD PTR [edx+708]
	xor	ecx, ecx
	mov	cl, BYTE PTR [eax+21]
	test	ecx, ecx
	je	SHORT $L19559
; Line 533
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	mov	ecx, DWORD PTR [eax+708]
	add	ecx, 21					; 00000015H
	push	ecx
	call	_SmartcardDeleteLink
	add	esp, 4
$L19559:
; Line 535
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_SmartcardExit
	add	esp, 4
; Line 536
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	shl	ecx, 4
	cmp	DWORD PTR _DriverData[ecx+8], 0
	je	SHORT $L19560
; Line 538
	push	0
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx+8]
	push	eax
	call	_CCODE__HeapFree
	add	esp, 8
$L19560:
; Line 540
	cmp	DWORD PTR _pReaderExtension$[ebp], 0
	je	SHORT $L19561
; Line 542
	push	0
	mov	ecx, DWORD PTR _pReaderExtension$[ebp]
	push	ecx
	call	_CCODE__HeapFree
	add	esp, 8
$L19561:
; Line 544
	mov	eax, DWORD PTR _status$[ebp]
	jmp	SHORT $L19524
$L19558:
; Line 553
	xor	eax, eax
$L19524:
; Line 554
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3InitSingleDevice ENDP
PNP	ENDS
_LTEXT	SEGMENT
_LinkName$ = 8
_DeviceName$ = 12
_SmartcardCreateLink PROC NEAR
; File ..\..\inc\smclib.h
; Line 948
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 949
	push	DWORD PTR _DeviceName$[ebp]
; Line 950
	push	DWORD PTR _LinkName$[ebp]
; Line 951
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	1
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 952
	add	sp, 8
; Line 953
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardCreateLink ENDP
_LinkName$ = 8
_SmartcardDeleteLink PROC NEAR
; Line 960
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 961
	push	DWORD PTR _LinkName$[ebp]
; Line 962
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	2
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 963
	add	sp, 4
; Line 964
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardDeleteLink ENDP
_SmartcardExtension$ = 8
_SmartcardExit PROC NEAR
; Line 984
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 985
	push	DWORD PTR _SmartcardExtension$[ebp]
; Line 986
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	4
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 987
	add	sp, 4
; Line 988
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardExit ENDP
_SmartcardExtension$ = 8
_SmartcardInitialize PROC NEAR
; Line 995
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 996
	push	DWORD PTR _SmartcardExtension$[ebp]
; Line 997
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	5
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 998
	add	sp, 4
; Line 999
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardInitialize ENDP
_LTEXT	ENDS
EXTRN	_CCODE__CONFIGMG_Get_DevNode_Key:NEAR
EXTRN	_CCODE__CONFIGMG_Get_Parent:NEAR
EXTRN	_CCODE__CONFIGMG_Read_Registry_Value:NEAR
EXTRN	_SysCopyMemory@12:NEAR
_PDATA	SEGMENT
	ORG $+2
$SG19577 DB	'PORTNAME', 00H
_PDATA	ENDS
PNP	SEGMENT
_SmartcardExtension$ = 8
_DevNode$ = 12
_ParentDevNode$ = -260
_pcParentKey$ = -256
_pcPort$ = -272
_cbLength$ = -264
_cfFunctionRet$ = -276
_TLP3GetComPort PROC NEAR
; File tlp3scr.c
; Line 578
	push	ebp
	mov	ebp, esp
	sub	esp, 276				; 00000114H
; Line 583
	mov	DWORD PTR _cfFunctionRet$[ebp], 0
; Line 594
	push	0
	mov	eax, DWORD PTR _DevNode$[ebp]
	push	eax
	lea	ecx, DWORD PTR _ParentDevNode$[ebp]
	push	ecx
	call	_CCODE__CONFIGMG_Get_Parent
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _cfFunctionRet$[ebp], eax
; Line 597
	cmp	DWORD PTR _cfFunctionRet$[ebp], 0
	jne	SHORT $L19573
; Line 608
	push	0
	push	256					; 00000100H
	lea	edx, DWORD PTR _pcParentKey$[ebp]
	push	edx
	push	0
	mov	eax, DWORD PTR _ParentDevNode$[ebp]
	push	eax
	call	_CCODE__CONFIGMG_Get_DevNode_Key
	add	esp, 20					; 00000014H
	mov	DWORD PTR _cfFunctionRet$[ebp], eax
$L19573:
; Line 613
	cmp	DWORD PTR _cfFunctionRet$[ebp], 0
	jne	SHORT $L19578
; Line 622
	mov	DWORD PTR _cbLength$[ebp], 6
; Line 635
	push	0
	lea	ecx, DWORD PTR _cbLength$[ebp]
	push	ecx
	lea	edx, DWORD PTR _pcPort$[ebp]
	push	edx
	push	1
	push	OFFSET FLAT:$SG19577
	push	0
	mov	eax, DWORD PTR _ParentDevNode$[ebp]
	push	eax
	call	_CCODE__CONFIGMG_Read_Registry_Value
	add	esp, 28					; 0000001cH
	mov	DWORD PTR _cfFunctionRet$[ebp], eax
; Line 639
	cmp	DWORD PTR _cfFunctionRet$[ebp], 0
	jne	SHORT $L19578
; Line 645
	push	6
	lea	ecx, DWORD PTR _pcPort$[ebp]
	push	ecx
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	add	eax, 8
	push	eax
	call	_SysCopyMemory@12
; Line 647
	movsx	ecx, BYTE PTR _pcPort$[ebp+3]
	sub	ecx, 48					; 00000030H
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+580], ecx
$L19578:
; Line 664
	cmp	DWORD PTR _cfFunctionRet$[ebp], 0
	jne	SHORT $L19579
; Line 666
	xor	eax, eax
	jmp	SHORT $L19581
$L19579:
; Line 670
	mov	eax, -1073741810			; c000000eH
$L19581:
; Line 672
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3GetComPort ENDP
PNP	ENDS
EXTRN	_TLP3CardTracking:NEAR
EXTRN	_TLP3ReaderPower:NEAR
EXTRN	_TLP3Transmit:NEAR
EXTRN	_TLP3VendorIoctl:NEAR
EXTRN	_TLP3SetProtocol:NEAR
_PDATA	SEGMENT
	ORG $+3
$SG19590 DB	'Bull', 00H
	ORG $+3
$SG19591 DB	'SmarTLP3', 00H
_PDATA	ENDS
PNP	SEGMENT
_DeviceNo$ = 8
_SmartcardExtension$ = -8
_readerExtension$ = -4
_TLP3SetupSmartcardExtension@4 PROC NEAR
; Line 692
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 698
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	DWORD PTR _SmartcardExtension$[ebp], ecx
; Line 699
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	DWORD PTR _readerExtension$[ebp], eax
; Line 710
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+716], 288		; 00000120H
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+728], 288		; 00000120H
; Line 713
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+216], OFFSET FLAT:_TLP3ReaderPower
; Line 714
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+220], OFFSET FLAT:_TLP3Transmit
; Line 715
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+232], OFFSET FLAT:_TLP3CardTracking
; Line 716
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+236], OFFSET FLAT:_TLP3SetProtocol
; Line 717
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+248], OFFSET FLAT:_TLP3VendorIoctl
; Line 726
	push	5
	push	OFFSET FLAT:$SG19590
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	add	edx, 6
	push	edx
	call	_SysCopyMemory@12
; Line 728
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	WORD PTR [eax+4], 5
; Line 734
	push	9
	push	OFFSET FLAT:$SG19591
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	add	ecx, 40					; 00000028H
	push	ecx
	call	_SysCopyMemory@12
; Line 736
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	WORD PTR [edx+38], 9
; Line 737
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	mov	DWORD PTR [eax+72], ecx
; Line 745
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+584], 3571		; 00000df3H
; Line 746
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+588], 3571		; 00000df3H
; Line 750
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR _?dataRatesSupported@?1??TLP3SetupSmartcardExtension@@9@9
	mov	DWORD PTR [ecx+596], edx
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR _?dataRatesSupported@?1??TLP3SetupSmartcardExtension@@9@9
	mov	DWORD PTR [eax+592], ecx
; Line 755
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+612], OFFSET FLAT:_?dataRatesSupported@?1??TLP3SetupSmartcardExtension@@9@9
; Line 757
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	BYTE PTR [eax+616], 5
; Line 759
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+600], 254		; 000000feH
; Line 763
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+576], 0
; Line 767
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+560], 3
; Line 773
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+568], 1
; Line 775
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+572], 0
; Line 780
	mov	eax, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [eax+92], 48			; 00000030H
; Line 781
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [ecx+96], 65302		; 0000ff16H
; Line 783
	mov	edx, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [edx+116], 2
; Line 784
	mov	eax, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [eax+115], 2
; Line 785
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [ecx+114], 8
; Line 786
	mov	edx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [edx+100], 1
; Line 787
	mov	eax, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [eax+736], 24			; 00000018H
; Line 792
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [ecx+140], 1000		; 000003e8H
; Line 794
	mov	edx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [edx+148], 3000		; 00000bb8H
; Line 795
	mov	eax, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [eax+144], 0
; Line 798
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [ecx+119], 0
; Line 799
	mov	edx, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [edx+117], 0
; Line 800
	mov	eax, DWORD PTR _readerExtension$[ebp]
	mov	BYTE PTR [eax+118], 0
; Line 803
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [ecx+104], 0
; Line 804
	mov	edx, DWORD PTR _readerExtension$[ebp]
	mov	DWORD PTR [edx+108], 0
; Line 811
	mov	esp, ebp
	pop	ebp
	ret	4
_TLP3SetupSmartcardExtension@4 ENDP
PNP	ENDS
EXTRN	_CCODE__VCOMM_OpenComm:NEAR
EXTRN	_CCODE__VCOMM_GetSetCommTimeouts:NEAR
EXTRN	_CCODE__VCOMM_SetCommState:NEAR
EXTRN	_CCODE__VCOMM_SetupComm:NEAR
EXTRN	_CCODE__VCOMM_CloseComm:NEAR
EXTRN	_CCODE__VCOMM_EscapeCommFunction:NEAR
PNP	SEGMENT
_SmartcardExtension$ = 8
_lhPort$ = -20
_actionmask$ = -8
_indata$ = -32
_outdata$ = -12
_bRet$ = -4
_readerExtension$ = -16
_qsb$ = -28
_TLP3InitCommPort PROC NEAR
; Line 833
	push	ebp
	mov	ebp, esp
	sub	esp, 32					; 00000020H
; Line 834
	mov	DWORD PTR _lhPort$[ebp], 0
; Line 835
	mov	DWORD PTR _actionmask$[ebp], 0
; Line 836
	mov	DWORD PTR _indata$[ebp], 0
; Line 837
	mov	DWORD PTR _outdata$[ebp], 0
; Line 838
	mov	DWORD PTR _bRet$[ebp], 0
; Line 839
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	mov	DWORD PTR _readerExtension$[ebp], ecx
; Line 854
	push	-1
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	add	eax, 8
	push	eax
	call	_CCODE__VCOMM_OpenComm
	add	esp, 8
	mov	DWORD PTR _lhPort$[ebp], eax
; Line 856
	cmp	DWORD PTR _lhPort$[ebp], -1
	je	SHORT $L19607
	cmp	DWORD PTR _lhPort$[ebp], -2		; fffffffeH
	jne	SHORT $L19606
$L19607:
; Line 865
	xor	eax, eax
	jmp	$L19596
$L19606:
; Line 868
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR _lhPort$[ebp]
	mov	DWORD PTR [edx+88], eax
; Line 878
	push	1
	mov	ecx, DWORD PTR _readerExtension$[ebp]
	add	ecx, 140				; 0000008cH
	push	ecx
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	push	ecx
	call	_CCODE__VCOMM_GetSetCommTimeouts
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _bRet$[ebp], eax
; Line 882
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19608
; Line 890
	mov	DWORD PTR _actionmask$[ebp], 599	; 00000257H
; Line 895
	mov	edx, DWORD PTR _actionmask$[ebp]
	push	edx
	mov	eax, DWORD PTR _readerExtension$[ebp]
	add	eax, 92					; 0000005cH
	push	eax
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+88]
	push	eax
	call	_CCODE__VCOMM_SetCommState
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _bRet$[ebp], eax
$L19608:
; Line 900
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19609
; Line 912
	lea	ecx, DWORD PTR _qsb$[ebp]
	push	ecx
	push	288					; 00000120H
	mov	edx, DWORD PTR _readerExtension$[ebp]
	add	edx, 448				; 000001c0H
	push	edx
	push	288					; 00000120H
	mov	eax, DWORD PTR _readerExtension$[ebp]
	add	eax, 160				; 000000a0H
	push	eax
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+88]
	push	eax
	call	_CCODE__VCOMM_SetupComm
	add	esp, 24					; 00000018H
	mov	DWORD PTR _bRet$[ebp], eax
$L19609:
; Line 917
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19610
; Line 927
	lea	ecx, DWORD PTR _outdata$[ebp]
	push	ecx
	mov	edx, DWORD PTR _indata$[ebp]
	push	edx
	push	5
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	mov	edx, DWORD PTR [ecx+88]
	push	edx
	call	_CCODE__VCOMM_EscapeCommFunction
	add	esp, 16					; 00000010H
	mov	DWORD PTR _bRet$[ebp], eax
$L19610:
; Line 932
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19612
; Line 942
	lea	eax, DWORD PTR _outdata$[ebp]
	push	eax
	mov	ecx, DWORD PTR _indata$[ebp]
	push	ecx
	push	3
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	push	ecx
	call	_CCODE__VCOMM_EscapeCommFunction
	add	esp, 16					; 00000010H
	mov	DWORD PTR _bRet$[ebp], eax
$L19612:
; Line 947
	cmp	DWORD PTR _bRet$[ebp], 0
	jne	SHORT $L19614
; Line 951
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	push	ecx
	call	_CCODE__VCOMM_CloseComm
	add	esp, 4
	mov	DWORD PTR _bRet$[ebp], eax
; Line 954
	xor	eax, eax
	jmp	SHORT $L19596
$L19614:
; Line 963
	mov	eax, 1
$L19596:
; Line 964
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3InitCommPort ENDP
PNP	ENDS
PUBLIC	_TLP3SerialEvent
EXTRN	_CCODE__VCOMM_EnableCommNotification:NEAR
EXTRN	_CCODE__VCOMM_GetModemStatus:NEAR
EXTRN	_CCODE__VCOMM_SetCommEventMask:NEAR
EXTRN	_CCODE__VCOMM_GetCommEventMask:NEAR
PNP	SEGMENT
_DeviceNo$ = 8
_bRet$ = -4
_ModemStatus$ = -20
_SmartcardExtension$ = -12
_hCommPort$ = -8
_dwdummy$19630 = -24
_TLP3StartSerialEventTracking PROC NEAR
; Line 988
	push	ebp
	mov	ebp, esp
	sub	esp, 24					; 00000018H
; Line 993
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	DWORD PTR _SmartcardExtension$[ebp], ecx
; Line 994
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	mov	DWORD PTR _hCommPort$[ebp], ecx
; Line 1008
	push	0
	push	24					; 00000018H
	mov	edx, DWORD PTR _hCommPort$[ebp]
	push	edx
	call	_CCODE__VCOMM_SetCommEventMask
	add	esp, 12					; 0000000cH
	mov	BYTE PTR _bRet$[ebp], al
; Line 1012
	mov	eax, DWORD PTR _bRet$[ebp]
	and	eax, 255				; 000000ffH
	test	eax, eax
	je	SHORT $L19624
; Line 1018
	mov	ecx, DWORD PTR _DeviceNo$[ebp]
	push	ecx
	push	OFFSET FLAT:_TLP3SerialEvent
	mov	edx, DWORD PTR _hCommPort$[ebp]
	push	edx
	call	_CCODE__VCOMM_EnableCommNotification
	add	esp, 12					; 0000000cH
	mov	BYTE PTR _bRet$[ebp], al
$L19624:
; Line 1023
	mov	eax, DWORD PTR _bRet$[ebp]
	and	eax, 255				; 000000ffH
	test	eax, eax
	je	SHORT $L19625
; Line 1025
	lea	ecx, DWORD PTR _ModemStatus$[ebp]
	push	ecx
	mov	edx, DWORD PTR _hCommPort$[ebp]
	push	edx
	call	_CCODE__VCOMM_GetModemStatus
	add	esp, 8
	mov	BYTE PTR _bRet$[ebp], al
$L19625:
; Line 1029
	mov	eax, DWORD PTR _bRet$[ebp]
	and	eax, 255				; 000000ffH
	test	eax, eax
	je	SHORT $L19628
; Line 1031
	mov	ecx, DWORD PTR _ModemStatus$[ebp]
	and	ecx, 16					; 00000010H
	test	ecx, ecx
	je	SHORT $L19627
; Line 1035
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+576], 3
; Line 1038
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+396], 0
; Line 1047
	jmp	SHORT $L19628
$L19627:
; Line 1051
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+576], 1
; Line 1054
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+396], 0
$L19628:
; Line 1065
	mov	eax, DWORD PTR _bRet$[ebp]
	and	eax, 255				; 000000ffH
	test	eax, eax
	jne	SHORT $L19629
; Line 1076
	push	0
	push	0
	mov	ecx, DWORD PTR _hCommPort$[ebp]
	push	ecx
	call	_CCODE__VCOMM_EnableCommNotification
	add	esp, 12					; 0000000cH
; Line 1084
	lea	edx, DWORD PTR _dwdummy$19630[ebp]
	push	edx
	push	24					; 00000018H
	mov	eax, DWORD PTR _hCommPort$[ebp]
	push	eax
	call	_CCODE__VCOMM_GetCommEventMask
	add	esp, 12					; 0000000cH
	mov	BYTE PTR _bRet$[ebp], al
; Line 1086
	mov	eax, -1073741436			; c0000184H
	jmp	SHORT $L19617
$L19629:
; Line 1095
	xor	eax, eax
$L19617:
; Line 1096
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3StartSerialEventTracking ENDP
_hPort$ = 8
_DeviceNo$ = 12
_lEvent$ = 16
_lSubEvent$ = 20
_events$ = -4
_ModemStatus$ = -12
_SmartcardExtension$ = -8
_TLP3SerialEvent PROC NEAR
; Line 1125
	push	ebp
	mov	ebp, esp
	sub	esp, 12					; 0000000cH
; Line 1128
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	DWORD PTR _SmartcardExtension$[ebp], ecx
; Line 1142
	cmp	DWORD PTR _lSubEvent$[ebp], 8
	jne	$L19649
	cmp	DWORD PTR _lEvent$[ebp], 4
	jne	$L19649
; Line 1145
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	BYTE PTR [edx+352], 0
; Line 1148
	lea	eax, DWORD PTR _events$[ebp]
	push	eax
	push	8
	mov	ecx, DWORD PTR _hPort$[ebp]
	push	ecx
	call	_CCODE__VCOMM_GetCommEventMask
	add	esp, 12					; 0000000cH
; Line 1149
	lea	edx, DWORD PTR _ModemStatus$[ebp]
	push	edx
	mov	eax, DWORD PTR _hPort$[ebp]
	push	eax
	call	_CCODE__VCOMM_GetModemStatus
	add	esp, 8
; Line 1151
	mov	ecx, DWORD PTR _ModemStatus$[ebp]
	and	ecx, 16					; 00000010H
	test	ecx, ecx
	je	SHORT $L19650
; Line 1157
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+576], 3
; Line 1160
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+396], 0
; Line 1169
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	cmp	DWORD PTR [edx+736], 1
	jne	SHORT $L19651
; Line 1171
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	mov	DWORD PTR [ecx+736], 0
$L19651:
; Line 1174
	jmp	SHORT $L19653
$L19650:
; Line 1181
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+576], 1
; Line 1184
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [eax+396], 0
; Line 1193
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	cmp	DWORD PTR [edx+736], 1
	jne	SHORT $L19653
; Line 1195
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	mov	DWORD PTR [ecx+736], 0
$L19653:
; Line 1200
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+556]
	cmp	DWORD PTR [eax+12], 0
	je	SHORT $L19655
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	xor	eax, eax
	mov	al, BYTE PTR [edx+20]
	cmp	eax, 1
	je	SHORT $L19655
; Line 1202
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	push	ecx
	call	_SmartcardCompleteCardTracking
	add	esp, 4
$L19655:
; Line 1208
	mov	edx, DWORD PTR _ModemStatus$[ebp]
	and	edx, 32					; 00000020H
	test	edx, edx
	je	SHORT $L19656
; Line 1216
	jmp	SHORT $L19657
$L19656:
; Line 1224
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	call	_TLP3DeleteDevice@4
$L19657:
; Line 1227
	jmp	$L19671
$L19649:
	cmp	DWORD PTR _lSubEvent$[ebp], 16		; 00000010H
	jne	SHORT $L19659
	cmp	DWORD PTR _lEvent$[ebp], 4
	jne	SHORT $L19659
; Line 1236
	lea	ecx, DWORD PTR _ModemStatus$[ebp]
	push	ecx
	mov	edx, DWORD PTR _hPort$[ebp]
	push	edx
	call	_CCODE__VCOMM_GetModemStatus
	add	esp, 8
; Line 1239
	lea	eax, DWORD PTR _events$[ebp]
	push	eax
	push	16					; 00000010H
	mov	ecx, DWORD PTR _hPort$[ebp]
	push	ecx
	call	_CCODE__VCOMM_GetCommEventMask
	add	esp, 12					; 0000000cH
; Line 1250
	mov	edx, DWORD PTR _ModemStatus$[ebp]
	and	edx, 32					; 00000020H
	test	edx, edx
	je	SHORT $L19660
; Line 1258
	jmp	SHORT $L19661
$L19660:
; Line 1266
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	call	_TLP3DeleteDevice@4
$L19661:
; Line 1270
	jmp	$L19671
$L19659:
	cmp	DWORD PTR _lSubEvent$[ebp], 24		; 00000018H
	jne	$L19671
	cmp	DWORD PTR _lEvent$[ebp], 4
	jne	$L19671
; Line 1277
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	BYTE PTR [ecx+352], 0
; Line 1280
	lea	edx, DWORD PTR _events$[ebp]
	push	edx
	push	24					; 00000018H
	mov	eax, DWORD PTR _hPort$[ebp]
	push	eax
	call	_CCODE__VCOMM_GetCommEventMask
	add	esp, 12					; 0000000cH
; Line 1281
	lea	ecx, DWORD PTR _ModemStatus$[ebp]
	push	ecx
	mov	edx, DWORD PTR _hPort$[ebp]
	push	edx
	call	_CCODE__VCOMM_GetModemStatus
	add	esp, 8
; Line 1283
	mov	eax, DWORD PTR _ModemStatus$[ebp]
	and	eax, 16					; 00000010H
	test	eax, eax
	je	SHORT $L19664
; Line 1290
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+576], 3
; Line 1293
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+396], 0
; Line 1295
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	cmp	DWORD PTR [ecx+736], 1
	jne	SHORT $L19665
; Line 1297
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	DWORD PTR [eax+736], 0
$L19665:
; Line 1301
	jmp	SHORT $L19667
$L19664:
; Line 1308
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [ecx+576], 1
; Line 1311
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	DWORD PTR [edx+396], 0
; Line 1313
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	cmp	DWORD PTR [ecx+736], 1
	jne	SHORT $L19667
; Line 1315
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	DWORD PTR [eax+736], 0
$L19667:
; Line 1320
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+556]
	cmp	DWORD PTR [edx+12], 0
	je	SHORT $L19669
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	xor	edx, edx
	mov	dl, BYTE PTR [ecx+20]
	cmp	edx, 1
	je	SHORT $L19669
; Line 1322
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	push	eax
	call	_SmartcardCompleteCardTracking
	add	esp, 4
$L19669:
; Line 1328
	mov	ecx, DWORD PTR _ModemStatus$[ebp]
	and	ecx, 32					; 00000020H
	test	ecx, ecx
	je	SHORT $L19670
; Line 1336
	jmp	SHORT $L19671
$L19670:
; Line 1344
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	push	edx
	call	_TLP3DeleteDevice@4
$L19671:
; Line 1353
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3SerialEvent ENDP
PNP	ENDS
_LTEXT	SEGMENT
_SmartcardExtension$ = 8
_SmartcardCompleteCardTracking PROC NEAR
; File ..\..\inc\smclib.h
; Line 1111
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 1112
	push	DWORD PTR _SmartcardExtension$[ebp]
; Line 1113
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	20					; 00000014H
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 1114
	add	sp, 4
; Line 1115
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardCompleteCardTracking ENDP
_LTEXT	ENDS
PUBLIC	_TLP3ConfigureSerialPort
PNP	SEGMENT
_SmartcardExtension$ = 8
_actionmask$ = -8
_bRet$ = -4
_indata$ = -16
_outdata$ = -12
_TLP3ConfigureSerialPort PROC NEAR
; File tlp3scr.c
; Line 1377
	push	ebp
	mov	ebp, esp
	sub	esp, 16					; 00000010H
; Line 1378
	mov	DWORD PTR _actionmask$[ebp], 0
; Line 1379
	mov	DWORD PTR _bRet$[ebp], 0
; Line 1380
	mov	DWORD PTR _indata$[ebp], 0
; Line 1381
	mov	DWORD PTR _outdata$[ebp], 0
; Line 1396
	push	1
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	add	ecx, 140				; 0000008cH
	push	ecx
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	push	ecx
	call	_CCODE__VCOMM_GetSetCommTimeouts
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _bRet$[ebp], eax
; Line 1400
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19679
; Line 1408
	mov	DWORD PTR _actionmask$[ebp], 599	; 00000257H
; Line 1413
	mov	edx, DWORD PTR _actionmask$[ebp]
	push	edx
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	add	ecx, 92					; 0000005cH
	push	ecx
	mov	edx, DWORD PTR _SmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+88]
	push	ecx
	call	_CCODE__VCOMM_SetCommState
	add	esp, 12					; 0000000cH
	mov	DWORD PTR _bRet$[ebp], eax
$L19679:
; Line 1418
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19680
; Line 1426
	lea	edx, DWORD PTR _outdata$[ebp]
	push	edx
	mov	eax, DWORD PTR _indata$[ebp]
	push	eax
	push	5
	mov	ecx, DWORD PTR _SmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+88]
	push	eax
	call	_CCODE__VCOMM_EscapeCommFunction
	add	esp, 16					; 00000010H
	mov	DWORD PTR _bRet$[ebp], eax
$L19680:
; Line 1431
	cmp	DWORD PTR _bRet$[ebp], 0
	je	SHORT $L19682
; Line 1439
	lea	ecx, DWORD PTR _outdata$[ebp]
	push	ecx
	mov	edx, DWORD PTR _indata$[ebp]
	push	edx
	push	3
	mov	eax, DWORD PTR _SmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	mov	edx, DWORD PTR [ecx+88]
	push	edx
	call	_CCODE__VCOMM_EscapeCommFunction
	add	esp, 16					; 00000010H
	mov	DWORD PTR _bRet$[ebp], eax
$L19682:
; Line 1450
	mov	eax, DWORD PTR _bRet$[ebp]
; Line 1451
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3ConfigureSerialPort ENDP
PNP	ENDS
PUBLIC	_TLP3StopSerialEventTracking@4
PNP	SEGMENT
_DeviceNo$ = 8
_dwdummy$ = -4
_hCommPort$ = -8
_TLP3StopSerialEventTracking@4 PROC NEAR
; Line 1469
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 1471
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+88]
	mov	DWORD PTR _hCommPort$[ebp], eax
; Line 1484
	push	0
	push	0
	mov	ecx, DWORD PTR _hCommPort$[ebp]
	push	ecx
	call	_CCODE__VCOMM_EnableCommNotification
	add	esp, 12					; 0000000cH
; Line 1491
	lea	edx, DWORD PTR _dwdummy$[ebp]
	push	edx
	push	24					; 00000018H
	mov	eax, DWORD PTR _hCommPort$[ebp]
	push	eax
	call	_CCODE__VCOMM_GetCommEventMask
	add	esp, 12					; 0000000cH
; Line 1498
	mov	esp, ebp
	pop	ebp
	ret	4
_TLP3StopSerialEventTracking@4 ENDP
PNP	ENDS
PUBLIC	_TLP3_SignalSemaphore
EXTRN	_CCODE_Signal_Semaphore@4:NEAR
PNP	SEGMENT
_pSmartcardExtension$ = -4
_TLP3_SignalSemaphore PROC NEAR
; Line 1517
	push	ebp
	mov	ebp, esp
	push	ecx
	push	ebx
	push	esi
	push	edi
; Line 1523
	mov	DWORD PTR _pSmartcardExtension$[ebp], edx
; Line 1533
	mov	eax, DWORD PTR _pSmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	cmp	DWORD PTR [ecx+740], 0
	je	SHORT $L19696
; Line 1537
	mov	edx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	eax, DWORD PTR [edx+708]
	mov	ecx, DWORD PTR [eax+740]
	push	ecx
	call	_CCODE_Signal_Semaphore@4
$L19696:
; Line 1546
	pop	edi
	pop	esi
	pop	ebx
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3_SignalSemaphore ENDP
PNP	ENDS
PUBLIC	_TLP3Delay
EXTRN	_CCODE_Create_Semaphore@4:NEAR
EXTRN	_CCODE_Destroy_Semaphore@4:NEAR
EXTRN	_CCODE_Wait_Semaphore@8:NEAR
EXTRN	_CCODE_Set_Global_Time_Out@12:NEAR
PNP	SEGMENT
_pSmartcardExtension$ = 8
_ulMillisecTimeout$ = 12
_htimer$ = -4
_TLP3Delay PROC NEAR
; Line 1567
	push	ebp
	mov	ebp, esp
	push	ecx
; Line 1568
	mov	DWORD PTR _htimer$[ebp], 0
; Line 1572
	push	0
	call	_CCODE_Create_Semaphore@4
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	DWORD PTR [edx+740], eax
; Line 1576
	mov	eax, DWORD PTR _pSmartcardExtension$[ebp]
	mov	ecx, DWORD PTR [eax+708]
	cmp	DWORD PTR [ecx+740], 0
	ja	SHORT $L19703
; Line 1578
	xor	eax, eax
	jmp	SHORT $L19701
$L19703:
; Line 1589
	mov	edx, DWORD PTR _pSmartcardExtension$[ebp]
	push	edx
	mov	eax, DWORD PTR _ulMillisecTimeout$[ebp]
	push	eax
	push	OFFSET FLAT:_TLP3_SignalSemaphore
	call	_CCODE_Set_Global_Time_Out@12
	mov	DWORD PTR _htimer$[ebp], eax
; Line 1593
	cmp	DWORD PTR _htimer$[ebp], 0
	jne	SHORT $L19705
; Line 1597
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+740]
	push	eax
	call	_CCODE_Destroy_Semaphore@4
; Line 1599
	xor	eax, eax
	jmp	SHORT $L19701
$L19705:
; Line 1608
	push	21					; 00000015H
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+740]
	push	eax
	call	_CCODE_Wait_Semaphore@8
; Line 1612
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+740]
	push	eax
	call	_CCODE_Destroy_Semaphore@4
; Line 1614
	mov	eax, 1
$L19701:
; Line 1615
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3Delay ENDP
_DeviceNode$ = 8
_NTStatus$ = -8
_DeviceNo$ = -4
_TLP3StopDevice PROC NEAR
; Line 1632
	push	ebp
	mov	ebp, esp
	sub	esp, 8
; Line 1633
	mov	DWORD PTR _NTStatus$[ebp], 0
; Line 1634
	mov	DWORD PTR _DeviceNo$[ebp], 0
$L19712:
; Line 1646
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+12]
	cmp	ecx, DWORD PTR _DeviceNode$[ebp]
	jne	SHORT $L19715
; Line 1648
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	push	edx
	call	_TLP3DeleteDevice@4
; Line 1649
	jmp	SHORT $L19714
$L19715:
; Line 1651
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	add	eax, 1
	mov	DWORD PTR _DeviceNo$[ebp], eax
	cmp	DWORD PTR _DeviceNo$[ebp], 4
	jb	SHORT $L19712
$L19714:
; Line 1660
	mov	eax, DWORD PTR _NTStatus$[ebp]
; Line 1661
	mov	esp, ebp
	pop	ebp
	ret	0
_TLP3StopDevice ENDP
_DeviceNo$ = 8
_pSmartcardExtension$ = -8
_bRet$ = -4
_status$ = -12
_TLP3DeleteDevice@4 PROC NEAR
; Line 1679
	push	ebp
	mov	ebp, esp
	sub	esp, 16					; 00000010H
; Line 1681
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax+8]
	mov	DWORD PTR _pSmartcardExtension$[ebp], ecx
; Line 1682
	mov	DWORD PTR _bRet$[ebp], 0
; Line 1683
	mov	DWORD PTR _status$[ebp], -1073741668	; c000009cH
; Line 1691
	cmp	DWORD PTR _DeviceNo$[ebp], 0
	je	SHORT $L19724
; Line 1693
	mov	edx, DWORD PTR _DeviceNo$[ebp]
	shl	edx, 4
	mov	eax, DWORD PTR _DriverData[edx]
	push	eax
	call	_VxD_DeleteDevice
	add	esp, 4
$L19724:
; Line 1700
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	DWORD PTR [edx+736], 0
; Line 1703
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	push	eax
	call	_TLP3StopSerialEventTracking@4
; Line 1708
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	mov	eax, DWORD PTR [edx+88]
	push	eax
	call	_CCODE__VCOMM_CloseComm
	add	esp, 4
; Line 1711
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	xor	eax, eax
	mov	al, BYTE PTR [edx+21]
	test	eax, eax
	je	SHORT $L19725
; Line 1713
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	add	edx, 21					; 00000015H
	push	edx
	call	_SmartcardDeleteLink
	add	esp, 4
$L19725:
; Line 1716
	mov	eax, DWORD PTR _pSmartcardExtension$[ebp]
	cmp	DWORD PTR [eax+556], 0
	je	SHORT $L19727
; Line 1719
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+556]
	cmp	DWORD PTR [edx+12], 0
	je	SHORT $L19729
; Line 1721
	mov	eax, DWORD PTR _pSmartcardExtension$[ebp]
	push	eax
	call	_SmartcardCompleteCardTracking
	add	esp, 4
$L19729:
; Line 1723
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	push	ecx
	call	_SmartcardExit
	add	esp, 4
$L19727:
; Line 1727
	cmp	DWORD PTR _pSmartcardExtension$[ebp], 0
	je	SHORT $L19730
; Line 1729
	push	0
	mov	edx, DWORD PTR _pSmartcardExtension$[ebp]
	push	edx
	call	_CCODE__HeapFree
	add	esp, 8
$L19730:
; Line 1732
	mov	eax, DWORD PTR _pSmartcardExtension$[ebp]
	cmp	DWORD PTR [eax+708], 0
	je	SHORT $L19731
; Line 1734
	push	0
	mov	ecx, DWORD PTR _pSmartcardExtension$[ebp]
	mov	edx, DWORD PTR [ecx+708]
	push	edx
	call	_CCODE__HeapFree
	add	esp, 8
$L19731:
; Line 1738
	push	16					; 00000010H
	push	0
	mov	eax, DWORD PTR _DeviceNo$[ebp]
	shl	eax, 4
	add	eax, OFFSET FLAT:_DriverData
	push	eax
	call	_SysFillMemory@12
; Line 1740
	mov	ecx, DWORD PTR _NumDevices
	sub	ecx, 1
	mov	DWORD PTR _NumDevices, ecx
; Line 1749
	mov	esp, ebp
	pop	ebp
	ret	4
_TLP3DeleteDevice@4 ENDP
PNP	ENDS
_LTEXT	SEGMENT
_pDDB$ = 8
_VxD_DeleteDevice PROC NEAR
; File ..\..\inc\smclib.h
; Line 919
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 920
	push	DWORD PTR _pDDB$[ebp]
; Line 921
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	19					; 00000013H
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 922
	add	sp, 4
; Line 923
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_VxD_DeleteDevice ENDP
_LTEXT	ENDS
PUBLIC	_TLP3DeviceIOControl@16
PNP	SEGMENT
_DDB$ = 12
_IOCTLParameter$ = 20
_NTStatus$ = -16
_IOStatus$ = -12
_Device$ = -4
_DeviceData$ = -8
_pSmartcardExtension$19756 = -20
_TLP3DeviceIOControl@16 PROC NEAR
; File tlp3scr.c
; Line 1778
	push	ebp
	mov	ebp, esp
	sub	esp, 24					; 00000018H
; Line 1779
	mov	DWORD PTR _NTStatus$[ebp], -1073741808	; c0000010H
; Line 1780
	mov	DWORD PTR _IOStatus$[ebp], 0
	mov	DWORD PTR _Device$[ebp], 0
; Line 1781
	mov	DWORD PTR _DeviceData$[ebp], OFFSET FLAT:_DriverData
$L19749:
; Line 1796
	mov	eax, DWORD PTR _Device$[ebp]
	shl	eax, 4
	mov	ecx, DWORD PTR _DriverData[eax]
	cmp	ecx, DWORD PTR _DDB$[ebp]
	jne	SHORT $L19753
; Line 1798
	mov	edx, DWORD PTR _Device$[ebp]
	shl	edx, 4
	add	edx, OFFSET FLAT:_DriverData
	mov	DWORD PTR _DeviceData$[ebp], edx
; Line 1799
	jmp	SHORT $L19751
$L19753:
; Line 1802
	mov	eax, DWORD PTR _Device$[ebp]
	add	eax, 1
	mov	DWORD PTR _Device$[ebp], eax
	mov	ecx, DWORD PTR _Device$[ebp]
	cmp	ecx, DWORD PTR _NumDevices
	jb	SHORT $L19749
$L19751:
; Line 1807
	cmp	DWORD PTR _DeviceData$[ebp], 0
	je	$L19758
; Line 1810
	mov	edx, DWORD PTR _DeviceData$[ebp]
	mov	eax, DWORD PTR [edx+8]
	mov	DWORD PTR _pSmartcardExtension$19756[ebp], eax
; Line 1813
	mov	ecx, DWORD PTR _IOCTLParameter$[ebp]
	mov	edx, DWORD PTR [ecx+12]
	mov	DWORD PTR -24+[ebp], edx
	cmp	DWORD PTR -24+[ebp], 0
	je	SHORT $L19761
	cmp	DWORD PTR -24+[ebp], -1
	je	SHORT $L19767
	jmp	SHORT $L19774
$L19761:
; Line 1822
	mov	DWORD PTR _NTStatus$[ebp], 0
; Line 1824
	mov	eax, DWORD PTR _DeviceData$[ebp]
	xor	ecx, ecx
	mov	cl, BYTE PTR [eax+4]
	test	ecx, ecx
	jne	SHORT $L19763
; Line 1826
	mov	edx, DWORD PTR _DeviceData$[ebp]
	mov	BYTE PTR [edx+4], 1
; Line 1827
	mov	DWORD PTR _NTStatus$[ebp], 0
; Line 1829
	jmp	SHORT $L19765
$L19763:
; Line 1830
	mov	DWORD PTR _NTStatus$[ebp], -1073741808	; c0000010H
$L19765:
; Line 1831
	jmp	SHORT $L19758
$L19767:
; Line 1845
	cmp	DWORD PTR _NumDevices, 0
	je	SHORT $L19768
; Line 1847
	mov	eax, DWORD PTR _pSmartcardExtension$19756[ebp]
	mov	ecx, DWORD PTR [eax+556]
	cmp	DWORD PTR [ecx+12], 0
	je	SHORT $L19770
; Line 1849
	mov	edx, DWORD PTR _pSmartcardExtension$19756[ebp]
	push	edx
	call	_SmartcardCompleteCardTracking
	add	esp, 4
$L19770:
; Line 1852
	mov	DWORD PTR _NTStatus$[ebp], 0
; Line 1853
	mov	eax, DWORD PTR _DeviceData$[ebp]
	mov	BYTE PTR [eax+4], 0
; Line 1855
	jmp	SHORT $L19772
$L19768:
; Line 1857
	mov	DWORD PTR _NTStatus$[ebp], -1073741823	; c0000001H
$L19772:
; Line 1859
	jmp	SHORT $L19758
$L19774:
; Line 1875
	cmp	DWORD PTR _NumDevices, 0
	je	SHORT $L19775
; Line 1880
	mov	ecx, DWORD PTR _IOCTLParameter$[ebp]
	push	ecx
	mov	edx, DWORD PTR _pSmartcardExtension$19756[ebp]
	push	edx
	call	_SmartcardDeviceControl
	add	esp, 8
	mov	DWORD PTR _NTStatus$[ebp], eax
; Line 1882
	jmp	SHORT $L19776
$L19775:
; Line 1884
	mov	DWORD PTR _NTStatus$[ebp], -1073741823	; c0000001H
$L19776:
$L19758:
; Line 1894
	mov	eax, DWORD PTR _NTStatus$[ebp]
	push	eax
	call	_MapNtStatusToWinError
	add	esp, 4
	mov	DWORD PTR _IOStatus$[ebp], eax
; Line 1903
	mov	eax, DWORD PTR _IOStatus$[ebp]
; Line 1904
	mov	esp, ebp
	pop	ebp
	ret	16					; 00000010H
_TLP3DeviceIOControl@16 ENDP
PNP	ENDS
_LTEXT	SEGMENT
_SmartcardExtension$ = 8
_lpDIOCParmas$ = 12
_SmartcardDeviceControl PROC NEAR
; File ..\..\inc\smclib.h
; Line 972
	push	ebp
	mov	ebp, esp
	push	ebx
	push	esi
	push	edi
; Line 973
	push	DWORD PTR _lpDIOCParmas$[ebp]
; Line 974
	push	DWORD PTR _SmartcardExtension$[ebp]
; Line 975
	DB	-51					; ffffffcdH
	DB	32					; 00000020H
	DB	3
	DB	0
	DB	78					; 0000004eH
	DB	0
; Line 976
	add	sp, 8
; Line 977
	pop	edi
	pop	esi
	pop	ebx
	pop	ebp
	ret	0
_SmartcardDeviceControl ENDP
_LTEXT	ENDS
END
