; Format      :	Binary file
; Base Address:	0000h Range: 0000h - 10E98h Loaded length: 10E98h

; Processor:	    68000
; Target Assembler: 680x0 Assembler in MRI compatible mode
; This file should be compiled with "as	-M"

; ===========================================================================

; Segment type:	Pure code
; segment "ROM"
off_0:		dc.l initial_SSP	; DATA XREF: initial_PCr
		dc.l initial_PC
		dc.l exc_BusError
		dc.l exc_AddressError
		dc.l exc_IllegalInstruction
		dc.l exc_ZeroDivide
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l exc_InterruptLevel2
		dc.l initial_SSP
		dc.l exc_InterruptLevel4
		dc.l initial_SSP
		dc.l exc_InterruptLevel6
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
UserInterrupt_0x118:dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP
		dc.l initial_SSP

; =============== S U B	R O U T	I N E =======================================


initial_SSP:				; CODE XREF: exc_BusError+4j
					; exc_AddressError+4j ...
		rte
; End of function initial_SSP


; =============== S U B	R O U T	I N E =======================================


exc_BusError:				; DATA XREF: ROM:00000008o
		btst	#5,(sp)
		bne.s	initial_SSP
		move.l	#2,-(sp)
		movem.l	d0-a7,-(sp)
		jsr	exception
		suba.l	a6,a6
		jmp	InitializeXL
; End of function exc_BusError


; =============== S U B	R O U T	I N E =======================================


exc_AddressError:			; DATA XREF: ROM:0000000Co
		btst	#5,(sp)
		bne.s	initial_SSP
		move.l	#3,-(sp)
		movem.l	d0-a7,-(sp)
		jsr	exception
		suba.l	a6,a6
		jmp	InitializeXL
; End of function exc_AddressError


; =============== S U B	R O U T	I N E =======================================


exc_IllegalInstruction:			; DATA XREF: ROM:00000010o
		move.l	#4,-(sp)
		move.l	d0,-(sp)
		move.l	($3FFF4).l,d0
		cmp.l	$A(sp),d0
		beq.s	exc_IllegalInstruction_0
		move.l	(sp)+,d0
		clr.l	(sp)+
		move.l	2(sp),($3FFF4).l
		rte
; ---------------------------------------------------------------------------

exc_IllegalInstruction_0:		; CODE XREF: exc_IllegalInstruction+12j
		move.l	(sp)+,d0
		movem.l	d0-a7,-(sp)
		jsr	commonexception
		suba.l	a6,a6
		jmp	InitializeXL
; End of function exc_IllegalInstruction


; =============== S U B	R O U T	I N E =======================================


exc_ZeroDivide:				; DATA XREF: ROM:00000014o
		move.l	#5,-(sp)
		move.l	a0,-(sp)
		move.w	d0,-(sp)
		movea.l	$C(sp),a0
		move.w	(a0),d0
		andi.w	#$80C0,d0
		cmpi.w	#$80C0,d0
		beq.s	exc_ZeroDivide_0
		move.w	(sp)+,d0
		movea.l	(sp)+,a0
		clr.l	(sp)+
		rte
; ---------------------------------------------------------------------------

exc_ZeroDivide_0:			; CODE XREF: exc_ZeroDivide+18j
		move.w	(sp)+,d0
		movea.l	(sp)+,a0
		movem.l	d0-a7,-(sp)
		jsr	commonexception
		suba.l	a6,a6
		jmp	InitializeXL
; End of function exc_ZeroDivide


; =============== S U B	R O U T	I N E =======================================


initial_PC:				; DATA XREF: ROM:00000004o
		cmpa.l	(off_0).w,sp
		bne.w	initial_SSP
		movea.l	#$13C00,a5
		movea.l	#$2A000,sp
		cmpi.b	#4,($3FFFE).l
		beq.s	found_common
		cmpi.b	#$A,($3FFFE).l
		beq.s	found_common
		cmpi.b	#$D,($3FFFE).l
		beq.s	found_common
		movea.l	a5,a6
		jsr	sub_FF22
		suba.l	d0,a6
		pea	(a5)
		jsr	sub_FF2E
		clr.w	-(sp)
		jsr	InitializeCommon
		move.l	a5,-$D28(a5)
		move.l	a5,-$D24(a5)
		bra.s	found_XL
; ---------------------------------------------------------------------------

found_common:				; CODE XREF: initial_PC+1Cj
					; initial_PC+26j ...
		movea.l	a5,a6
		jsr	sub_FF22
		suba.l	d0,a6
		pea	(a5)
		jsr	sub_FF2E
		clr.w	-(sp)
		jsr	InitializeCommon
		movea.l	a5,a4
		move.l	a5,d0
		move.l	#$2FC00,d0
		movea.l	d0,a5
		movea.l	a5,a6
		jsr	sub_FF22
		suba.l	d0,a6
		pea	(a5)
		jsr	sub_FF2E
		move.w	#1,-(sp)
		jsr	InitializeCommon
		move.l	a4,-$D28(a5)
		move.l	a4,-$D24(a5)
		move.l	a5,-$D28(a4)
		move.l	a4,-$D24(a4)

found_XL:				; CODE XREF: initial_PC+54j
		movea.l	a6,sp
		suba.l	a6,a6
		jmp	InitializeXL
; End of function initial_PC


; =============== S U B	R O U T	I N E =======================================


exc_InterruptLevel6:			; DATA XREF: ROM:00000078o
		movem.l	d0-d2/a0-a1/a5,-(sp)
		jsr	(WriteUart).l
		movem.l	(sp)+,d0-d2/a0-a1/a5
		rte
; End of function exc_InterruptLevel6


; =============== S U B	R O U T	I N E =======================================


exc_InterruptLevel4:			; DATA XREF: ROM:00000070o
		movem.l	d0-d2/a0-a1/a5,-(sp)
		jsr	(WriteBundledHscx).l
		movem.l	(sp)+,d0-d2/a0-a1/a5
		rte
; End of function exc_InterruptLevel4


; =============== S U B	R O U T	I N E =======================================


exc_InterruptLevel2:			; DATA XREF: ROM:00000068o
		movem.l	d0-d2/a0-a1/a5,-(sp)
		jsr	(IsacGetReceiveMsg).l
		movem.l	(sp)+,d0-d2/a0-a1/a5
		rte
; End of function exc_InterruptLevel2


; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

sub_58E:				; CODE XREF: UartTimer+Cp
					; ph_loop_off+10p ...

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	arg_4(a6),a2
		move.w	arg_8(a6),d3
		bra.s	loc_5B4
; ---------------------------------------------------------------------------

loc_5A4:				; CODE XREF: sub_58E+2Cj
		move.b	(a2)+,d0
		move.b	d0,var_4(a6)
		moveq	#0,d1
		move.b	d0,d1
		add.l	a3,d1
		movea.l	d1,a0
		move.b	(a2)+,(a0)

loc_5B4:				; CODE XREF: sub_58E+14j
		subq.w	#2,d3
		cmpi.w	#0,d3
		bpl.s	loc_5A4
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function sub_58E

; ---------------------------------------------------------------------------
aSetupio:	dc.b 135,'SetupIO',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SetupIO:				; CODE XREF: DispatchEvent+84p
					; PostEvent+7Cp ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		moveq	#0,d0
		movea.l	arg_0(a6),a2
		move.l	d0,(a2)
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		movea.l	arg_4(a6),a3
		movea.l	4(a3),a4
		cmpa.w	#0,a4
		beq.s	loc_602
		move.l	a2,(a4)
		move.l	a2,4(a3)
		move.w	d3,d0
		move	d0,sr
		clr.b	d0
		bra.s	loc_616
; ---------------------------------------------------------------------------

loc_602:				; CODE XREF: SetupIO+24j
		move.l	arg_0(a6),d0
		movea.l	arg_4(a6),a2
		move.l	d0,4(a2)
		move.l	d0,(a2)
		move.w	d3,d0
		move	d0,sr
		moveq	#1,d0

loc_616:				; CODE XREF: SetupIO+32j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
; End of function SetupIO

		rts
; ---------------------------------------------------------------------------
aEnqueue:	dc.b 135,'Enqueue',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Enqueue:				; CODE XREF: StartTimer+Cp
					; StartTimer+20p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		movea.l	arg_4(a6),a2
		movea.l	(a2),a0
		movea.l	arg_0(a6),a3
		cmpa.l	a3,a0
		bne.s	loc_656
		move.l	(a3),d0
		move.l	d0,(a2)
		tst.l	d0
		bne.s	loc_692
		moveq	#0,d0
		move.l	d0,4(a2)
		bra.s	loc_692
; ---------------------------------------------------------------------------

loc_656:				; CODE XREF: Enqueue+1Cj
		movea.l	arg_4(a6),a0
		movea.l	(a0),a4
		bra.s	loc_660
; ---------------------------------------------------------------------------

loc_65E:				; CODE XREF: Enqueue+42j
		movea.l	(a4),a4

loc_660:				; CODE XREF: Enqueue+34j
		move.l	a4,d0
		beq.s	loc_66C
		movea.l	(a4),a0
		cmpa.l	arg_0(a6),a0
		bne.s	loc_65E

loc_66C:				; CODE XREF: Enqueue+3Aj
		move.l	a4,d0
		beq.s	loc_68A
		movea.l	arg_0(a6),a2
		move.l	(a2),d0
		move.l	d0,(a4)
		movea.l	arg_4(a6),a3
		movea.l	4(a3),a0
		cmpa.l	a2,a0
		bne.s	loc_692
		move.l	a4,4(a3)
		bra.s	loc_692
; ---------------------------------------------------------------------------

loc_68A:				; CODE XREF: Enqueue+46j
		move.w	d3,d0
		move	d0,sr
		moveq	#1,d0
		bra.s	loc_698
; ---------------------------------------------------------------------------

loc_692:				; CODE XREF: Enqueue+24j Enqueue+2Cj ...
		move.w	d3,d0
		move	d0,sr
		clr.b	d0

loc_698:				; CODE XREF: Enqueue+68j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function Enqueue

; ---------------------------------------------------------------------------
aDequeue:	dc.b 135,'Dequeue',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Dequeue:				; CODE XREF: EventLoop+1Cp
					; EventLoop+2Ep ...

var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-4
		movem.l	d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.l	a4,var_4(a6)
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d4
		movea.l	arg_4(a6),a0
		movea.l	(a0),a2
		cmpa.l	a4,a2
		beq.s	loc_6E8
		movea.l	a2,a3
		bra.s	loc_6D2
; ---------------------------------------------------------------------------

loc_6D0:				; CODE XREF: Dequeue+30j
		movea.l	(a3),a3

loc_6D2:				; CODE XREF: Dequeue+24j
		move.l	a3,d0
		beq.s	loc_6DC
		movea.l	(a3),a0
		cmpa.l	a4,a0
		bne.s	loc_6D0

loc_6DC:				; CODE XREF: Dequeue+2Aj
		move.l	a3,d0
		bne.s	loc_6E8
		move.w	d4,d0
		move	d0,sr
		clr.b	d0
		bra.s	loc_6EE
; ---------------------------------------------------------------------------

loc_6E8:				; CODE XREF: Dequeue+20j Dequeue+34j
		move.w	d4,d0
		move	d0,sr
		moveq	#1,d0

loc_6EE:				; CODE XREF: Dequeue+3Cj
		movem.l	(sp)+,d4/a2-a4
		unlk	a6
		rts
; End of function Dequeue

; ---------------------------------------------------------------------------
aInqueue:	dc.b 135,'Inqueue',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Inqueue:				; CODE XREF: ROM:000009AEp
					; ROM:000009C2p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		movea.l	(a3),a4
		cmpa.w	#0,a4
		beq.s	loc_72A
		move.l	(a4),d0
		move.l	d0,(a3)
		tst.l	d0
		bne.s	loc_72A
		moveq	#0,d0
		move.l	d0,4(a3)

loc_72A:				; CODE XREF: Inqueue+1Aj Inqueue+22j
		move.w	d3,d0
		move	d0,sr
		move.l	a4,d0
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function Inqueue

; ---------------------------------------------------------------------------
aFirst:		dc.b 133,'First',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

First:					; CODE XREF: ROM:000009D4p
					; WriteDeviceProtocol+5Ap ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	-$D20(a5),a4
		jsr	(WritePString).l
		move.l	4(a3),d0
		move.l	d0,-$D20(a5)
		movea.l	-$DB8(a5),a0
		move.l	d0,$1FA0(a0)
		tst.l	4(a3)
		bne.s	loc_7AA
		pea	(aIllegalEvent+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a3,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$2D,d0	; '-'
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		moveq	#$10,d0
		move.l	d0,-(sp)
		move.l	a3,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		jsr	(WritePString).l
		jsr	InitCommands
		bra.s	loc_7B4
; ---------------------------------------------------------------------------

loc_7AA:				; CODE XREF: First+2Aj
		move.l	a3,-(sp)
		movea.l	-$D20(a5),a0
		jsr	(a0)
		addq.w	#4,sp

loc_7B4:				; CODE XREF: First+68j
		jsr	(WritePString).l
		move.l	a4,-$D20(a5)
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function First

; ---------------------------------------------------------------------------
aDispatchevent:	dc.b 141,'DispatchEvent',0
aIllegalEvent:	dc.b 16,'illegal event ',0,0 ; DATA XREF: First+2Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DispatchEvent:				; CODE XREF: SendEvent+28p
					; ReturnMsgBuffer+80p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	-$D20(a5),8(a3)
		cmpa.w	#0,a3
		beq.s	loc_826
		move.l	4(a3),d3
		lea	(First).l,a0
		move.l	a0,d0
		cmp.l	d0,d3
		ble.s	loc_826
		lea	(InitializeXL).l,a0
		move.l	a0,d0
		cmp.l	d0,d3
		bge.s	loc_826
		move.l	4(a3),d0
		andi.l	#$FFFF0000,d0
		beq.s	loc_864

loc_826:				; CODE XREF: DispatchEvent+16j
					; DispatchEvent+26j ...
		pea	aIllegalSendeve	; "Illegal SendEvent in	"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	-$D20(a5),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		pea	(asc_885+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	4(a3),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		jsr	(WritePString).l
		jsr	InitCommands
		bra.s	loc_872
; ---------------------------------------------------------------------------

loc_864:				; CODE XREF: DispatchEvent+3Ej
		pea	-$D30(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_872:				; CODE XREF: DispatchEvent+7Cj
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function DispatchEvent

; ---------------------------------------------------------------------------
aSendevent:	dc.b 137,'SendEvent',0
asc_885:	dc.b 26,': ',0,0        ; DATA XREF: DispatchEvent+58o
aIllegalSendeve:dc.b 'Illegal SendEvent in ',0 ; DATA XREF: DispatchEvent:loc_826o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendEvent:				; CODE XREF: VoiceStart+90p
					; ModemCommand+1D0p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_8D0
		move.l	arg_0(a6),4(a2)
		move.l	arg_4(a6),$C(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_8D0:				; CODE XREF: SendEvent+18j
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function SendEvent

; ---------------------------------------------------------------------------
aPostevent:	dc.b 137,'PostEvent',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PostEvent:				; CODE XREF: monitor_interrupt+24p
					; CheckLeo+36p	...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	a2,d0
		beq.s	loc_91A
		move.l	4(a2),d3
		lea	(First).l,a0
		move.l	a0,d0
		cmp.l	d0,d3
		ble.s	loc_91A
		lea	(InitializeXL).l,a0
		move.l	a0,d0
		cmp.l	d0,d3
		bge.s	loc_91A
		move.l	4(a2),d0
		andi.l	#$FFFF0000,d0
		beq.s	loc_958

loc_91A:				; CODE XREF: PostEvent+Ej
					; PostEvent+1Ej ...
		pea	aIllegalIdleeve	; "Illegal IdleEvent in	"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	-$D20(a5),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		pea	(asc_979+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	4(a2),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		jsr	(WritePString).l
		jsr	InitCommands
		bra.s	loc_966
; ---------------------------------------------------------------------------

loc_958:				; CODE XREF: PostEvent+36j
		pea	-$D38(a5)
		move.l	a2,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_966:				; CODE XREF: PostEvent+74j
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function PostEvent

; ---------------------------------------------------------------------------
aIdleevent:	dc.b 137,'IdleEvent',0
asc_979:	dc.b 26,': ',0,0        ; DATA XREF: PostEvent+50o
aIllegalIdleeve:dc.b 'Illegal IdleEvent in ',0 ; DATA XREF: PostEvent:loc_91Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: noreturn bp-based	frame

IdleEvent:				; CODE XREF: InitializeXL+8Ap
		link	a6,#0
; End of function IdleEvent

		move.l	a2,-(sp)

loc_99A:				; CODE XREF: ROM:000009E2j
		addq.l	#1,-$D1C(a5)
		move.l	-$D1C(a5),d0
		movea.l	-$DB8(a5),a0
		move.l	d0,$1FA4(a0)
		pea	-$D30(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_9D2
		pea	-$D38(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_9DC

loc_9D2:				; CODE XREF: ROM:000009BCj
		move.l	a2,-(sp)
		jsr	(First).l
		addq.w	#4,sp

loc_9DC:				; CODE XREF: ROM:000009D0j
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		bra.s	loc_99A
; ---------------------------------------------------------------------------
		movea.l	(sp)+,a2
		unlk	a6
		rts
; ---------------------------------------------------------------------------
aEventloop:	dc.b 137,'EventLoop',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

EventLoop:				; CODE XREF: ReturnMsgBuffer+A0p
					; VoiceStop+16Ap ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	-$D44(a5),d0
		add.l	arg_4(a6),d0
		move.l	d0,8(a3)
		pea	-$D40(a5)
		move.l	a3,-(sp)
		jsr	(Dequeue).l
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_A30
		pea	-$D30(a5)
		move.l	a3,-(sp)
		jsr	(Dequeue).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_A3E

loc_A30:				; CODE XREF: EventLoop+26j
		pea	(aUnexpectedStarttimer+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_A4C
; ---------------------------------------------------------------------------

loc_A3E:				; CODE XREF: EventLoop+38j
		pea	-$D40(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_A4C:				; CODE XREF: EventLoop+46j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function EventLoop

; ---------------------------------------------------------------------------
aStarttimer:	dc.b 138,'StartTimer',0,0
aUnexpectedStarttimer:dc.b 22,'unexpected starttimer',0 ; DATA XREF: EventLoop:loc_A30o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

StartTimer:				; CODE XREF: ResetModem+78p
					; ph_transition+12p ...

arg_0		=  8

		link	a6,#0
		pea	-$D40(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_AA2
		pea	-$D30(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_AA6

loc_AA2:				; CODE XREF: StartTimer+16j
		moveq	#0,d0
		bra.s	loc_AA8
; ---------------------------------------------------------------------------

loc_AA6:				; CODE XREF: StartTimer+2Aj
		moveq	#1,d0

loc_AA8:				; CODE XREF: StartTimer+2Ej
		unlk	a6
		rts
; End of function StartTimer

; ---------------------------------------------------------------------------
aStoptimer:	dc.b 137,'StopTimer',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

StopTimer:				; CODE XREF: CheckTimer+4p
		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	-$D40(a5),a4
		addq.l	#1,-$D44(a5)
		bra.s	loc_AF2
; ---------------------------------------------------------------------------

loc_ACA:				; CODE XREF: StopTimer+40j
		movea.l	(a4),a4
		move.l	8(a3),d0
		cmp.l	-$D44(a5),d0
		bgt.s	loc_AF2
		pea	-$D40(a5)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		pea	-$D30(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_AF2:				; CODE XREF: StopTimer+10j
					; StopTimer+1Cj
		movea.l	a4,a3
		cmpa.w	#0,a3
		bne.s	loc_ACA
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function StopTimer

; ---------------------------------------------------------------------------
aChecktimer:	dc.b 138,'CheckTimer',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckTimer:				; DATA XREF: IsacGetReceiveMsg+152o

arg_0		=  8

		link	a6,#0
		jsr	(StopTimer).l
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function CheckTimer

; ---------------------------------------------------------------------------
aTimerevent:	dc.b 138,'TimerEvent',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

TimerEvent:				; CODE XREF: SendEvent+Ap
					; receiveV110frame+10p	...

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4/a2-a4,-(sp)
		move.l	arg_0(a6),d4
		lea	-$D9C(a5),a3
		lea	-$DA4(a5),a2
		bra.s	loc_B6E
; ---------------------------------------------------------------------------

loc_B4C:				; CODE XREF: TimerEvent+40j
		move.l	(a2),d0
		cmp.l	d4,d0
		blt.s	loc_B68
		move.l	a3,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a4
		cmpa.w	#0,a4
		beq.s	loc_B68
		move.l	a4,d0
		bra.s	loc_B7A
; ---------------------------------------------------------------------------

loc_B68:				; CODE XREF: TimerEvent+1Aj
					; TimerEvent+2Cj
		moveq	#$10,d3
		adda.l	d3,a3
		adda.l	d3,a2

loc_B6E:				; CODE XREF: TimerEvent+14j
		lea	-$D44(a5),a0
		move.l	a0,d0
		cmpa.l	d0,a2
		blt.s	loc_B4C
		moveq	#0,d0

loc_B7A:				; CODE XREF: TimerEvent+30j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function TimerEvent

; ---------------------------------------------------------------------------
aAlloc:		dc.b 133,'Alloc',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Alloc:					; CODE XREF: CheckTimer+Ep Free+22p ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		pea	-$D40(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Dequeue).l
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_BB8
		pea	-$D30(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Dequeue).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_BC6

loc_BB8:				; CODE XREF: Alloc+18j
		pea	(aUnexpectedFree+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_BEA
; ---------------------------------------------------------------------------

loc_BC6:				; CODE XREF: Alloc+2Cj
		move.b	arg_0(a6),d3
		moveq	#6,d0
		cmp.b	d0,d3
		bcc.s	loc_BEA
		moveq	#0,d0
		move.b	d3,d0
		asl.l	#4,d0
		lea	-$D9C(a5),a0
		add.l	a0,d0
		move.l	d0,-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_BEA:				; CODE XREF: Alloc+3Aj	Alloc+44j
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function Alloc

; ---------------------------------------------------------------------------
aFree:		dc.b 132,'Free',0,0
aUnexpectedFree:dc.b 16,'unexpected free',0 ; DATA XREF: Alloc:loc_BB8o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Free:					; CODE XREF: InitializeCommon+FEp

arg_0		=  8

		link	a6,#0
		movem.l	d3-d5/a2-a3,-(sp)
		move.l	arg_0(a6),d4
		lea	-$DA4(a5),a2
		moveq	#0,d5
		lea	-$DA0(a5),a3
		bra.s	loc_C4A
; ---------------------------------------------------------------------------

loc_C20:				; CODE XREF: Free+4Aj
		moveq	#0,d3
		bra.s	loc_C38
; ---------------------------------------------------------------------------

loc_C24:				; CODE XREF: Free+34j
		move.l	d4,d0
		add.l	d5,d0
		move.l	d0,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	(a2),d0
		add.l	d0,d4
		addq.l	#1,d3

loc_C38:				; CODE XREF: Free+1Aj
		move.l	(a3),d0
		cmp.l	d3,d0
		bgt.s	loc_C24
		moveq	#$10,d3
		adda.l	d3,a2
		addi.l	#$1000000,d5
		adda.l	d3,a3

loc_C4A:				; CODE XREF: Free+16j
		lea	-$D44(a5),a0
		move.l	a0,d0
		cmpa.l	d0,a2
		blt.s	loc_C20
		movem.l	(sp)+,d3-d5/a2-a3
		unlk	a6
		rts
; End of function Free

; ---------------------------------------------------------------------------
aInitmemory:	dc.b 138,'InitMemory',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitMemory:				; DATA XREF: CmdBControl+14o
					; dumpline+7Eo

var_60		= -$60
var_5C		= -$5C
var_58		= -$58
arg_0		=  8

		link	a6,#-$60
		movem.l	d3-d4/a2-a4,-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		moveq	#$5F,d0	; '_'
		lea	-$DA4(a5),a0
		lea	var_60(a6),a1

loc_C88:				; CODE XREF: InitMemory+20j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_C88
		lea	var_5C(a6),a3
		lea	var_58(a6),a4
		bra.s	loc_CAE
; ---------------------------------------------------------------------------

loc_C98:				; CODE XREF: InitMemory+4Cj
		movea.l	(a4),a2
		moveq	#0,d4
		bra.s	loc_CA2
; ---------------------------------------------------------------------------

loc_C9E:				; CODE XREF: InitMemory+3Aj
		addq.l	#1,d4
		movea.l	(a2),a2

loc_CA2:				; CODE XREF: InitMemory+32j
		move.l	a2,d0
		bne.s	loc_C9E
		move.l	d4,(a3)
		moveq	#$10,d3
		adda.l	d3,a3
		adda.l	d3,a4

loc_CAE:				; CODE XREF: InitMemory+2Cj
		lea	4(a6),a0
		move.l	a0,d0
		cmpa.l	d0,a3
		blt.s	loc_C98
		lea	var_5C(a6),a3
		lea	var_60(a6),a2
		bra.s	loc_CF2
; ---------------------------------------------------------------------------

loc_CC2:				; CODE XREF: InitMemory+8Ej
		move.l	(a2),d0
		move.w	d0,-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp
		pea	(asc_D0F+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	(a3),d0
		move.w	d0,-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp
		jsr	(WritePString).l
		moveq	#$10,d3
		adda.l	d3,a3
		adda.l	d3,a2

loc_CF2:				; CODE XREF: InitMemory+56j
		lea	(a6),a0
		move.l	a0,d0
		cmpa.l	d0,a2
		blt.s	loc_CC2
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function InitMemory

; ---------------------------------------------------------------------------
aMemory_dump:	dc.b 139,'memory_dump',0
asc_D0F:	dc.b 4,' - ',0          ; DATA XREF: InitMemory+64o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

memory_dump:				; CODE XREF: HandleV110Frame+5Ap
					; HandleV110Frame+96p

arg_0		=  8
arg_4		=  $C
arg_8		=  $10
arg_C		=  $14

		link	a6,#0
		movem.l	d3-d7/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	arg_4(a6),a0
		movea.l	arg_8(a6),a1
		movea.l	arg_C(a6),a2
		move.b	$63(a3),d3
		move.b	$62(a3),d4
		move.b	$7E(a3),d5
		moveq	#$7E,d6	; '~'
		move.b	$84(a3),d7
		clr.w	d0
		bra.w	loc_DE0
; ---------------------------------------------------------------------------

loc_D44:				; CODE XREF: memory_dump+D0j
		move.b	d0,d2
		and.b	d5,d2
		bne.s	loc_DAC
		tst.b	d3
		beq.s	loc_D9E
		cmpi.b	#5,d3
		beq.s	loc_D9A
		cmpi.b	#2,d3
		beq.s	loc_D60
		cmpi.b	#7,d3
		bne.s	loc_D68

loc_D60:				; CODE XREF: memory_dump+44j
		move.b	d4,d1
		or.b	$83(a3),d1
		bra.s	loc_D98
; ---------------------------------------------------------------------------

loc_D68:				; CODE XREF: memory_dump+4Aj
		cmpi.b	#4,d3
		beq.s	loc_D74
		cmpi.b	#9,d3
		bne.s	loc_D7A

loc_D74:				; CODE XREF: memory_dump+58j
		move.b	d4,d1
		or.b	d7,d1
		bra.s	loc_D98
; ---------------------------------------------------------------------------

loc_D7A:				; CODE XREF: memory_dump+5Ej
		cmpa.l	a1,a0
		bge.s	loc_D92
		move.b	(a0),d1
		lsl.b	#2,d1
		and.b	d6,d1
		or.b	d7,d1
		move.b	(a0)+,d2
		lsr.b	#4,d2
		ori.b	#$71,d2	; 'q'
		move.b	d2,d4
		bra.s	loc_D98
; ---------------------------------------------------------------------------

loc_D92:				; CODE XREF: memory_dump+68j
		move.b	d6,d1
		or.b	d7,d1
		move.b	d6,d4

loc_D98:				; CODE XREF: memory_dump+52j
					; memory_dump+64j ...
		bra.s	loc_D9C
; ---------------------------------------------------------------------------

loc_D9A:				; CODE XREF: memory_dump+3Ej
		moveq	#$FFFFFFFD,d1

loc_D9C:				; CODE XREF: memory_dump:loc_D98j
		bra.s	loc_DA0
; ---------------------------------------------------------------------------

loc_D9E:				; CODE XREF: memory_dump+38j
		clr.b	d1

loc_DA0:				; CODE XREF: memory_dump:loc_D9Cj
		cmpi.b	#9,d3
		blt.s	loc_DAA
		clr.b	d3
		bra.s	loc_DAC
; ---------------------------------------------------------------------------

loc_DAA:				; CODE XREF: memory_dump+90j
		addq.b	#1,d3

loc_DAC:				; CODE XREF: memory_dump+34j
					; memory_dump+94j
		cmpi.b	#7,d5
		bne.s	loc_DBC
		moveq	#$FFFFFFFE,d2
		or.b	d1,d2
		move.b	d2,(a2)
		lsr.b	#1,d1
		bra.s	loc_DDE
; ---------------------------------------------------------------------------

loc_DBC:				; CODE XREF: memory_dump+9Cj
		cmpi.b	#3,d5
		bne.s	loc_DCC
		moveq	#$FFFFFFFC,d2
		or.b	d1,d2
		move.b	d2,(a2)
		lsr.b	#2,d1
		bra.s	loc_DDE
; ---------------------------------------------------------------------------

loc_DCC:				; CODE XREF: memory_dump+ACj
		cmpi.b	#1,d5
		bne.s	loc_DDC
		moveq	#$FFFFFFF0,d2
		or.b	d1,d2
		move.b	d2,(a2)
		lsr.b	#4,d1
		bra.s	loc_DDE
; ---------------------------------------------------------------------------

loc_DDC:				; CODE XREF: memory_dump+BCj
		move.b	d1,(a2)

loc_DDE:				; CODE XREF: memory_dump+A6j
					; memory_dump+B6j ...
		addq.w	#1,d0

loc_DE0:				; CODE XREF: memory_dump+2Cj
		cmpi.w	#$1F,d0
		ble.w	loc_D44
		move.b	d3,$63(a3)
		move.b	d4,$62(a3)
		move.l	a0,d0
		movem.l	(sp)+,d3-d7/a2-a3
		unlk	a6
		rts
; End of function memory_dump

; ---------------------------------------------------------------------------
aSendv110frame:	dc.b 141,'sendV110frame',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

sendV110frame:				; CODE XREF: HandleV110Frame+D6p

arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#0
		movem.l	d3-d6/a2,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	arg_4(a6),a0
		movea.l	arg_8(a6),a1
		move.b	$60(a2),d3
		move.b	$7F(a2),d4
		move.b	$7E(a2),d5
		moveq	#$7E,d6	; '~'
		move.w	#$20,d0	; ' '
		bra.s	loc_E9C
; ---------------------------------------------------------------------------

loc_E32:				; CODE XREF: sendV110frame:loc_E9Cj
		move.b	(a1),d1
		move.b	d4,d2
		addq.b	#1,d4
		and.b	d5,d2
		bne.s	loc_E9C
		tst.b	d3
		beq.s	loc_E8C
		cmpi.b	#5,d3
		beq.s	loc_E7E
		move.b	d1,d2
		andi.b	#$81,d2
		cmpi.b	#2,d3
		beq.s	loc_E58
		cmpi.b	#7,d3
		bne.s	loc_E5E

loc_E58:				; CODE XREF: sendV110frame+46j
		move.b	d2,$81(a2)
		bra.s	loc_E62
; ---------------------------------------------------------------------------

loc_E5E:				; CODE XREF: sendV110frame+4Cj
		move.b	d2,$82(a2)

loc_E62:				; CODE XREF: sendV110frame+52j
		and.b	d6,d1
		cmp.b	d1,d6
		beq.s	loc_E72
		move.b	d1,(a0)+
		move.b	#2,$80(a2)
		bra.s	loc_E7E
; ---------------------------------------------------------------------------

loc_E72:				; CODE XREF: sendV110frame+5Cj
		tst.b	$80(a2)
		beq.s	loc_E7E
		subq.b	#1,$80(a2)
		move.b	d1,(a0)+

loc_E7E:				; CODE XREF: sendV110frame+3Aj
					; sendV110frame+66j ...
		cmpi.b	#9,d3
		blt.s	loc_E88
		clr.b	d3
		bra.s	loc_E8A
; ---------------------------------------------------------------------------

loc_E88:				; CODE XREF: sendV110frame+78j
		addq.b	#1,d3

loc_E8A:				; CODE XREF: sendV110frame+7Cj
		bra.s	loc_E9C
; ---------------------------------------------------------------------------

loc_E8C:				; CODE XREF: sendV110frame+34j
		tst.b	d1
		beq.s	loc_E9A
		clr.b	d4
		clr.b	d3
		clr.w	$56(a2)
		bra.s	loc_E9C
; ---------------------------------------------------------------------------

loc_E9A:				; CODE XREF: sendV110frame+84j
		moveq	#1,d3

loc_E9C:				; CODE XREF: sendV110frame+26j
					; sendV110frame+30j ...
		dbf	d0,loc_E32
		move.b	d3,$60(a2)
		move.b	d4,$7F(a2)
		move.l	a0,d0
		movem.l	(sp)+,d3-d6/a2
		unlk	a6
		rts
; End of function sendV110frame

; ---------------------------------------------------------------------------
aReceivev110frame:dc.b 144,'receiveV110frame ',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

receiveV110frame:			; CODE XREF: ReturnMsgBuffer+Ep
					; VoiceStop+Ep	...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_0(a6),d0
		moveq	#$20,d1	; ' '
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_EF4
		moveq	#$1F,d0
		clr.b	d1
		movea.l	a2,a0

loc_EEC:				; CODE XREF: receiveV110frame+28j
		move.b	d1,(a0)+
		dbf	d0,loc_EEC
		bra.s	loc_F0A
; ---------------------------------------------------------------------------

loc_EF4:				; CODE XREF: receiveV110frame+1Ej
		cmpi.l	#$5F,arg_0(a6) ; '_'
		beq.s	loc_F0A
		pea	(aGetmsgNil+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_F0A:				; CODE XREF: receiveV110frame+2Cj
					; receiveV110frame+36j
		move.l	a2,d0
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function receiveV110frame

; ---------------------------------------------------------------------------
aGetmsgbuffer:	dc.b 140,'GetMsgBuffer',0,0
aGetmsgNil:	dc.b 12,'GetMsg nil',0,0 ; DATA XREF: receiveV110frame+38o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

GetMsgBuffer:				; CODE XREF: VoiceSignal+9Cp
					; AllocateModemBuffers+10p ...

arg_0		=  8

		link	a6,#0
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function GetMsgBuffer

; ---------------------------------------------------------------------------
aReturnmsgbuffer:dc.b 143,'ReturnMsgBuffer',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ReturnMsgBuffer:			; DATA XREF: VoiceStop+158o
		link	a6,#0
		movem.l	d3-d4/a2-a4,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		pea	-$C7E(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a4
		jsr	(WriteProc).l
		cmpa.w	#0,a3
		beq.s	loc_FFA
		movea.l	a3,a2
		moveq	#$1E,d3
		adda.l	d3,a2
		move.b	#$A1,(a2)+
		move.b	-$CD7(a5),d0
		moveq	#1,d4
		cmp.b	d4,d0
		bne.s	loc_F9C
		moveq	#$14,d0
		bra.s	loc_F9E
; ---------------------------------------------------------------------------

loc_F9C:				; CODE XREF: ReturnMsgBuffer+44j
		moveq	#$54,d0	; 'T'

loc_F9E:				; CODE XREF: ReturnMsgBuffer+48j
		move.b	d0,(a2)+
		clr.b	(a2)+
		move.b	-$CD7(a5),d0
		cmp.b	d4,d0
		bne.s	loc_FAE
		moveq	#$25,d0	; '%'
		bra.s	loc_FB0
; ---------------------------------------------------------------------------

loc_FAE:				; CODE XREF: ReturnMsgBuffer+56j
		moveq	#$65,d0	; 'e'

loc_FB0:				; CODE XREF: ReturnMsgBuffer+5Aj
		move.b	d0,(a2)+
		move.b	#$10,(a2)+
		move.b	#$D0,(a2)+
		move.l	a2,d0
		movea.l	a3,a0
		adda.l	d3,a0
		sub.l	a0,d0
		move.l	d0,$14(a3)
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.l	-$C7E(a5),d0
		beq.s	loc_FFA
		lea	(VoiceStop).l,a0
		move.l	a0,-$C8A(a5)
		moveq	#1,d0
		move.l	d0,-(sp)
		pea	-$C8E(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_FFA:				; CODE XREF: ReturnMsgBuffer+30j
					; ReturnMsgBuffer+8Cj
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function ReturnMsgBuffer

; ---------------------------------------------------------------------------
aVoicestop:	dc.b 137,'VoiceStop',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

VoiceStop:				; CODE XREF: VoiceControl+48p
					; DATA XREF: ReturnMsgBuffer+8Eo

var_4		= -4

		link	a6,#-4
		movem.l	d3-d6/a2-a3,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		movea.l	-$C7E(a5),a0
		move.l	$C(a0),d0
		move.b	d0,var_4(a6)
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	var_4(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$2A,d1	; '*'
		cmp.l	d1,d0
		beq.s	loc_108C
		moveq	#$23,d1	; '#'
		cmp.l	d1,d0
		beq.s	loc_1094
		moveq	#$41,d1	; 'A'
		cmp.l	d1,d0
		beq.s	loc_109C
		moveq	#$61,d1	; 'a'
		cmp.l	d1,d0
		beq.s	loc_109C
		moveq	#$42,d1	; 'B'
		cmp.l	d1,d0
		beq.s	loc_10A4
		moveq	#$62,d1	; 'b'
		cmp.l	d1,d0
		beq.s	loc_10A4
		moveq	#$43,d1	; 'C'
		cmp.l	d1,d0
		beq.s	loc_10AC
		moveq	#$63,d1	; 'c'
		cmp.l	d1,d0
		beq.s	loc_10AC
		moveq	#$44,d1	; 'D'
		cmp.l	d1,d0
		beq.s	loc_10B4
		moveq	#$64,d1	; 'd'
		cmp.l	d1,d0
		beq.s	loc_10B4
		bra.s	loc_10BC
; ---------------------------------------------------------------------------

loc_108C:				; CODE XREF: VoiceStop+3Aj
		move.b	#$A,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_1094:				; CODE XREF: VoiceStop+40j
		move.b	#$B,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_109C:				; CODE XREF: VoiceStop+46j
					; VoiceStop+4Cj
		move.b	#$C,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_10A4:				; CODE XREF: VoiceStop+52j
					; VoiceStop+58j
		move.b	#$D,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_10AC:				; CODE XREF: VoiceStop+5Ej
					; VoiceStop+64j
		move.b	#$E,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_10B4:				; CODE XREF: VoiceStop+6Aj
					; VoiceStop+70j
		move.b	#$F,var_4(a6)
		bra.s	loc_10C2
; ---------------------------------------------------------------------------

loc_10BC:				; CODE XREF: VoiceStop+72j
		andi.b	#$F,var_4(a6)

loc_10C2:				; CODE XREF: VoiceStop+7Aj
					; VoiceStop+82j ...
		move.l	a3,d0
		beq.w	loc_118A
		movea.l	a3,a2
		moveq	#$1E,d3
		adda.l	d3,a2
		move.b	#$A1,(a2)+
		move.b	-$CD7(a5),d0
		moveq	#1,d4
		cmp.b	d4,d0
		bne.s	loc_10E0
		moveq	#$22,d0	; '"'
		bra.s	loc_10E2
; ---------------------------------------------------------------------------

loc_10E0:				; CODE XREF: VoiceStop+C2j
		moveq	#$62,d0	; 'b'

loc_10E2:				; CODE XREF: VoiceStop+C6j
		move.b	d0,(a2)+
		move.b	var_4(a6),d6
		moveq	#0,d5
		move.b	d6,d5
		lea	-$D16(a5),a0
		move.b	(a0,d5.w),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#1,d0
		lea	-$CEE(a5),a0
		move.w	(a0,d0.w),d0
		move.w	d0,(a2)+
		move.w	#$2C4A,(a2)+
		move.w	#$3799,(a2)+
		lea	-$D06(a5),a0
		move.b	(a0,d5.w),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#1,d0
		lea	-$CF6(a5),a0
		move.w	(a0,d0.w),d0
		move.w	d0,(a2)+
		move.b	-$CD7(a5),d0
		cmp.b	d4,d0
		bne.s	loc_1130
		moveq	#$25,d0	; '%'
		bra.s	loc_1132
; ---------------------------------------------------------------------------

loc_1130:				; CODE XREF: VoiceStop+112j
		moveq	#$65,d0	; 'e'

loc_1132:				; CODE XREF: VoiceStop+116j
		move.b	d0,(a2)+
		move.b	#$A2,(a2)+
		move.b	#$AA,(a2)+
		move.b	-$CD7(a5),d0
		cmp.b	d4,d0
		bne.s	loc_1148
		moveq	#$14,d0
		bra.s	loc_114A
; ---------------------------------------------------------------------------

loc_1148:				; CODE XREF: VoiceStop+12Aj
		moveq	#$54,d0	; 'T'

loc_114A:				; CODE XREF: VoiceStop+12Ej
		move.b	d0,(a2)+
		move.b	#8,(a2)+
		move.l	a2,d0
		movea.l	a3,a0
		adda.l	d3,a0
		sub.l	a0,d0
		move.l	d0,$14(a3)
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		lea	(ReturnMsgBuffer).l,a0
		move.l	a0,-$C8A(a5)
		moveq	#2,d0
		move.l	d0,-(sp)
		pea	-$C8E(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_118A:				; CODE XREF: VoiceStop+ACj
		movem.l	(sp)+,d3-d6/a2-a3
		unlk	a6
		rts
; End of function VoiceStop

; ---------------------------------------------------------------------------
aVoicestart:	dc.b 138,'VoiceStart',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

VoiceStart:				; DATA XREF: CmdDial+4Eo

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a4
		jsr	(WriteProc).l
		cmpa.w	#0,a4
		beq.w	loc_12AA
		movea.l	a4,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		movea.l	arg_0(a6),a2
		moveq	#$C,d0
		adda.l	d0,a2
		move.l	(a2),d0
		moveq	#1,d3
		and.l	d3,d0
		beq.s	loc_123A
		move.b	#$A1,(a3)+
		cmpi.b	#1,-$CD7(a5)
		bne.s	loc_11EC
		moveq	#$15,d0
		bra.s	loc_11EE
; ---------------------------------------------------------------------------

loc_11EC:				; CODE XREF: VoiceStart+46j
		moveq	#$55,d0	; 'U'

loc_11EE:				; CODE XREF: VoiceStart+4Aj
		move.b	d0,(a3)+
		move.l	(a2),d0
		move.b	d0,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.l	(a2),d0
		asr.l	#8,d0
		andi.l	#$FF,d0
		tst.l	d0
		beq.s	loc_1212
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_121C
		bra.s	loc_1288
; ---------------------------------------------------------------------------

loc_1212:				; CODE XREF: VoiceStart+68j
		clr.b	(a3)+
		move.b	#$38,-$CD3(a5) ; '8'
		bra.s	loc_1226
; ---------------------------------------------------------------------------

loc_121C:				; CODE XREF: VoiceStart+6Ej
		move.b	-$D18(a5),(a3)+
		move.b	#3,-$CD3(a5)

loc_1226:				; CODE XREF: VoiceStart+7Aj
		pea	-$CE6(a5)
		pea	(NL_DISCONNECT_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_1288
; ---------------------------------------------------------------------------

loc_123A:				; CODE XREF: VoiceStart+3Aj
		move.b	#$A1,(a3)+
		move.b	-$CD7(a5),d0
		moveq	#1,d3
		cmp.b	d3,d0
		bne.s	loc_124C
		moveq	#$16,d0
		bra.s	loc_124E
; ---------------------------------------------------------------------------

loc_124C:				; CODE XREF: VoiceStart+A6j
		moveq	#$56,d0	; 'V'

loc_124E:				; CODE XREF: VoiceStart+AAj
		move.b	d0,(a3)+
		moveq	#$30,d0	; '0'
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d1
		asr.l	#4,d1
		andi.b	#$F0,d1
		sub.b	d1,d0
		move.b	d0,(a3)+
		move.b	-$CD7(a5),d0
		cmp.b	d3,d0
		bne.s	loc_1270
		moveq	#$15,d0
		bra.s	loc_1272
; ---------------------------------------------------------------------------

loc_1270:				; CODE XREF: VoiceStart+CAj
		moveq	#$55,d0	; 'U'

loc_1272:				; CODE XREF: VoiceStart+CEj
		move.b	d0,(a3)+
		move.l	$C(a2),d0
		asr.l	#8,d0
		andi.b	#$F0,d0
		moveq	#$40,d1	; '@'
		add.b	d1,d0
		move.b	d0,-$D18(a5)
		move.b	d0,(a3)+

loc_1288:				; CODE XREF: VoiceStart+70j
					; VoiceStart+98j
		move.l	a3,d0
		movea.l	a4,a2
		moveq	#$1E,d1
		adda.l	d1,a2
		sub.l	a2,d0
		move.l	d0,$14(a4)
		lea	(monitor_start).l,a0
		move.l	a0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_12AA:				; CODE XREF: VoiceStart+22j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function VoiceStart

; ---------------------------------------------------------------------------
aVoicecontrol:	dc.b 140,'VoiceControl',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

VoiceControl:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	-$C76(a5),d0
		beq.s	loc_131C
		move.l	$14(a3),d0
		moveq	#1,d1
		cmp.l	d1,d0
		bne.s	loc_131C
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	$1E(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,$C(a2)
		pea	-$C7E(a5)
		move.l	a2,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		tst.b	d0

loc_1314:				; DATA XREF: ROM:off_10114o
		beq.s	loc_131C
		jsr	(VoiceStop).l

loc_131C:				; CODE XREF: VoiceControl+10j
					; VoiceControl+1Aj ...
		lea	(B_DATA_INDICATION).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function VoiceControl

; ---------------------------------------------------------------------------
aVoicerequest:	dc.b 140,'VoiceRequest',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

VoiceRequest:				; CODE XREF: AttachVoice+8p

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a4
		move.b	#$A1,$1E(a3)
		move.b	-$C76(a5),d0
		beq.s	loc_1386
		move.b	$F(a4),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_1382
		moveq	#$31,d0	; '1'
		bra.s	loc_1384
; ---------------------------------------------------------------------------

loc_1382:				; CODE XREF: VoiceRequest+34j
		moveq	#$71,d0	; 'q'

loc_1384:				; CODE XREF: VoiceRequest+38j
		bra.s	loc_1396
; ---------------------------------------------------------------------------

loc_1386:				; CODE XREF: VoiceRequest+2Aj
		move.b	$F(a4),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_1394
		moveq	#$2F,d0	; '/'
		bra.s	loc_1396
; ---------------------------------------------------------------------------

loc_1394:				; CODE XREF: VoiceRequest+46j
		moveq	#$3F,d0	; '?'

loc_1396:				; CODE XREF: VoiceRequest:loc_1384j
					; VoiceRequest+4Aj
		move.b	d0,$1F(a3)
		move.b	$F(a4),d0
		moveq	#1,d3
		cmp.b	d3,d0
		bne.s	loc_13A8
		moveq	#$10,d0
		bra.s	loc_13AA
; ---------------------------------------------------------------------------

loc_13A8:				; CODE XREF: VoiceRequest+5Aj
		moveq	#$50,d0	; 'P'

loc_13AA:				; CODE XREF: VoiceRequest+5Ej
		addq.b	#5,d0
		move.b	d0,$20(a3)
		move.b	#$60,$21(a3) ; '`'
		move.b	-$CD7(a5),d0
		cmp.b	d3,d0
		bne.s	loc_13C2
		moveq	#$16,d0
		bra.s	loc_13C4
; ---------------------------------------------------------------------------

loc_13C2:				; CODE XREF: VoiceRequest+74j
		moveq	#$56,d0	; 'V'

loc_13C4:				; CODE XREF: VoiceRequest+78j
		move.b	d0,$22(a3)
		move.b	#$30,$23(a3) ; '0'
		move.b	-$CD7(a5),d0
		cmp.b	d3,d0
		bne.s	loc_13DA
		moveq	#$15,d0
		bra.s	loc_13DC
; ---------------------------------------------------------------------------

loc_13DA:				; CODE XREF: VoiceRequest+8Cj
		moveq	#$55,d0	; 'U'

loc_13DC:				; CODE XREF: VoiceRequest+90j
		move.b	d0,$24(a3)
		moveq	#$40,d0	; '@'
		move.b	d0,-$D18(a5)
		move.b	d0,$25(a3)
		moveq	#8,d0
		move.l	d0,$14(a3)
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function VoiceRequest

; ---------------------------------------------------------------------------
aAttachvoice:	dc.b 139,'AttachVoice',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AttachVoice:

arg_0		=  8

		link	a6,#0
		move.l	arg_0(a6),-(sp)
		jsr	(VoiceRequest).l
		unlk	a6
		rts
; End of function AttachVoice

; ---------------------------------------------------------------------------
aListenvoice:	dc.b 139,'ListenVoice',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ListenVoice:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a0
		move.b	#3,$13(a0)
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function ListenVoice

; ---------------------------------------------------------------------------
aConnectvoice:	dc.b 140,'ConnectVoice',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ConnectVoice:

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a4
		movea.l	$C(a3),a2
		move.b	#$A1,$1E(a4)
		move.b	-$C76(a5),d0
		beq.s	loc_14F4
		move.b	$F(a2),d0
		moveq	#1,d3
		cmp.b	d3,d0
		bne.s	loc_14B2
		moveq	#$30,d0	; '0'
		bra.s	loc_14B4
; ---------------------------------------------------------------------------

loc_14B2:				; CODE XREF: ConnectVoice+34j
		moveq	#$70,d0	; 'p'

loc_14B4:				; CODE XREF: ConnectVoice+38j
		move.b	d0,$1F(a4)
		move.b	-$CD7(a5),d0
		cmp.b	d3,d0
		bne.s	loc_14C4
		moveq	#$14,d0
		bra.s	loc_14C6
; ---------------------------------------------------------------------------

loc_14C4:				; CODE XREF: ConnectVoice+46j
		moveq	#$54,d0	; 'T'

loc_14C6:				; CODE XREF: ConnectVoice+4Aj
		move.b	d0,$20(a4)
		clr.b	$21(a4)
		move.b	-$CD7(a5),d0
		cmp.b	d3,d0
		bne.s	loc_14DA
		moveq	#$25,d0	; '%'
		bra.s	loc_14DC
; ---------------------------------------------------------------------------

loc_14DA:				; CODE XREF: ConnectVoice+5Cj
		moveq	#$65,d0	; 'e'

loc_14DC:				; CODE XREF: ConnectVoice+60j
		move.b	d0,$22(a4)
		move.b	#$10,$23(a4)
		move.b	#$D0,$24(a4)
		moveq	#7,d0
		move.l	d0,$14(a4)
		bra.s	loc_1500
; ---------------------------------------------------------------------------

loc_14F4:				; CODE XREF: ConnectVoice+2Aj
		move.b	#$F,$1F(a4)
		moveq	#2,d0
		move.l	d0,$14(a4)

loc_1500:				; CODE XREF: ConnectVoice+7Aj
		lea	(monitor_start).l,a0
		move.l	a0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_1514:				; CODE XREF: ConnectVoice+B8j
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		pea	-$C7E(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		bne.s	loc_1514
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function ConnectVoice

; ---------------------------------------------------------------------------
aDisconnectvoice:dc.b 143,'DisconnectVoice',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DisconnectVoice:			; DATA XREF: IsacGetReceiveMsg+9Ao

arg_0		=  8

		link	a6,#0
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		bne.s	loc_1584
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		moveq	#$40,d1	; '@'
		and.b	d1,d0
		bne.s	loc_15A8
		pea	(aVoiceInstalledvoiceRemoved+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	-$DB8(a5),a0
		ori.b	#$40,$1F91(a0) ; '@'
		bra.s	loc_15A8
; ---------------------------------------------------------------------------

loc_1584:				; CODE XREF: DisconnectVoice+10j
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		moveq	#$40,d1	; '@'
		and.b	d1,d0
		beq.s	loc_15A8
		pea	(aVoiceInstalledvoiceRemoved+$11)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	-$DB8(a5),a0
		andi.b	#$BF,$1F91(a0)

loc_15A8:				; CODE XREF: DisconnectVoice+1Ej
					; DisconnectVoice+36j ...
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
; End of function DisconnectVoice

		rts
; ---------------------------------------------------------------------------
aVoicesignal:	dc.b 139,'VoiceSignal',0
aVoiceInstalledvoiceRemoved:dc.b 30,'Voice installed',0,'Voice removed',0
					; DATA XREF: DisconnectVoice+20o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

VoiceSignal:				; DATA XREF: PH_DATA_REQUEST:loc_323Eo

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),d0
		moveq	#2,d3
		cmp.l	d3,d0
		bge.s	loc_161E
		move.b	#$A0,$1E(a3)
		clr.b	$1F(a3)
		move.l	d3,$14(a3)
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.w	loc_16D0
; ---------------------------------------------------------------------------

loc_161E:				; CODE XREF: VoiceSignal+14j
		move.b	$1F(a3),d0
		cmpi.b	#$80,d0
		bne.s	loc_164A
		movea.l	a3,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		moveq	#$C,d0
		move.l	d0,$14(a3)
		move.w	d0,d3
		ble.s	loc_1648
		move.w	d3,d0
		subq.w	#1,d0
		lea	-$CAE(a5),a0
		movea.l	a4,a1

loc_1642:				; CODE XREF: VoiceSignal+62j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_1642

loc_1648:				; CODE XREF: VoiceSignal+54j
		bra.s	loc_1688
; ---------------------------------------------------------------------------

loc_164A:				; CODE XREF: VoiceSignal+44j
		move.b	$1F(a3),d0
		cmpi.b	#$82,d0
		bne.s	loc_167C
		move.b	#1,-$C76(a5)
		movea.l	a3,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		moveq	#$13,d0
		move.l	d0,$14(a3)
		move.w	d0,d3
		ble.s	loc_167A
		move.w	d3,d0
		subq.w	#1,d0
		lea	-$CA2(a5),a0
		movea.l	a4,a1

loc_1674:				; CODE XREF: VoiceSignal+94j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_1674

loc_167A:				; CODE XREF: VoiceSignal+86j
		bra.s	loc_1688
; ---------------------------------------------------------------------------

loc_167C:				; CODE XREF: VoiceSignal+70j
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_16D0
; ---------------------------------------------------------------------------

loc_1688:				; CODE XREF: VoiceSignal:loc_1648j
					; VoiceSignal:loc_167Aj
		pea	(aVoicePresent+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		pea	-$656(a5)
		pea	-$CE6(a5)
		jsr	(SetupIO).l
		addq.w	#8,sp
		movea.l	#$3FFFE,a0
		move.b	(a0),d0
		moveq	#6,d1
		cmp.b	d1,d0
		beq.s	loc_16D0
		movea.l	-$DB8(a5),a0
		ori.b	#$40,$1F91(a0) ; '@'

loc_16D0:				; CODE XREF: VoiceSignal+38j
					; VoiceSignal+A4j ...
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function VoiceSignal

; ---------------------------------------------------------------------------
aMonitor_voice_indication:dc.b 152,'monitor_voice_indication',0,0
aVoicePresent:	dc.b 14,'voice present',0 ; DATA XREF: VoiceSignal:loc_1688o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_voice_indication:		; CODE XREF: InitializeCommon+132p
		link	a6,#0
		move.l	a2,-(sp)
		jsr	(InitVoice).l
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	#$A0,$1E(a2)
		clr.b	$1F(a2)
		moveq	#2,d0
		move.l	d0,$14(a2)
		lea	(monitor_start).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function monitor_voice_indication

; ---------------------------------------------------------------------------
aInitvoice:	dc.b 137,'InitVoice',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitVoice:				; CODE XREF: monitor_voice_indication+6p
		link	a6,#0
		move.l	a2,-(sp)
		movea.l	-$DB8(a5),a2
		lea	$1F91(a2),a2
		move.b	(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		addq.b	#8,d0
		move.b	d0,-$CAC(a5)
		move.b	(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		moveq	#$1C,d1
		add.b	d1,d0
		move.b	d0,-$CA0(a5)
		movea.l	#$3FFFE,a0
		move.b	(a0),d0
		moveq	#6,d1
		cmp.b	d1,d0
		beq.s	loc_178E
		moveq	#3,d0
		bra.s	loc_1790
; ---------------------------------------------------------------------------

loc_178E:				; CODE XREF: InitVoice+34j
		moveq	#$53,d0	; 'S'

loc_1790:				; CODE XREF: InitVoice+38j
		move.b	d0,-$C9E(a5)
		move.b	(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		moveq	#$10,d1
		add.b	d1,d0
		move.b	d0,-$C93(a5)
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function InitVoice

; ---------------------------------------------------------------------------
a_stivoice_c_:	dc.b 140,'_STIVoice_c_',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

_STIVoice_c_:				; DATA XREF: ModemCmd+4Ao

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),d0
		moveq	#4,d1
		cmp.l	d1,d0
		ble.s	loc_17EA
		move.b	$20(a3),d0
		moveq	#$78,d1	; 'x'
		cmp.b	d1,d0
		bne.s	loc_17EA
		move.b	$21(a3),d0
		moveq	#$33,d1	; '3'
		cmp.b	d1,d0
		bne.s	loc_17EA
		move.b	$22(a3),d0
		moveq	#$64,d1	; 'd'
		cmp.b	d1,d0
		beq.s	loc_17EE

loc_17EA:				; CODE XREF: _STIVoice_c_+12j
					; _STIVoice_c_+1Cj ...
		moveq	#0,d0
		bra.s	loc_17F0
; ---------------------------------------------------------------------------

loc_17EE:				; CODE XREF: _STIVoice_c_+30j
		moveq	#1,d0

loc_17F0:				; CODE XREF: _STIVoice_c_+34j
		move.w	d0,-$ADA(a5)
		movea.l	a3,a0
		moveq	#$1E,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		lea	(UartClear).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function _STIVoice_c_

; ---------------------------------------------------------------------------
aModemcmd:	dc.b 136,'ModemCmd',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemCmd:				; CODE XREF: ModemCommand+1A4p
					; addparm+166p	...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	a0,a2
		moveq	#$50,d0	; 'P'
		move.l	d0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		movea.l	a3,a1
		moveq	#$1E,d3
		adda.l	d3,a1
		movea.l	a2,a0

loc_184E:				; CODE XREF: ModemCmd+26j
		move.b	(a0)+,(a1)+
		bne.s	loc_184E
		movea.l	arg_0(a6),a0
		lea	1(a0),a1

loc_185A:				; CODE XREF: ModemCmd+32j
		tst.b	(a0)+
		bne.s	loc_185A
		suba.l	a1,a0
		move.l	a0,$14(a3)
		moveq	#0,d0
		move.l	d0,$10(a3)
		movea.l	a3,a0
		adda.l	d3,a0
		adda.l	$14(a3),a0
		clr.b	(a0)
		lea	(_STIVoice_c_).l,a0
		move.l	a0,4(a3)
		jsr	(WritePString).l
		move.b	-$AD6(a5),d0
		beq.s	loc_189A
		pea	-$AD4(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		bra.s	loc_18AA
; ---------------------------------------------------------------------------

loc_189A:				; CODE XREF: ModemCmd+5Ej
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	#1,-$AD6(a5)

loc_18AA:				; CODE XREF: ModemCmd+6Ej
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function ModemCmd

; ---------------------------------------------------------------------------
aModemcommand:	dc.b 140,'ModemCommand',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemCommand:				; CODE XREF: ROM:0000289Ap

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d4/a2-a4,-(sp)
		moveq	#0,d4
		movea.l	arg_0(a6),a3
		moveq	#$14,d0
		adda.l	d0,a3
		movea.l	arg_0(a6),a4
		moveq	#$1E,d0
		adda.l	d0,a4
		bra.w	loc_1AD6
; ---------------------------------------------------------------------------

loc_18E0:				; CODE XREF: ModemCommand+218j
		move.l	d4,d0
		addq.l	#1,d4
		add.l	a4,d0
		movea.l	d0,a0
		move.b	(a0),d0
		move.b	d0,var_8(a6)
		moveq	#$20,d1	; ' '
		cmp.b	d1,d0
		bcs.s	loc_1914
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	-$B34(a5),d0
		addq.l	#1,-$B34(a5)
		lea	-$B30(a5),a0
		move.b	var_8(a6),(a0,d0.w)
		bra.w	loc_1AD6
; ---------------------------------------------------------------------------

loc_1914:				; CODE XREF: ModemCommand+30j
		move.l	-$B34(a5),d0
		beq.w	loc_1AD6
		move.l	-$B34(a5),d0
		lea	-$B30(a5),a0
		clr.b	(a0,d0.w)
		move.b	-$B30(a5),d3
		moveq	#$5B,d0	; '['
		cmp.b	d0,d3
		bcc.w	loc_1AD0
		moveq	#$A,d0
		move.l	d0,var_4(a6)
		move.b	-$B2F(a5),d0
		bne.s	loc_195C
		moveq	#$30,d0	; '0'
		cmp.b	d0,d3
		bcs.s	loc_195C
		moveq	#$39,d0	; '9'
		cmp.b	d0,d3
		bhi.s	loc_195C
		moveq	#0,d0
		move.b	d3,d0
		ext.l	d0
		moveq	#$FFFFFFD0,d1
		add.l	d1,d0
		move.l	d0,var_4(a6)
		bra.s	loc_19B2
; ---------------------------------------------------------------------------

loc_195C:				; CODE XREF: ModemCommand+7Cj
					; ModemCommand+82j ...
		lea	-$C4C(a5),a2

loc_1960:				; CODE XREF: ModemCommand+D0j
		subq.w	#4,a2
		subq.l	#1,var_4(a6)
		cmpi.l	#0,var_4(a6)
		bmi.s	loc_1994
		movea.l	(a2),a0
		lea	1(a0),a1

loc_1976:				; CODE XREF: ModemCommand+B6j
		tst.b	(a0)+
		bne.s	loc_1976
		suba.l	a1,a0
		move.w	a0,d0
		lea	-$B30(a5),a0
		movea.l	(a2),a1
		moveq	#0,d1
		bra.s	loc_198C
; ---------------------------------------------------------------------------

loc_1988:				; CODE XREF: ModemCommand:loc_198Cj
		move.b	(a0)+,d1
		sub.b	(a1)+,d1

loc_198C:				; CODE XREF: ModemCommand+C4j
		dbne	d0,loc_1988
		tst.b	d1
		bne.s	loc_1960

loc_1994:				; CODE XREF: ModemCommand+ACj
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	var_4+2(a6),-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp
		jsr	(WritePString).l

loc_19B2:				; CODE XREF: ModemCommand+98j
		cmpi.l	#0,var_4(a6)
		bmi.s	loc_19DE
		move.l	-$AD4(a5),d0
		beq.s	loc_19DA
		pea	-$AD4(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_19DE
; ---------------------------------------------------------------------------

loc_19DA:				; CODE XREF: ModemCommand+FEj
		clr.b	-$AD6(a5)

loc_19DE:				; CODE XREF: ModemCommand+F8j
					; ModemCommand+116j
		move.l	var_4(a6),d0
		beq.s	loc_1A30
		moveq	#1,d1
		cmp.l	d1,d0
		beq.w	loc_1A74
		moveq	#5,d1
		cmp.l	d1,d0
		beq.w	loc_1A74
		moveq	#2,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#4,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#6,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#7,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#8,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		moveq	#9,d1
		cmp.l	d1,d0
		beq.w	loc_1AB0
		bra.w	loc_1AD0
; ---------------------------------------------------------------------------

loc_1A30:				; CODE XREF: ModemCommand+120j
		movea.l	-$DB8(a5),a2
		move.b	$1F91(a2),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		bne.s	loc_1A54
		ori.b	#$20,$1F91(a2) ; ' '
		pea	-$656(a5)
		pea	-$B7C(a5)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_1A54:				; CODE XREF: ModemCommand+17Aj
		move.b	-$ADC(a5),d0
		beq.s	loc_1A6E
		cmpi.b	#$FF,-$AE0(a5)
		bne.s	loc_1A6E
		pea	ModemInput
		jsr	(ModemCmd).l
		addq.w	#4,sp

loc_1A6E:				; CODE XREF: ModemCommand+196j
					; ModemCommand+19Ej
		move.w	-$ADA(a5),d0
		beq.s	loc_1AD0

loc_1A74:				; CODE XREF: ModemCommand+126j
					; ModemCommand+12Ej
		movea.l	-$DB0(a5),a0
		move.b	#$DF,$66(a0)
		move.b	#1,-$AD8(a5)
		move.b	#3,-$B69(a5)
		pea	-$B7C(a5)
		move.l	-$B48(a5),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	-$ADE(a5),d0
		moveq	#4,d1
		and.b	d1,d0
		beq.s	loc_1AD0
		clr.b	-(sp)
		jsr	(monitor_modem_indication).l
		addq.w	#2,sp
		bra.s	loc_1AD0
; ---------------------------------------------------------------------------

loc_1AB0:				; CODE XREF: ModemCommand+136j
					; ModemCommand+13Ej ...
		clr.b	-(sp)
		jsr	(monitor_modem_indication).l
		addq.w	#2,sp
		move.b	#4,-$B69(a5)
		pea	-$B7C(a5)
		move.l	-$B48(a5),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_1AD0:				; CODE XREF: ModemCommand+6Ej
					; ModemCommand+16Aj ...
		moveq	#0,d0
		move.l	d0,-$B34(a5)

loc_1AD6:				; CODE XREF: ModemCommand+1Aj
					; ModemCommand+4Ej ...
		move.l	(a3),d0
		cmp.l	d4,d0
		bgt.w	loc_18E0
		pea	-$A0C(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
; End of function ModemCommand

		rts
; ---------------------------------------------------------------------------
aModeminput:	dc.b 138,'ModemInput',0,0,6
; ---------------------------------------------------------------------------

ModemInput:				; DATA XREF: ModemCommand+1A0o
		bsr.s	sub_1B7A

loc_1B06:				; CODE XREF: addbyte+22p addparm+11Ap	...
		move.l	$D00(a4),$4E56(a2)
; ---------------------------------------------------------------------------
		dc.b $FF
		dc.b $F8 ; ø
; ---------------------------------------------------------------------------
		movem.l	d3/a2,-(sp)
		movea.l	8(a6),a2
		move.b	$C(a6),d3
		moveq	#$64,d0	; 'd'
		cmp.b	d0,d3
		bcs.s	loc_1B42
		ext.w	d0
		move.w	d0,d1
		moveq	#0,d0
		move.b	d3,d0
		move.l	d0,-8(a6)
		divs.w	d1,d0
		moveq	#$30,d1	; '0'
		add.b	d1,d0
		move.b	d0,(a2)+
		moveq	#$64,d1	; 'd'
		move.l	-8(a6),d0
		divs.w	d1,d0
		swap	d0
		move.b	d0,$C(a6)

loc_1B42:				; CODE XREF: ROM:00001B1Ej
		move.b	$C(a6),d3
		moveq	#$A,d0
		cmp.b	d0,d3
		bcs.s	loc_1B6E
		ext.w	d0
		move.w	d0,d1
		moveq	#0,d0
		move.b	d3,d0
		move.l	d0,-4(a6)
		divs.w	d1,d0
		moveq	#$30,d1	; '0'
		add.b	d1,d0
		move.b	d0,(a2)+
		moveq	#$A,d1
		move.l	-4(a6),d0
		divs.w	d1,d0
		swap	d0
		move.b	d0,$C(a6)

loc_1B6E:				; CODE XREF: ROM:00001B4Aj
		move.b	$C(a6),d0
		moveq	#$30,d1	; '0'
		add.b	d1,d0
		move.b	d0,(a2)+
		move.l	a2,d0

; =============== S U B	R O U T	I N E =======================================


sub_1B7A:				; CODE XREF: ROM:ModemInputp
		movem.l	(sp)+,d3/a2
		unlk	a6
; End of function sub_1B7A

		rts
; ---------------------------------------------------------------------------
aAddbyte:	dc.b 135,'addbyte',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

addbyte:				; CODE XREF: addparm+180p addparm+328p ...

arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	arg_4(a6),a0
		movea.l	a2,a1

loc_1B9C:				; CODE XREF: addbyte+12j
		move.b	(a0)+,(a1)+
		bne.s	loc_1B9C
		subq.l	#1,a1
		movea.l	a1,a2
		move.b	#$3D,(a2)+ ; '='
		move.b	arg_8(a6),-(sp)
		move.l	a2,-(sp)
		jsr	(loc_1B06+4).l
		addq.w	#6,sp
		movea.l	d0,a2
		move.b	#$3B,(a2)+ ; ';'
		move.l	a2,d0
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function addbyte

; ---------------------------------------------------------------------------
aAddparm:	dc.b 135,'addparm',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

addparm:				; CODE XREF: ScanDevice+14Ep
					; checkblacklisted+200p

var_FC		= -$FC
var_FA		= -$FA
var_D9		= -$D9
var_34		= -$34
var_30		= -$30
var_2C		= -$2C
var_28		= -$28
var_24		= -$24
var_20		= -$20
var_1C		= -$1C
var_18		= -$18
var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$FC
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		lea	var_FC(a6),a3
		tst.b	$64(a4)
		beq.s	loc_1C02
		move.b	#3,$27(a4)
		moveq	#1,d0
		move.b	d0,-(sp)
		clr.b	-(sp)
		moveq	#8,d0
		move.b	d0,-(sp)
		moveq	#6,d0
		move.b	d0,-(sp)
		jsr	(_STIModem_c_).l
		addq.w	#8,sp
		bra.s	loc_1C1A
; ---------------------------------------------------------------------------

loc_1C02:				; CODE XREF: addparm+14j
		move.b	$43(a4),-(sp)
		move.b	$42(a4),-(sp)
		move.b	$41(a4),-(sp)
		moveq	#5,d0
		move.b	d0,-(sp)
		jsr	(_STIModem_c_).l
		addq.w	#8,sp

loc_1C1A:				; CODE XREF: addparm+32j
		tst.b	$64(a4)
		beq.s	loc_1C24
		moveq	#$1D,d0
		bra.s	loc_1C26
; ---------------------------------------------------------------------------

loc_1C24:				; CODE XREF: addparm+50j
		moveq	#$1C,d0

loc_1C26:				; CODE XREF: addparm+54j
		move.b	d0,-$B69(a5)
		move.b	#$FF,-$B6D(a5)
		move.b	$45(a4),d0
		move.b	d0,-$AE0(a5)
		move.b	$16(a4),d0
		move.b	d0,-$ADE(a5)
		move.b	#$61,(a3)+ ; 'a'
		move.b	#$74,(a3)+ ; 't'
		lea	-$C49(a5),a0
		move.l	a0,var_2C(a6)
		lea	-$C4A(a5),a0
		move.l	a0,var_28(a6)
		lea	-$C4B(a5),a0
		move.l	a0,var_24(a6)
		lea	-$C4C(a5),a2
		bra.s	loc_1CAC
; ---------------------------------------------------------------------------

loc_1C66:				; CODE XREF: addparm+E6j
		move.b	(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	a4,d1
		movea.l	d1,a0
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		movea.l	var_24(a6),a0
		move.b	(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		and.l	d1,d0
		movea.l	var_28(a6),a0
		move.b	(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		cmp.l	d1,d0
		bne.s	loc_1C9E
		movea.l	var_2C(a6),a0
		movea.l	a3,a1

loc_1C96:				; CODE XREF: addparm+CAj
		move.b	(a0)+,(a1)+
		bne.s	loc_1C96
		subq.l	#1,a1
		movea.l	a1,a3

loc_1C9E:				; CODE XREF: addparm+C0j
		addq.l	#7,var_2C(a6)
		addq.l	#7,var_28(a6)
		addq.l	#7,var_24(a6)
		addq.w	#7,a2

loc_1CAC:				; CODE XREF: addparm+96j
		lea	-$BC0(a5),a0
		move.l	a0,d0
		cmpa.l	d0,a2
		blt.s	loc_1C66
		lea	-$BBF(a5),a0
		move.l	a0,var_20(a6)
		lea	-$BC0(a5),a2
		bra.s	loc_1D12
; ---------------------------------------------------------------------------

loc_1CC4:				; CODE XREF: addparm+14Cj
		move.b	(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,var_34(a6)
		add.l	a4,d0
		movea.l	d0,a0
		move.b	(a0),d0
		movea.l	var_20(a6),a0
		move.b	(a0),d1
		cmp.b	d1,d0
		beq.s	loc_1D0C
		move.b	#$73,(a3)+ ; 's'
		move.b	var_34+3(a6),-(sp)
		move.l	a3,-(sp)
		jsr	(loc_1B06+4).l
		addq.w	#6,sp
		movea.l	d0,a3
		move.b	#$3D,(a3)+ ; '='
		move.l	var_34(a6),d0
		add.l	a4,d0
		movea.l	d0,a0
		move.b	(a0),-(sp)
		move.l	a3,-(sp)
		jsr	(loc_1B06+4).l
		addq.w	#6,sp
		movea.l	d0,a3

loc_1D0C:				; CODE XREF: addparm+10Ej
		addq.l	#2,var_20(a6)
		addq.w	#2,a2

loc_1D12:				; CODE XREF: addparm+F4j
		lea	-$BAA(a5),a0
		move.l	a0,d0
		cmpa.l	d0,a2
		blt.s	loc_1CC4
		move.b	#$D,(a3)+
		clr.b	(a3)
		move.l	a3,d0
		lea	var_FC(a6),a0
		sub.l	a0,d0
		moveq	#3,d1
		cmp.l	d1,d0
		ble.s	loc_1D3C
		pea	var_FC(a6)
		jsr	(ModemCmd).l
		addq.w	#4,sp

loc_1D3C:				; CODE XREF: addparm+160j
		move.b	$64(a4),d3
		beq.w	loc_1FE4
		move.b	d3,-(sp)
		pea	(aFclass+1)
		pea	var_FA(a6)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3
		move.b	$64(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.w	loc_1F6E
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_1D74
		bra.w	loc_1F6E
; ---------------------------------------------------------------------------

loc_1D74:				; CODE XREF: addparm+1A0j
		tst.b	$7E(a4)
		beq.s	loc_1DB8
		lea	aFlid,a0	; "flid=\""
		movea.l	a3,a1

loc_1D80:				; CODE XREF: addparm+1B4j
		move.b	(a0)+,(a1)+
		bne.s	loc_1D80
		subq.l	#1,a1
		movea.l	a1,a3
		moveq	#1,d4
		movea.l	a4,a2
		moveq	#$7E,d0	; '~'
		adda.l	d0,a2
		move.l	a2,var_1C(a6)
		addq.w	#1,a2
		bra.s	loc_1DA0
; ---------------------------------------------------------------------------

loc_1D98:				; CODE XREF: addparm+1E0j
		move.b	(a2),d0
		move.b	d0,(a3)+
		addq.w	#1,a2
		addq.l	#1,d4

loc_1DA0:				; CODE XREF: addparm+1C8j
		movea.l	var_1C(a6),a0
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		ext.l	d0
		cmp.l	d4,d0
		bge.s	loc_1D98
		move.b	#$22,(a3)+ ; '"'
		move.b	#$3B,(a3)+ ; ';'

loc_1DB8:				; CODE XREF: addparm+1AAj
		moveq	#7,d4
		lea	-$BA3(a5),a2
		movea.l	a4,a0
		moveq	#$6D,d0	; 'm'
		adda.l	d0,a0
		move.l	a0,var_18(a6)
		bra.s	loc_1DDE
; ---------------------------------------------------------------------------

loc_1DCA:				; CODE XREF: addparm+216j
		movea.l	var_18(a6),a0
		move.b	(a0),d0
		move.b	(a2),d1
		cmp.b	d1,d0
		bne.s	loc_1DE6
		subq.w	#1,a2
		subq.l	#1,var_18(a6)
		subq.l	#1,d4

loc_1DDE:				; CODE XREF: addparm+1FAj
		cmpi.l	#0,d4
		bpl.s	loc_1DCA

loc_1DE6:				; CODE XREF: addparm+206j
		moveq	#0,d3
		cmp.l	d3,d4
		bmi.s	loc_1E44
		lea	aFdcc,a0	; "fdcc="
		movea.l	a3,a1

loc_1DF2:				; CODE XREF: addparm+226j
		move.b	(a0)+,(a1)+
		bne.s	loc_1DF2
		subq.l	#1,a1
		movea.l	a1,a3
		move.l	d3,var_34(a6)
		movea.l	a4,a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		lea	-$BAA(a5),a0
		move.l	a0,var_14(a6)
		bra.s	loc_1E36
; ---------------------------------------------------------------------------

loc_1E0E:				; CODE XREF: addparm+26Ej
		move.b	(a2),d3
		movea.l	var_14(a6),a0
		move.b	(a0),d0
		cmp.b	d0,d3
		beq.s	loc_1E28
		move.b	d3,-(sp)
		move.l	a3,-(sp)
		jsr	(loc_1B06+4).l
		addq.w	#6,sp
		movea.l	d0,a3

loc_1E28:				; CODE XREF: addparm+24Aj
		move.b	#$2C,(a3)+ ; ','
		addq.w	#1,a2
		addq.l	#1,var_14(a6)
		addq.l	#1,var_34(a6)

loc_1E36:				; CODE XREF: addparm+23Ej
		move.l	var_34(a6),d0
		cmp.l	d4,d0
		ble.s	loc_1E0E
		move.b	#$3B,-1(a3) ; ';'

loc_1E44:				; CODE XREF: addparm+21Cj
		moveq	#7,d4
		movea.l	a4,a2
		moveq	#$6D,d0	; 'm'
		adda.l	d0,a2
		move.l	a2,var_10(a6)
		movea.l	a4,a0
		moveq	#$75,d0	; 'u'
		adda.l	d0,a0
		move.l	a0,var_C(a6)
		bra.s	loc_1E76
; ---------------------------------------------------------------------------

loc_1E5C:				; CODE XREF: addparm+2AEj
		movea.l	var_C(a6),a0
		move.b	(a0),d0
		movea.l	var_10(a6),a0
		move.b	(a0),d1
		cmp.b	d1,d0
		bne.s	loc_1E7E
		subq.l	#1,var_10(a6)
		subq.l	#1,var_C(a6)
		subq.l	#1,d4

loc_1E76:				; CODE XREF: addparm+28Cj
		cmpi.l	#0,d4
		bpl.s	loc_1E5C

loc_1E7E:				; CODE XREF: addparm+29Cj
		moveq	#0,d3
		cmp.l	d3,d4
		bmi.s	loc_1EE8
		lea	aFdis,a0	; "fdis="
		movea.l	a3,a1

loc_1E8A:				; CODE XREF: addparm+2BEj
		move.b	(a0)+,(a1)+
		bne.s	loc_1E8A
		subq.l	#1,a1
		movea.l	a1,a3
		move.l	d3,var_34(a6)
		movea.l	a4,a2
		moveq	#$6E,d0	; 'n'
		adda.l	d0,a2
		move.l	a2,var_8(a6)
		movea.l	a4,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,var_4(a6)
		bra.s	loc_1EDA
; ---------------------------------------------------------------------------

loc_1EAC:				; CODE XREF: addparm+312j
		movea.l	var_4(a6),a0
		move.b	(a0),d0
		movea.l	var_8(a6),a0
		move.b	(a0),d3
		cmp.b	d3,d0
		beq.s	loc_1ECA
		move.b	d3,-(sp)
		move.l	a3,-(sp)
		jsr	(loc_1B06+4).l
		addq.w	#6,sp
		movea.l	d0,a3

loc_1ECA:				; CODE XREF: addparm+2ECj
		move.b	#$2C,(a3)+ ; ','
		addq.l	#1,var_8(a6)
		addq.l	#1,var_4(a6)
		addq.l	#1,var_34(a6)

loc_1EDA:				; CODE XREF: addparm+2DCj
		move.l	var_34(a6),d0
		cmp.l	d4,d0
		ble.s	loc_1EAC
		move.b	#$3B,-1(a3) ; ';'

loc_1EE8:				; CODE XREF: addparm+2B4j
		move.b	$94(a4),d3
		beq.s	loc_1F02
		move.b	d3,-(sp)
		pea	aFcr		; "fcr"
		move.l	a3,-(sp)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3

loc_1F02:				; CODE XREF: addparm+31Ej
		move.b	$95(a4),d3
		beq.s	loc_1F1C
		move.b	d3,-(sp)
		pea	aFpts		; "fpts"
		move.l	a3,-(sp)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3

loc_1F1C:				; CODE XREF: addparm+338j
		move.b	$96(a4),d3
		beq.s	loc_1F36
		move.b	d3,-(sp)
		pea	aFcq		; "fcq"
		move.l	a3,-(sp)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3

loc_1F36:				; CODE XREF: addparm+352j
		move.b	$97(a4),d3
		moveq	#$1E,d0
		cmp.b	d0,d3
		beq.s	loc_1F54
		move.b	d3,-(sp)
		pea	aFphcto		; "fphcto"
		move.l	a3,-(sp)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3

loc_1F54:				; CODE XREF: addparm+370j
		move.b	$99(a4),d3
		beq.s	loc_1F6E
		move.b	d3,-(sp)
		pea	aFbor		; "fbor"
		move.l	a3,-(sp)
		jsr	(addbyte).l
		lea	$A(sp),sp
		movea.l	d0,a3

loc_1F6E:				; CODE XREF: addparm+198j addparm+1A2j ...
		move.b	#$D,-1(a3)
		clr.b	(a3)
		move.l	a3,d0
		lea	var_FC(a6),a0
		sub.l	a0,d0
		move.l	d0,var_34(a6)
		bra.s	loc_1FCE
; ---------------------------------------------------------------------------

loc_1F84:				; CODE XREF: addparm+408j
		lea	var_D9(a6),a3
		bra.s	loc_1F8C
; ---------------------------------------------------------------------------

loc_1F8A:				; CODE XREF: addparm+3C4j
		subq.w	#1,a3

loc_1F8C:				; CODE XREF: addparm+3BAj
		move.b	(a3),d0
		moveq	#$3B,d1	; ';'
		cmp.b	d1,d0
		bne.s	loc_1F8A
		move.b	1(a3),d0
		move.b	d0,var_30(a6)
		move.b	#$D,(a3)+
		clr.b	(a3)
		pea	var_FC(a6)
		jsr	(ModemCmd).l
		addq.w	#4,sp
		move.b	var_30(a6),(a3)
		movea.l	a3,a0
		lea	var_FA(a6),a1

loc_1FB8:				; CODE XREF: addparm+3ECj
		move.b	(a0)+,(a1)+
		bne.s	loc_1FB8
		lea	var_FC(a6),a0
		lea	1(a0),a1

loc_1FC4:				; CODE XREF: addparm+3F8j
		tst.b	(a0)+
		bne.s	loc_1FC4
		suba.l	a1,a0
		move.l	a0,var_34(a6)

loc_1FCE:				; CODE XREF: addparm+3B4j
		cmpi.l	#$23,var_34(a6)	; '#'
		bgt.s	loc_1F84
		pea	var_FC(a6)
		jsr	(ModemCmd).l
		addq.w	#4,sp

loc_1FE4:				; CODE XREF: addparm+172j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function addparm

; ---------------------------------------------------------------------------
aSetmodem:	dc.b 136,'SetModem',0,0
aFclass:	dc.b 64,'+fclass',0     ; DATA XREF: addparm+178o
aFlid:		dc.b 43,'flid="',0      ; DATA XREF: addparm+1ACo
aFdcc:		dc.b 43,'fdcc=',0,0     ; DATA XREF: addparm+21Eo
aFdis:		dc.b 43,'fdis=',0,0     ; DATA XREF: addparm+2B6o
aFcr:		dc.b 43,'fcr',0,0       ; DATA XREF: addparm+322o
aFpts:		dc.b 43,'fpts',0        ; DATA XREF: addparm+33Co
aFcq:		dc.b 43,'fcq',0,0       ; DATA XREF: addparm+356o
aFphcto:	dc.b 43,'fphcto',0      ; DATA XREF: addparm+374o
aFbor:		dc.b 43,'fbor',0        ; DATA XREF: addparm+38Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SetModem:				; DATA XREF: ResetModem+4Co
		link	a6,#0
		jsr	(UartStart).l
		movea.l	-$DB0(a5),a0
		move.b	#$F7,$66(a0)
		clr.b	-$AD8(a5)
		move.b	#4,-$B69(a5)
		pea	-$B7C(a5)
		move.l	-$B48(a5),-(sp)
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function SetModem

; ---------------------------------------------------------------------------
aResetmodem:	dc.b 138,'ResetModem',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ResetModem:				; DATA XREF: IsacGetReceiveMsg+74o

var_4		= -4
var_3		= -3
arg_0		=  8

		link	a6,#-4
		move.l	d3,-(sp)
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		move.b	d0,var_4(a6)
		move.b	-$BA2(a5),d1
		eor.b	d1,d0
		move.b	d0,var_3(a6)
		move.b	var_4(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.b	-$AD8(a5),d0
		beq.s	loc_210E
		move.b	var_3(a6),d0
		moveq	#4,d3
		and.b	d3,d0
		beq.s	loc_20F6
		move.b	var_4(a6),d0
		and.b	d3,d0
		beq.s	loc_20DE
		pea	(aCarrierDropped+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		lea	(SetModem).l,a0
		move.l	a0,-$B40(a5)
		moveq	#$F,d0
		move.l	d0,-(sp)
		pea	-$B44(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_20F6
; ---------------------------------------------------------------------------

loc_20DE:				; CODE XREF: ResetModem+3Ej
		pea	aCarrierResumed	; "carrier resumed"
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	-$B44(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_20F6:				; CODE XREF: ResetModem+36j
					; ResetModem+66j
		move.b	var_3(a6),d0
		moveq	#$10,d3
		and.b	d3,d0
		beq.s	loc_210E
		move.b	var_4(a6),d0
		and.b	d3,d0
		bne.s	loc_210E
		jsr	(UartStartModem).l

loc_210E:				; CODE XREF: ResetModem+2Cj
					; ResetModem+88j ...
		move.b	var_4(a6),-$BA2(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function ResetModem

; ---------------------------------------------------------------------------
aModemsignal:	dc.b 139,'ModemSignal',0
aCarrierDropped:dc.b 36,' carrier dropped',0,0 ; DATA XREF: ResetModem+40o
aCarrierResumed:dc.b 32,'carrier resumed',0,0 ; DATA XREF: ResetModem:loc_20DEo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemSignal:				; DATA XREF: AllocateModemBuffers+46o
		link	a6,#0
		jsr	(WriteProc).l
		movea.l	-$DB0(a5),a0
		move.b	#$FF,$66(a0)
		clr.b	-(sp)
		clr.b	-(sp)
		clr.b	-(sp)
		moveq	#6,d0
		move.b	d0,-(sp)
		jsr	(_STIModem_c_).l
		addq.w	#8,sp
		moveq	#0,d0
		move.l	d0,-$B74(a5)
		pea	(aAts2128s9110s9210C1s9544+1)
		jsr	(ModemCmd).l
		addq.w	#4,sp
		move.b	#8,-$B6B(a5)
		pea	-$B7C(a5)
		pea	(UpdateUse).l
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function ModemSignal

; ---------------------------------------------------------------------------
aStartmodem:	dc.b 138,'StartModem',0,0
aAts2128s9110s9210C1s9544:dc.b 32,'ats2=128s91=10s92=10&c1s95=44',$D,0,0
					; DATA XREF: ModemSignal+2Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

StartModem:				; CODE XREF: AllocateModemBuffers+34p
					; ArcofiTest+22p ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		move.w	arg_0(a6),d3
		bra.s	loc_2202
; ---------------------------------------------------------------------------

loc_21E4:				; CODE XREF: StartModem+2Ej
		pea	-$A0C(a5)
		move.l	#$400,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		subq.w	#1,d3

loc_2202:				; CODE XREF: StartModem+Aj
		cmpi.w	#0,d3
		bgt.s	loc_21E4
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function StartModem

; ---------------------------------------------------------------------------
aAllocatemodembuffers:dc.b 148,'AllocateModemBuffers',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AllocateModemBuffers:			; DATA XREF: RestartModem+84o
					; ROM:00002758o
		link	a6,#0
		move.l	a2,-(sp)
		jsr	(WriteProc).l
		bra.s	loc_223E
; ---------------------------------------------------------------------------

loc_2234:				; CODE XREF: AllocateModemBuffers+2Aj
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_223E:				; CODE XREF: AllocateModemBuffers+Cj
		pea	-$AD4(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_2234
		clr.b	-$AD6(a5)
		moveq	#3,d0
		move.w	d0,-(sp)
		jsr	(StartModem).l
		addq.w	#2,sp
		movea.l	-$DB0(a5),a0
		move.b	#$FF,$66(a0)
		lea	(ModemSignal).l,a0
		move.l	a0,-$B40(a5)
		moveq	#$1F,d0
		move.l	d0,-(sp)
		pea	-$B44(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function AllocateModemBuffers

; ---------------------------------------------------------------------------
aRestartmodem:	dc.b 140,'RestartModem',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

RestartModem:				; DATA XREF: PH_DATA_REQUEST+28o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),d0
		moveq	#2,d3
		cmp.l	d3,d0
		bge.s	loc_22D6
		move.b	#$B0,$1E(a3)
		clr.b	$1F(a3)
		move.l	d3,$14(a3)
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_2344
; ---------------------------------------------------------------------------

loc_22D6:				; CODE XREF: RestartModem+14j
		move.b	$1F(a3),d0
		cmpi.b	#$82,d0
		bne.s	loc_2344
		pea	(aModemPresentInitializing___+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a3,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		moveq	#$1D,d0
		move.l	d0,$14(a3)
		move.w	d0,d3
		ble.s	loc_230C
		move.w	d3,d0
		subq.w	#1,d0
		lea	-$BA0(a5),a0
		movea.l	a4,a1

loc_2306:				; CODE XREF: RestartModem+6Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_2306

loc_230C:				; CODE XREF: RestartModem+5Ej
		lea	(monitor_start).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		lea	(AllocateModemBuffers).l,a0
		move.l	a0,-$B40(a5)
		movea.l	-$DB0(a5),a0
		move.b	#$F7,$66(a0)
		moveq	#$C,d0
		move.l	d0,-(sp)
		pea	-$B44(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_2344:				; CODE XREF: RestartModem+38j
					; RestartModem+42j
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function RestartModem

; ---------------------------------------------------------------------------
aMonitor_modem_indication:dc.b 152,'monitor_modem_indication',0,0
aModemPresentInitializing___:dc.b 34,'modem present -- initializing...',0,0
					; DATA XREF: RestartModem+44o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_modem_indication:		; CODE XREF: ModemCommand+1E4p
					; ModemCommand+1F0p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4/a2,-(sp)
		move.b	arg_0(a6),d0
		beq.s	loc_23A6
		move.b	-$ADE(a5),d0
		moveq	#3,d1
		and.b	d1,d0
		moveq	#0,d4
		move.b	d0,d4
		bra.s	loc_23A8
; ---------------------------------------------------------------------------

loc_23A6:				; CODE XREF: monitor_modem_indication+Cj
		moveq	#4,d4

loc_23A8:				; CODE XREF: monitor_modem_indication+1Aj
		moveq	#3,d3
		move.l	d3,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	#$B1,$1E(a2)
		cmpi.b	#1,-$ADC(a5)
		bne.s	loc_23C8
		moveq	#$56,d0	; 'V'
		bra.s	loc_23CA
; ---------------------------------------------------------------------------

loc_23C8:				; CODE XREF: monitor_modem_indication+38j
		moveq	#$16,d0

loc_23CA:				; CODE XREF: monitor_modem_indication+3Cj
		move.b	d0,$1F(a2)
		lea	-$B82(a5),a0
		move.b	(a0,d4.w),d0
		move.b	d0,$20(a2)
		move.l	d3,$14(a2)
		lea	(monitor_start).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d4/a2
		unlk	a6
		rts
; End of function monitor_modem_indication

; ---------------------------------------------------------------------------
aArcofispeaker:	dc.b 141,'ArcofiSpeaker',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ArcofiSpeaker:				; CODE XREF: ArcofiTest+18p
					; ListenModem+24p
		link	a6,#0
		movem.l	d3/a2,-(sp)
		moveq	#2,d3
		move.l	d3,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	#$B1,$1E(a2)
		cmpi.b	#1,-$ADC(a5)
		bne.s	loc_2432
		moveq	#$71,d0	; 'q'
		bra.s	loc_2434
; ---------------------------------------------------------------------------

loc_2432:				; CODE XREF: ArcofiSpeaker+22j
		moveq	#$31,d0	; '1'

loc_2434:				; CODE XREF: ArcofiSpeaker+26j
		move.b	d0,$1F(a2)
		move.l	d3,$14(a2)
		lea	(monitor_start).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	-$ADE(a5),d1
		moveq	#$C,d2
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#4,d1
		cmp.l	d1,d0
		beq.s	loc_246A
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_246A
		bra.s	loc_2476
; ---------------------------------------------------------------------------

loc_246A:				; CODE XREF: ArcofiSpeaker+56j
					; ArcofiSpeaker+5Cj
		moveq	#1,d0
		move.b	d0,-(sp)
		jsr	(monitor_modem_indication).l
		addq.w	#2,sp

loc_2476:				; CODE XREF: ArcofiSpeaker+5Ej
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function ArcofiSpeaker

; ---------------------------------------------------------------------------
aActivatearcofi:dc.b 142,'ActivateArcofi',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ActivateArcofi:				; CODE XREF: ROM:00002746p
		link	a6,#0
		movem.l	d3/a2,-(sp)
		moveq	#2,d3
		move.l	d3,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	#$B1,$1E(a2)
		cmpi.b	#1,-$ADC(a5)
		bne.s	loc_24B8
		moveq	#$70,d0	; 'p'
		bra.s	loc_24BA
; ---------------------------------------------------------------------------

loc_24B8:				; CODE XREF: ActivateArcofi+22j
		moveq	#$30,d0	; '0'

loc_24BA:				; CODE XREF: ActivateArcofi+26j
		move.b	d0,$1F(a2)
		move.l	d3,$14(a2)
		lea	(monitor_start).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		clr.b	-(sp)
		jsr	(monitor_modem_indication).l
		addq.w	#2,sp
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function ActivateArcofi

; ---------------------------------------------------------------------------
aReleasearcofi:	dc.b 141,'ReleaseArcofi',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ReleaseArcofi:				; DATA XREF: ModemResponse+Ao
		link	a6,#0
		movem.l	d3/a2,-(sp)
		moveq	#2,d3
		move.l	d3,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		move.b	#$B0,$1E(a2)
		clr.b	$1F(a2)
		move.l	d3,$14(a2)
		lea	(monitor_start).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	-$DB0(a5),a0
		move.b	#$FF,$66(a0)
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function ReleaseArcofi

; ---------------------------------------------------------------------------
aArcofitest:	dc.b 138,'ArcofiTest',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ArcofiTest:

arg_0		=  8

		link	a6,#0
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a0
		movea.l	8(a0),a0
		move.b	8(a0),d0
		move.b	d0,-$ADC(a5)
		jsr	(ArcofiSpeaker).l
		moveq	#3,d0
		move.w	d0,-(sp)
		jsr	(StartModem).l
		addq.w	#2,sp
		move.b	-$AE0(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_259C
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_25AA
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_25D2
		cmpi.l	#$FF,d0
		beq.s	loc_25E0
		bra.s	loc_25EC
; ---------------------------------------------------------------------------

loc_259C:				; CODE XREF: ArcofiTest+34j
		pea	(aAtx3dX4o+1)
		jsr	(ModemCmd).l
		addq.w	#4,sp
		bra.s	loc_25EC
; ---------------------------------------------------------------------------

loc_25AA:				; CODE XREF: ArcofiTest+3Aj
		movea.l	-$DB0(a5),a0
		move.b	#$DF,$66(a0)
		move.b	#1,-$AD8(a5)
		move.b	#3,-$B69(a5)
		pea	-$B7C(a5)
		move.l	-$B48(a5),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_25EC
; ---------------------------------------------------------------------------

loc_25D2:				; CODE XREF: ArcofiTest+40j
		pea	aTx3dX4		; "tx3d;x4\r"
		jsr	(ModemCmd).l
		addq.w	#4,sp
		bra.s	loc_25EC
; ---------------------------------------------------------------------------

loc_25E0:				; CODE XREF: ArcofiTest+48j
		pea	aTx3dL		; "tx3d;%l\r"
		jsr	(ModemCmd).l
		addq.w	#4,sp

loc_25EC:				; CODE XREF: ArcofiTest+4Aj
					; ArcofiTest+58j ...
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function ArcofiTest

; ---------------------------------------------------------------------------
aAttachmodem:	dc.b 139,'AttachModem',0
aAtx3dX4o:	dc.b 32,'atx3d;x4o',$D,0,0 ; DATA XREF: ArcofiTest:loc_259Co
aTx3dX4:	dc.b 97,'tx3d;x4',$D,0  ; DATA XREF: ArcofiTest:loc_25D2o
aTx3dL:		dc.b 97,'tx3d;%l',$D,0  ; DATA XREF: ArcofiTest:loc_25E0o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AttachModem:

arg_0		=  8

		link	a6,#0
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function AttachModem

; ---------------------------------------------------------------------------
aListenmodem:	dc.b 139,'ListenModem',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ListenModem:

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	-$ADC(a5),d0
		bne.w	loc_26E2
		movea.l	8(a2),a0
		move.b	8(a0),d0
		move.b	d0,-$ADC(a5)
		jsr	(ArcofiSpeaker).l
		moveq	#3,d0
		move.w	d0,-(sp)
		jsr	(StartModem).l
		addq.w	#2,sp
		move.b	-$AE0(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_26A0
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_26A0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_26AE
		cmpi.l	#$FF,d0
		beq.s	loc_26D6
		bra.s	loc_26E2
; ---------------------------------------------------------------------------

loc_26A0:				; CODE XREF: ListenModem+40j
					; ListenModem+46j
		pea	ConnectModem
		jsr	(ModemCmd).l
		addq.w	#4,sp
		bra.s	loc_26E2
; ---------------------------------------------------------------------------

loc_26AE:				; CODE XREF: ListenModem+4Cj
		movea.l	-$DB0(a5),a0
		move.b	#$DF,$66(a0)
		move.b	#1,-$AD8(a5)
		move.b	#3,-$B69(a5)
		pea	-$B7C(a5)
		move.l	-$B48(a5),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_26E2
; ---------------------------------------------------------------------------

loc_26D6:				; CODE XREF: ListenModem+54j
		pea	(loc_2722+2)
		jsr	(ModemCmd).l
		addq.w	#4,sp

loc_26E2:				; CODE XREF: ListenModem+14j
					; ListenModem+56j ...
		move.b	-$ADE(a5),d0
		moveq	#$C,d3
		and.b	d3,d0
		cmp.b	d3,d0
		bne.s	loc_26FA
		moveq	#1,d0
		move.b	d0,-(sp)
		jsr	(monitor_modem_indication).l
		addq.w	#2,sp

loc_26FA:				; CODE XREF: ListenModem+A4j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; ---------------------------------------------------------------------------
aConnectmodem:	dc.b 140,'ConnectModem',0,0,$C
; End of function ListenModem

; ---------------------------------------------------------------------------

ConnectModem:				; DATA XREF: ListenModem:loc_26A0o
		bsr.s	sub_2794
		bsr.s	loc_272C+3

loc_2722:				; DATA XREF: ListenModem:loc_26D6o
		ori.b	#$74,d0	; 't'
		move.l	$D00(a4),$4E56(a2)

loc_272C:				; CODE XREF: ROM:00002720p
		ori.b	#3,d0
		jsr	(WriteProc).l
		jsr	(UartStart).l
		clr.b	d3
		move.b	d3,-$AD8(a5)
		move.b	d3,-$AE0(a5)
		jsr	(ActivateArcofi).l
		move.b	d3,-$ADC(a5)
		lea	-$ACC(a5),a0
		move.l	a0,-$B74(a5)
		lea	(AllocateModemBuffers).l,a0
		move.l	a0,-$B40(a5)
		movea.l	-$DB0(a5),a0
		move.b	#$F7,$66(a0)
		moveq	#9,d0
		move.l	d0,-(sp)
		pea	-$B44(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp
		move.l	8(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.b	#8,-$B6B(a5)
		bra.s	loc_27A6
; ---------------------------------------------------------------------------
; START	OF FUNCTION CHUNK FOR sub_2794

loc_2790:				; CODE XREF: sub_2794+16j
		pea	-$A0C(a5)
; END OF FUNCTION CHUNK	FOR sub_2794

; =============== S U B	R O U T	I N E =======================================


sub_2794:				; CODE XREF: ROM:ConnectModemp

; FUNCTION CHUNK AT 00002790 SIZE 00000004 BYTES

		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_27A6:				; CODE XREF: ROM:0000278Ej
		move.l	-$A0C(a5),d0
		bne.s	loc_2790
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function sub_2794

; ---------------------------------------------------------------------------
aDisconnectmodem:dc.b 143,'DisconnectModem',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DisconnectModem:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.b	-$AD8(a5),d0
		beq.s	loc_27E0
		lea	(UartClear).l,a0
		move.l	a0,4(a2)
		bra.s	loc_27EC
; ---------------------------------------------------------------------------

loc_27E0:				; CODE XREF: DisconnectModem+Ej
		jsr	(WriteBegin).l
		move.l	-$B4C(a5),4(a2)

loc_27EC:				; CODE XREF: DisconnectModem+1Aj
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function DisconnectModem

; ---------------------------------------------------------------------------
aModemrequest:	dc.b 140,'ModemRequest',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemRequest:				; DATA XREF: WriteUart+C0o
					; WriteUart+188o

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	-$AD8(a5),d0
		beq.s	loc_2836
		move.l	-$B4C(a5),4(a3)
		lea	-$B7C(a5),a0
		move.l	a0,$C(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_2840
; ---------------------------------------------------------------------------

loc_2836:				; CODE XREF: ModemRequest+Ej
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_2840:				; CODE XREF: ModemRequest+28j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function ModemRequest

; ---------------------------------------------------------------------------
aModemconfirm:	dc.b 140,'ModemConfirm',0,0,0
; ---------------------------------------------------------------------------

ModemConfirm:				; DATA XREF: IrqUART+44o
		link	a6,#0
		move.l	a3,-(sp)
		movea.l	8(a6),a3
		move.b	-$AD8(a5),d0
		beq.s	loc_2880
		move.l	-$B50(a5),4(a3)
		lea	-$B7C(a5),a0
		move.l	a0,$C(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_28A2
; ---------------------------------------------------------------------------

loc_2880:				; CODE XREF: ROM:00002864j
		movea.l	-$B74(a5),a0
		lea	-$ACC(a5),a1
		cmpa.l	a1,a0
		bne.s	loc_2898
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_28A2
; ---------------------------------------------------------------------------

loc_2898:				; CODE XREF: ROM:0000288Aj
		move.l	a3,-(sp)
		jsr	(ModemCommand).l
		addq.w	#4,sp

loc_28A2:				; CODE XREF: ROM:0000287Ej
					; ROM:00002896j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; ---------------------------------------------------------------------------
aModemindication:dc.b 143,'ModemIndication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemIndication:

arg_0		=  8

		link	a6,#0
		pea	-$A0C(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(SetupIO).l
		unlk	a6
		rts
; End of function ModemIndication

; ---------------------------------------------------------------------------
aModemresponse:	dc.b 141,'ModemResponse',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ModemResponse:				; CODE XREF: InitializeCommon+12Cp
		link	a6,#0
		jsr	(InitModem).l
		lea	(ReleaseArcofi).l,a0
		move.l	a0,-$B40(a5)
		moveq	#3,d0
		move.l	d0,-(sp)
		pea	-$B44(a5)
		jsr	(EventLoop).l
		unlk	a6
; End of function ModemResponse

		rts
; ---------------------------------------------------------------------------
aInitmodem:	dc.b 137,'InitModem',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitModem:				; CODE XREF: ModemResponse+4p
		link	a6,#0
		move.l	a2,-(sp)
		movea.l	-$DB8(a5),a2
		move.b	$1F91(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		moveq	#$3C,d1	; '<'
		add.b	d1,d0
		move.b	d0,-$B9E(a5)
		move.b	$1F91(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		moveq	#$30,d1	; '0'
		add.b	d1,d0
		move.b	d0,-$B89(a5)
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function InitModem

; ---------------------------------------------------------------------------
a_stimodem_c_:	dc.b 140,'_STIModem_c_',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

_STIModem_c_:				; CODE XREF: addparm+2Ap addparm+44p ...

arg_0		=  8
arg_2		=  $A
arg_4		=  $C
arg_6		=  $E

		link	a6,#0
		move.l	d3,-(sp)
		move.b	arg_0(a6),d0
		moveq	#1,d3
		and.b	d3,d0
		beq.s	loc_296A
		move.l	#$DD,d0	; 'Ý'
		bra.s	loc_2970
; ---------------------------------------------------------------------------

loc_296A:				; CODE XREF: _STIModem_c_+Ej
		move.l	#$CC,d0	; 'Ì'

loc_2970:				; CODE XREF: _STIModem_c_+16j
		movea.l	-$DA8(a5),a0
		move.b	d0,$12(a0)
		move.b	arg_4(a6),d0
		cmp.b	d3,d0
		bne.s	loc_2988
		move.b	#4,arg_4(a6)
		bra.s	loc_299C
; ---------------------------------------------------------------------------

loc_2988:				; CODE XREF: _STIModem_c_+2Cj
		cmpi.b	#2,arg_4(a6)
		bne.s	loc_2996
		clr.b	arg_4(a6)
		bra.s	loc_299C
; ---------------------------------------------------------------------------

loc_2996:				; CODE XREF: _STIModem_c_+3Cj
		move.b	#$10,arg_4(a6)

loc_299C:				; CODE XREF: _STIModem_c_+34j
					; _STIModem_c_+42j
		subq.b	#5,arg_2(a6)
		move.b	arg_2(a6),d0
		moveq	#3,d3
		cmp.b	d3,d0
		bls.s	loc_29AE
		move.b	d3,arg_2(a6)

loc_29AE:				; CODE XREF: _STIModem_c_+56j
		cmpi.b	#2,arg_6(a6)
		bne.s	loc_29BE
		move.b	#$F,arg_6(a6)
		bra.s	loc_29C4
; ---------------------------------------------------------------------------

loc_29BE:				; CODE XREF: _STIModem_c_+62j
		move.b	#7,arg_6(a6)

loc_29C4:				; CODE XREF: _STIModem_c_+6Aj
		move.l	-$A18(a5),d0
		bne.s	loc_29DA
		pea	-$A0C(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-$A18(a5)

loc_29DA:				; CODE XREF: _STIModem_c_+76j
		movea.l	-$DA8(a5),a0
		move.b	#$11,$14(a0)
		move.b	arg_4(a6),d0
		add.b	arg_2(a6),d0
		moveq	#$20,d1	; ' '
		add.b	d1,d0
		movea.l	-$DA8(a5),a0
		move.b	d0,$10(a0)
		movea.l	-$DA8(a5),a0
		move.b	arg_6(a6),$10(a0)
		move.b	arg_0(a6),-$A1A(a5)
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function _STIModem_c_

; ---------------------------------------------------------------------------
aUartsetmode:	dc.b 139,'UartSetMode',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UartSetMode:				; CODE XREF: IrqUART:loc_2D3Cp
		link	a6,#0
		move.b	-$A1A(a5),d0
		moveq	#4,d1
		and.b	d1,d0
		beq.s	loc_2A34
		movea.l	-$DB0(a5),a0
		ori.b	#$20,$66(a0) ; ' '

loc_2A34:				; CODE XREF: UartSetMode+Cj
		unlk	a6
		rts
; End of function UartSetMode

; ---------------------------------------------------------------------------
aUartstopmodem:	dc.b 141,'UartStopModem',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UartStopModem:				; CODE XREF: IrqUART+62p
		link	a6,#0
		move.b	-$A1A(a5),d0
		moveq	#4,d1
		and.b	d1,d0
		beq.s	loc_2A60
		movea.l	-$DB0(a5),a0
		andi.b	#$DF,$66(a0)

loc_2A60:				; CODE XREF: UartStopModem+Cj
		unlk	a6
		rts
; End of function UartStopModem

; ---------------------------------------------------------------------------
aUartstartmodem:dc.b 142,'UartStartModem',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UartStartModem:				; CODE XREF: ResetModem+92p
					; UartClear+1Ep
		link	a6,#0
		movea.l	-$DA8(a5),a0
		move.b	#4,$14(a0)
		unlk	a6
		rts
; End of function UartStartModem

; ---------------------------------------------------------------------------
aUartstart:	dc.b 137,'UartStart',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UartStart:				; CODE XREF: SetModem+4p ROM:00002736p
		link	a6,#0
		move.l	a2,-(sp)
		bra.s	loc_2AA6
; ---------------------------------------------------------------------------

loc_2A9C:				; CODE XREF: UartStart+24j
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_2AA6:				; CODE XREF: UartStart+6j
		pea	-$A14(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_2A9C
		move.b	#5,-$A1A(a5)
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function UartStart

; ---------------------------------------------------------------------------
aUartclear:	dc.b 137,'UartClear',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UartClear:				; DATA XREF: _STIVoice_c_+4Co
					; DisconnectModem+10o

uart_base	=  8

		link	a6,#0		; reserve stack
		move.l	a2,-(sp)	; save a2 on stack
		moveq	#0,d0		; command for uart
		movea.l	uart_base(a6),a2 ; arg_0 has address of	uart ;;	register indirect relative !!!
		move.l	d0,$10(a2)	; now move 0 to	uart register $10 (=2)
		pea	-$A14(a5)
		move.l	a2,-(sp)
		jsr	(SetupIO).l	; setup	io again after reset of	uart
		addq.w	#8,sp
		jsr	(UartStartModem).l
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function UartClear

; ---------------------------------------------------------------------------
aWriteuart:	dc.b 137,'WriteUart',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteUart:				; CODE XREF: exc_InterruptLevel6+4p

uart_base	= -4

		link	a6,#-4
		movem.l	a2-a3,-(sp)
		move.l	-$D24(a5),d0
		movea.l	d0,a5
		bra.w	loc_2CAA
; ---------------------------------------------------------------------------

loc_2B1A:				; CODE XREF: WriteUart+1B4j
		move.b	uart_base(a6),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		beq.s	loc_2B5A
		movea.l	-$DA8(a5),a0
		move.b	$16(a0),d0
		movea.l	-$A18(a5),a2
		moveq	#$1E,d1
		adda.l	d1,a2
		movea.l	-$A18(a5),a0
		move.l	$14(a0),d1
		addq.l	#1,$14(a0)
		adda.l	d1,a2
		move.b	d0,(a2)
		movea.l	-$A18(a5),a0
		move.l	$14(a0),d0
		cmpi.l	#$400,d0
		ble.s	loc_2B5A
		jsr	(IrqUART).l

loc_2B5A:				; CODE XREF: WriteUart+1Aj
					; WriteUart+4Aj
		move.b	uart_base(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_2BDC
		movea.l	-$A14(a5),a3
		move.l	-$A14(a5),d0
		beq.s	loc_2B82
		move.b	-$AD8(a5),d0
		beq.s	loc_2B8E
		movea.l	-$DB0(a5),a0
		move.b	$66(a0),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_2B8E

loc_2B82:				; CODE XREF: WriteUart+64j
		movea.l	-$DA8(a5),a0
		move.b	#8,$14(a0)
		bra.s	loc_2BDC
; ---------------------------------------------------------------------------

loc_2B8E:				; CODE XREF: WriteUart+6Aj
					; WriteUart+78j
		movea.l	-$A14(a5),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	-$A14(a5),a0
		move.l	$10(a0),d0
		addq.l	#1,$10(a0)
		adda.l	d0,a2
		move.b	(a2),d0
		movea.l	-$DA8(a5),a0
		move.b	d0,$16(a0)
		move.l	$10(a3),d0
		move.l	$14(a3),d1
		cmp.l	d1,d0
		bne.s	loc_2BDC
		pea	-$A14(a5)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		lea	(ModemRequest).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_2BDC:				; CODE XREF: WriteUart+5Aj
					; WriteUart+84j ...
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		move.b	uart_base(a6),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_2C22
		movea.l	-$DA8(a5),a0
		move.b	$16(a0),d0
		movea.l	-$A18(a5),a2
		moveq	#$1E,d1
		adda.l	d1,a2
		movea.l	-$A18(a5),a0
		move.l	$14(a0),d1
		addq.l	#1,$14(a0)
		adda.l	d1,a2
		move.b	d0,(a2)
		movea.l	-$A18(a5),a0
		move.l	$14(a0),d0
		cmpi.l	#$400,d0
		ble.s	loc_2C22
		jsr	(IrqUART).l

loc_2C22:				; CODE XREF: WriteUart+E2j
					; WriteUart+112j
		move.b	uart_base(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_2CA4
		movea.l	-$A14(a5),a3
		move.l	-$A14(a5),d0
		beq.s	loc_2C4A
		move.b	-$AD8(a5),d0
		beq.s	loc_2C56
		movea.l	-$DB0(a5),a0
		move.b	$66(a0),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_2C56

loc_2C4A:				; CODE XREF: WriteUart+12Cj
		movea.l	-$DA8(a5),a0
		move.b	#8,$14(a0)
		bra.s	loc_2CA4
; ---------------------------------------------------------------------------

loc_2C56:				; CODE XREF: WriteUart+132j
					; WriteUart+140j
		movea.l	-$A14(a5),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	-$A14(a5),a0
		move.l	$10(a0),d0
		addq.l	#1,$10(a0)
		adda.l	d0,a2
		move.b	(a2),d0
		movea.l	-$DA8(a5),a0
		move.b	d0,$16(a0)
		move.l	$10(a3),d0
		move.l	$14(a3),d1
		cmp.l	d1,d0
		bne.s	loc_2CA4
		pea	-$A14(a5)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		lea	(ModemRequest).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_2CA4:				; CODE XREF: WriteUart+122j
					; WriteUart+14Cj ...
		move.l	-$D28(a5),d0
		movea.l	d0,a5

loc_2CAA:				; CODE XREF: WriteUart+Ej
		movea.l	-$DA8(a5),a0
		move.b	$A(a0),d0
		moveq	#$33,d1	; '3'
		and.b	d1,d0
		move.b	d0,uart_base(a6)
		tst.b	d0
		bne.w	loc_2B1A
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function WriteUart

; ---------------------------------------------------------------------------
aIrquart:	dc.b 135,'IrqUART',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IrqUART:				; CODE XREF: WriteUart+4Cp
					; WriteUart+114p ...
		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	-$DAC(a5),a0
		move.b	#$40,$1C(a0) ; '@'
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		move.l	-$A18(a5),d0
		beq.s	loc_2D42
		movea.l	-$A18(a5),a0
		tst.l	$14(a0)
		beq.s	loc_2D42
		pea	-$A0C(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_2D3C
		moveq	#0,d0
		move.l	d0,$14(a3)
		lea	(ModemConfirm).l,a0
		movea.l	-$A18(a5),a1
		move.l	a0,4(a1)
		move.l	-$A18(a5),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.l	a3,-$A18(a5)
		jsr	(UartStopModem).l
		bra.s	loc_2D42
; ---------------------------------------------------------------------------

loc_2D3C:				; CODE XREF: IrqUART+3Cj
		jsr	(UartSetMode).l

loc_2D42:				; CODE XREF: IrqUART+1Ej IrqUART+28j ...
		move.w	d3,d0
		move	d0,sr
		movea.l	-$DAC(a5),a0
		move.b	#$40,$1E(a0) ; '@'
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function IrqUART

; ---------------------------------------------------------------------------
aUarttimer:	dc.b 137,'UartTimer',0,0

; =============== S U B	R O U T	I N E =======================================


UartTimer:				; CODE XREF: InitializeCommon+116p
		moveq	#$20,d0	; ' '
		move.w	d0,-(sp)
		pea	-$A3A(a5)
		move.l	-$DA8(a5),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		movea.l	#$3FFFE,a0
		move.b	(a0),d0
		moveq	#9,d1
		cmp.b	d1,d0
		bcs.s	loc_2D92
		movea.l	-$DA8(a5),a0
		move.b	#2,$E(a0)

loc_2D92:				; CODE XREF: UartTimer+22j
		movea.l	-$DA8(a5),a0
		tst.b	$1C(a0)
		rts
; End of function UartTimer


; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

sub_2D9C:				; DATA XREF: ph_transition+26o
					; ph_persistant_deactivation+60o ...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d0
		asl.l	#2,d0
		lea	-$9E6(a5),a0
		move.l	(a0,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function sub_2D9C

; ---------------------------------------------------------------------------
aPh_transition:	dc.b 141,'ph_transition',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_transition:				; DATA XREF: ph_persistant_deactivation+6Eo
					; ph_activate_indication:loc_2FD8o
		link	a6,#0
		movea.l	-$DB0(a5),a0
		move.b	#$3F,$62(a0) ; '?'
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp
		clr.b	d0
		move.b	d0,-$8EE(a5)
		moveq	#0,d1
		move.b	d0,d1
		move.l	d1,-(sp)
		pea	(sub_2D9C).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.l	-(sp)
		pea	(PH_ACTIVATE_INDICATION).l
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function ph_transition

; ---------------------------------------------------------------------------
aPh_persistant_deactivation:dc.b 154,'ph_persistant_deactivation',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_persistant_deactivation:		; DATA XREF: dl_timer_indication+6Ao

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	-$8EE(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_2E7A
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_2E88
		tst.l	d0
		beq.s	loc_2E94
		moveq	#1,d1
		cmp.l	d1,d0
		beq.w	loc_2EFE
		bra.w	loc_2F08
; ---------------------------------------------------------------------------

loc_2E7A:				; CODE XREF: ph_persistant_deactivation+22j
		lea	(MDL_UNITDATA_INDICATION).l,a0
		move.l	a0,4(a3)
		bra.w	loc_2F08
; ---------------------------------------------------------------------------

loc_2E88:				; CODE XREF: ph_persistant_deactivation+28j
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_2E94:				; CODE XREF: ph_persistant_deactivation+2Cj
		moveq	#1,d0
		move.b	d0,-$8EE(a5)
		moveq	#0,d1
		move.b	d0,d1
		move.l	d1,-(sp)
		pea	(sub_2D9C).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		lea	(ph_transition).l,a0
		move.l	a0,-$8FA(a5)
		move.b	-$8EC(a5),d0
		bne.s	loc_2EC2
		moveq	#$5D,d0	; ']'
		bra.s	loc_2EC8
; ---------------------------------------------------------------------------

loc_2EC2:				; CODE XREF: ph_persistant_deactivation+7Cj
		move.l	#$1D4,d0

loc_2EC8:				; CODE XREF: ph_persistant_deactivation+80j
		move.l	d0,-(sp)
		pea	-$8FE(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	-$DB0(a5),a0
		ori.b	#$80,$60(a0)

loc_2EE0:				; CODE XREF: ph_persistant_deactivation+ACj
		movea.l	-$DB0(a5),a2
		move.b	$62(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		bne.s	loc_2EE0
		move.b	#$23,$62(a2) ; '#'
		movea.l	-$DB0(a5),a0
		andi.b	#$7F,$60(a0) ; ''

loc_2EFE:				; CODE XREF: ph_persistant_deactivation+32j
		lea	(Alloc).l,a0
		move.l	a0,4(a3)

loc_2F08:				; CODE XREF: ph_persistant_deactivation+36j
					; ph_persistant_deactivation+44j
		jsr	(WriteProc).l
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function ph_persistant_deactivation

; ---------------------------------------------------------------------------
aPh_activate_request:dc.b 147,'PH_ACTIVATE_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_ACTIVATE_REQUEST:			; CODE XREF: ph_interrupt:loc_3104p
		link	a6,#0
		move.b	-$8EE(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_2F94
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_2F50
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_2F5E
		tst.l	d0
		beq.s	loc_2F6A
		bra.s	loc_2F7A
; ---------------------------------------------------------------------------

loc_2F50:				; CODE XREF: PH_ACTIVATE_REQUEST+16j
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp
		bra.s	loc_2F7A
; ---------------------------------------------------------------------------

loc_2F5E:				; CODE XREF: PH_ACTIVATE_REQUEST+1Cj
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_2F6A:				; CODE XREF: PH_ACTIVATE_REQUEST+20j
		clr.l	-(sp)
		pea	(MDL_UNITDATA_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_2F7A:				; CODE XREF: PH_ACTIVATE_REQUEST+22j
					; PH_ACTIVATE_REQUEST+30j
		moveq	#3,d0
		move.b	d0,-$8EE(a5)
		moveq	#0,d1
		move.b	d0,d1
		move.l	d1,-(sp)
		pea	(sub_2D9C).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_2F94:				; CODE XREF: PH_ACTIVATE_REQUEST+10j
		unlk	a6
		rts
; End of function PH_ACTIVATE_REQUEST

; ---------------------------------------------------------------------------
aPh_activate_indication:dc.b 150,'ph_activate_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_activate_indication:			; CODE XREF: ph_interrupt:loc_30CCp
		link	a6,#0
		move.b	-$8EE(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_2FCC
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_2FD8
		bra.s	loc_300C
; ---------------------------------------------------------------------------

loc_2FCC:				; CODE XREF: ph_activate_indication+10j
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_2FD8:				; CODE XREF: ph_activate_indication+16j
		lea	(ph_transition).l,a0
		move.l	a0,-$8FA(a5)
		moveq	#9,d0
		move.l	d0,-(sp)
		pea	-$8FE(a5)
		jsr	(EventLoop).l
		addq.w	#8,sp
		moveq	#2,d0
		move.b	d0,-$8EE(a5)
		moveq	#0,d1
		move.b	d0,d1
		move.l	d1,-(sp)
		pea	(sub_2D9C).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_300C:				; CODE XREF: ph_activate_indication+18j
		unlk	a6
		rts
; End of function ph_activate_indication

; ---------------------------------------------------------------------------
aPh_deactivate_indication:dc.b 152,'ph_deactivate_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_deactivate_indication:		; DATA XREF: ph_deactivate_indication+4Co
					; ph_interrupt+B0o

var_4		= -4
arg_0		=  8

		link	a6,#-4
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d0
		move.b	d0,var_4(a6)
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.b	var_4(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#2,d0
		lea	-$9D4(a5),a0
		move.l	(a0,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		cmpi.b	#$10,var_4(a6)
		beq.s	loc_3088
		move.b	-$9D6(a5),d0
		cmp.b	-$900(a5),d0
		bne.s	loc_3088
		moveq	#$10,d0
		move.l	d0,-(sp)
		pea	(ph_deactivate_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_308C
; ---------------------------------------------------------------------------

loc_3088:				; CODE XREF: ph_deactivate_indication+3Cj
					; ph_deactivate_indication+46j
		addq.b	#1,-$9D6(a5)

loc_308C:				; CODE XREF: ph_deactivate_indication+5Aj
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function ph_deactivate_indication

; ---------------------------------------------------------------------------
aPh_interrupt:	dc.b 140,'ph_interrupt',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_interrupt:				; CODE XREF: IsacGetReceiveMsg+C2p

arg_0		=  8

		link	a6,#0
		move.b	arg_0(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_30CC
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_30D4
		moveq	#$A,d1
		cmp.l	d1,d0
		beq.s	loc_30F4
		moveq	#$C,d1
		cmp.l	d1,d0
		beq.s	loc_30F4
		moveq	#$E,d1
		cmp.l	d1,d0
		beq.s	loc_3128
		bra.s	loc_313E
; ---------------------------------------------------------------------------

loc_30CC:				; CODE XREF: ph_interrupt+Ej
		jsr	(ph_activate_indication).l
		bra.s	loc_313E
; ---------------------------------------------------------------------------

loc_30D4:				; CODE XREF: ph_interrupt+14j
		cmpi.b	#3,-$8EC(a5)
		bne.s	loc_30E6
		movea.l	-$DB0(a5),a0
		move.b	#$33,$62(a0) ; '3'

loc_30E6:				; CODE XREF: ph_interrupt+38j
		pea	-$8FE(a5)
		jsr	(StartTimer).l
		addq.w	#4,sp
		bra.s	loc_313E
; ---------------------------------------------------------------------------

loc_30F4:				; CODE XREF: ph_interrupt+1Aj
					; ph_interrupt+20j
		move.b	-$8EC(a5),d0
		bne.s	loc_3104
		movea.l	-$DB0(a5),a0
		move.b	#$23,$62(a0) ; '#'

loc_3104:				; CODE XREF: ph_interrupt+56j
		jsr	(PH_ACTIVATE_REQUEST).l
		cmpi.b	#3,-$8EC(a5)
		bne.s	loc_313E
		clr.l	-(sp)
		pea	(ph_loop_on).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.b	-$A04(a5)
		bra.s	loc_313E
; ---------------------------------------------------------------------------

loc_3128:				; CODE XREF: ph_interrupt+26j
		clr.l	-(sp)
		pea	(DisconnectLoop).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#1,-$A04(a5)

loc_313E:				; CODE XREF: ph_interrupt+28j
					; ph_interrupt+30j ...
		move.b	-$900(a5),d0
		cmp.b	-$9D6(a5),d0
		beq.s	loc_3164
		move.b	arg_0(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,-(sp)
		pea	(ph_deactivate_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		addq.b	#1,-$900(a5)

loc_3164:				; CODE XREF: ph_interrupt+A4j
		unlk	a6
		rts
; End of function ph_interrupt

; ---------------------------------------------------------------------------
aPh_interrupt_0:dc.b 140,'PH_INTERRUPT',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_INTERRUPT:				; DATA XREF: IsacGetReceiveMsg+338o
					; DL_transition+42o ...

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),d0
		ble.s	loc_3194
		move.l	a3,-(sp)
		jsr	(WriteLong).l
		addq.w	#4,sp

loc_3194:				; CODE XREF: PH_INTERRUPT+10j
		pea	-$908(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_31F0
		movea.l	a3,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	$10(a3),d3
		adda.l	d3,a2
		move.l	$14(a3),d4
		sub.l	d3,d4
		moveq	#$20,d3	; ' '
		cmp.l	d3,d4
		ble.s	loc_31C0
		move.l	d3,d4

loc_31C0:				; CODE XREF: PH_INTERRUPT+44j
		add.l	d4,$10(a3)
		bra.s	loc_31CC
; ---------------------------------------------------------------------------

loc_31C6:				; CODE XREF: PH_INTERRUPT+5Aj
		movea.l	-$DB0(a5),a0
		move.b	(a2)+,(a0)

loc_31CC:				; CODE XREF: PH_INTERRUPT+4Cj
		subq.l	#1,d4
		moveq	#0,d3
		cmp.l	d3,d4
		bpl.s	loc_31C6
		move.l	$10(a3),d0
		move.l	$14(a3),d1
		cmp.l	d1,d0
		bne.s	loc_31E4
		moveq	#2,d0
		bra.s	loc_31E6
; ---------------------------------------------------------------------------

loc_31E4:				; CODE XREF: PH_INTERRUPT+66j
		move.l	d3,d0

loc_31E6:				; CODE XREF: PH_INTERRUPT+6Aj
		addq.b	#8,d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$42(a0)

loc_31F0:				; CODE XREF: PH_INTERRUPT+2Cj
		movem.l	(sp)+,d3-d4/a2-a3
		unlk	a6
		rts
; End of function PH_INTERRUPT

; ---------------------------------------------------------------------------
aPh_data_request:dc.b 143,'PH_DATA_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_DATA_REQUEST:			; DATA XREF: monitor_request+BAo

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),-(sp)
		movea.l	a3,a0
		moveq	#$1E,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		move.b	$1E(a3),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_323E
		lea	(RestartModem).l,a0
		move.l	a0,4(a3)
		bra.s	loc_3248
; ---------------------------------------------------------------------------

loc_323E:				; CODE XREF: PH_DATA_REQUEST+26j
		lea	(VoiceSignal).l,a0
		move.l	a0,4(a3)

loc_3248:				; CODE XREF: PH_DATA_REQUEST+32j
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function PH_DATA_REQUEST

; ---------------------------------------------------------------------------
aMonitor_indication:dc.b 146,'monitor_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_indication:			; DATA XREF: monitor_timer:loc_330Co

arg_0		=  8

		link	a6,#0
		jsr	(WriteProc).l
		moveq	#0,d0
		move.l	d0,-$916(a5)
		andi.b	#$EF,-$90E(a5)
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)
		move.l	arg_0(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		pea	-$91E(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-$916(a5)
		tst.l	d0
		beq.s	loc_32BE
		moveq	#3,d1
		move.l	d1,-(sp)
		move.l	d0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_32BE:				; CODE XREF: monitor_indication+40j
		unlk	a6
		rts
; End of function monitor_indication

; ---------------------------------------------------------------------------
aMonitor_timer:	dc.b 141,'monitor_timer',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_timer:				; DATA XREF: monitor_start+Ao

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		clr.w	d3
		move.l	$14(a3),-(sp)
		movea.l	a3,a0
		moveq	#$1E,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		bra.s	loc_32F8
; ---------------------------------------------------------------------------

loc_32F6:				; CODE XREF: monitor_timer+38j
		addq.w	#1,d3

loc_32F8:				; CODE XREF: monitor_timer+22j
		cmpi.w	#$3E8,d3
		bcc.s	loc_330C
		movea.l	-$DB0(a5),a0
		move.b	$42(a0),d0
		moveq	#4,d1
		and.b	d1,d0
		bne.s	loc_32F6

loc_330C:				; CODE XREF: monitor_timer+2Aj
		lea	(monitor_indication).l,a0
		move.l	a0,4(a3)
		moveq	#6,d0
		move.l	d0,-(sp)
		move.l	a3,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		move.b	$1E(a3),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$68(a0)
		moveq	#1,d0
		move.l	d0,$10(a3)
		ori.b	#$10,-$90E(a5)
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function monitor_timer

; ---------------------------------------------------------------------------
aMonitor_start:	dc.b 141,'monitor_start',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_start:				; DATA XREF: ReturnMsgBuffer+74o
					; VoiceStop+144o ...

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		lea	(monitor_timer).l,a0
		move.l	a0,4(a3)
		move.l	-$916(a5),d0
		bne.s	loc_338A
		move.l	a3,-$916(a5)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_3398
; ---------------------------------------------------------------------------

loc_338A:				; CODE XREF: monitor_start+18j
		pea	-$91E(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_3398:				; CODE XREF: monitor_start+28j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function monitor_start

; ---------------------------------------------------------------------------
aMonitor_request:dc.b 143,'monitor_request',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_request:			; CODE XREF: IsacGetReceiveMsg+140p

var_4		= -4

		link	a6,#-4
		move.l	a2,-(sp)
		movea.l	-$DB0(a5),a0
		move.b	$74(a0),d0
		move.b	d0,var_4(a6)
		andi.b	#$80,d0
		beq.s	loc_3426
		move.l	-$912(a5),d0
		bne.s	loc_3406
		moveq	#$64,d0	; 'd'
		move.l	d0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$912(a5)
		tst.l	d0
		bne.s	loc_33F4
		pea	(aMonitorMdrNoBuffer+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_33F4:				; CODE XREF: monitor_request+30j
		ori.b	#$40,-$90E(a5) ; '@'
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)

loc_3406:				; CODE XREF: monitor_request+1Cj
		movea.l	-$DB0(a5),a0
		move.b	$68(a0),d0
		movea.l	-$912(a5),a2
		moveq	#$1E,d1
		adda.l	d1,a2
		movea.l	-$912(a5),a0
		move.l	$14(a0),d1
		addq.l	#1,$14(a0)
		adda.l	d1,a2
		move.b	d0,(a2)

loc_3426:				; CODE XREF: monitor_request+16j
		move.b	var_4(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_345A
		move.l	-$912(a5),d0
		beq.s	loc_3442
		move.l	-$912(a5),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_3442:				; CODE XREF: monitor_request+84j
		moveq	#0,d0
		move.l	d0,-$912(a5)
		andi.b	#$BF,-$90E(a5)
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)

loc_345A:				; CODE XREF: monitor_request+7Ej
		move.b	var_4(a6),d0
		moveq	#$40,d1	; '@'
		and.b	d1,d0
		beq.s	loc_34B0
		move.l	-$912(a5),d0
		beq.s	loc_3486
		lea	(PH_DATA_REQUEST).l,a0
		movea.l	-$912(a5),a1
		move.l	a0,4(a1)
		move.l	-$912(a5),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_3498
; ---------------------------------------------------------------------------

loc_3486:				; CODE XREF: monitor_request+B8j
		pea	aMonitorMerNoBuffer ; "monitor MER: no buffer"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_3498:				; CODE XREF: monitor_request+D4j
		moveq	#0,d0
		move.l	d0,-$912(a5)
		andi.b	#$BF,-$90E(a5)
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)

loc_34B0:				; CODE XREF: monitor_request+B2j
		move.b	var_4(a6),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		beq.s	loc_3530
		movea.l	-$916(a5),a2
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bge.s	loc_34E8
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	-$916(a5),a0
		move.l	$10(a0),d0
		addq.l	#1,$10(a0)
		adda.l	d0,a2
		move.b	(a2),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$68(a0)
		bra.s	loc_3530
; ---------------------------------------------------------------------------

loc_34E8:				; CODE XREF: monitor_request+118j
		andi.b	#$EF,-$90E(a5)
		move.b	-$90E(a5),d0
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)
		move.l	-$916(a5),-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	-$916(a5),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		pea	-$91E(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-$916(a5)
		tst.l	d0
		beq.s	loc_3530
		move.l	d0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_3530:				; CODE XREF: monitor_request+108j
					; monitor_request+136j	...
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function monitor_request

; ---------------------------------------------------------------------------
aMonitor_interrupt:dc.b	145,'monitor_interrupt',0
aMonitorMdrNoBuffer:dc.b 48,'monitor MDR: no buffer',0,0 ; DATA XREF: monitor_request+32o
aMonitorMerNoBuffer:dc.b 'monitor MER: no buffer',0,0 ; DATA XREF: monitor_request:loc_3486o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

monitor_interrupt:			; DATA XREF: IsacGetReceiveMsg+380o

arg_0		=  8

		link	a6,#0
		jsr	(WriteProc).l
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$90C(a5)
		tst.l	d0
		bne.s	loc_35A8
		move.l	arg_0(a6),-(sp)
		jsr	(PostEvent).l
		addq.w	#4,sp
		bra.s	loc_35BC
; ---------------------------------------------------------------------------

loc_35A8:				; CODE XREF: monitor_interrupt+1Ej
		movea.l	-$DB0(a5),a0
		clr.b	$40(a0)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_35BC:				; CODE XREF: monitor_interrupt+2Cj
		unlk	a6
		rts
; End of function monitor_interrupt

; ---------------------------------------------------------------------------
aIsacgetreceivemsg:dc.b	145,'IsacGetReceiveMsg',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IsacGetReceiveMsg:			; CODE XREF: exc_InterruptLevel2+4p

var_18		= -$18
var_14		= -$14
var_10		= -$10
var_F		= -$F
var_E		= -$E
var_D		= -$D
var_C		= -$C
var_8		= -8
var_4		= -4

		link	a6,#-$18
		movem.l	d3-d7/a2-a4,-(sp)
		movea.l	#$3FFFE,a0
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		lea	-$20(a5),a0
		move.b	(a0,d0.w),d0
		moveq	#0,d7
		move.b	d0,d7
		asl.w	#1,d7
		bra.w	loc_397A
; ---------------------------------------------------------------------------

loc_35FA:				; CODE XREF: IsacGetReceiveMsg+3ACj
		movea.l	-$DB0(a5),a3
		move.b	$40(a3),d0
		move.b	d0,var_18(a6)
		tst.b	d0
		beq.w	loc_3974
		move.l	-$908(a5),var_14(a6)
		moveq	#4,d1
		and.b	d1,d0
		beq.w	loc_369E
		move.b	$62(a3),d0
		move.b	d0,var_10(a6)
		andi.b	#$80,d0
		beq.s	loc_3630
		move.b	$76(a3),d0
		move.b	d0,var_F(a6)

loc_3630:				; CODE XREF: IsacGetReceiveMsg+52j
		move.b	var_10(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_367C
		move.b	$66(a3),d1
		move.b	d1,var_E(a6)
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,-(sp)
		pea	(ResetModem).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	#$3FFFE,a0
		move.b	(a0),d0
		moveq	#6,d1
		cmp.b	d1,d0
		bne.s	loc_367C
		move.b	var_E(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,-(sp)
		pea	(DisconnectVoice).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_367C:				; CODE XREF: IsacGetReceiveMsg+64j
					; IsacGetReceiveMsg+8Ej
		move.b	var_10(a6),d3
		moveq	#2,d0
		and.b	d0,d3
		beq.s	loc_369E
		move.b	var_10(a6),d1
		moveq	#$3C,d2	; '<'
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		asr.l	#2,d0
		move.b	d0,-(sp)
		jsr	(ph_interrupt).l
		addq.w	#2,sp

loc_369E:				; CODE XREF: IsacGetReceiveMsg+42j
					; IsacGetReceiveMsg+B0j
		move.b	var_18(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_371A
		move.b	$48(a3),d0
		move.b	d0,var_D(a6)
		andi.b	#$C0,d0
		beq.s	loc_36D2
		bra.s	loc_36C0
; ---------------------------------------------------------------------------

loc_36B8:				; CODE XREF: IsacGetReceiveMsg+F6j
		subi.l	#$20,(a4) ; ' '
		bra.s	loc_36C8
; ---------------------------------------------------------------------------

loc_36C0:				; CODE XREF: IsacGetReceiveMsg+E2j
		movea.l	var_14(a6),a4
		moveq	#$10,d0
		adda.l	d0,a4

loc_36C8:				; CODE XREF: IsacGetReceiveMsg+EAj
		move.l	(a4),d0
		bgt.s	loc_36B8
		ori.b	#$10,var_18(a6)

loc_36D2:				; CODE XREF: IsacGetReceiveMsg+E0j
		move.b	var_D(a6),d0
		andi.b	#$80,d0
		beq.s	loc_36EE
		pea	(aDl_xmr+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_36EE:				; CODE XREF: IsacGetReceiveMsg+106j
		move.b	var_D(a6),d0
		moveq	#$40,d1	; '@'
		and.b	d1,d0
		beq.s	loc_370A
		pea	aDl_xdu		; "dl_xdu"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_370A:				; CODE XREF: IsacGetReceiveMsg+122j
		move.b	var_D(a6),d0
		moveq	#4,d1
		and.b	d1,d0
		beq.s	loc_371A
		jsr	(monitor_request).l

loc_371A:				; CODE XREF: IsacGetReceiveMsg+D2j
					; IsacGetReceiveMsg+13Ej
		move.b	var_18(a6),d0
		moveq	#8,d1
		and.b	d1,d0
		beq.s	loc_374C
		clr.l	-(sp)
		pea	(CheckTimer).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	-$990(a5),d0
		subq.b	#1,-$990(a5)
		tst.b	d0
		bne.s	loc_374C
		move.b	#1,-$990(a5)
		jsr	(IrqUART).l

loc_374C:				; CODE XREF: IsacGetReceiveMsg+14Ej
					; IsacGetReceiveMsg+16Aj
		move.b	var_18(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.w	loc_37F4
		move.l	var_14(a6),d0
		beq.w	loc_37F4
		movea.l	var_14(a6),a0
		move.l	$10(a0),d0
		move.l	$14(a0),d1
		cmp.l	d1,d0
		bne.s	loc_3796
		pea	-$908(a5)
		move.l	a0,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		move.l	var_14(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	-$908(a5),d0
		move.l	d0,var_14(a6)
		tst.l	d0
		beq.s	loc_37F4

loc_3796:				; CODE XREF: IsacGetReceiveMsg+19Aj
		movea.l	var_14(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_14(a6),a0
		move.l	$10(a0),d3
		adda.l	d3,a2
		move.l	a2,var_C(a6)
		move.l	$14(a0),d4
		sub.l	d3,d4
		moveq	#$20,d3	; ' '
		cmp.l	d3,d4
		ble.s	loc_37BA
		move.l	d3,d4

loc_37BA:				; CODE XREF: IsacGetReceiveMsg+1E2j
		movea.l	var_14(a6),a0
		add.l	d4,$10(a0)
		bra.s	loc_37D0
; ---------------------------------------------------------------------------

loc_37C4:				; CODE XREF: IsacGetReceiveMsg+202j
		movea.l	var_C(a6),a0
		addq.l	#1,var_C(a6)
		move.b	(a0),d0
		move.b	d0,(a3)

loc_37D0:				; CODE XREF: IsacGetReceiveMsg+1EEj
		subq.l	#1,d4
		moveq	#0,d3
		cmp.l	d3,d4
		bpl.s	loc_37C4
		movea.l	var_14(a6),a2
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bne.s	loc_37EC
		moveq	#2,d0
		bra.s	loc_37EE
; ---------------------------------------------------------------------------

loc_37EC:				; CODE XREF: IsacGetReceiveMsg+212j
		move.l	d3,d0

loc_37EE:				; CODE XREF: IsacGetReceiveMsg+216j
		addq.b	#8,d0
		move.b	d0,$42(a3)

loc_37F4:				; CODE XREF: IsacGetReceiveMsg+180j
					; IsacGetReceiveMsg+188j ...
		move.b	var_18(a6),d0
		moveq	#$40,d1	; '@'
		and.b	d1,d0
		beq.s	loc_3860
		movea.l	-$90C(a5),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	-$90C(a5),a0
		move.l	$14(a0),d3
		adda.l	d3,a2
		move.l	a2,var_8(a6)
		moveq	#$20,d6	; ' '
		tst.l	d3
		bne.s	loc_3830
		move.b	$52(a3),d0
		move.b	d0,$1C(a0)
		bra.s	loc_3830
; ---------------------------------------------------------------------------

loc_3824:				; CODE XREF: IsacGetReceiveMsg+264j
		move.b	(a3),d0
		movea.l	var_8(a6),a0
		addq.l	#1,var_8(a6)
		move.b	d0,(a0)

loc_3830:				; CODE XREF: IsacGetReceiveMsg+244j
					; IsacGetReceiveMsg+24Ej
		subq.l	#1,d6
		cmpi.l	#0,d6
		bpl.s	loc_3824
		movea.l	-$90C(a5),a0
		addi.l	#$20,$14(a0) ; ' '
		move.l	$14(a0),d0
		cmpi.l	#$104,d0
		bgt.s	loc_385A
		move.b	#$80,$42(a3)
		bra.s	loc_3860
; ---------------------------------------------------------------------------

loc_385A:				; CODE XREF: IsacGetReceiveMsg+27Cj
		move.b	#$C1,$42(a3)

loc_3860:				; CODE XREF: IsacGetReceiveMsg+228j
					; IsacGetReceiveMsg+284j
		move.b	var_18(a6),d0
		andi.b	#$80,d0
		beq.w	loc_3974
		movea.l	-$90C(a5),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	-$90C(a5),a0
		move.l	$14(a0),d3
		adda.l	d3,a2
		move.l	a2,var_4(a6)
		move.b	$54(a3),d0
		moveq	#0,d5
		move.b	d0,d5
		asl.l	#8,d5
		move.b	$4A(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	d0,d5
		andi.l	#$FFF,d5
		sub.l	d3,d5
		tst.l	d3
		bne.s	loc_38AA
		move.b	$52(a3),d0
		move.b	d0,$1C(a0)

loc_38AA:				; CODE XREF: IsacGetReceiveMsg+2CCj
		move.b	$4E(a3),d0
		movea.l	-$90C(a5),a0
		move.b	d0,$1D(a0)
		movea.l	-$90C(a5),a0
		add.l	d5,$14(a0)
		bra.s	loc_38CC
; ---------------------------------------------------------------------------

loc_38C0:				; CODE XREF: IsacGetReceiveMsg+300j
		move.b	(a3),d0
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	d0,(a0)

loc_38CC:				; CODE XREF: IsacGetReceiveMsg+2EAj
		subq.l	#1,d5
		cmpi.l	#0,d5
		bpl.s	loc_38C0
		movea.l	-$90C(a5),a0
		move.l	$14(a0),d0
		cmpi.l	#$104,d0
		bgt.s	loc_38EE
		move.b	#$80,$42(a3)
		bra.s	loc_38F4
; ---------------------------------------------------------------------------

loc_38EE:				; CODE XREF: IsacGetReceiveMsg+310j
		move.b	#$C1,$42(a3)

loc_38F4:				; CODE XREF: IsacGetReceiveMsg+318j
		movea.l	-$90C(a5),a2
		move.b	$1D(a2),d0
		moveq	#$70,d1	; 'p'
		and.b	d1,d0
		moveq	#$20,d1	; ' '
		cmp.b	d1,d0
		bne.s	loc_396A
		move.b	-$A04(a5),d0
		beq.s	loc_3914
		lea	(PH_INTERRUPT).l,a0
		bra.s	loc_391A
; ---------------------------------------------------------------------------

loc_3914:				; CODE XREF: IsacGetReceiveMsg+336j
		lea	(dl_s_or_i_indication).l,a0

loc_391A:				; CODE XREF: IsacGetReceiveMsg+33Ej
		move.l	a0,4(a2)
		move.l	-$90C(a5),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$90C(a5)
		tst.l	d0
		bne.s	loc_3974
		pea	aIsacirqNoBuffers ; "isacirq: no buffers"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.l	-(sp)
		pea	(monitor_interrupt).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$C0,$40(a3)
		bra.s	loc_3974
; ---------------------------------------------------------------------------

loc_396A:				; CODE XREF: IsacGetReceiveMsg+330j
		moveq	#0,d0
		movea.l	-$90C(a5),a0
		move.l	d0,$14(a0)

loc_3974:				; CODE XREF: IsacGetReceiveMsg+34j
					; IsacGetReceiveMsg+294j ...
		move.l	-$D28(a5),d0
		movea.l	d0,a5

loc_397A:				; CODE XREF: IsacGetReceiveMsg+22j
		subq.w	#1,d7
		cmpi.w	#0,d7
		bpl.w	loc_35FA
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function IsacGetReceiveMsg

; ---------------------------------------------------------------------------
aIrqisac:	dc.b 135,'IrqISAC',0
aDl_xmr:	dc.b 36,'dl_xmr',0,0    ; DATA XREF: IsacGetReceiveMsg+108o
aDl_xdu:	dc.b 'dl_xdu',0,0       ; DATA XREF: IsacGetReceiveMsg+124o
aIsacirqNoBuffers:dc.b 'isacirq: no buffers',0 ; DATA XREF: IsacGetReceiveMsg+36Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IrqISAC:

arg_0		=  8

		link	a6,#0
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
; End of function IrqISAC

		rts
; ---------------------------------------------------------------------------
aNothingloop:	dc.b 139,'NothingLoop',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NothingLoop:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	-$DB0(a5),a0
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a1
		move.b	$F(a1),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_39FA
		moveq	#$C,d0
		bra.s	loc_39FC
; ---------------------------------------------------------------------------

loc_39FA:				; CODE XREF: NothingLoop+1Aj
		moveq	#3,d0

loc_39FC:				; CODE XREF: NothingLoop+1Ej
		or.b	d0,$60(a0)
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function NothingLoop

; ---------------------------------------------------------------------------
aConnectloop:	dc.b 139,'ConnectLoop',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ConnectLoop:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	-$DB0(a5),a0
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a1
		move.b	$F(a1),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_3A3E
		moveq	#$FFFFFFF3,d0
		bra.s	loc_3A40
; ---------------------------------------------------------------------------

loc_3A3E:				; CODE XREF: ConnectLoop+1Aj
		moveq	#$FFFFFFFC,d0

loc_3A40:				; CODE XREF: ConnectLoop+1Ej
		and.b	d0,$60(a0)
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function ConnectLoop

; ---------------------------------------------------------------------------
aDisconnectloop:dc.b 142,'DisconnectLoop',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DisconnectLoop:				; DATA XREF: ph_interrupt+88o

arg_0		=  8

		link	a6,#0
		movea.l	-$DB0(a5),a0
		ori.b	#$F,$60(a0)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function DisconnectLoop

; ---------------------------------------------------------------------------
aPh_loop_on:	dc.b 138,'ph_loop_on',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_loop_on:				; DATA XREF: ph_interrupt+72o

arg_0		=  8

		link	a6,#0
		movea.l	-$DB0(a5),a0
		andi.b	#$F0,$60(a0)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function ph_loop_on

; ---------------------------------------------------------------------------
aPh_loop_off:	dc.b 139,'ph_loop_off',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ph_loop_off:				; CODE XREF: InitializeCommon:loc_FD5Ap
		link	a6,#0
		moveq	#$1C,d0
		move.w	d0,-(sp)
		pea	-$A02(a5)
		move.l	-$DB0(a5),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		movea.l	#$3FFFE,a0
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_3AFA
		moveq	#$C,d1
		cmp.l	d1,d0
		beq.s	loc_3B04
		moveq	#$D,d1
		cmp.l	d1,d0
		beq.s	loc_3B04
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_3B20
		bra.s	loc_3B32
; ---------------------------------------------------------------------------

loc_3AFA:				; CODE XREF: ph_loop_off+2Aj
		movea.l	#$60003,a0
		move.b	#$35,(a0) ; '5'

loc_3B04:				; CODE XREF: ph_loop_off+30j
					; ph_loop_off+36j
		move.b	#3,-$8EC(a5)
		movea.l	-$DB0(a5),a0
		move.b	#$CA,$44(a0)
		movea.l	-$DB0(a5),a0
		move.b	#$20,$70(a0) ; ' '
		bra.s	loc_3B40
; ---------------------------------------------------------------------------

loc_3B20:				; CODE XREF: ph_loop_off+3Cj
		move.b	#2,-$8EC(a5)
		movea.l	-$DB0(a5),a0
		move.b	#$CA,$44(a0)
		bra.s	loc_3B40
; ---------------------------------------------------------------------------

loc_3B32:				; CODE XREF: ph_loop_off+3Ej
		clr.b	-$8EC(a5)
		movea.l	-$DB0(a5),a0
		move.b	#$C9,$44(a0)

loc_3B40:				; CODE XREF: ph_loop_off+64j
					; ph_loop_off+76j
		move.b	#$A0,d0
		move.b	d0,-$90E(a5)
		movea.l	-$DB0(a5),a0
		move.b	d0,$74(a0)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$90C(a5)
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		andi.b	#$80,d0
		beq.s	loc_3B90
		pea	-$656(a5)
		pea	-$98E(a5)
		jsr	(SetupIO).l
		addq.w	#8,sp
		pea	-$656(a5)
		pea	-$956(a5)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_3B90:				; CODE XREF: ph_loop_off+B4j
		unlk	a6
		rts
; End of function ph_loop_off

; ---------------------------------------------------------------------------
aInitisac:	dc.b 136,'InitISAC',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitISAC:				; CODE XREF: SplitBuffers+202p
					; IgnoreIrq+22p ...

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		movea.l	(a2),a3
		moveq	#0,d0
		movea.l	arg_0(a6),a0
		move.l	d0,$4C(a0)
		move.l	d0,(a2)
		movea.l	a2,a4
		bra.s	loc_3C00
; ---------------------------------------------------------------------------

loc_3BC2:				; CODE XREF: InitISAC+62j
		movea.l	(a3),a2
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		moveq	#$1F,d0
		clr.b	d1
		move.l	a3,d2
		addi.l	#$840,d2
		addi.l	#$1000000,d2
		movea.l	d2,a0
		movea.l	a0,a3

loc_3BE6:				; CODE XREF: InitISAC+48j
		move.b	d1,(a0)+
		dbf	d0,loc_3BE6
		move.l	arg_0(a6),$C(a3)
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		movea.l	a2,a3

loc_3C00:				; CODE XREF: InitISAC+20j
		move.l	a3,d0
		bne.s	loc_3BC2
		movea.l	arg_0(a6),a0
		movea.l	$38(a0),a0
		move.b	#$C0,$5C(a0)
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function InitISAC

; ---------------------------------------------------------------------------
aSplitbuffers:	dc.b 140,'SplitBuffers',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SplitBuffers:				; CODE XREF: AllocHscx+16p
					; AttachHscx+12p

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a4
		move.l	$38(a4),d0
		move.l	d0,var_8(a6)
		move.l	#$FA0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_3CBE
		moveq	#3,d3
		move.l	#$FA0,d4
		move.l	a4,$C(a3)
		movea.l	a4,a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		move.b	$E(a4),d0
		moveq	#$C,d1
		cmp.b	d1,d0
		bne.s	loc_3C9C
		moveq	#8,d3
		move.l	#$100,d4
		bra.s	loc_3C9C
; ---------------------------------------------------------------------------

loc_3C8A:				; CODE XREF: SplitBuffers+92j
		move.l	a4,$C(a3)
		move.l	a2,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		bra.s	loc_3CA2
; ---------------------------------------------------------------------------

loc_3C9C:				; CODE XREF: SplitBuffers+54j
					; SplitBuffers+5Ej
		movea.l	a4,a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2

loc_3CA2:				; CODE XREF: SplitBuffers+70j
		subq.l	#1,d3
		cmpi.l	#0,d3
		bmi.s	loc_3CBE
		move.l	d4,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		bne.s	loc_3C8A

loc_3CBE:				; CODE XREF: SplitBuffers+2Cj
					; SplitBuffers+80j
		move.l	a3,d0
		bne.s	loc_3CCE
		pea	(aOutOfBuffers+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_3CCE:				; CODE XREF: SplitBuffers+96j
		movea.l	a4,a2
		moveq	#$E,d0
		adda.l	d0,a2
		move.b	(a2),d3
		moveq	#$7F,d4	; ''
		cmp.b	d4,d3
		bls.s	loc_3CE0
		moveq	#8,d0
		bra.s	loc_3CE8
; ---------------------------------------------------------------------------

loc_3CE0:				; CODE XREF: SplitBuffers+B0j
		moveq	#7,d1
		and.b	d1,d3
		moveq	#0,d0
		move.b	d3,d0

loc_3CE8:				; CODE XREF: SplitBuffers+B4j
		moveq	#4,d3
		asl.l	d3,d0
		lea	-$880(a5),a0
		add.l	a0,d0
		move.l	d0,var_4(a6)
		move.l	4(a4),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d5	; ' '
		move.b	d5,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	var_4(a6),a0
		move.l	(a0),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	var_4(a6),a0
		move.w	4(a0),d0
		move.b	d0,$13(a4)
		move.l	$C(a0),d0
		move.l	d0,$3C(a4)
		move.b	$F(a4),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_3D3E
		moveq	#$2F,d0	; '/'
		bra.s	loc_3D40
; ---------------------------------------------------------------------------

loc_3D3E:				; CODE XREF: SplitBuffers+10Ej
		moveq	#3,d0

loc_3D40:				; CODE XREF: SplitBuffers+112j
		movea.l	var_8(a6),a3
		move.b	d0,$62(a3)
		move.b	d0,$60(a3)
		move.b	(a2),d0
		and.b	d5,d0
		beq.s	loc_3D56
		moveq	#6,d0
		bra.s	loc_3D58
; ---------------------------------------------------------------------------

loc_3D56:				; CODE XREF: SplitBuffers+126j
		moveq	#7,d0

loc_3D58:				; CODE XREF: SplitBuffers+12Aj
		move.b	d0,$66(a3)
		move.b	d0,$64(a3)
		move.b	(a2),d3
		cmp.b	d4,d3
		bls.w	loc_3E08
		cmpi.b	#$84,d3
		bls.w	loc_3DF2
		move.l	#$88,d4	; 'ˆ'
		moveq	#0,d0
		move.b	d3,d0
		sub.l	d0,d4
		move.l	d4,d0
		mulu.w	#5,d4
		swap	d0
		mulu.w	#5,d0
		swap	d0
		clr.w	d0
		add.l	d0,d4
		lea	-$7EC(a5),a0
		move.b	(a0,d4.w),d0
		move.b	d0,$66(a3)
		move.l	#$88,d0	; 'ˆ'
		move.b	(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		sub.l	d1,d0
		move.l	d0,d1
		mulu.w	#5,d0
		swap	d1
		mulu.w	#5,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		lea	-$7EF(a5),a0
		move.b	(a0,d0.w),d0
		move.b	d0,$7E(a4)
		clr.b	d3
		move.b	d3,$7F(a4)
		move.b	#$81,d0
		move.b	d0,$84(a4)
		move.b	d0,$83(a4)
		clr.w	d0
		move.w	d0,$56(a4)
		move.l	#$FF,$86(a4)
		move.b	d3,$80(a4)
		moveq	#7,d0
		move.w	d0,$8A(a4)
		bra.s	loc_3E4E
; ---------------------------------------------------------------------------

loc_3DF2:				; CODE XREF: SplitBuffers+142j
		move.b	#$22,$13(a4) ; '"'
		move.l	a4,-(sp)
		move.l	$34(a4),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_3E4E
; ---------------------------------------------------------------------------

loc_3E08:				; CODE XREF: SplitBuffers+13Aj
		movea.l	8(a4),a0
		move.b	4(a0),d0
		andi.b	#$80,d0
		bne.s	loc_3E4E
		move.b	$E(a4),d3
		moveq	#7,d0
		and.b	d0,d3
		moveq	#4,d0
		cmp.b	d0,d3
		beq.s	loc_3E2A
		moveq	#2,d0
		cmp.b	d0,d3
		bne.s	loc_3E34

loc_3E2A:				; CODE XREF: SplitBuffers+1F8j
		move.l	a4,-(sp)
		jsr	(InitISAC).l
		addq.w	#4,sp

loc_3E34:				; CODE XREF: SplitBuffers+1FEj
		move.b	$E(a4),d0
		moveq	#7,d1
		and.b	d1,d0
		moveq	#4,d1
		cmp.b	d1,d0
		bne.s	loc_3E4E
		move.b	#1,$64(a4)
		move.b	#3,$65(a4)

loc_3E4E:				; CODE XREF: SplitBuffers+1C6j
					; SplitBuffers+1DCj ...
		movea.l	var_4(a6),a2
		move.w	6(a2),-(sp)
		move.l	8(a2),-(sp)
		move.l	var_8(a6),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function SplitBuffers

; ---------------------------------------------------------------------------
aAllochscx:	dc.b 137,'AllocHscx',0
aOutOfBuffers:	dc.b 16,'out of buffers',0,0 ; DATA XREF: SplitBuffers+98o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AllocHscx:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		movea.l	$38(a3),a4
		move.l	a2,-(sp)
		jsr	(SplitBuffers).l
		addq.w	#4,sp
		move.b	$E(a3),d0
		moveq	#$FFFFFFDF,d1
		and.b	d1,d0
		moveq	#7,d1
		cmp.b	d1,d0
		bcc.s	loc_3ECA
		move.b	#$8D,$5E(a4)

loc_3ECA:				; CODE XREF: AllocHscx+2Aj
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function AllocHscx

; ---------------------------------------------------------------------------
aAttachhscx:	dc.b 138,'AttachHscx',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AttachHscx:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		move.l	a2,-(sp)
		jsr	(SplitBuffers).l
		addq.w	#4,sp
		move.b	$E(a3),d0
		moveq	#$FFFFFFDF,d1
		and.b	d1,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_3F0E
		andi.b	#$20,$E(a3) ; ' '

loc_3F0E:				; CODE XREF: AttachHscx+26j
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function AttachHscx

; ---------------------------------------------------------------------------
aListenhscx:	dc.b 138,'ListenHscx',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ListenHscx:				; CODE XREF: sendframe+5Ep
					; SendSabm+5Cp	...

arg_0		=  8
arg_4		=  $C
arg_6		=  $E

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3

loc_3F2E:				; CODE XREF: ListenHscx+16j
		move.b	$42(a3),d0
		moveq	#$42,d1	; 'B'
		and.b	d1,d0
		moveq	#$40,d1	; '@'
		cmp.b	d1,d0
		bne.s	loc_3F2E
		move.b	arg_4(a6),(a3)
		move.b	arg_6(a6),(a3)
		move.b	#$A,$42(a3)
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function ListenHscx

; ---------------------------------------------------------------------------
aSendframe:	dc.b 137,'sendframe',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

sendframe:				; DATA XREF: WaitForLeoFrame+10o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	$54(a3),d0
		moveq	#$A,d1
		cmp.w	d1,d0
		bne.s	loc_3FAA
		move.b	#8,$13(a3)
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$54(a3)
		bra.s	loc_3FF8
; ---------------------------------------------------------------------------

loc_3FAA:				; CODE XREF: sendframe+30j
		addq.w	#1,$54(a3)
		moveq	#$3F,d0	; '?'
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		pea	(aSabm+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	$7A(a3),d3
		beq.s	loc_3FE4
		move.l	d3,d0
		addq.l	#1,d0
		moveq	#2,d1
		jsr	main
		add.l	d3,d0
		bra.s	loc_3FE6
; ---------------------------------------------------------------------------

loc_3FE4:				; CODE XREF: sendframe+76j
		moveq	#9,d0

loc_3FE6:				; CODE XREF: sendframe+86j
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_3FF8:				; CODE XREF: sendframe+4Cj
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function sendframe

; ---------------------------------------------------------------------------
aSendsabm:	dc.b 136,'SendSabm',0,0
aSabm:		dc.b 8,'SABM ->',0      ; DATA XREF: sendframe+66o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendSabm:				; DATA XREF: startx75+10o

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	$54(a3),d0
		moveq	#$A,d1
		cmp.w	d1,d0
		bne.s	loc_4060
		move.b	#8,$13(a3)
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$54(a3)
		bra.s	loc_4098
; ---------------------------------------------------------------------------

loc_4060:				; CODE XREF: SendSabm+2Ej
		addq.w	#1,$54(a3)
		moveq	#$11,d0
		move.b	d0,-(sp)
		moveq	#$60,d0	; '`'
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		pea	(aRr+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#9,d0
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_4098:				; CODE XREF: SendSabm+4Aj
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function SendSabm

; ---------------------------------------------------------------------------
aSendrrpoll:	dc.b 138,'SendRRPoll',0,0
aRr:		dc.b 6,'RR ->',0        ; DATA XREF: SendSabm+64o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendRRPoll:				; DATA XREF: V110Irq+19Ao

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	$54(a3),d0
		moveq	#3,d1
		cmp.w	d1,d0
		bne.s	loc_4132
		pea	(aTimeoutOldX_leoAssumed+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#6,d0
		move.w	d0,-(sp)
		pea	-$8C6(a5)
		move.l	$38(a3),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		move.b	$13(a3),d0
		moveq	#6,d1
		cmp.b	d1,d0
		beq.s	loc_411C
		move.b	#3,$13(a3)

loc_411C:				; CODE XREF: SendRRPoll+62j
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$54(a3)
		bra.s	loc_4180
; ---------------------------------------------------------------------------

loc_4132:				; CODE XREF: SendRRPoll+30j
		addq.w	#1,$54(a3)
		moveq	#$3F,d0	; '?'
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		pea	aSabm_0		; "SABM	->"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	$7A(a3),d3
		beq.s	loc_416C
		move.l	d3,d0
		addq.l	#1,d0
		moveq	#2,d1
		jsr	main
		add.l	d3,d0
		bra.s	loc_416E
; ---------------------------------------------------------------------------

loc_416C:				; CODE XREF: SendRRPoll+A8j
		moveq	#$F,d0

loc_416E:				; CODE XREF: SendRRPoll+B8j
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_4180:				; CODE XREF: SendRRPoll+7Ej
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function SendRRPoll

; ---------------------------------------------------------------------------
aSendleosabm:	dc.b 139,'SendLeoSabm',0
aTimeoutOldX_leoAssumed:dc.b '$Timeout - old x.leo assumed',0 ; DATA XREF: SendRRPoll+32o
aSabm_0:	dc.b 'SABM ->',0        ; DATA XREF: SendRRPoll+98o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendLeoSabm:				; DATA XREF: LeoPrivateIrq+224o

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	#3,$13(a2)
		move.l	a2,-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		jsr	(WriteProc).l
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function SendLeoSabm

; ---------------------------------------------------------------------------
aWaitforleoframe:dc.b 143,'WaitForLeoFrame',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WaitForLeoFrame:			; CODE XREF: TestInterfills+C2p

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		clr.w	d0
		move.w	d0,$54(a3)
		lea	(sendframe).l,a0
		move.l	a0,$6A(a3)
		move.l	a3,$72(a3)
		moveq	#1,d0
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function WaitForLeoFrame

; ---------------------------------------------------------------------------
aStartx75:	dc.b 136,'startx75',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

startx75:				; CODE XREF: TestInterfills+D0p

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		clr.w	d0
		move.w	d0,$54(a3)
		lea	(SendSabm).l,a0
		move.l	a0,$6A(a3)
		move.l	a3,$72(a3)
		lea	(V110Irq).l,a0
		move.l	a0,$3C(a3)
		moveq	#$C,d0
		move.w	d0,-(sp)
		pea	-$898(a5)
		move.l	$38(a3),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function startx75

; ---------------------------------------------------------------------------
aStartleo:	dc.b 136,'startleo',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

startleo:				; DATA XREF: LapBIrq+294o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$C(a4),a3
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	$1D(a4),d1
		andi.b	#$EF,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$63,d1	; 'c'
		cmp.l	d1,d0
		beq.s	loc_42FC
		moveq	#$43,d1	; 'C'
		cmp.l	d1,d0
		beq.w	loc_43A0
		moveq	#$2F,d1	; '/'
		cmp.l	d1,d0
		beq.w	loc_43F2
		moveq	#$F,d1
		cmp.l	d1,d0
		beq.w	loc_4490
		moveq	#3,d1
		cmp.l	d1,d0
		beq.w	loc_449E
		bra.w	loc_44C4
; ---------------------------------------------------------------------------

loc_42FC:				; CODE XREF: startleo+38j
		pea	(aRua+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a3,a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.w	$56(a3),d0
		andi.w	#$4000,d0
		bne.w	loc_44D0
		move.b	#1,$64(a3)
		move.b	#3,$65(a3)
		move.w	#$4000,$56(a3)
		lea	(HuntIrq).l,a0
		move.l	a0,$3C(a3)
		moveq	#$14,d0
		move.w	d0,-(sp)
		pea	-$8C0(a5)
		move.l	$38(a3),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		pea	aNewX_leoSwitchingToX_75 ; "New	X.Leo -	Switching to X.75"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	-$DBA(a5),d0
		beq.s	loc_4376
		move.b	#$35,$13(a3) ; '5'
		bra.s	loc_438E
; ---------------------------------------------------------------------------

loc_4376:				; CODE XREF: startleo+CEj
		moveq	#3,d3
		move.b	d3,$13(a3)
		move.b	d3,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp

loc_438E:				; CODE XREF: startleo+D6j
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_44D0
; ---------------------------------------------------------------------------

loc_43A0:				; CODE XREF: startleo+3Ej
		pea	aDisc		; "DISC	<-"
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a3,a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.b	#4,$13(a3)
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	$1D(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		moveq	#$63,d1	; 'c'
		or.b	d1,d0
		move.b	d0,-(sp)
		moveq	#$60,d0	; '`'
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_44D0
; ---------------------------------------------------------------------------

loc_43F2:				; CODE XREF: startleo+46j
		pea	aSabm_1		; "SABM	<-"
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a3,a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.w	$56(a3),d0
		andi.w	#$4000,d0
		bne.s	loc_4470
		move.b	#3,$64(a3)
		move.b	#1,$65(a3)
		move.w	#$4000,$56(a3)
		move.b	#$35,$13(a3) ; '5'
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		lea	(HuntIrq).l,a0
		move.l	a0,$3C(a3)
		moveq	#$14,d0
		move.w	d0,-(sp)
		pea	-$8AC(a5)
		move.l	$38(a3),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		pea	aNewX_leoX_75	; "New X.Leo ->	X.75"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_4470:				; CODE XREF: startleo+178j
		move.b	$1D(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		moveq	#$63,d1	; 'c'
		or.b	d1,d0
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	$38(a3),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.s	loc_44D0
; ---------------------------------------------------------------------------

loc_4490:				; CODE XREF: startleo+4Ej
		pea	aDm		; "DM <-"
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_44D0
; ---------------------------------------------------------------------------

loc_449E:				; CODE XREF: startleo+56j
		pea	aUi		; "UI <-"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	$2C(a3),d0
		move.l	d0,4(a4)
		moveq	#1,d0
		move.w	d0,$18(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_44EC
; ---------------------------------------------------------------------------

loc_44C4:				; CODE XREF: startleo+5Aj
		move.b	$1D(a4),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp

loc_44D0:				; CODE XREF: startleo+82j startleo+FEj ...
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,$14(a4)
		movea.l	a3,a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a4,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_44EC:				; CODE XREF: startleo+224j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function startleo

; ---------------------------------------------------------------------------
aCheckleo:	dc.b 136,'CheckLeo',0,0
aRua:		dc.b 'RUA <-',0         ; DATA XREF: startleo:loc_42FCo
aNewX_leoSwitchingToX_75:dc.b 'New X.Leo - Switching to X.75',0 ; DATA XREF: startleo+B8o
aDisc:		dc.b 'DISC <-',0        ; DATA XREF: startleo:loc_43A0o
aSabm_1:	dc.b 'SABM <-',0        ; DATA XREF: startleo:loc_43F2o
aNewX_leoX_75:	dc.b 'New X.Leo -> X.75',0 ; DATA XREF: startleo+1C0o
aDm:		dc.b 'DM <-',0          ; DATA XREF: startleo:loc_4490o
aUi:		dc.b 'UI <-',0          ; DATA XREF: startleo:loc_449Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckLeo:				; DATA XREF: TestInterfills+17Eo

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$C(a4),a3
		cmpa.w	#0,a3
		beq.s	loc_45BA
		tst.l	$76(a3)
		beq.s	loc_45BA
		movea.l	-$DB4(a5),a2
		move.b	$42(a2),d0
		moveq	#8,d1
		and.b	d1,d0
		bne.s	loc_4586
		move.b	$C2(a2),d0
		moveq	#8,d1
		and.b	d1,d0
		beq.s	loc_4592

loc_4586:				; CODE XREF: CheckLeo+28j
		move.l	a4,-(sp)
		jsr	(PostEvent).l
		addq.w	#4,sp
		bra.s	loc_45C4
; ---------------------------------------------------------------------------

loc_4592:				; CODE XREF: CheckLeo+32j
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		moveq	#$15,d0
		move.b	d0,-$773(a5)
		move.b	d0,-$6E7(a5)
		move.l	$C(a4),-(sp)
		pea	(NL_DISCONNECT_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_45C4
; ---------------------------------------------------------------------------

loc_45BA:				; CODE XREF: CheckLeo+14j CheckLeo+1Aj
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_45C4:				; CODE XREF: CheckLeo+3Ej CheckLeo+66j
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function CheckLeo

; ---------------------------------------------------------------------------
aTestinterfills:dc.b 142,'TestInterfills',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

TestInterfills:

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		move.l	$38(a3),d0
		move.l	d0,var_4(a6)
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		jsr	(WriteProc).l
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	$E(a3),d3
		move.b	#$80,d4
		cmp.b	d4,d3
		bls.s	loc_462E
		moveq	#8,d0
		bra.s	loc_4636
; ---------------------------------------------------------------------------

loc_462E:				; CODE XREF: TestInterfills+4Aj
		moveq	#7,d1
		and.b	d1,d3
		moveq	#0,d0
		move.b	d3,d0

loc_4636:				; CODE XREF: TestInterfills+4Ej
		asl.l	#4,d0
		lea	-$880(a5),a0
		move.l	(a0,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	-$D44(a5),$76(a3)
		move.b	$E(a3),d0
		andi.b	#$F0,d0
		cmp.b	d4,d0
		bne.s	loc_4664
		movea.l	$38(a3),a0
		move.b	#1,$42(a0)

loc_4664:				; CODE XREF: TestInterfills+7Aj
		move.b	$13(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$1F,d1
		cmp.l	d1,d0
		beq.s	loc_4682
		moveq	#$21,d1	; '!'
		cmp.l	d1,d0
		beq.s	loc_46AC
		moveq	#$15,d1
		cmp.l	d1,d0
		beq.s	loc_46C0
		bra.w	loc_477E
; ---------------------------------------------------------------------------

loc_4682:				; CODE XREF: TestInterfills+92j
		movea.l	8(a3),a0
		move.b	4(a0),d0
		andi.b	#$80,d0
		beq.s	loc_469E
		move.l	a3,-(sp)
		jsr	(IgnoreIrq).l
		addq.w	#4,sp
		bra.w	loc_477E
; ---------------------------------------------------------------------------

loc_469E:				; CODE XREF: TestInterfills+B0j
		move.l	a3,-(sp)
		jsr	(WaitForLeoFrame).l
		addq.w	#4,sp
		bra.w	loc_477E
; ---------------------------------------------------------------------------

loc_46AC:				; CODE XREF: TestInterfills+98j
		move.l	a3,-(sp)
		jsr	(startx75).l
		addq.w	#4,sp
		move.b	#$20,$13(a3) ; ' '
		bra.w	loc_477E
; ---------------------------------------------------------------------------

loc_46C0:				; CODE XREF: TestInterfills+9Ej
		pea	(aHighspeed+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	#$16,$13(a3)
		lea	(Bundled1Irq).l,a0
		move.l	a0,$3C(a3)
		lea	(WriteHscx).l,a0
		move.l	a0,$24(a3)
		lea	(ClearHscx).l,a0
		move.l	a0,$28(a3)
		movea.l	a3,a4
		moveq	#$48,d0	; 'H'
		adda.l	d0,a4
		bra.s	loc_4702
; ---------------------------------------------------------------------------

loc_46F8:				; CODE XREF: TestInterfills+134j
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_4702:				; CODE XREF: TestInterfills+118j
		move.l	a4,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_46F8
		lea	-$6FA(a5),a0
		cmpa.l	a0,a3
		bne.s	loc_4722
		lea	-$786(a5),a4
		bra.s	loc_4726
; ---------------------------------------------------------------------------

loc_4722:				; CODE XREF: TestInterfills+13Cj
		lea	-$6FA(a5),a4

loc_4726:				; CODE XREF: TestInterfills+142j
		lea	(HdlcIrq).l,a0
		move.l	a0,$3C(a4)
		lea	(WriteHscx).l,a0
		move.l	a0,$24(a4)
		lea	(ClearHscx).l,a0
		move.l	a0,$28(a4)
		moveq	#$12,d0
		move.w	d0,-(sp)
		pea	-$8EA(a5)
		move.l	$38(a4),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		move.l	a4,-(sp)
		pea	(CheckLeo).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$BE,d3
		movea.l	$38(a3),a0
		move.b	d3,$5C(a0)
		movea.l	$38(a4),a0
		move.b	d3,$5C(a0)

loc_477E:				; CODE XREF: TestInterfills+A0j
					; TestInterfills+BCj ...
		move.b	$E(a3),d0
		moveq	#$FFFFFFDF,d1
		and.b	d1,d0
		moveq	#7,d1
		cmp.b	d1,d0
		bcc.s	loc_4796
		movea.l	var_4(a6),a0
		move.b	#$8D,$5E(a0)

loc_4796:				; CODE XREF: TestInterfills+1ACj
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
; End of function TestInterfills

		rts
; ---------------------------------------------------------------------------
aConnecthscx:	dc.b 139,'ConnectHscx',0
aHighspeed:	dc.b 10,'Highspeed',0   ; DATA XREF: TestInterfills:loc_46C0o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ConnectHscx:

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		movea.l	$38(a3),a2
		lea	(PrintError).l,a0
		move.l	a0,$3C(a3)
		lea	(Bundled2Irq).l,a0
		move.l	a0,$24(a3)
		lea	(DisconnectHscx).l,a0
		move.l	a0,$28(a3)
		moveq	#$C,d0
		move.w	d0,-(sp)
		pea	-$88C(a5)
		move.l	a2,-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		jsr	(WriteProc).l
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		jsr	(WritePString).l
		move.w	$58(a3),d1
		moveq	#0,d0
		move.w	d1,d0
		move.l	d0,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	$5A(a3),d1
		moveq	#0,d0
		move.w	d1,d0
		move.l	d0,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		clr.w	d3
		move.w	d3,$5A(a3)
		move.w	d3,$58(a3)
		move.w	d3,$56(a3)
		clr.b	d0
		move.b	d0,$62(a3)
		move.b	d0,$63(a3)
		move.b	d0,$61(a3)
		move.b	d0,$60(a3)
		move.w	d3,$54(a3)
		moveq	#0,d0
		move.l	d0,$76(a3)
		move.l	d0,$7A(a3)
		moveq	#0,d0
		move.l	d0,$50(a3)
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	a3,a4
		moveq	#$40,d0	; '@'
		adda.l	d0,a4
		movea.l	a3,a0
		moveq	#$30,d0	; '0'
		adda.l	d0,a0
		move.l	a0,var_4(a6)
		bra.s	loc_48AE
; ---------------------------------------------------------------------------

loc_489A:				; CODE XREF: ConnectHscx+10Aj
		movea.l	var_4(a6),a0
		move.l	(a0),d0
		move.l	d0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_48AE:				; CODE XREF: ConnectHscx+E2j
		move.l	a4,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_48CE
		bra.s	loc_489A
; ---------------------------------------------------------------------------

loc_48C2:				; CODE XREF: ConnectHscx+12Ej
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_48D4
; ---------------------------------------------------------------------------

loc_48CE:				; CODE XREF: ConnectHscx+108j
		movea.l	a3,a4
		moveq	#$48,d0	; 'H'
		adda.l	d0,a4

loc_48D4:				; CODE XREF: ConnectHscx+116j
		move.l	a4,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_48C2
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function ConnectHscx

; ---------------------------------------------------------------------------
aDisconnecthscx:dc.b 142,'DisconnectHscx',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DisconnectHscx:				; DATA XREF: ConnectHscx+28o

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	$C(a3),a4
		move.l	$38(a4),d0
		move.l	d0,var_8(a6)
		clr.w	d1
		move.w	d1,$18(a3)
		moveq	#0,d0
		move.w	d1,d0
		move.l	d0,$10(a3)
		move.l	d0,$14(a3)
		tst.l	8(a4)
		bne.s	loc_494A
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.w	loc_49D2
; ---------------------------------------------------------------------------

loc_494A:				; CODE XREF: DisconnectHscx+2Ej
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d4
		movea.l	a4,a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		movea.l	a4,a2
		moveq	#$56,d0	; 'V'
		adda.l	d0,a2
		move.w	(a2),d3
		move.w	d3,var_4(a6)
		andi.w	#$4000,d3
		beq.s	loc_49C0
		move.w	var_4(a6),d0
		moveq	#2,d1
		and.w	d1,d0
		beq.s	loc_49CE
		movea.l	$48(a4),a0
		movea.l	$4C(a4),a1
		cmpa.l	a1,a0
		beq.s	loc_49CE
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		move.w	(a2),d0
		moveq	#$FFFFFFFD,d1
		and.w	d1,d0
		moveq	#$40,d1	; '@'
		or.w	d1,d0
		move.w	d0,(a2)
		andi.w	#$200,d0
		bne.s	loc_49BA
		moveq	#$10,d0
		move.w	d0,-(sp)
		move.l	$38(a4),-(sp)
		move.l	a4,-(sp)
		movea.l	$3C(a4),a0
		jsr	(a0)
		lea	$A(sp),sp

loc_49BA:				; CODE XREF: DisconnectHscx+98j
		move.w	d3,d0
		move	d0,sr
		bra.s	loc_49CE
; ---------------------------------------------------------------------------

loc_49C0:				; CODE XREF: DisconnectHscx+68j
		clr.b	d3
		movea.l	var_8(a6),a2
		move.b	d3,$42(a2)
		move.b	d3,$40(a2)

loc_49CE:				; CODE XREF: DisconnectHscx+72j
					; DisconnectHscx+7Ej ...
		move.w	d4,d0
		move	d0,sr

loc_49D2:				; CODE XREF: DisconnectHscx+3Aj
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function DisconnectHscx

; ---------------------------------------------------------------------------
aClearhscx:	dc.b 137,'ClearHscx',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ClearHscx:				; CODE XREF: HscxErrLog+1Ep
					; DATA XREF: TestInterfills+108o ...

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	$C(a3),a4
		move.l	$38(a4),d0
		move.l	d0,var_8(a6)
		eori.l	#$80,d0	; '€'
		move.l	d0,var_4(a6)
		tst.l	8(a4)
		bne.s	loc_4A1A
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_4A60
; ---------------------------------------------------------------------------

loc_4A1A:				; CODE XREF: ClearHscx+26j
		moveq	#0,d0
		move.l	d0,$10(a3)
		move.l	d0,$14(a3)
		move.l	d0,$1A(a3)
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d4
		movea.l	a4,a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		clr.b	d3
		movea.l	var_8(a6),a2
		move.b	d3,$42(a2)
		move.b	d3,$40(a2)
		movea.l	var_4(a6),a2
		move.b	d3,$42(a2)
		move.b	d3,$40(a2)
		move.w	d4,d0
		move	d0,sr

loc_4A60:				; CODE XREF: ClearHscx+32j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function ClearHscx

; ---------------------------------------------------------------------------
aClearbundledhscx:dc.b 144,'ClearBundledHscx',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ClearBundledHscx:			; DATA XREF: PrintError+3Co
					; WriteBundledHscx+C4o	...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function ClearBundledHscx

; ---------------------------------------------------------------------------
aHscxintlog:	dc.b 138,'HscxIntLog',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

HscxIntLog:				; DATA XREF: V110Irq+136o
					; LeoPrivateIrq+132o ...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function HscxIntLog

; ---------------------------------------------------------------------------
aHscxerrlog:	dc.b 138,'HscxErrLog',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

HscxErrLog:				; DATA XREF: HdlcIrq:loc_6CCCo
					; Bundled1Irq:loc_71A0o

arg_0		=  8

		link	a6,#0
		moveq	#$20,d0	; ' '
		move.l	d0,-(sp)
		move.l	arg_0(a6),d0
		moveq	#$10,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		move.l	arg_0(a6),-(sp)
		jsr	(ClearHscx).l
		unlk	a6
		rts
; End of function HscxErrLog

; ---------------------------------------------------------------------------
aPrinterror:	dc.b 138,'PrintError',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PrintError:				; CODE XREF: TransmitError+14Ap
					; V110Irq+224p	...

arg_4		=  $C
arg_8		=  $10

		link	a6,#0
		movea.l	arg_4(a6),a0
		move.b	$42(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		move.l	arg_4(a6),d1
		andi.l	#$80,d1	; '€'
		beq.s	loc_4B42
		move.l	#$B0000000,d1
		bra.s	loc_4B48
; ---------------------------------------------------------------------------

loc_4B42:				; CODE XREF: PrintError+1Ej
		move.l	#$A0000000,d1

loc_4B48:				; CODE XREF: PrintError+26j
		add.l	d1,d0
		move.w	arg_8(a6),d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(ClearBundledHscx).l
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function PrintError

; ---------------------------------------------------------------------------
aIgnoreirq:	dc.b 137,'IgnoreIrq',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IgnoreIrq:				; CODE XREF: TestInterfills+B4p
					; LeoPrivateIrq+31Ap

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		moveq	#$14,d0
		move.w	d0,-(sp)
		pea	-$8AC(a5)
		move.l	$38(a3),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		move.l	a3,-(sp)
		jsr	(InitISAC).l
		addq.w	#4,sp
		lea	(HuntIrq).l,a0
		move.l	a0,$3C(a3)
		ori.b	#4,$E(a3)
		move.b	#3,$64(a3)
		move.b	#1,$65(a3)
		move.w	#$4000,$56(a3)
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function IgnoreIrq

; ---------------------------------------------------------------------------
aSwitchlapb:	dc.b 138,'SwitchLapb',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SwitchLapb:				; CODE XREF: TransmitDone+3Cp
					; TransmitError+CEp ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a4
		clr.w	d0
		move.w	d0,$54(a4)
		movea.l	a4,a0
		moveq	#$40,d0	; '@'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a3
		move.l	$14(a3),d0
		move.l	d0,$10(a3)
		move.l	$30(a4),d0
		move.l	d0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function SwitchLapb

; ---------------------------------------------------------------------------
aTransmitdone:	dc.b 140,'TransmitDone',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

TransmitDone:				; CODE XREF: HuntIrq+78Ap LapBIrq+398p ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		pea	(aTransmiterror+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#8,$13(a3)
		move.l	a3,-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	a3,a4
		moveq	#$40,d0	; '@'
		adda.l	d0,a4
		bra.s	loc_4C6C
; ---------------------------------------------------------------------------

loc_4C62:				; CODE XREF: TransmitDone+46j
		move.l	a3,-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp

loc_4C6C:				; CODE XREF: TransmitDone+38j
		tst.l	(a4)
		bne.s	loc_4C62
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function TransmitDone

; ---------------------------------------------------------------------------
aTransmiterror_0:dc.b 141,'TransmitError',0
aTransmiterror:	dc.b 14,'TransmitError',0 ; DATA XREF: TransmitDone+Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

TransmitError:

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.w	arg_8(a6),d4
		movea.l	a4,a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		movea.l	(a2),a3
		cmpa.w	#0,a3
		beq.s	loc_4D30
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_4D30
		moveq	#$1F,d0
		movea.l	a3,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		adda.l	$14(a3),a1
		movea.l	arg_4(a6),a0

loc_4CCC:				; CODE XREF: TransmitError+38j
		move.b	(a0),(a1)+
		dbf	d0,loc_4CCC
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)
		addi.l	#$20,$14(a3) ; ' '
		move.l	$14(a3),d0
		andi.l	#$100,d0
		beq.s	loc_4D42
		move.l	a2,-(sp)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		move.l	$2C(a4),d0
		move.l	d0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		tst.l	(a2)
		bne.s	loc_4D42
		pea	(aOctetNoReceiveBuffers+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	arg_4(a6),a0
		move.b	#$C0,$40(a0)
		bra.s	loc_4D42
; ---------------------------------------------------------------------------

loc_4D30:				; CODE XREF: TransmitError+1Cj
					; TransmitError+24j
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_4D42
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)

loc_4D42:				; CODE XREF: TransmitError+58j
					; TransmitError+7Aj ...
		movea.l	$40(a4),a3
		cmpa.w	#0,a3
		beq.w	loc_4DD0
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.s	loc_4DD0
		move.l	$10(a3),d0
		move.l	$14(a3),d1
		cmp.l	d1,d0
		bne.s	loc_4D8A
		move.l	a4,-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		movea.l	$40(a4),a3
		cmpa.w	#0,a3
		bne.s	loc_4D8A
		pea	aOctetNoSendBuffers ; "Octet: no send buffers"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_4DD0
; ---------------------------------------------------------------------------

loc_4D8A:				; CODE XREF: TransmitError+CAj
					; TransmitError+DEj
		movea.l	a3,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	$10(a3),d3
		adda.l	d3,a2
		move.l	a2,var_4(a6)
		move.l	$14(a3),d0
		move.w	d0,d5
		sub.w	d3,d5
		moveq	#$20,d3	; ' '
		cmp.w	d3,d5
		ble.s	loc_4DAA
		move.w	d3,d5

loc_4DAA:				; CODE XREF: TransmitError+110j
		move.w	d5,d3
		move.w	d3,d0
		ext.l	d0
		add.l	d0,$10(a3)
		move.w	d3,d0
		subq.w	#1,d0
		movea.l	arg_4(a6),a1
		movea.l	var_4(a6),a0

loc_4DC0:				; CODE XREF: TransmitError+12Cj
		move.b	(a0)+,(a1)
		dbf	d0,loc_4DC0
		movea.l	arg_4(a6),a0
		move.b	#8,$42(a0)

loc_4DD0:				; CODE XREF: TransmitError+B4j
					; TransmitError+BEj ...
		move.w	d4,d3
		andi.w	#$BFAF,d3
		beq.s	loc_4DEA
		move.w	d4,-(sp)
		move.l	arg_4(a6),-(sp)
		move.l	a4,-(sp)
		jsr	(PrintError).l
		lea	$A(sp),sp

loc_4DEA:				; CODE XREF: TransmitError+140j
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function TransmitError

; ---------------------------------------------------------------------------
aOctetirq:	dc.b 136,'OctetIrq',0,0
aOctetNoReceiveBuffers:dc.b 50,'Octet: no receive buffers',0 ; DATA XREF: TransmitError+7Co
aOctetNoSendBuffers:dc.b 'Octet: no send buffers',0,0 ; DATA XREF: TransmitError+E0o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

OctetIrq:				; CODE XREF: Sync2Async+1Ep

arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#0
		movem.l	d3-d4/a2-a4,-(sp)
		move.l	arg_8(a6),d4
		movea.l	arg_4(a6),a2
		movea.l	arg_0(a6),a3
		lea	$8A(a3),a3
		movea.l	arg_0(a6),a4
		lea	$86(a4),a4
		bra.s	loc_4E98
; ---------------------------------------------------------------------------

loc_4E52:				; CODE XREF: OctetIrq+6Ej
		movea.l	arg_4(a6),a0
		addq.l	#1,arg_4(a6)
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		move.w	(a3),d1
		ext.l	d1
		asl.l	d1,d0
		or.l	d0,(a4)
		addq.w	#6,(a3)
		bra.s	loc_4E90
; ---------------------------------------------------------------------------

loc_4E6C:				; CODE XREF: OctetIrq+66j
		move.l	(a4),d0
		moveq	#1,d1
		and.w	d1,d0
		bne.s	loc_4E88
		move.l	(a4),d3
		asr.l	#1,d3
		move.l	d3,(a4)
		move.b	d3,(a2)+
		move.l	(a4),d0
		asr.l	#8,d0
		move.l	d0,(a4)
		subi.w	#9,(a3)
		bra.s	loc_4E90
; ---------------------------------------------------------------------------

loc_4E88:				; CODE XREF: OctetIrq+42j
		move.l	(a4),d0
		asr.l	#1,d0
		move.l	d0,(a4)
		subq.w	#1,(a3)

loc_4E90:				; CODE XREF: OctetIrq+3Aj OctetIrq+56j
		move.w	(a3),d0
		moveq	#$A,d1
		cmp.w	d1,d0
		bgt.s	loc_4E6C

loc_4E98:				; CODE XREF: OctetIrq+20j
		move.l	d4,d0
		subq.l	#1,d4
		tst.l	d0
		bne.s	loc_4E52
		move.l	a2,d0
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function OctetIrq

; ---------------------------------------------------------------------------
aSync2async:	dc.b 138,'Sync2Async',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Sync2Async:				; DATA XREF: HandleV110Frame+17Eo

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),-(sp)
		movea.l	a3,a0
		moveq	#$1E,d3
		adda.l	d3,a0
		move.l	a0,-(sp)
		movea.l	$C(a3),a4
		move.l	a4,-(sp)
		jsr	(OctetIrq).l
		lea	$C(sp),sp
		movea.l	d0,a0
		movea.l	a3,a1
		adda.l	d3,a1
		suba.l	a1,a0
		move.l	a0,$14(a3)
		moveq	#0,d0
		move.l	d0,$10(a3)
		move.l	$2C(a4),d0
		move.l	d0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function Sync2Async

; ---------------------------------------------------------------------------
aHandlev110frame:dc.b 143,'HandleV110Frame',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

HandleV110Frame:

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.w	arg_8(a6),d4
		movea.l	$40(a4),a3
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_4FC8
		cmpa.w	#0,a3
		beq.s	loc_4FAA
		move.b	$81(a4),d0
		moveq	#1,d3
		cmp.b	d3,d0
		bne.s	loc_4FAA
		move.b	$82(a4),d0
		cmp.b	d3,d0
		bne.s	loc_4FAA
		move.l	arg_4(a6),-(sp)
		movea.l	a3,a2
		moveq	#$1E,d3
		adda.l	d3,a2
		move.l	a2,var_4(a6)
		adda.l	$14(a3),a2
		move.l	a2,-(sp)
		movea.l	var_4(a6),a0
		movea.l	a3,a2
		moveq	#$10,d0
		adda.l	d0,a2
		adda.l	(a2),a0
		move.l	a0,-(sp)
		move.l	a4,-(sp)
		jsr	(memory_dump).l
		lea	$10(sp),sp
		movea.l	a3,a0
		adda.l	d3,a0
		sub.l	a0,d0
		move.l	d0,(a2)
		movea.l	arg_4(a6),a0
		move.b	#8,$42(a0)
		move.l	(a2),d0
		move.l	$14(a3),d1
		cmp.l	d1,d0
		bne.s	loc_4FC8
		move.l	a4,-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		bra.s	loc_4FC8
; ---------------------------------------------------------------------------

loc_4FAA:				; CODE XREF: HandleV110Frame+22j
					; HandleV110Frame+2Cj ...
		move.l	arg_4(a6),-(sp)
		clr.l	-(sp)
		clr.l	-(sp)
		move.l	a4,-(sp)
		jsr	(memory_dump).l
		lea	$10(sp),sp
		movea.l	arg_4(a6),a0
		move.b	#8,$42(a0)

loc_4FC8:				; CODE XREF: HandleV110Frame+1Aj
					; HandleV110Frame+7Ej ...
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.w	loc_50CE
		movea.l	$48(a4),a3
		cmpa.w	#0,a3
		beq.w	loc_50C4
		move.l	arg_4(a6),-(sp)
		movea.l	a3,a0
		moveq	#$1E,d3
		adda.l	d3,a0
		movea.l	a3,a2
		moveq	#$14,d0
		adda.l	d0,a2
		adda.l	(a2),a0
		move.l	a0,-(sp)
		move.l	a4,-(sp)
		jsr	(sendV110frame).l
		lea	$C(sp),sp
		movea.l	a3,a0
		adda.l	d3,a0
		sub.l	a0,d0
		move.l	d0,(a2)
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)
		tst.w	$56(a4)
		bne.s	loc_5026
		addq.w	#1,$56(a4)
		move.b	#$81,$83(a4)
		moveq	#0,d0
		move.l	d0,(a2)
		bra.s	loc_506A
; ---------------------------------------------------------------------------

loc_5026:				; CODE XREF: HandleV110Frame+F6j
		move.w	$56(a4),d0
		moveq	#1,d1
		cmp.w	d1,d0
		bne.s	loc_506A
		movea.l	8(a4),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_506A
		moveq	#2,d0
		move.w	d0,$56(a4)
		moveq	#1,d3
		move.b	d3,$83(a4)
		move.b	d3,$84(a4)
		move.b	$13(a4),d0
		moveq	#3,d3
		cmp.b	d3,d0
		beq.s	loc_506A
		move.b	d3,$13(a4)
		move.l	a4,-(sp)
		move.l	$34(a4),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_506A:				; CODE XREF: HandleV110Frame+106j
					; HandleV110Frame+110j	...
		tst.l	$14(a3)
		beq.s	loc_50CE
		move.l	$10(a3),d0
		addq.l	#1,$10(a3)
		moveq	#$28,d1	; '('
		cmp.l	d1,d0
		ble.s	loc_50CE
		movea.l	$48(a4),a0
		movea.l	$4C(a4),a1
		cmpa.l	a1,a0
		beq.s	loc_50BC
		movea.l	a4,a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		lea	(Sync2Async).l,a0
		move.l	a0,4(a3)
		move.l	a4,$C(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	#1,$83(a4)
		bra.s	loc_50CE
; ---------------------------------------------------------------------------

loc_50BC:				; CODE XREF: HandleV110Frame+16Aj
		move.b	#$81,$83(a4)
		bra.s	loc_50CE
; ---------------------------------------------------------------------------

loc_50C4:				; CODE XREF: HandleV110Frame+BCj
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)

loc_50CE:				; CODE XREF: HandleV110Frame+B0j
					; HandleV110Frame+150j	...
		move.w	d4,d0
		andi.w	#$4000,d0
		beq.s	loc_50E0
		movea.l	arg_4(a6),a0
		move.b	#1,$42(a0)

loc_50E0:				; CODE XREF: HandleV110Frame+1B6j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function HandleV110Frame

; ---------------------------------------------------------------------------
aV110irq:	dc.b 135,'V110Irq',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

V110Irq:				; DATA XREF: startx75+1Eo

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3-d5/a2-a4,-(sp)
		move.w	arg_8(a6),d5
		movea.l	arg_0(a6),a0
		movea.l	$48(a0),a4
		cmpa.w	#0,a4
		beq.w	loc_5308
		move.w	d5,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_5140
		movea.l	a4,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		adda.l	$10(a4),a2
		addi.l	#$20,$10(a4) ; ' '
		moveq	#$1F,d0
		movea.l	a2,a1
		movea.l	arg_4(a6),a0

loc_5130:				; CODE XREF: V110Irq+40j
		move.b	(a0),(a1)+
		dbf	d0,loc_5130
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)

loc_5140:				; CODE XREF: V110Irq+22j
		move.w	d5,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_5304
		movea.l	a4,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		adda.l	$10(a4),a3
		movea.l	arg_4(a6),a2
		move.b	$5A(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$4A(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		andi.l	#$FFF,d0
		move.l	d0,$14(a4)
		move.w	d0,d4
		move.l	$10(a4),d0
		sub.w	d0,d4
		moveq	#$20,d3	; ' '
		cmp.w	d3,d4
		ble.s	loc_518C
		move.w	d3,d4
		moveq	#0,d0
		move.l	d0,$14(a4)

loc_518C:				; CODE XREF: V110Irq+90j
		subq.l	#1,$14(a4)
		tst.w	d4
		ble.s	loc_51AE
		move.w	d4,d0
		subq.w	#1,d0
		movea.l	a3,a1
		movea.l	arg_4(a6),a0

loc_519E:				; CODE XREF: V110Irq+AEj
		move.b	(a0),(a1)+
		dbf	d0,loc_519E
		move.b	-1(a1),d0
		move.b	d0,var_4(a6)
		bra.s	loc_51B4
; ---------------------------------------------------------------------------

loc_51AE:				; CODE XREF: V110Irq+A0j
		move.b	#$FF,var_4(a6)

loc_51B4:				; CODE XREF: V110Irq+BAj
		move.b	#$80,d0
		movea.l	arg_4(a6),a2
		move.b	d0,$42(a2)
		move.l	$14(a4),d3
		moveq	#0,d4
		cmp.l	d4,d3
		ble.s	loc_51D8
		move.b	var_4(a6),d1
		andi.b	#$F0,d1
		cmpi.b	#$A0,d1
		beq.s	loc_523A

loc_51D8:				; CODE XREF: V110Irq+D6j
		cmp.l	d4,d3
		ble.w	loc_52FA
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d1
		moveq	#$A,d2
		cmp.b	d2,d1
		bne.w	loc_52FA
		move.b	$4E(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		asl.l	#8,d1
		moveq	#0,d2
		move.b	d0,d2
		moveq	#$10,d0
		asl.l	d0,d2
		add.l	d2,d1
		cmpa.l	-$DB4(a5),a2
		bne.s	loc_5214
		move.l	#$A0000000,d0
		bra.s	loc_521A
; ---------------------------------------------------------------------------

loc_5214:				; CODE XREF: V110Irq+118j
		move.l	#$B0000000,d0

loc_521A:				; CODE XREF: V110Irq+120j
		add.l	d0,d1
		move.b	var_4(a6),d2
		moveq	#0,d0
		move.b	d2,d0
		add.l	d0,d1
		move.l	d1,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_52FA
; ---------------------------------------------------------------------------

loc_523A:				; CODE XREF: V110Irq+E4j
		movea.l	arg_0(a6),a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		lea	(LapBIrq).l,a0
		movea.l	arg_0(a6),a1
		move.l	a0,$3C(a1)
		move.l	$14(a4),d0
		moveq	#2,d1
		cmp.l	d1,d0
		bne.s	loc_52B8
		move.b	$1E(a4),d0
		moveq	#$60,d1	; '`'
		cmp.b	d1,d0
		bne.s	loc_52B8
		move.b	$1F(a4),d0
		moveq	#$11,d1
		cmp.b	d1,d0
		bne.s	loc_52B8
		move.l	-$D44(a5),d0
		sub.l	$76(a1),d0
		addq.l	#3,d0
		move.l	d0,$7A(a1)
		clr.w	d0
		move.w	d0,$54(a1)
		lea	(SendRRPoll).l,a0
		move.l	a0,$6A(a1)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		moveq	#$12,d0
		move.w	d0,-(sp)
		pea	-$8D8(a5)
		move.l	arg_4(a6),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		bra.s	loc_52FA
; ---------------------------------------------------------------------------

loc_52B8:				; CODE XREF: V110Irq+170j V110Irq+17Aj ...
		pea	(aOldX_leo+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a2
		move.b	#3,$13(a2)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$12,d0
		move.w	d0,-(sp)
		pea	-$8EA(a5)
		move.l	arg_4(a6),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp

loc_52FA:				; CODE XREF: V110Irq+E8j V110Irq+FCj ...
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,$14(a4)

loc_5304:				; CODE XREF: V110Irq+54j
		andi.w	#$FF3F,d5

loc_5308:				; CODE XREF: V110Irq+18j
		tst.w	d5
		beq.s	loc_5320
		move.w	d5,-(sp)
		move.l	arg_4(a6),-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	(PrintError).l
		lea	$A(sp),sp

loc_5320:				; CODE XREF: V110Irq+218j
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function V110Irq

; ---------------------------------------------------------------------------
aLeoprivateirq:	dc.b 141,'LeoPrivateIrq',0
aOldX_leo:	dc.b 10,'old x.leo',0   ; DATA XREF: V110Irq:loc_52B8o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

LeoPrivateIrq:

var_4		= -4
var_3		= -3
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3-d5/a2-a4,-(sp)
		move.w	arg_8(a6),d5
		movea.l	arg_0(a6),a0
		movea.l	$48(a0),a4
		cmpa.w	#0,a4
		beq.w	loc_573E
		move.w	d5,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_5390
		movea.l	a4,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		adda.l	$10(a4),a2
		addi.l	#$20,$10(a4) ; ' '
		moveq	#$1F,d0
		movea.l	a2,a1
		movea.l	arg_4(a6),a0

loc_5380:				; CODE XREF: LeoPrivateIrq+40j
		move.b	(a0),(a1)+
		dbf	d0,loc_5380
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)

loc_5390:				; CODE XREF: LeoPrivateIrq+22j
		move.w	d5,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_573A
		movea.l	a4,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		adda.l	$10(a4),a3
		movea.l	arg_4(a6),a2
		move.b	$5A(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$4A(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		andi.l	#$FFF,d0
		move.l	d0,$14(a4)
		move.w	d0,d4
		move.l	$10(a4),d0
		sub.w	d0,d4
		moveq	#$20,d3	; ' '
		cmp.w	d3,d4
		ble.s	loc_53DC
		move.w	d3,d4
		moveq	#0,d0
		move.l	d0,$14(a4)

loc_53DC:				; CODE XREF: LeoPrivateIrq+90j
		subq.l	#1,$14(a4)
		tst.w	d4
		ble.s	loc_53FE
		move.w	d4,d0
		subq.w	#1,d0
		movea.l	a3,a1
		movea.l	arg_4(a6),a0

loc_53EE:				; CODE XREF: LeoPrivateIrq+AEj
		move.b	(a0),(a1)+
		dbf	d0,loc_53EE
		move.b	-1(a1),d0
		move.b	d0,var_4(a6)
		bra.s	loc_5404
; ---------------------------------------------------------------------------

loc_53FE:				; CODE XREF: LeoPrivateIrq+A0j
		move.b	#$FF,var_4(a6)

loc_5404:				; CODE XREF: LeoPrivateIrq+BAj
		move.b	#$80,d0
		movea.l	arg_4(a6),a2
		move.b	d0,$42(a2)
		move.l	$14(a4),d3
		moveq	#0,d4
		cmp.l	d4,d3
		ble.s	loc_5428
		move.b	var_4(a6),d1
		andi.b	#$F0,d1
		cmpi.b	#$A0,d1
		beq.s	loc_5490

loc_5428:				; CODE XREF: LeoPrivateIrq+D6j
		cmp.l	d4,d3
		ble.s	loc_5482
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d1
		moveq	#$A,d2
		cmp.b	d2,d1
		bne.s	loc_5482
		move.b	$4E(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		asl.l	#8,d1
		moveq	#0,d2
		move.b	d0,d2
		moveq	#$10,d0
		asl.l	d0,d2
		add.l	d2,d1
		cmpa.l	-$DB4(a5),a2
		bne.s	loc_5460
		move.l	#$A0000000,d0
		bra.s	loc_5466
; ---------------------------------------------------------------------------

loc_5460:				; CODE XREF: LeoPrivateIrq+114j
		move.l	#$B0000000,d0

loc_5466:				; CODE XREF: LeoPrivateIrq+11Cj
		add.l	d0,d1
		move.b	var_4(a6),d2
		moveq	#0,d0
		move.b	d2,d0
		add.l	d0,d1
		move.l	d1,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5482:				; CODE XREF: LeoPrivateIrq+E8j
					; LeoPrivateIrq+FAj
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,$14(a4)
		bra.w	loc_573A
; ---------------------------------------------------------------------------

loc_5490:				; CODE XREF: LeoPrivateIrq+E4j
		move.b	$1F(a4),d0
		move.b	d0,var_3(a6)
		pea	(aReceivedFrame+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	a4,a2
		moveq	#$14,d0
		adda.l	d0,a2
		move.l	(a2),d0
		moveq	#$10,d1
		asl.l	d1,d0
		move.w	$1E(a4),d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	$1E(a4),d0
		moveq	#$60,d1	; '`'
		cmp.b	d1,d0
		bne.w	loc_55D4
		move.b	var_3(a6),d0
		bne.s	loc_54EA
		move.l	(a2),d0
		moveq	#2,d1
		cmp.l	d1,d0
		bgt.s	loc_54FE

loc_54EA:				; CODE XREF: LeoPrivateIrq+19Ej
		cmpi.b	#$11,var_3(a6)
		bne.w	loc_55D4
		move.l	(a2),d0
		moveq	#2,d1
		cmp.l	d1,d0
		bne.w	loc_55D4

loc_54FE:				; CODE XREF: LeoPrivateIrq+1A6j
		moveq	#3,d3
		movea.l	arg_0(a6),a3
		move.b	d3,$13(a3)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a3),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		ori.b	#3,$E(a3)
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,(a2)
		lea	(LapBIrq).l,a0
		move.l	a0,$3C(a3)
		cmpi.b	#$11,var_3(a6)
		bne.s	loc_558A
		moveq	#$12,d0
		move.w	d0,-(sp)
		pea	-$8D8(a5)
		move.l	arg_4(a6),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		pea	aSwitchToNew?Leo ; "Switch to (new?) Leo"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$20,$13(a3) ; ' '
		lea	(SendLeoSabm).l,a0
		move.l	a0,$6A(a3)
		move.l	arg_0(a6),$72(a3)
		moveq	#$2E,d0	; '.'
		move.l	d0,-(sp)
		moveq	#$66,d0	; 'f'
		adda.l	d0,a3
		move.l	a3,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_55B2
; ---------------------------------------------------------------------------

loc_558A:				; CODE XREF: LeoPrivateIrq+1F4j
		moveq	#$12,d0
		move.w	d0,-(sp)
		pea	-$8EA(a5)
		move.l	arg_4(a6),-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		pea	aSwitchToOldLeo	; "Switch to (old) Leo"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_55B2:				; CODE XREF: LeoPrivateIrq+246j
		move.b	var_3(a6),d0
		moveq	#$11,d3
		cmp.b	d3,d0
		bne.w	loc_573A
		move.b	d3,-(sp)
		moveq	#$60,d0	; '`'
		move.b	d0,-(sp)
		move.l	arg_4(a6),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_573A
; ---------------------------------------------------------------------------

loc_55D4:				; CODE XREF: LeoPrivateIrq+196j
					; LeoPrivateIrq+1AEj ...
		move.w	$1E(a4),d0
		andi.w	#$F1EF,d0
		cmpi.w	#$1AF,d0
		bne.s	loc_5608
		pea	aXid		; "XID"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.w	$1E(a4),d0
		andi.w	#$F1FF,d0
		cmpi.w	#$1BF,d0
		bne.w	loc_573A
		bra.w	loc_56B4
; ---------------------------------------------------------------------------

loc_5608:				; CODE XREF: LeoPrivateIrq+29Ej
		move.l	$14(a4),d0
		moveq	#2,d1
		cmp.l	d1,d0
		bne.w	loc_56CA
		move.w	$1E(a4),d1
		moveq	#0,d0
		move.w	d1,d0
		cmpi.l	#$13F,d0
		beq.s	loc_5640
		cmpi.l	#$73F,d0
		beq.s	loc_5698
		cmpi.l	#$17F,d0
		beq.s	loc_5698
		cmpi.l	#$77F,d0
		beq.s	loc_5698
		bra.w	loc_56CA
; ---------------------------------------------------------------------------

loc_5640:				; CODE XREF: LeoPrivateIrq+2E0j
		movea.l	arg_0(a6),a2
		move.b	#3,$13(a2)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a2,-(sp)
		jsr	(IgnoreIrq).l
		addq.w	#4,sp
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,$14(a4)
		pea	aSwitchToX75	; "Switch to X75"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$73,d0	; 's'
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	arg_4(a6),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_573A
; ---------------------------------------------------------------------------

loc_5698:				; CODE XREF: LeoPrivateIrq+2E8j
					; LeoPrivateIrq+2F0j ...
		moveq	#0,d0
		move.l	d0,$10(a4)
		move.l	d0,$14(a4)
		pea	aDenyMlpOrSabme	; "Deny	MLP or SABME"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_56B4:				; CODE XREF: LeoPrivateIrq+2C2j
		moveq	#$1F,d0
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	arg_4(a6),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.s	loc_573A
; ---------------------------------------------------------------------------

loc_56CA:				; CODE XREF: LeoPrivateIrq+2CEj
					; LeoPrivateIrq+2FAj
		movea.l	arg_0(a6),a2
		move.b	#3,$13(a2)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		ori.b	#2,$E(a2)
		move.l	a2,-(sp)
		jsr	(InitISAC).l
		addq.w	#4,sp
		lea	(AutomodeIrq).l,a0
		move.l	a0,$3C(a2)
		pea	aSwitchToHdlc	; "Switch to Hdlc"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a4,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a0
		move.l	$2C(a0),d0
		move.l	d0,4(a4)
		addq.w	#1,$58(a0)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_573A:				; CODE XREF: LeoPrivateIrq+54j
					; LeoPrivateIrq+14Aj ...
		andi.w	#$FF3F,d5

loc_573E:				; CODE XREF: LeoPrivateIrq+18j
		tst.w	d5
		beq.s	loc_5756
		move.w	d5,-(sp)
		move.l	arg_4(a6),-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	(PrintError).l
		lea	$A(sp),sp

loc_5756:				; CODE XREF: LeoPrivateIrq+3FEj
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function LeoPrivateIrq

; ---------------------------------------------------------------------------
aHuntirq:	dc.b 135,'HuntIrq',0
aReceivedFrame:	dc.b 110,'received frame',0,0 ; DATA XREF: LeoPrivateIrq+156o
aSwitchToNew?Leo:dc.b 'Switch to (new?) Leo',0,0 ; DATA XREF: LeoPrivateIrq+20Co
aSwitchToOldLeo:dc.b 'Switch to (old) Leo',0 ; DATA XREF: LeoPrivateIrq+25Eo
aXid:		dc.b 'XID',0            ; DATA XREF: LeoPrivateIrq+2A0o
aSwitchToX75:	dc.b 'Switch to X75',0  ; DATA XREF: LeoPrivateIrq+32Co
aDenyMlpOrSabme:dc.b 'Deny MLP or SABME',0 ; DATA XREF: LeoPrivateIrq+360o
aSwitchToHdlc:	dc.b 'Switch to Hdlc',0 ; DATA XREF: LeoPrivateIrq+3BCo
		dc.b   0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

HuntIrq:				; DATA XREF: startleo+98o
					; startleo+1A0o ...

var_24		= -$24
var_23		= -$23
var_22		= -$22
var_20		= -$20
var_1C		= -$1C
var_18		= -$18
var_17		= -$17
var_16		= -$16
var_14		= -$14
var_10		= -$10
var_C		= -$C
var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-$24
		movem.l	d3-d7/a2-a4,-(sp)
		move.w	arg_8(a6),d6
		movea.l	arg_0(a6),a2
		move.w	$56(a2),d5
		movea.l	$48(a2),a4
		move.w	d6,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_5850
		cmpa.w	#0,a4
		beq.s	loc_5834
		tst.w	$12(a4)
		bne.s	loc_5808
		moveq	#$FFFFFFFF,d0
		move.w	d0,$12(a4)

loc_5808:				; CODE XREF: HuntIrq+2Aj
		moveq	#$1F,d0
		movea.l	a4,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		move.w	$12(a4),d1
		ext.l	d1
		adda.l	d1,a1
		movea.l	arg_4(a6),a0

loc_581C:				; CODE XREF: HuntIrq+48j
		move.b	(a0),(a1)+
		dbf	d0,loc_581C
		addi.w	#$20,$12(a4) ; ' '
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)
		bra.s	loc_5850
; ---------------------------------------------------------------------------

loc_5834:				; CODE XREF: HuntIrq+24j
		movea.l	arg_4(a6),a0
		move.b	#$40,$42(a0) ; '@'
		pea	(aRpfRhr+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5850:				; CODE XREF: HuntIrq+1Ej HuntIrq+5Cj
		move.w	d6,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_5F30
		movea.l	arg_4(a6),a2
		move.b	$5A(a2),d0
		moveq	#0,d4
		move.b	d0,d4
		asl.w	#8,d4
		move.b	$4A(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		add.w	d0,d4
		andi.w	#$FFF,d4
		move.l	a4,d0
		beq.w	loc_5926
		tst.w	$12(a4)
		beq.w	loc_5926
		move.w	d4,d0
		subq.w	#2,d0
		move.w	d0,$16(a4)
		tst.w	d4
		bne.s	loc_58B0
		move.b	#$40,$42(a2) ; '@'
		pea	aEmptyFrame	; "empty frame"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.b	var_24(a6)
		bra.w	loc_5A16
; ---------------------------------------------------------------------------

loc_58B0:				; CODE XREF: HuntIrq+B8j
		move.w	d4,d0
		subq.w	#2,d0
		move.w	$12(a4),d3
		sub.w	d3,d0
		move.w	d0,d4
		moveq	#$1F,d1
		and.w	d1,d0
		cmp.w	d4,d0
		bne.s	loc_58E6
		move.w	d4,d0
		movea.l	a4,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		move.w	d3,d1
		ext.l	d1
		adda.l	d1,a1
		movea.l	arg_4(a6),a0

loc_58D6:				; CODE XREF: HuntIrq+102j
		move.b	(a0),(a1)+
		dbf	d0,loc_58D6
		move.b	-1(a1),d0
		move.b	d0,var_24(a6)
		bra.s	loc_5910
; ---------------------------------------------------------------------------

loc_58E6:				; CODE XREF: HuntIrq+ECj
		pea	aN1		; "n1"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.w	d4,d0
		ext.l	d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.b	var_24(a6)

loc_5910:				; CODE XREF: HuntIrq+10Ej
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)
		move.b	$1D(a4),d0
		move.b	d0,var_23(a6)
		bra.w	loc_5A16
; ---------------------------------------------------------------------------

loc_5926:				; CODE XREF: HuntIrq+A2j HuntIrq+AAj
		movea.l	arg_4(a6),a0
		move.b	(a0),d0
		move.b	d0,var_23(a6)
		moveq	#3,d1
		and.b	d1,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_5972
		cmpi.w	#2,d4
		bne.s	loc_594E
		movea.l	arg_4(a6),a0
		move.b	(a0),d0
		move.b	d0,var_24(a6)
		bra.w	loc_59EA
; ---------------------------------------------------------------------------

loc_594E:				; CODE XREF: HuntIrq+168j
		clr.b	var_24(a6)
		movea.l	arg_4(a6),a0
		move.b	#$40,$42(a0) ; '@'
		pea	aRmeRhrS	; "RME:RHR:S"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_5A16
; ---------------------------------------------------------------------------

loc_5972:				; CODE XREF: HuntIrq+162j
		move.l	a4,d0
		beq.w	loc_59F6
		cmpi.w	#2,d4
		blt.s	loc_59F6
		move.b	var_23(a6),$1D(a4)
		move.w	d4,d0
		subq.w	#2,d0
		move.w	d0,$16(a4)
		moveq	#$1F,d1
		move.w	d0,var_4(a6)
		and.w	d1,d0
		move.w	var_4(a6),d1
		cmp.w	d1,d0
		bne.s	loc_59C0
		move.w	d1,d0
		movea.l	a4,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		move.w	$12(a4),d1
		ext.l	d1
		adda.l	d1,a1
		movea.l	arg_4(a6),a0

loc_59B0:				; CODE XREF: HuntIrq+1DCj
		move.b	(a0),(a1)+
		dbf	d0,loc_59B0
		move.b	-1(a1),d0
		move.b	d0,var_24(a6)
		bra.s	loc_59EA
; ---------------------------------------------------------------------------

loc_59C0:				; CODE XREF: HuntIrq+1C4j
		pea	aN2		; "n2"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.w	d4,d0
		ext.l	d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.b	var_24(a6)

loc_59EA:				; CODE XREF: HuntIrq+174j HuntIrq+1E8j
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)
		bra.s	loc_5A16
; ---------------------------------------------------------------------------

loc_59F6:				; CODE XREF: HuntIrq+19Ej HuntIrq+1A6j
		clr.b	var_24(a6)
		movea.l	arg_4(a6),a0
		move.b	#$40,$42(a0) ; '@'
		pea	aRmeRhrUI	; "RME:RHR:U/I"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5A16:				; CODE XREF: HuntIrq+D6j HuntIrq+14Cj	...
		move.b	var_24(a6),d0
		andi.b	#$F0,d0
		cmpi.b	#$A0,d0
		beq.s	loc_5A96
		move.l	a4,d0
		beq.s	loc_5A32
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)

loc_5A32:				; CODE XREF: HuntIrq+250j
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.w	loc_5F30
		movea.l	arg_4(a6),a2
		move.b	$4E(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$42(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		cmpa.l	-$DB4(a5),a2
		bne.s	loc_5A70
		move.l	#$A0000000,d1
		bra.s	loc_5A76
; ---------------------------------------------------------------------------

loc_5A70:				; CODE XREF: HuntIrq+290j
		move.l	#$B0000000,d1

loc_5A76:				; CODE XREF: HuntIrq+298j
		add.l	d1,d0
		move.b	var_24(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5A96:				; CODE XREF: HuntIrq+24Cj
		move.b	var_23(a6),d3
		moveq	#3,d4
		and.b	d4,d3
		cmp.b	d4,d3
		bne.w	loc_5CE4
		move.b	var_23(a6),d1
		andi.b	#$EF,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_5AE6
		moveq	#$63,d1	; 'c'
		cmp.l	d1,d0
		beq.w	loc_5B62
		moveq	#$43,d1	; 'C'
		cmp.l	d1,d0
		beq.w	loc_5BAE
		moveq	#$2F,d1	; '/'
		cmp.l	d1,d0
		beq.w	loc_5BE8
		cmpi.l	#$87,d0	; '‡'
		beq.w	loc_5C66
		cmpi.l	#$AF,d0	; '¯'
		beq.w	loc_5CA4
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5AE6:				; CODE XREF: HuntIrq+2DEj
		pea	aUi_1		; "<- UI"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		tst.w	$16(a4)
		beq.s	loc_5B62
		move.b	-$DBA(a5),d0
		beq.s	loc_5B38
		movea.l	arg_0(a6),a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a4,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		moveq	#1,d0
		move.w	d0,$18(a4)
		movea.l	arg_0(a6),a0
		move.l	$2C(a0),d0
		move.l	d0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5B38:				; CODE XREF: HuntIrq+32Cj
		movea.l	arg_0(a6),a2
		move.b	$E(a2),d0
		moveq	#7,d1
		and.b	d1,d0
		moveq	#3,d3
		cmp.b	d3,d0
		bne.w	loc_5F30
		move.b	d3,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	$38(a2),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5B62:				; CODE XREF: HuntIrq+2E4j HuntIrq+326j
		pea	aUa		; "<- UA"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)
		movea.l	arg_0(a6),a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.b	$13(a0),d0
		moveq	#$35,d1	; '5'
		cmp.b	d1,d0
		beq.w	loc_5F30
		move.b	#3,$13(a0)
		move.w	#$4000,d5
		bra.w	loc_5C8C
; ---------------------------------------------------------------------------

loc_5BAE:				; CODE XREF: HuntIrq+2ECj
		pea	aDisc_1		; "<- DISC"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)
		movea.l	arg_0(a6),a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.b	#4,$13(a0)
		bra.s	loc_5C2C
; ---------------------------------------------------------------------------

loc_5BE8:				; CODE XREF: HuntIrq+2F4j
		pea	aSabm_3		; "<- SABM"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)
		movea.l	arg_0(a6),a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.b	$13(a0),d0
		moveq	#3,d3
		cmp.b	d3,d0
		beq.s	loc_5C40
		move.b	d3,$13(a0)
		move.w	#$4000,d5

loc_5C2C:				; CODE XREF: HuntIrq+410j
		move.l	arg_0(a6),-(sp)
		movea.l	arg_0(a6),a0
		move.l	$34(a0),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5C40:				; CODE XREF: HuntIrq+44Cj
		move.b	var_23(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		moveq	#$63,d1	; 'c'
		or.b	d1,d0
		move.b	d0,-(sp)
		moveq	#1,d0
		move.b	d0,-(sp)
		movea.l	arg_0(a6),a0
		move.l	$38(a0),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5C66:				; CODE XREF: HuntIrq+2FEj
		pea	aFrmr		; "<- FRMR"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)
		movea.l	arg_0(a6),a0
		move.b	#8,$13(a0)

loc_5C8C:				; CODE XREF: HuntIrq+3D4j
		move.l	arg_0(a6),-(sp)
		movea.l	arg_0(a6),a0
		move.l	$34(a0),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5CA4:				; CODE XREF: HuntIrq+308j
		pea	aXid_1		; "<- XID"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)
		move.b	var_23(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		moveq	#$F,d1
		or.b	d1,d0
		move.b	d0,-(sp)
		move.b	d4,-(sp)
		movea.l	arg_0(a6),a0
		move.l	$38(a0),-(sp)
		jsr	(ListenHscx).l
		addq.w	#8,sp
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5CE4:				; CODE XREF: HuntIrq+2CAj
		move.b	var_23(a6),d0
		andi.b	#$E0,d0
		rol.b	#4,d0
		move.b	d0,var_22(a6)
		movea.l	arg_0(a6),a2
		movea.l	$40(a2),a3
		move.b	$62(a2),d3
		move.b	$63(a2),d4
		cmp.b	d4,d3
		bhi.s	loc_5D0E
		cmp.b	d0,d3
		bhi.s	loc_5D0E
		cmp.b	d0,d4
		bcc.s	loc_5D18

loc_5D0E:				; CODE XREF: HuntIrq+52Ej HuntIrq+532j
		cmp.b	d0,d4
		bcc.s	loc_5D18
		cmp.b	d0,d3
		bhi.w	loc_5DA6

loc_5D18:				; CODE XREF: HuntIrq+536j HuntIrq+53Aj
		bra.s	loc_5D5A
; ---------------------------------------------------------------------------

loc_5D1A:				; CODE XREF: HuntIrq+5B0j
		move.l	(a3),d0
		move.l	d0,var_20(a6)
		tst.w	$18(a3)
		bne.s	loc_5D54
		move.b	$1A(a3),d0
		movea.l	var_14(a6),a0
		move.b	d0,(a0)
		movea.l	var_10(a6),a0
		movea.l	(a0),a0
		cmpa.l	a3,a0
		bne.s	loc_5D42
		move.b	#$FF,$1B(a3)
		bra.s	loc_5D4E
; ---------------------------------------------------------------------------

loc_5D42:				; CODE XREF: HuntIrq+562j
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp

loc_5D4E:				; CODE XREF: HuntIrq+56Aj
		movea.l	var_C(a6),a0
		clr.b	(a0)

loc_5D54:				; CODE XREF: HuntIrq+54Ej
		movea.l	var_20(a6),a3
		bra.s	loc_5D7A
; ---------------------------------------------------------------------------

loc_5D5A:				; CODE XREF: HuntIrq:loc_5D18j
		moveq	#$62,d0	; 'b'
		adda.l	d0,a2
		move.l	a2,var_14(a6)
		movea.l	arg_0(a6),a0
		moveq	#$50,d0	; 'P'
		adda.l	d0,a0
		move.l	a0,var_10(a6)
		movea.l	arg_0(a6),a0
		moveq	#$61,d0	; 'a'
		adda.l	d0,a0
		move.l	a0,var_C(a6)

loc_5D7A:				; CODE XREF: HuntIrq+582j
		move.l	a3,d0
		beq.s	loc_5D88
		move.b	$1A(a3),d0
		cmp.b	var_22(a6),d0
		bne.s	loc_5D1A

loc_5D88:				; CODE XREF: HuntIrq+5A6j
		movea.l	arg_4(a6),a0
		move.b	#$10,$46(a0)
		andi.w	#$EFFF,d5
		movea.l	arg_0(a6),a0
		tst.l	$40(a0)
		beq.s	loc_5DD2
		ori.w	#$800,d5
		bra.s	loc_5DD2
; ---------------------------------------------------------------------------

loc_5DA6:				; CODE XREF: HuntIrq+53Ej
		pea	aNRError	; "N(R)	error"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a2
		move.b	#8,$13(a2)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5DD2:				; CODE XREF: HuntIrq+5C8j HuntIrq+5CEj
		move.b	var_23(a6),d3
		moveq	#$10,d4
		and.b	d4,d3
		moveq	#0,d0
		move.b	d3,d0
		move.b	var_23(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.w	loc_5E7A
		move.b	var_23(a6),d1
		moveq	#$C,d2
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#4,d1
		cmp.l	d1,d0
		beq.s	loc_5E04
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_5E0A
		bra.s	loc_5E2E
; ---------------------------------------------------------------------------

loc_5E04:				; CODE XREF: HuntIrq+624j
		ori.w	#4,d5
		bra.s	loc_5E32
; ---------------------------------------------------------------------------

loc_5E0A:				; CODE XREF: HuntIrq+62Aj
		andi.w	#$FFFB,d5
		move.w	d5,d0
		moveq	#8,d1
		and.w	d1,d0
		bne.s	loc_5E32
		movea.l	arg_0(a6),a0
		move.b	var_22(a6),$63(a0)
		andi.w	#$EFFF,d5
		movea.l	arg_4(a6),a0
		move.b	d4,$46(a0)
		bra.s	loc_5E32
; ---------------------------------------------------------------------------

loc_5E2E:				; CODE XREF: HuntIrq+62Cj
		andi.w	#$FFFB,d5

loc_5E32:				; CODE XREF: HuntIrq+632j HuntIrq+63Ej ...
		move.b	var_23(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.w	loc_5F30
		move.b	var_24(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_5E50
		ori.w	#$20,d5	; ' '
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5E50:				; CODE XREF: HuntIrq+670j
		movea.l	arg_0(a6),a0
		move.b	var_22(a6),$63(a0)
		movea.l	arg_4(a6),a0
		move.b	#$10,$46(a0)
		andi.w	#$EFF7,d5
		move.w	d5,d0
		moveq	#4,d1
		and.w	d1,d0
		beq.w	loc_5F30
		ori.w	#$800,d5
		bra.w	loc_5F30
; ---------------------------------------------------------------------------

loc_5E7A:				; CODE XREF: HuntIrq+610j
		move.b	var_23(a6),d0
		move.b	d4,d1
		and.b	d1,d0
		beq.s	loc_5E92
		move.b	var_24(a6),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_5E92
		ori.w	#$20,d5	; ' '

loc_5E92:				; CODE XREF: HuntIrq+6ACj HuntIrq+6B6j
		move.l	a4,d0
		beq.s	loc_5F04
		move.b	var_23(a6),d0
		moveq	#$E,d1
		and.b	d1,d0
		movea.l	arg_0(a6),a0
		move.b	$60(a0),d1
		cmp.b	d1,d0
		bne.s	loc_5F04
		ori.w	#$40,d5	; '@'
		andi.w	#$FFFE,d5
		movea.l	arg_0(a6),a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a4,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a0
		addq.w	#1,$58(a0)
		move.l	$2C(a0),d0
		move.l	d0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.b	$60(a0),d0
		addq.b	#2,d0
		moveq	#$E,d1
		and.b	d1,d0
		move.b	d0,$60(a0)
		movea.l	$48(a0),a1
		movea.l	$4C(a0),a0
		cmpa.l	a0,a1
		bne.s	loc_5F30
		ori.w	#2,d5
		bra.s	loc_5F30
; ---------------------------------------------------------------------------

loc_5F04:				; CODE XREF: HuntIrq+6BEj HuntIrq+6D2j
		move.l	a4,d0
		beq.s	loc_5F12
		clr.w	d0
		move.w	d0,$12(a4)
		move.w	d0,$16(a4)

loc_5F12:				; CODE XREF: HuntIrq+730j
		move.w	d5,d0
		moveq	#$23,d1	; '#'
		and.w	d1,d0
		bne.s	loc_5F30
		ori.w	#$2001,d5
		pea	aForcingReject	; "forcing reject"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_5F30:				; CODE XREF: HuntIrq+80j HuntIrq+26Cj	...
		move.w	d6,d0
		moveq	#8,d1
		and.w	d1,d0
		beq.s	loc_5F68
		andi.w	#$EFFF,d5
		move.w	d5,d0
		moveq	#4,d1
		and.w	d1,d0
		bne.s	loc_5F56
		movea.l	arg_0(a6),a0
		move.b	$61(a0),d0
		addq.b	#1,$61(a0)
		moveq	#8,d1
		cmp.b	d1,d0
		bcc.s	loc_5F5C

loc_5F56:				; CODE XREF: HuntIrq+76Cj
		ori.w	#$18,d5
		bra.s	loc_5F68
; ---------------------------------------------------------------------------

loc_5F5C:				; CODE XREF: HuntIrq+77Ej
		move.l	arg_0(a6),-(sp)
		jsr	(TransmitDone).l
		addq.w	#4,sp

loc_5F68:				; CODE XREF: HuntIrq+760j HuntIrq+784j
		movea.l	arg_0(a6),a0
		movea.l	$50(a0),a4
		move.w	d6,d0
		andi.w	#$4000,d0
		beq.s	loc_5F8A
		cmpa.w	#0,a4
		beq.s	loc_5F8A
		move.w	$16(a4),d0
		move.w	d0,$12(a4)
		ori.w	#$10,d6

loc_5F8A:				; CODE XREF: HuntIrq+7A0j HuntIrq+7A6j
		move.w	d6,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_6040
		move.l	a4,d0
		beq.s	loc_5FF6
		move.w	$12(a4),d0
		move.w	$16(a4),d1
		cmp.w	d1,d0
		beq.s	loc_5FF6

loc_5FA4:				; CODE XREF: HuntIrq+902j
		movea.l	a4,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.w	$12(a4),d3
		move.w	d3,d0
		ext.l	d0
		adda.l	d0,a2
		move.l	a2,var_1C(a6)
		move.b	#8,var_18(a6)
		move.w	$16(a4),d7
		sub.w	d3,d7
		moveq	#$20,d3	; ' '
		cmp.w	d3,d7
		ble.s	loc_5FCE
		move.w	d3,d7
		bra.s	loc_5FD4
; ---------------------------------------------------------------------------

loc_5FCE:				; CODE XREF: HuntIrq+7F2j
		move.b	#$A,var_18(a6)

loc_5FD4:				; CODE XREF: HuntIrq+7F6j
		add.w	d7,$12(a4)
		move.w	d7,d0
		subq.w	#1,d0
		movea.l	arg_4(a6),a1
		movea.l	var_1C(a6),a0

loc_5FE4:				; CODE XREF: HuntIrq+810j
		move.b	(a0)+,(a1)
		dbf	d0,loc_5FE4
		movea.l	arg_4(a6),a0
		move.b	var_18(a6),$42(a0)
		bra.s	loc_6040
; ---------------------------------------------------------------------------

loc_5FF6:				; CODE XREF: HuntIrq+7C0j HuntIrq+7CCj
		move.l	a4,d0
		beq.s	loc_6016
		tst.w	$18(a4)
		bne.s	loc_6006
		tst.b	$1B(a4)
		beq.s	loc_6016

loc_6006:				; CODE XREF: HuntIrq+828j
		clr.b	$1B(a4)
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp

loc_6016:				; CODE XREF: HuntIrq+822j HuntIrq+82Ej
		andi.w	#$FDFF,d5
		move.w	d5,d0
		andi.w	#$800,d0
		beq.s	loc_6040
		andi.w	#$F7FF,d5
		move.w	d5,d0
		andi.w	#$1000,d0
		bne.s	loc_6040
		ori.w	#$1000,d5
		moveq	#$10,d3
		movea.l	arg_4(a6),a2
		move.b	d3,$46(a2)
		move.b	d3,$42(a2)

loc_6040:				; CODE XREF: HuntIrq+7BAj HuntIrq+81Ej ...
		move.w	d5,d3
		andi.w	#$200,d3
		bne.w	loc_61B8
		move.w	d5,d0
		andi.w	#$203C,d0
		bne.w	loc_60E6
		movea.l	arg_0(a6),a0
		movea.l	$40(a0),a4
		bra.s	loc_6060
; ---------------------------------------------------------------------------

loc_605E:				; CODE XREF: HuntIrq+8A2j
		movea.l	(a4),a4

loc_6060:				; CODE XREF: HuntIrq+886j
		move.l	a4,d0
		beq.s	loc_607A
		tst.w	$18(a4)
		bne.s	loc_607A
		move.b	$1A(a4),d0
		movea.l	arg_0(a6),a0
		move.b	$63(a0),d1
		cmp.b	d1,d0
		bne.s	loc_605E

loc_607A:				; CODE XREF: HuntIrq+88Cj HuntIrq+892j
		move.l	a4,d0
		beq.s	loc_60DC
		moveq	#$FFFFFFFE,d0
		move.w	d0,$12(a4)
		movea.l	arg_0(a6),a0
		move.b	$64(a0),d0
		move.b	d0,$1C(a4)
		tst.w	$18(a4)
		beq.s	loc_60A8
		move.b	#$FF,$1A(a4)
		move.b	#3,$1D(a4)
		ori.w	#$200,d5
		bra.s	loc_60D0
; ---------------------------------------------------------------------------

loc_60A8:				; CODE XREF: HuntIrq+8BEj
		movea.l	arg_0(a6),a2
		move.b	$60(a2),d0
		rol.b	#4,d0
		add.b	$1A(a4),d0
		move.b	d0,$1D(a4)
		ori.w	#$A00,d5
		andi.w	#$FFBF,d5
		move.b	$63(a2),d0
		addq.b	#2,d0
		moveq	#$E,d1
		and.b	d1,d0
		move.b	d0,$63(a2)

loc_60D0:				; CODE XREF: HuntIrq+8D0j
		movea.l	arg_0(a6),a0
		move.l	a4,$50(a0)
		bra.w	loc_5FA4
; ---------------------------------------------------------------------------

loc_60DC:				; CODE XREF: HuntIrq+8A6j
		moveq	#0,d0
		movea.l	arg_0(a6),a0
		move.l	d0,$50(a0)

loc_60E6:				; CODE XREF: HuntIrq+87Aj
		move.w	d5,d3
		moveq	#4,d0
		and.w	d0,d3
		beq.s	loc_6104
		move.w	d5,d0
		seq	d0
		neg.b	d0
		ext.w	d0
		ext.l	d0
		andi.l	#$1000,d0
		beq.s	loc_6104
		ori.w	#$10,d5

loc_6104:				; CODE XREF: HuntIrq+916j HuntIrq+928j
		move.w	d5,d3
		andi.w	#$2070,d3
		beq.w	loc_61B8
		movea.l	arg_0(a6),a0
		move.b	$65(a0),d0
		move.b	d0,var_17(a6)
		move.b	#$10,var_16(a6)
		moveq	#$FFFFFFBF,d3
		move.w	d5,d0
		moveq	#$20,d1	; ' '
		and.w	d1,d0
		beq.s	loc_613E
		move.w	d5,d0
		andi.w	#$2000,d0
		beq.s	loc_6138
		move.b	#$18,var_16(a6)

loc_6138:				; CODE XREF: HuntIrq+95Aj
		move.w	#$DF9F,d3
		bra.s	loc_617A
; ---------------------------------------------------------------------------

loc_613E:				; CODE XREF: HuntIrq+952j
		move.w	d5,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.s	loc_615A
		moveq	#$FFFFFFAF,d3
		ori.w	#$800,d5
		movea.l	arg_0(a6),a0
		move.b	$64(a0),d0
		move.b	d0,var_17(a6)
		bra.s	loc_617A
; ---------------------------------------------------------------------------

loc_615A:				; CODE XREF: HuntIrq+96Ej
		move.w	d5,d0
		andi.w	#$2000,d0
		beq.s	loc_616E
		move.w	#$DFBF,d3

loc_6166:
		move.b	#8,var_16(a6)
		bra.s	loc_617A
; ---------------------------------------------------------------------------

loc_616E:				; CODE XREF: HuntIrq+98Aj
		move.w	d5,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_617A
		clr.b	var_16(a6)

loc_617A:				; CODE XREF: HuntIrq+966j HuntIrq+982j ...
		movea.l	arg_4(a6),a2
		move.b	var_17(a6),(a2)
		movea.l	arg_0(a6),a3
		move.b	$60(a3),d0
		rol.b	#4,d0
		move.w	d5,d1
		moveq	#2,d2
		and.w	d2,d1
		beq.s	loc_6198
		moveq	#5,d1
		bra.s	loc_619A
; ---------------------------------------------------------------------------

loc_6198:				; CODE XREF: HuntIrq+9BCj
		moveq	#1,d1

loc_619A:				; CODE XREF: HuntIrq+9C0j
		add.b	d1,d0
		add.b	var_16(a6),d0
		move.b	d0,(a2)
		move.b	#$A,$42(a2)
		move.w	d5,d0
		and.w	d3,d0
		ori.w	#$200,d0
		move.w	d0,d5
		moveq	#0,d0
		move.l	d0,$50(a3)

loc_61B8:				; CODE XREF: HuntIrq+870j HuntIrq+934j
		movea.l	arg_0(a6),a0
		move.w	d5,$56(a0)
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function HuntIrq

; ---------------------------------------------------------------------------
aLapbirq:	dc.b 135,'LapBIrq',0
aRpfRhr:	dc.b 122,'RPF:RHR',0    ; DATA XREF: HuntIrq+68o
aEmptyFrame:	dc.b 'empty frame',0    ; DATA XREF: HuntIrq+C0o
aN1:		dc.b 'n1',0,0           ; DATA XREF: HuntIrq:loc_58E6o
aRmeRhrS:	dc.b 'RME:RHR:S',0      ; DATA XREF: HuntIrq+186o
aN2:		dc.b 'n2',0,0           ; DATA XREF: HuntIrq:loc_59C0o
aRmeRhrUI:	dc.b 'RME:RHR:U/I',0    ; DATA XREF: HuntIrq+22Eo
aUi_1:		dc.b '<- UI',0          ; DATA XREF: HuntIrq:loc_5AE6o
aUa:		dc.b '<- UA',0          ; DATA XREF: HuntIrq:loc_5B62o
aDisc_1:	dc.b '<- DISC',0        ; DATA XREF: HuntIrq:loc_5BAEo
aSabm_3:	dc.b '<- SABM',0        ; DATA XREF: HuntIrq:loc_5BE8o
aFrmr:		dc.b '<- FRMR',0        ; DATA XREF: HuntIrq:loc_5C66o
aXid_1:		dc.b '<- XID',0,0       ; DATA XREF: HuntIrq:loc_5CA4o
aNRError:	dc.b 'N(R) error',0,0   ; DATA XREF: HuntIrq:loc_5DA6o
aForcingReject:	dc.b 'forcing reject',0,0 ; DATA XREF: HuntIrq+748o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

LapBIrq:				; DATA XREF: V110Irq+15Ao
					; LeoPrivateIrq+1E4o

var_20		= -$20
var_1C		= -$1C
var_18		= -$18
var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-$20
		movem.l	d3-d7/a2-a4,-(sp)
		movea.l	arg_4(a6),a4
		move.w	arg_8(a6),d4
		movea.l	arg_0(a6),a2
		move.l	$40(a2),d0
		move.l	d0,var_20(a6)
		move.b	$42(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		move.b	d0,var_18(a6)
		move.l	$48(a2),d0
		move.l	d0,var_1C(a6)
		tst.l	d0
		beq.w	loc_6590
		move.w	d4,d0
		andi.w	#$C0,d0	; 'À'
		beq.s	loc_62AE
		movea.l	var_1C(a6),a0
		tst.l	(a0)
		bne.s	loc_62AE
		move.b	var_18(a6),d0
		bne.s	loc_62AE
		move.b	#$20,var_18(a6)	; ' '
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_62AE
		move.b	#$F0,$46(a4)

loc_62AE:				; CODE XREF: LapBIrq+3Cj LapBIrq+44j ...
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_62F0
		movea.l	var_1C(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_1C(a6),a0
		adda.l	$10(a0),a2
		subq.w	#1,a2
		move.l	a2,var_14(a6)
		moveq	#$20,d6	; ' '
		move.w	d6,d0
		ext.l	d0
		add.l	d0,$10(a0)
		move.w	d6,d0
		subq.w	#1,d0
		movea.l	a2,a1
		movea.l	a4,a0

loc_62DE:				; CODE XREF: LapBIrq+94j
		move.b	(a0),(a1)+
		dbf	d0,loc_62DE
		move.b	var_18(a6),d0
		addi.b	#-$80,d0
		move.b	d0,$42(a4)

loc_62F0:				; CODE XREF: LapBIrq+68j
		move.w	d4,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_65AA
		movea.l	var_1C(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_1C(a6),a0
		adda.l	$10(a0),a2
		subq.w	#1,a2
		move.l	a2,var_C(a6)
		move.b	$5A(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$4A(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		andi.l	#$FFF,d0
		move.l	d0,$14(a0)
		move.w	d0,d7
		move.l	$10(a0),d0
		sub.w	d0,d7
		subq.l	#2,$14(a0)
		move.w	d7,d0
		subq.w	#1,d0
		movea.l	a2,a1
		movea.l	a4,a0

loc_6342:				; CODE XREF: LapBIrq+F8j
		move.b	(a0),(a1)+
		dbf	d0,loc_6342
		move.b	-1(a1),d0
		move.b	d0,var_10(a6)
		move.l	var_20(a6),d0
		beq.s	loc_6378
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_6378
		movea.l	var_20(a6),a0
		tst.l	$10(a0)
		bne.s	loc_6378
		move.b	var_18(a6),d0
		addi.b	#-$70,d0
		move.b	d0,$42(a4)
		bra.s	loc_6384
; ---------------------------------------------------------------------------

loc_6378:				; CODE XREF: LapBIrq+108j LapBIrq+112j ...
		move.b	var_18(a6),d0
		addi.b	#-$80,d0
		move.b	d0,$42(a4)

loc_6384:				; CODE XREF: LapBIrq+12Aj
		move.b	var_10(a6),d3
		andi.b	#$F0,d3
		cmpi.b	#$A0,d3
		beq.w	loc_6412
		moveq	#0,d0
		movea.l	var_1C(a6),a2
		move.l	d0,$10(a2)
		move.l	d0,$14(a2)
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_63FC
		move.b	$4E(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$42(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		cmpa.l	-$DB4(a5),a4
		bne.s	loc_63DA
		move.l	#$A0000000,d1
		bra.s	loc_63E0
; ---------------------------------------------------------------------------

loc_63DA:				; CODE XREF: LapBIrq+184j
		move.l	#$B0000000,d1

loc_63E0:				; CODE XREF: LapBIrq+18Cj
		add.l	d1,d0
		move.b	var_10(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_63FC:				; CODE XREF: LapBIrq+166j
		move.b	var_18(a6),d0
		beq.w	loc_65AA
		clr.b	d3
		move.b	d3,var_18(a6)
		move.b	d3,$42(a4)
		bra.w	loc_65AA
; ---------------------------------------------------------------------------

loc_6412:				; CODE XREF: LapBIrq+144j
		movea.l	var_1C(a6),a0
		move.b	$1D(a0),d0
		moveq	#1,d1
		and.b	d1,d0
		bne.w	loc_64BC
		movea.l	arg_0(a6),a2
		move.b	$13(a2),d0
		moveq	#$16,d1
		cmp.b	d1,d0
		bne.s	loc_6452
		movea.l	8(a2),a0
		move.b	4(a0),d0
		andi.b	#$80,d0
		beq.s	loc_6452
		pea	(a2ndChannelFailed+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_64A2
; ---------------------------------------------------------------------------

loc_6452:				; CODE XREF: LapBIrq+1E2j LapBIrq+1F0j
		movea.l	arg_0(a6),a2
		move.b	$13(a2),d0
		moveq	#$20,d1	; ' '
		cmp.b	d1,d0
		bne.s	loc_64BC
		movea.l	8(a2),a0
		move.b	4(a0),d0
		andi.b	#$80,d0
		beq.s	loc_64BC
		pea	aPeerIsOldX_leo	; "peer	is old x.leo"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#6,d0
		move.w	d0,-(sp)
		pea	-$8C6(a5)
		move.l	a4,-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_64A2:				; CODE XREF: LapBIrq+204j
		movea.l	arg_0(a6),a2
		move.b	#3,$13(a2)
		move.l	arg_0(a6),-(sp)
		move.l	$34(a2),-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_64BC:				; CODE XREF: LapBIrq+1D2j LapBIrq+212j ...
		movea.l	arg_0(a6),a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	var_1C(a6),-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		movea.l	var_1C(a6),a0
		move.b	$1D(a0),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_64EE
		lea	(startleo).l,a1
		move.l	a1,4(a0)
		bra.w	loc_6572
; ---------------------------------------------------------------------------

loc_64EE:				; CODE XREF: LapBIrq+292j
		movea.l	arg_0(a6),a2
		moveq	#$58,d1	; 'X'
		adda.l	d1,a2
		move.w	(a2),d1
		moveq	#7,d2
		and.w	d2,d1
		moveq	#0,d0
		move.w	d1,d0
		movea.l	var_1C(a6),a3
		move.b	$1D(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		asr.l	#1,d1
		moveq	#7,d2
		and.w	d2,d1
		move.w	d1,var_8(a6)
		ext.l	d1
		cmp.l	d1,d0
		beq.s	loc_655E
		pea	aHdlcOutOfSequenceModifyingCount ; "hdlc out of	sequence, modifying counter"...
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.w	(a2),d1
		moveq	#0,d0
		move.w	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		move.b	$1D(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.w	(a2),d0
		andi.w	#$FFF8,d0
		add.w	var_8(a6),d0
		move.w	d0,(a2)

loc_655E:				; CODE XREF: LapBIrq+2CEj
		movea.l	arg_0(a6),a2
		addq.w	#1,$58(a2)
		move.l	$2C(a2),d0
		movea.l	var_1C(a6),a0
		move.l	d0,4(a0)

loc_6572:				; CODE XREF: LapBIrq+29Ej
		move.l	var_1C(a6),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		tst.l	$48(a0)
		bne.s	loc_65AA
		move.b	#$C0,$40(a4)
		bra.s	loc_65AA
; ---------------------------------------------------------------------------

loc_6590:				; CODE XREF: LapBIrq+32j
		move.w	d4,d0
		andi.w	#$C0,d0	; 'À'
		beq.s	loc_65AA
		pea	aRecmsgNilAuto	; "recmsg nil (auto)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_65AA:				; CODE XREF: LapBIrq+AAj LapBIrq+1B4j	...
		move.l	var_20(a6),d0
		beq.w	loc_6764
		movea.l	arg_0(a6),a0
		move.b	$13(a0),d3
		moveq	#3,d0
		cmp.b	d0,d3
		beq.s	loc_65C8
		moveq	#6,d0
		cmp.b	d0,d3
		bne.w	loc_6764

loc_65C8:				; CODE XREF: LapBIrq+372j
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_6608
		movea.l	arg_0(a6),a2
		addq.w	#1,$54(a2)
		move.w	$54(a2),d0
		moveq	#5,d1
		cmp.w	d1,d0
		bne.s	loc_65F0
		move.l	a2,-(sp)
		jsr	(TransmitDone).l
		addq.w	#4,sp
		bra.w	loc_677E
; ---------------------------------------------------------------------------

loc_65F0:				; CODE XREF: LapBIrq+394j
		moveq	#0,d0
		movea.l	var_20(a6),a0
		move.l	d0,$10(a0)
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_6608
		ori.w	#$10,d4

loc_6608:				; CODE XREF: LapBIrq+382j LapBIrq+3B6j
		move.w	d4,d0
		moveq	#$20,d1	; ' '
		and.w	d1,d0
		beq.s	loc_6634
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_6634
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_662A
		move.b	#$F0,$46(a4)

loc_662A:				; CODE XREF: LapBIrq+3D6j
		movea.l	var_20(a6),a0
		tst.l	$10(a0)
		beq.s	loc_669E

loc_6634:				; CODE XREF: LapBIrq+3C2j LapBIrq+3CCj
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_677E
		movea.l	var_20(a6),a2
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bne.s	loc_669E
		move.b	#$F0,$46(a4)
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.l	$40(a0),d0
		move.l	d0,var_20(a6)
		tst.l	d0
		beq.w	loc_677E
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_669E
		movea.l	$48(a0),a2
		cmpa.w	#0,a2
		beq.s	loc_668E
		tst.l	$10(a2)
		bne.w	loc_677E

loc_668E:				; CODE XREF: LapBIrq+438j
		move.b	var_18(a6),d0
		moveq	#$10,d1
		add.b	d1,d0
		move.b	d0,$42(a4)
		bra.w	loc_677E
; ---------------------------------------------------------------------------

loc_669E:				; CODE XREF: LapBIrq+3E6j LapBIrq+400j ...
		movea.l	var_20(a6),a0
		tst.l	$10(a0)
		bne.s	loc_66C8
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_66C8
		pea	aXpr_peer_rnr	; "XPR_peer_RNR"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_677E
; ---------------------------------------------------------------------------

loc_66C8:				; CODE XREF: LapBIrq+45Aj LapBIrq+464j
		movea.l	var_20(a6),a2
		tst.l	$10(a2)
		bne.s	loc_66EA
		tst.w	$18(a2)
		beq.s	loc_66EA
		moveq	#$FFFFFFFE,d0
		move.l	d0,$10(a2)
		move.b	#$60,$1C(a2) ; '`'
		move.b	#3,$1D(a2)

loc_66EA:				; CODE XREF: LapBIrq+484j LapBIrq+48Aj
		movea.l	var_20(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_20(a6),a0
		move.l	$10(a0),d3
		adda.l	d3,a2
		move.l	a2,var_4(a6)
		move.l	$14(a0),d0
		move.w	d0,d5
		sub.w	d3,d5
		moveq	#$20,d3	; ' '
		cmp.w	d3,d5
		ble.s	loc_6710
		move.w	d3,d5

loc_6710:				; CODE XREF: LapBIrq+4C0j
		movea.l	var_20(a6),a2
		move.w	d5,d3
		move.w	d3,d0
		ext.l	d0
		add.l	d0,$10(a2)
		move.w	d3,d0
		subq.w	#1,d0
		movea.l	a4,a1
		movea.l	var_4(a6),a0

loc_6728:				; CODE XREF: LapBIrq+4DEj
		move.b	(a0)+,(a1)
		dbf	d0,loc_6728
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bne.s	loc_674A
		addq.b	#2,var_18(a6)
		tst.w	$18(a2)
		bne.s	loc_674A
		move.b	#$70,$46(a4) ; 'p'

loc_674A:				; CODE XREF: LapBIrq+4ECj LapBIrq+4F6j
		movea.l	var_20(a6),a0
		tst.w	$18(a0)
		beq.s	loc_6758
		moveq	#8,d0
		bra.s	loc_675A
; ---------------------------------------------------------------------------

loc_6758:				; CODE XREF: LapBIrq+506j
		moveq	#4,d0

loc_675A:				; CODE XREF: LapBIrq+50Aj
		add.b	var_18(a6),d0
		move.b	d0,$42(a4)
		bra.s	loc_677E
; ---------------------------------------------------------------------------

loc_6764:				; CODE XREF: LapBIrq+362j LapBIrq+378j
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_677E
		pea	aSendmsgNilAuto	; "sendmsg nil (auto)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_677E:				; CODE XREF: LapBIrq+3A0j LapBIrq+3EEj ...
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function LapBIrq

; ---------------------------------------------------------------------------
aAutomodeirq:	dc.b 139,'AutomodeIrq',0
a2ndChannelFailed:dc.b 132,'2nd channel failed',0,0 ; DATA XREF: LapBIrq+1F2o
aPeerIsOldX_leo:dc.b 'peer is old x.leo',0 ; DATA XREF: LapBIrq+222o
aHdlcOutOfSequenceModifyingCount:dc.b 7,'hdlc out of sequence, modifying counter',0,0
					; DATA XREF: LapBIrq+2D0o
aRecmsgNilAuto:	dc.b 'recmsg nil (auto)',0 ; DATA XREF: LapBIrq+34Co
aXpr_peer_rnr:	dc.b 'XPR_peer_RNR',0,0 ; DATA XREF: LapBIrq+466o
aSendmsgNilAuto:dc.b 'sendmsg nil (auto)',0,0 ; DATA XREF: LapBIrq+520o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AutomodeIrq:				; DATA XREF: LeoPrivateIrq+3B2o

var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-$14
		movem.l	d3-d7/a2-a4,-(sp)
		move.w	arg_8(a6),d4
		movea.l	arg_0(a6),a0
		move.l	$48(a0),d0
		move.l	d0,var_14(a6)
		tst.l	d0
		beq.w	loc_699E
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.s	loc_6876
		movea.l	var_14(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_14(a6),a0
		adda.l	$10(a0),a2
		move.l	a2,var_10(a6)
		moveq	#$20,d6	; ' '
		move.w	d6,d0
		ext.l	d0
		add.l	d0,$10(a0)
		move.w	d6,d0
		subq.w	#1,d0
		movea.l	a2,a1
		movea.l	arg_4(a6),a0

loc_6866:				; CODE XREF: AutomodeIrq+50j
		move.b	(a0),(a1)+
		dbf	d0,loc_6866
		movea.l	arg_4(a6),a0
		move.b	#$80,$42(a0)

loc_6876:				; CODE XREF: AutomodeIrq+24j
		move.w	d4,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_69B8
		movea.l	var_14(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_14(a6),a3
		moveq	#$10,d0
		adda.l	d0,a3
		adda.l	(a3),a2
		move.l	a2,var_8(a6)
		movea.l	arg_4(a6),a4
		move.b	$5A(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#8,d3
		asl.l	d3,d0
		move.b	$4A(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		andi.l	#$FFF,d0
		movea.l	var_14(a6),a2
		moveq	#$14,d1
		adda.l	d1,a2
		move.l	d0,(a2)
		move.w	d0,d7
		move.l	(a3),d0
		sub.w	d0,d7
		subq.l	#1,(a2)
		move.w	d7,d0
		subq.w	#1,d0
		movea.l	var_8(a6),a1
		movea.l	a4,a0

loc_68D2:				; CODE XREF: AutomodeIrq+BCj
		move.b	(a0),(a1)+
		dbf	d0,loc_68D2
		move.b	-1(a1),d0
		move.b	d0,var_C(a6)
		move.b	#$80,$42(a4)
		andi.b	#$F0,d0
		cmpi.b	#$A0,d0
		beq.s	loc_6954
		moveq	#0,d0
		move.l	d0,(a3)
		move.l	d0,(a2)
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.w	loc_69B8
		move.b	$4E(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	d3,d0
		move.b	$42(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		cmpa.l	-$DB4(a5),a4
		bne.s	loc_6930
		move.l	#$A0000000,d1
		bra.s	loc_6936
; ---------------------------------------------------------------------------

loc_6930:				; CODE XREF: AutomodeIrq+10Ej
		move.l	#$B0000000,d1

loc_6936:				; CODE XREF: AutomodeIrq+116j
		add.l	d1,d0
		move.b	var_C(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_69B8
; ---------------------------------------------------------------------------

loc_6954:				; CODE XREF: AutomodeIrq+D6j
		movea.l	arg_0(a6),a2
		moveq	#$48,d0	; 'H'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	var_14(a6),-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a0
		move.l	$2C(a0),d0
		movea.l	var_14(a6),a1
		move.l	d0,4(a1)
		addq.w	#1,$58(a0)
		move.l	a1,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		tst.l	$48(a0)
		bne.s	loc_69B8
		movea.l	arg_4(a6),a0
		move.b	#$C0,$40(a0)
		bra.s	loc_69B8
; ---------------------------------------------------------------------------

loc_699E:				; CODE XREF: AutomodeIrq+1Aj
		move.w	d4,d0
		andi.w	#$C0,d0	; 'À'
		beq.s	loc_69B8
		pea	(aRecmsgNilHdlc+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_69B8:				; CODE XREF: AutomodeIrq+64j
					; AutomodeIrq+EEj ...
		movea.l	arg_0(a6),a0
		move.l	$40(a0),d0
		move.l	d0,var_14(a6)
		tst.l	d0
		beq.w	loc_6A9E
		move.w	d4,d0
		andi.w	#$4000,d0
		beq.s	loc_6A06
		movea.l	arg_0(a6),a2
		addq.w	#1,$54(a2)
		move.w	$54(a2),d0
		moveq	#5,d1
		cmp.w	d1,d0
		bne.s	loc_69F2
		move.l	a2,-(sp)
		jsr	(TransmitDone).l
		addq.w	#4,sp
		bra.w	loc_6A9E
; ---------------------------------------------------------------------------

loc_69F2:				; CODE XREF: AutomodeIrq+1CAj
		moveq	#0,d0
		movea.l	var_14(a6),a0
		move.l	d0,$10(a0)
		movea.l	arg_4(a6),a0
		move.b	#1,$42(a0)

loc_6A06:				; CODE XREF: AutomodeIrq+1B8j
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_6A9E
		movea.l	var_14(a6),a2
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bne.s	loc_6A3C
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.l	$40(a0),d0
		move.l	d0,var_14(a6)
		tst.l	d0
		beq.s	loc_6A9E

loc_6A3C:				; CODE XREF: AutomodeIrq+206j
		movea.l	var_14(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_14(a6),a0
		move.l	$10(a0),d3
		adda.l	d3,a2
		move.l	a2,var_4(a6)
		move.l	$14(a0),d0
		move.w	d0,d5
		sub.w	d3,d5
		moveq	#$20,d3	; ' '
		cmp.w	d3,d5
		ble.s	loc_6A62
		move.w	d3,d5

loc_6A62:				; CODE XREF: AutomodeIrq+246j
		movea.l	var_14(a6),a2
		move.w	d5,d3
		move.w	d3,d0
		ext.l	d0
		add.l	d0,$10(a2)
		move.w	d3,d0
		subq.w	#1,d0
		movea.l	arg_4(a6),a1
		movea.l	var_4(a6),a0

loc_6A7C:				; CODE XREF: AutomodeIrq+266j
		move.b	(a0)+,(a1)
		dbf	d0,loc_6A7C
		move.l	$10(a2),d0
		move.l	$14(a2),d1
		cmp.l	d1,d0
		bne.s	loc_6A92
		moveq	#2,d0
		bra.s	loc_6A94
; ---------------------------------------------------------------------------

loc_6A92:				; CODE XREF: AutomodeIrq+274j
		moveq	#0,d0

loc_6A94:				; CODE XREF: AutomodeIrq+278j
		addq.b	#8,d0
		movea.l	arg_4(a6),a0
		move.b	d0,$42(a0)

loc_6A9E:				; CODE XREF: AutomodeIrq+1AEj
					; AutomodeIrq+1D6j ...
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function AutomodeIrq

; ---------------------------------------------------------------------------
aHdlcirq:	dc.b 135,'HdlcIrq',0
aRecmsgNilHdlc:	dc.b 18,'recmsg nil (hdlc)',0 ; DATA XREF: AutomodeIrq+18Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

HdlcIrq:				; DATA XREF: TestInterfills:loc_4726o

var_24		= -$24
var_23		= -$23
var_20		= -$20
var_1C		= -$1C
var_18		= -$18
var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-$24
		movem.l	d3-d7/a2-a4,-(sp)
		movea.l	arg_4(a6),a4
		move.w	arg_8(a6),d4
		move.b	$42(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		move.b	d0,var_24(a6)
		move.w	d4,d0
		andi.w	#$C0,d0	; 'À'
		beq.w	loc_6D0E
		movea.l	arg_0(a6),a0
		movea.l	$48(a0),a3
		cmpa.w	#0,a3
		beq.s	loc_6AFE
		tst.b	$1A(a3)
		beq.s	loc_6AFE
		movea.l	(a3),a3

loc_6AFE:				; CODE XREF: HdlcIrq+32j HdlcIrq+38j
		move.l	a3,d0
		beq.w	loc_6CFC
		tst.l	(a3)
		bne.s	loc_6B24
		move.b	var_24(a6),d0
		bne.s	loc_6B24
		move.b	#$20,var_24(a6)	; ' '
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_6B24
		move.b	#$F0,$46(a4)

loc_6B24:				; CODE XREF: HdlcIrq+44j HdlcIrq+4Aj ...
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.w	loc_6BC0
		moveq	#$20,d5	; ' '
		tst.w	$10(a3)
		bne.s	loc_6B8C
		moveq	#$FFFFFFFE,d0
		move.w	d0,$10(a3)
		move.b	(a4),d0
		move.b	d0,var_23(a6)
		move.b	$52(a4),d1
		cmp.b	d1,d0
		bne.s	loc_6B54
		move.b	(a4),d0
		move.b	d0,var_23(a6)
		moveq	#$1E,d5
		bra.s	loc_6B8C
; ---------------------------------------------------------------------------

loc_6B54:				; CODE XREF: HdlcIrq+86j
		moveq	#$1F,d5
		pea	(aMissingRhcr1+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	var_23(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$52(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_6B8C:				; CODE XREF: HdlcIrq+72j HdlcIrq+90j
		move.w	d5,d0
		subq.w	#1,d0
		movea.l	a3,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		move.w	$10(a3),d1
		ext.l	d1
		adda.l	d1,a1
		move.l	a1,var_20(a6)
		movea.l	a4,a0

loc_6BA4:				; CODE XREF: HdlcIrq+E6j
		move.b	(a0),(a1)
		addq.l	#2,a1
		dbf	d0,loc_6BA4
		move.b	var_24(a6),d0
		addi.b	#-$80,d0
		move.b	d0,$42(a4)
		move.w	d5,d0
		add.w	d0,d0
		add.w	d0,$10(a3)

loc_6BC0:				; CODE XREF: HdlcIrq+68j
		move.w	d4,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_6D0E
		move.b	$4A(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		subq.w	#1,d0
		moveq	#$1F,d1
		and.w	d1,d0
		move.w	d0,var_14(a6)
		movea.l	a3,a2
		moveq	#$1E,d1
		adda.l	d1,a2
		move.w	$10(a3),d1
		ext.l	d1
		adda.l	d1,a2
		move.l	a2,var_18(a6)
		movea.l	a2,a1
		movea.l	a4,a0

loc_6BF2:				; CODE XREF: HdlcIrq+134j
		move.b	(a0),(a1)
		addq.l	#2,a1
		dbf	d0,loc_6BF2
		move.b	-2(a1),d0
		move.b	d0,var_1C(a6)
		movea.l	a4,a2
		moveq	#$42,d1	; 'B'
		adda.l	d1,a2
		move.b	(a2),d1
		moveq	#$10,d2
		and.b	d2,d1
		addi.b	#-$80,d1
		add.b	var_24(a6),d1
		move.b	d1,(a2)
		andi.b	#$F0,d0
		cmpi.b	#$A0,d0
		beq.s	loc_6C86
		clr.w	d0
		move.w	d0,$10(a3)
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_6C70
		move.b	$4E(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		addi.l	#$10000000,d0
		move.b	var_1C(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_6C70:				; CODE XREF: HdlcIrq+176j
		move.b	var_24(a6),d0
		beq.w	loc_6D0E
		clr.b	d3
		move.b	d3,var_24(a6)
		move.b	d3,$42(a4)
		bra.w	loc_6D0E
; ---------------------------------------------------------------------------

loc_6C86:				; CODE XREF: HdlcIrq+15Ej
		move.b	#1,$1A(a3)
		movea.l	arg_0(a6),a0
		movea.l	$4C(a0),a0
		cmpa.l	a3,a0
		bne.s	loc_6C9E
		move.b	#$C0,$40(a4)

loc_6C9E:				; CODE XREF: HdlcIrq+1D4j
		tst.b	$1B(a3)
		beq.s	loc_6D0E
		move.w	$1C(a3),d0
		moveq	#0,d7
		move.w	d0,d7
		movea.l	arg_0(a6),a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		tst.l	d7
		ble.s	loc_6CCC
		cmpi.l	#$FA0,d7
		ble.s	loc_6CD8

loc_6CCC:				; CODE XREF: HdlcIrq+200j
		lea	(HscxErrLog).l,a0
		move.l	a0,4(a3)
		bra.s	loc_6CE8
; ---------------------------------------------------------------------------

loc_6CD8:				; CODE XREF: HdlcIrq+208j
		move.l	d7,$14(a3)
		movea.l	arg_0(a6),a0
		move.l	$2C(a0),d0
		move.l	d0,4(a3)

loc_6CE8:				; CODE XREF: HdlcIrq+214j
		movea.l	arg_0(a6),a0
		addq.w	#1,$58(a0)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_6D0E
; ---------------------------------------------------------------------------

loc_6CFC:				; CODE XREF: HdlcIrq+3Ej
		pea	aRecmsgNil1	; "recmsg nil (1)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_6D0E:				; CODE XREF: HdlcIrq+22j HdlcIrq+104j	...
		move.w	d4,d0
		andi.w	#$C038,d0
		beq.w	loc_6F12
		movea.l	arg_0(a6),a0
		move.l	$40(a0),d0
		move.l	d0,var_10(a6)
		tst.l	d0
		beq.w	loc_6EF8
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_6D70
		move.b	#$F0,$46(a4)
		movea.l	arg_0(a6),a2
		addq.w	#1,$54(a2)
		move.w	$54(a2),d0
		moveq	#5,d1
		cmp.w	d1,d0
		bne.s	loc_6D58
		move.l	a2,-(sp)
		jsr	(TransmitDone).l
		addq.w	#4,sp
		bra.w	loc_6F12
; ---------------------------------------------------------------------------

loc_6D58:				; CODE XREF: HdlcIrq+286j
		clr.w	d0
		movea.l	var_10(a6),a0
		move.w	d0,$10(a0)
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_6D70
		ori.w	#$10,d4

loc_6D70:				; CODE XREF: HdlcIrq+26Ej HdlcIrq+2A8j
		move.w	d4,d0
		moveq	#$20,d1	; ' '
		and.w	d1,d0
		beq.s	loc_6D9E
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_6D9E
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_6D92
		move.b	#$F0,$46(a4)

loc_6D92:				; CODE XREF: HdlcIrq+2C8j
		movea.l	var_10(a6),a0
		tst.w	$10(a0)
		beq.w	loc_6E2E

loc_6D9E:				; CODE XREF: HdlcIrq+2B4j HdlcIrq+2BEj
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_6F12
		movea.l	var_10(a6),a2
		move.w	$14(a2),d0
		move.w	$10(a2),d1
		cmp.w	d1,d0
		bne.s	loc_6E2E
		clr.w	d0
		move.w	d0,$14(a2)
		move.b	#$F0,$46(a4)
		tst.w	$16(a2)
		bne.w	loc_6F12
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		tst.l	$40(a0)
		beq.w	loc_6F12
		move.b	$42(a4),d0
		moveq	#$10,d3
		and.b	d3,d0
		beq.s	loc_6DF2
		moveq	#$10,d0
		bra.s	loc_6DF4
; ---------------------------------------------------------------------------

loc_6DF2:				; CODE XREF: HdlcIrq+32Aj
		moveq	#1,d0

loc_6DF4:				; CODE XREF: HdlcIrq+32Ej
		add.b	var_24(a6),d0
		move.b	d0,$42(a4)
		move.l	a4,d0
		eori.l	#$80,d0	; '€'
		movea.l	d0,a0
		move.l	a0,var_8(a6)
		move.b	$42(a0),d0
		move.b	d0,var_C(a6)
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		move.b	var_C(a6),d1
		and.b	d3,d1
		beq.s	loc_6E22
		moveq	#$10,d1
		bra.s	loc_6E24
; ---------------------------------------------------------------------------

loc_6E22:				; CODE XREF: HdlcIrq+35Aj
		moveq	#1,d1

loc_6E24:				; CODE XREF: HdlcIrq+35Ej
		add.b	d1,d0
		move.b	d0,$42(a0)
		bra.w	loc_6F12
; ---------------------------------------------------------------------------

loc_6E2E:				; CODE XREF: HdlcIrq+2D8j HdlcIrq+2F4j
		movea.l	var_10(a6),a0
		tst.w	$10(a0)
		bne.s	loc_6E74
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_6E58
		pea	aXpr_peer_rnr1	; "XPR_peer_RNR	(1)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_6F12
; ---------------------------------------------------------------------------

loc_6E58:				; CODE XREF: HdlcIrq+37Ej
		move.b	$52(a4),d0
		rol.b	#4,d0
		moveq	#$11,d1
		or.b	d1,d0
		eori.b	#$88,d0
		movea.l	var_10(a6),a2
		move.b	d0,$1A(a2)
		moveq	#$FFFFFFFC,d0
		move.w	d0,$10(a2)

loc_6E74:				; CODE XREF: HdlcIrq+374j
		movea.l	var_10(a6),a2
		move.w	$14(a2),d6
		sub.w	$10(a2),d6
		bgt.s	loc_6E94
		pea	aN01		; "n <=	0 (1)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_6E94:				; CODE XREF: HdlcIrq+3BEj
		movea.l	var_10(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_10(a6),a0
		move.w	$10(a0),d0
		ext.l	d0
		adda.l	d0,a2
		move.l	a2,var_4(a6)
		moveq	#$40,d3	; '@'
		cmp.w	d3,d6
		ble.s	loc_6EB4
		move.w	d3,d6

loc_6EB4:				; CODE XREF: HdlcIrq+3EEj
		movea.l	var_10(a6),a2
		add.w	d6,$10(a2)
		move.w	d6,d0
		move.w	d0,d1
		ext.l	d1
		asr.l	#1,d1
		move.w	d1,d0
		subq.w	#1,d0
		movea.l	a4,a1
		movea.l	var_4(a6),a0

loc_6ECE:				; CODE XREF: HdlcIrq+410j
		move.b	(a0),(a1)
		addq.l	#2,a0
		dbf	d0,loc_6ECE
		move.w	$14(a2),d0
		move.w	$10(a2),d1
		cmp.w	d1,d0
		bne.s	loc_6EEC
		addq.b	#2,var_24(a6)
		move.b	#$70,$46(a4) ; 'p'

loc_6EEC:				; CODE XREF: HdlcIrq+41Ej
		move.b	var_24(a6),d0
		addq.b	#4,d0
		move.b	d0,$42(a4)
		bra.s	loc_6F12
; ---------------------------------------------------------------------------

loc_6EF8:				; CODE XREF: HdlcIrq+264j
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_6F12
		pea	aSendmsgNil1	; "sendmsg nil (1)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_6F12:				; CODE XREF: HdlcIrq+252j HdlcIrq+292j ...
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function HdlcIrq

; ---------------------------------------------------------------------------
aBundled1irq:	dc.b 139,'Bundled1Irq',0
aMissingRhcr1:	dc.b 80,'missing RHCR (1)',0,0 ; DATA XREF: HdlcIrq+94o
aRecmsgNil1:	dc.b 'recmsg nil (1)',0,0 ; DATA XREF: HdlcIrq:loc_6CFCo
aXpr_peer_rnr1:	dc.b 'XPR_peer_RNR (1)',0,0 ; DATA XREF: HdlcIrq+380o
aN01:		dc.b 'n <= 0 (1)',0,0   ; DATA XREF: HdlcIrq+3C0o
aSendmsgNil1:	dc.b 'sendmsg nil (1)',0 ; DATA XREF: HdlcIrq+43Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Bundled1Irq:				; DATA XREF: TestInterfills+F4o

var_24		= -$24
var_23		= -$23
var_20		= -$20
var_1C		= -$1C
var_18		= -$18
var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-$24
		movem.l	d3-d7/a2-a4,-(sp)
		movea.l	arg_4(a6),a4
		move.w	arg_8(a6),d4
		move.b	$42(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		move.b	d0,var_24(a6)
		movea.l	arg_0(a6),a0
		lea	-$6FA(a5),a1
		cmpa.l	a1,a0
		bne.s	loc_6FAA
		lea	-$786(a5),a0
		move.l	a0,arg_0(a6)
		bra.s	loc_6FB2
; ---------------------------------------------------------------------------

loc_6FAA:				; CODE XREF: Bundled1Irq+26j
		lea	-$6FA(a5),a0
		move.l	a0,arg_0(a6)

loc_6FB2:				; CODE XREF: Bundled1Irq+30j
		move.w	d4,d0
		andi.w	#$C0,d0	; 'À'
		beq.w	loc_71E2
		movea.l	arg_0(a6),a0
		movea.l	$48(a0),a3
		cmpa.w	#0,a3
		beq.s	loc_6FD2
		tst.b	$1B(a3)
		beq.s	loc_6FD2
		movea.l	(a3),a3

loc_6FD2:				; CODE XREF: Bundled1Irq+50j
					; Bundled1Irq+56j
		move.l	a3,d0
		beq.w	loc_71D0
		tst.l	(a3)
		bne.s	loc_6FF8
		move.b	var_24(a6),d0
		bne.s	loc_6FF8
		move.b	#$20,var_24(a6)	; ' '
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_6FF8
		move.b	#$F0,$46(a4)

loc_6FF8:				; CODE XREF: Bundled1Irq+62j
					; Bundled1Irq+68j ...
		move.w	d4,d0
		moveq	#$40,d1	; '@'
		and.w	d1,d0
		beq.w	loc_7094
		moveq	#$20,d5	; ' '
		tst.w	$12(a3)
		bne.s	loc_7060
		moveq	#$FFFFFFFF,d0
		move.w	d0,$12(a3)
		move.b	(a4),d0
		move.b	d0,var_23(a6)
		move.b	$52(a4),d1
		cmp.b	d1,d0
		bne.s	loc_7028
		move.b	(a4),d0
		move.b	d0,var_23(a6)
		moveq	#$1E,d5
		bra.s	loc_7060
; ---------------------------------------------------------------------------

loc_7028:				; CODE XREF: Bundled1Irq+A4j
		moveq	#$1F,d5
		pea	(aMissingRhcr2+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	var_23(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	$52(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(LogString).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_7060:				; CODE XREF: Bundled1Irq+90j
					; Bundled1Irq+AEj
		move.w	d5,d0
		subq.w	#1,d0
		movea.l	a3,a1
		moveq	#$1E,d1
		adda.l	d1,a1
		move.w	$12(a3),d1
		ext.l	d1
		adda.l	d1,a1
		move.l	a1,var_20(a6)
		movea.l	a4,a0

loc_7078:				; CODE XREF: Bundled1Irq+104j
		move.b	(a0),(a1)
		addq.l	#2,a1
		dbf	d0,loc_7078
		move.b	var_24(a6),d0
		addi.b	#-$80,d0
		move.b	d0,$42(a4)
		move.w	d5,d0
		add.w	d0,d0
		add.w	d0,$12(a3)

loc_7094:				; CODE XREF: Bundled1Irq+86j
		move.w	d4,d0
		andi.w	#$80,d0	; '€'
		beq.w	loc_71E2
		move.b	$4A(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		subq.w	#1,d0
		moveq	#$1F,d1
		and.w	d1,d0
		move.w	d0,var_14(a6)
		movea.l	a3,a2
		moveq	#$1E,d1
		adda.l	d1,a2
		move.w	$12(a3),d1
		ext.l	d1
		adda.l	d1,a2
		move.l	a2,var_18(a6)
		movea.l	a2,a1
		movea.l	a4,a0

loc_70C6:				; CODE XREF: Bundled1Irq+152j
		move.b	(a0),(a1)
		addq.l	#2,a1
		dbf	d0,loc_70C6
		move.b	-2(a1),d0
		move.b	d0,var_1C(a6)
		movea.l	a4,a2
		moveq	#$42,d1	; 'B'
		adda.l	d1,a2
		move.b	(a2),d1
		moveq	#$10,d2
		and.b	d2,d1
		addi.b	#-$80,d1
		add.b	var_24(a6),d1
		move.b	d1,(a2)
		andi.b	#$F0,d0
		cmpi.b	#$A0,d0
		beq.s	loc_715A
		clr.w	d0
		move.w	d0,$12(a3)
		movea.l	arg_0(a6),a0
		movea.l	8(a0),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_7144
		move.b	$4E(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	(a2),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		addi.l	#$20000000,d0
		move.b	var_1C(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(HscxIntLog).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_7144:				; CODE XREF: Bundled1Irq+194j
		move.b	var_24(a6),d0
		beq.w	loc_71E2
		clr.b	d3
		move.b	d3,var_24(a6)
		move.b	d3,$42(a4)
		bra.w	loc_71E2
; ---------------------------------------------------------------------------

loc_715A:				; CODE XREF: Bundled1Irq+17Cj
		move.b	#1,$1B(a3)
		movea.l	arg_0(a6),a0
		movea.l	$4C(a0),a0
		cmpa.l	a3,a0
		bne.s	loc_7172
		move.b	#$C0,$40(a4)

loc_7172:				; CODE XREF: Bundled1Irq+1F2j
		tst.b	$1A(a3)
		beq.s	loc_71E2
		move.w	$1C(a3),d0
		moveq	#0,d7
		move.w	d0,d7
		movea.l	arg_0(a6),a0
		moveq	#$48,d0	; 'H'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		tst.l	d7
		ble.s	loc_71A0
		cmpi.l	#$FA0,d7
		ble.s	loc_71AC

loc_71A0:				; CODE XREF: Bundled1Irq+21Ej
		lea	(HscxErrLog).l,a0
		move.l	a0,4(a3)
		bra.s	loc_71BC
; ---------------------------------------------------------------------------

loc_71AC:				; CODE XREF: Bundled1Irq+226j
		move.l	d7,$14(a3)
		movea.l	arg_0(a6),a0
		move.l	$2C(a0),d0
		move.l	d0,4(a3)

loc_71BC:				; CODE XREF: Bundled1Irq+232j
		movea.l	arg_0(a6),a0
		addq.w	#1,$58(a0)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_71E2
; ---------------------------------------------------------------------------

loc_71D0:				; CODE XREF: Bundled1Irq+5Cj
		pea	aRecmsgNil2	; "recmsg nil (2)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_71E2:				; CODE XREF: Bundled1Irq+40j
					; Bundled1Irq+122j ...
		move.w	d4,d3
		andi.w	#$C038,d3
		beq.w	loc_73E2
		movea.l	arg_0(a6),a2
		move.l	$40(a2),d0
		move.l	d0,var_10(a6)
		tst.l	d0
		beq.w	loc_73C8
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_7240
		move.b	#$F0,$46(a4)
		addq.w	#1,$54(a2)
		move.w	$54(a2),d0
		moveq	#5,d1
		cmp.w	d1,d0
		bne.s	loc_7228
		move.l	a2,-(sp)
		jsr	(TransmitDone).l
		addq.w	#4,sp
		bra.w	loc_73E2
; ---------------------------------------------------------------------------

loc_7228:				; CODE XREF: Bundled1Irq+2A0j
		clr.w	d0
		movea.l	var_10(a6),a0
		move.w	d0,$12(a0)
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_7240
		ori.w	#$10,d4

loc_7240:				; CODE XREF: Bundled1Irq+28Cj
					; Bundled1Irq+2C2j
		move.w	d4,d0
		moveq	#$20,d1	; ' '
		and.w	d1,d0
		beq.s	loc_726E
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_726E
		move.b	$46(a4),d0
		cmpi.b	#$F0,d0
		bne.s	loc_7262
		move.b	#$F0,$46(a4)

loc_7262:				; CODE XREF: Bundled1Irq+2E2j
		movea.l	var_10(a6),a0
		tst.w	$12(a0)
		beq.w	loc_72FE

loc_726E:				; CODE XREF: Bundled1Irq+2CEj
					; Bundled1Irq+2D8j
		move.w	d4,d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.w	loc_73E2
		movea.l	var_10(a6),a2
		move.w	$16(a2),d0
		move.w	$12(a2),d1
		cmp.w	d1,d0
		bne.s	loc_72FE
		clr.w	d0
		move.w	d0,$16(a2)
		move.b	#$F0,$46(a4)
		tst.w	$14(a2)
		bne.w	loc_73E2
		move.l	arg_0(a6),-(sp)
		jsr	(SwitchLapb).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		tst.l	$40(a0)
		beq.w	loc_73E2
		move.b	$42(a4),d0
		moveq	#$10,d3
		and.b	d3,d0
		beq.s	loc_72C2
		moveq	#$10,d0
		bra.s	loc_72C4
; ---------------------------------------------------------------------------

loc_72C2:				; CODE XREF: Bundled1Irq+344j
		moveq	#1,d0

loc_72C4:				; CODE XREF: Bundled1Irq+348j
		add.b	var_24(a6),d0
		move.b	d0,$42(a4)
		move.l	a4,d0
		eori.l	#$80,d0	; '€'
		movea.l	d0,a0
		move.l	a0,var_8(a6)
		move.b	$42(a0),d0
		move.b	d0,var_C(a6)
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		move.b	var_C(a6),d1
		and.b	d3,d1
		beq.s	loc_72F2
		moveq	#$10,d1
		bra.s	loc_72F4
; ---------------------------------------------------------------------------

loc_72F2:				; CODE XREF: Bundled1Irq+374j
		moveq	#1,d1

loc_72F4:				; CODE XREF: Bundled1Irq+378j
		add.b	d1,d0
		move.b	d0,$42(a0)
		bra.w	loc_73E2
; ---------------------------------------------------------------------------

loc_72FE:				; CODE XREF: Bundled1Irq+2F2j
					; Bundled1Irq+30Ej
		movea.l	var_10(a6),a0
		tst.w	$12(a0)
		bne.s	loc_7344
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		beq.s	loc_7328
		pea	aXpr_peer_rnr2	; "XPR_peer_RNR	(2)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.w	loc_73E2
; ---------------------------------------------------------------------------

loc_7328:				; CODE XREF: Bundled1Irq+398j
		move.b	$52(a4),d0
		rol.b	#4,d0
		moveq	#$11,d1
		or.b	d1,d0
		eori.b	#$88,d0
		movea.l	var_10(a6),a2
		move.b	d0,$1B(a2)
		moveq	#$FFFFFFFD,d0
		move.w	d0,$12(a2)

loc_7344:				; CODE XREF: Bundled1Irq+38Ej
		movea.l	var_10(a6),a2
		move.w	$16(a2),d6
		sub.w	$12(a2),d6
		bgt.s	loc_7364
		pea	aN02		; "n <=	0 (2)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_7364:				; CODE XREF: Bundled1Irq+3D8j
		movea.l	var_10(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_10(a6),a0
		move.w	$12(a0),d0
		ext.l	d0
		adda.l	d0,a2
		move.l	a2,var_4(a6)
		moveq	#$40,d3	; '@'
		cmp.w	d3,d6
		ble.s	loc_7384
		move.w	d3,d6

loc_7384:				; CODE XREF: Bundled1Irq+408j
		movea.l	var_10(a6),a2
		add.w	d6,$12(a2)
		move.w	d6,d0
		move.w	d0,d1
		ext.l	d1
		asr.l	#1,d1
		move.w	d1,d0
		subq.w	#1,d0
		movea.l	a4,a1
		movea.l	var_4(a6),a0

loc_739E:				; CODE XREF: Bundled1Irq+42Aj
		move.b	(a0),(a1)
		addq.l	#2,a0
		dbf	d0,loc_739E
		move.w	$16(a2),d0
		move.w	$12(a2),d1
		cmp.w	d1,d0
		bne.s	loc_73BC
		addq.b	#2,var_24(a6)
		move.b	#$70,$46(a4) ; 'p'

loc_73BC:				; CODE XREF: Bundled1Irq+438j
		move.b	var_24(a6),d0
		addq.b	#4,d0
		move.b	d0,$42(a4)
		bra.s	loc_73E2
; ---------------------------------------------------------------------------

loc_73C8:				; CODE XREF: Bundled1Irq+282j
		move.w	d4,d0
		andi.w	#$C008,d0
		beq.s	loc_73E2
		pea	aSendmsgNil2	; "sendmsg nil (2)"
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_73E2:				; CODE XREF: Bundled1Irq+270j
					; Bundled1Irq+2ACj ...
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function Bundled1Irq

; ---------------------------------------------------------------------------
aBundled2irq:	dc.b 139,'Bundled2Irq',0
aMissingRhcr2:	dc.b 80,'missing RHCR (2)',0,0 ; DATA XREF: Bundled1Irq+B2o
aRecmsgNil2:	dc.b 'recmsg nil (2)',0,0 ; DATA XREF: Bundled1Irq:loc_71D0o
aXpr_peer_rnr2:	dc.b 'XPR_peer_RNR (2)',0,0 ; DATA XREF: Bundled1Irq+39Ao
aN02:		dc.b 'n <= 0 (2)',0,0   ; DATA XREF: Bundled1Irq+3DAo
aSendmsgNil2:	dc.b 'sendmsg nil (2)',0 ; DATA XREF: Bundled1Irq+458o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Bundled2Irq:				; DATA XREF: ConnectHscx+1Eo

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	$C(a3),a4
		tst.l	8(a4)
		bne.s	loc_7474
		move.l	$30(a4),d0
		move.l	d0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.w	loc_7570
; ---------------------------------------------------------------------------

loc_7474:				; CODE XREF: Bundled2Irq+14j
		moveq	#0,d0
		move.l	d0,$10(a3)
		move.w	$56(a4),d0
		andi.w	#$4000,d0
		beq.s	loc_74F8
		tst.w	$18(a3)
		bne.s	loc_749C
		move.w	$5A(a4),d0
		addq.w	#1,$5A(a4)
		asl.b	#1,d0
		moveq	#$E,d1
		and.b	d1,d0
		move.b	d0,$1A(a3)

loc_749C:				; CODE XREF: Bundled2Irq+40j
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d4
		movea.l	a4,a2
		moveq	#$40,d0	; '@'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		move.w	$56(a4),d3
		moveq	#4,d0
		move.w	d3,var_4(a6)
		and.w	d0,d3
		beq.s	loc_74D6
		move.w	var_4(a6),d0
		andi.w	#$1008,d0
		bne.s	loc_74E0
		ori.w	#$18,$56(a4)
		bra.s	loc_74E0
; ---------------------------------------------------------------------------

loc_74D6:				; CODE XREF: Bundled2Irq+7Aj
		move.w	$56(a4),d0
		andi.w	#$200,d0
		bne.s	loc_74F2

loc_74E0:				; CODE XREF: Bundled2Irq+84j
					; Bundled2Irq+8Cj
		clr.w	-(sp)
		move.l	$38(a4),-(sp)
		move.l	a4,-(sp)
		movea.l	$3C(a4),a0
		jsr	(a0)
		lea	$A(sp),sp

loc_74F2:				; CODE XREF: Bundled2Irq+96j
		move.w	d4,d0
		move	d0,sr
		bra.s	loc_7570
; ---------------------------------------------------------------------------

loc_74F8:				; CODE XREF: Bundled2Irq+3Aj
		movea.l	a4,a2
		moveq	#$40,d0	; '@'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_7570
		movea.l	$38(a4),a3
		clr.b	var_8(a6)
		addq.w	#1,$5A(a4)
		move.b	$E(a4),d0
		moveq	#$FFFFFFDF,d1
		and.b	d1,d0
		moveq	#7,d1
		cmp.b	d1,d0
		bhi.s	loc_7570
		move.b	$42(a3),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_753A
		move.b	#1,var_8(a6)
		bra.s	loc_755A
; ---------------------------------------------------------------------------

loc_753A:				; CODE XREF: Bundled2Irq+E8j
		move.b	$E(a4),d0
		moveq	#2,d1
		cmp.b	d1,d0
		beq.s	loc_754A
		tst.l	$48(a4)
		beq.s	loc_7554

loc_754A:				; CODE XREF: Bundled2Irq+FAj
		movea.l	$48(a4),a0
		tst.l	$10(a0)
		bne.s	loc_755A

loc_7554:				; CODE XREF: Bundled2Irq+100j
		move.b	#$10,var_8(a6)

loc_755A:				; CODE XREF: Bundled2Irq+F0j
					; Bundled2Irq+10Aj
		move.b	var_8(a6),d0
		beq.s	loc_7570
		move.b	$42(a3),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		add.b	var_8(a6),d0
		move.b	d0,$42(a3)

loc_7570:				; CODE XREF: Bundled2Irq+28j
					; Bundled2Irq+AEj ...
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function Bundled2Irq

; ---------------------------------------------------------------------------
aWritehscx:	dc.b 137,'WriteHscx',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteHscx:				; DATA XREF: TestInterfills+FEo
					; TestInterfills+152o

var_8		= -8
var_4		= -4
var_3		= -3
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.l	$C(a4),d0
		move.l	d0,var_8(a6)
		move.l	$14(a4),d1
		move.w	d1,d5
		moveq	#0,d1
		move.l	d1,$10(a4)
		move.w	d5,d1
		move.w	d1,d2
		ext.l	d2
		move.l	d2,$1A(a4)
		movea.l	d0,a0
		tst.l	8(a0)
		bne.s	loc_75CC
		move.l	$30(a0),d0
		move.l	d0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.w	loc_7680
; ---------------------------------------------------------------------------

loc_75CC:				; CODE XREF: WriteHscx+30j
		move.w	#$84,d3	; '„'
		cmp.w	d3,d5
		bge.s	loc_75D6
		move.w	d3,d5

loc_75D6:				; CODE XREF: WriteHscx+4Ej
		move.w	d5,d3
		moveq	#1,d4
		and.w	d4,d3
		add.w	d5,d3
		move.w	d3,$14(a4)
		move.w	d5,d0
		or.w	d4,d0
		move.w	d0,$16(a4)
		movea.l	var_8(a6),a2
		addq.w	#1,$5A(a2)
		moveq	#$40,d0	; '@'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a4,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_7680
		movea.l	var_8(a6),a0
		movea.l	$38(a0),a3
		move.l	a3,d0
		eori.l	#$80,d0	; '€'
		movea.l	d0,a4
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		move.b	$42(a3),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_7632
		move.b	#1,var_4(a6)
		bra.s	loc_7638
; ---------------------------------------------------------------------------

loc_7632:				; CODE XREF: WriteHscx+A4j
		move.b	#$10,var_4(a6)

loc_7638:				; CODE XREF: WriteHscx+ACj
		move.b	var_4(a6),d0
		beq.s	loc_764E
		move.b	$42(a3),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		add.b	var_4(a6),d0
		move.b	d0,$42(a3)

loc_764E:				; CODE XREF: WriteHscx+B8j
		move.b	$42(a4),d0
		moveq	#$10,d1
		and.b	d1,d0
		bne.s	loc_7660
		move.b	#1,var_3(a6)
		bra.s	loc_7666
; ---------------------------------------------------------------------------

loc_7660:				; CODE XREF: WriteHscx+D2j
		move.b	#$10,var_3(a6)

loc_7666:				; CODE XREF: WriteHscx+DAj
		move.b	var_3(a6),d0
		beq.s	loc_767C
		move.b	$42(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		add.b	var_3(a6),d0
		move.b	d0,$42(a4)

loc_767C:				; CODE XREF: WriteHscx+E6j
		move.w	d3,d0
		move	d0,sr

loc_7680:				; CODE XREF: WriteHscx+44j
					; WriteHscx+80j
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function WriteHscx

; ---------------------------------------------------------------------------
aWritebundledhscx:dc.b 144,'WriteBundledHscx',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteBundledHscx:			; CODE XREF: exc_InterruptLevel4+4p
		link	a6,#0
		movem.l	d3-d6/a2,-(sp)
		clr.w	d6
		bra.w	loc_77AA
; ---------------------------------------------------------------------------

loc_76AA:				; CODE XREF: WriteBundledHscx+130j
		clr.w	d5
		movea.l	-$DB4(a5),a2
		move.b	$C0(a2),d0
		moveq	#0,d4
		move.b	d0,d4
		tst.w	d4
		beq.w	loc_77A4
		clr.w	d6
		move.w	d4,d0
		moveq	#4,d1
		and.w	d1,d0
		beq.s	loc_76D0
		move.b	$40(a2),d0
		moveq	#0,d5
		move.b	d0,d5

loc_76D0:				; CODE XREF: WriteBundledHscx+2Aj
		move.w	d4,d0
		moveq	#1,d1
		and.w	d1,d0
		beq.s	loc_76E8
		movea.l	-$DB4(a5),a0
		move.b	$C8(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.w	#8,d0
		add.w	d0,d4

loc_76E8:				; CODE XREF: WriteBundledHscx+3Aj
		move.w	d4,d0
		moveq	#2,d1
		and.w	d1,d0
		beq.s	loc_7700
		movea.l	-$DB4(a5),a0
		move.b	$48(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.w	#8,d0
		add.w	d0,d5

loc_7700:				; CODE XREF: WriteBundledHscx+52j
		andi.w	#$FFF8,d4
		beq.s	loc_7720
		move.w	d4,-(sp)
		movea.l	-$DB4(a5),a0
		lea	$80(a0),a0
		move.l	a0,-(sp)
		pea	-$786(a5)
		movea.l	-$74A(a5),a0
		jsr	(a0)
		lea	$A(sp),sp

loc_7720:				; CODE XREF: WriteBundledHscx+68j
		tst.w	d5
		beq.s	loc_7738
		move.w	d5,-(sp)
		move.l	-$DB4(a5),-(sp)
		pea	-$6FA(a5)
		movea.l	-$6BE(a5),a0
		jsr	(a0)
		lea	$A(sp),sp

loc_7738:				; CODE XREF: WriteBundledHscx+86j
		move.w	d5,d3
		andi.w	#$F008,d3
		beq.s	loc_776E
		movea.l	-$DB4(a5),a0
		move.b	$42(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$60000000,d0
		move.w	d5,d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(ClearBundledHscx).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_776E:				; CODE XREF: WriteBundledHscx+A2j
		move.w	d4,d3
		andi.w	#$F008,d3
		beq.s	loc_77A4
		movea.l	-$DB4(a5),a0
		move.b	$C2(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$50000000,d0
		move.w	d4,d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(ClearBundledHscx).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_77A4:				; CODE XREF: WriteBundledHscx+1Ej
					; WriteBundledHscx+D8j
		move.l	-$D28(a5),d0
		movea.l	d0,a5

loc_77AA:				; CODE XREF: WriteBundledHscx+Aj
		movea.l	#$3FFFE,a0
		move.b	(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		lea	-$20(a5),a0
		move.b	(a0,d1.w),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#1,d0
		move.w	d6,d1
		addq.w	#1,d6
		ext.l	d1
		cmp.l	d1,d0
		bgt.w	loc_76AA
		movem.l	(sp)+,d3-d6/a2
		unlk	a6
		rts
; End of function WriteBundledHscx

; ---------------------------------------------------------------------------
aIrqhscx:	dc.b 135,'IrqHSCX',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IrqHSCX:				; CODE XREF: SetupHscx+12p
					; SetupHscx+2Ep

arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a2
		moveq	#$37,d0	; '7'
		lea	-$7BE(a5),a0
		movea.l	a2,a1

loc_77F6:				; CODE XREF: IrqHSCX+16j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_77F6
		move.l	arg_4(a6),4(a2)
		move.l	arg_8(a6),d3
		move.l	d3,$38(a2)
		moveq	#$1E,d0
		move.w	d0,-(sp)
		pea	-$7DC(a5)
		move.l	d3,-(sp)
		jsr	(sub_58E).l
		lea	$A(sp),sp
		lea	(PrintError).l,a0
		move.l	a0,$3C(a2)
		pea	-$656(a5)
		move.l	a2,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function IrqHSCX

; ---------------------------------------------------------------------------
aSetuphscx:	dc.b 137,'SetupHscx',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SetupHscx:				; CODE XREF: InitializeCommon+124p
		link	a6,#0
		move.l	d3,-(sp)
		move.l	-$DB4(a5),-(sp)
		pea	aHscxA		; "HSCX	A"
		pea	-$6FA(a5)
		jsr	(IrqHSCX).l
		lea	$C(sp),sp
		movea.l	-$DB4(a5),a0
		lea	$80(a0),a0
		move.l	a0,-(sp)
		pea	(aHscxB+1)
		pea	-$786(a5)
		jsr	(IrqHSCX).l
		lea	$C(sp),sp
		moveq	#1,d3
		move.b	d3,-$6EA(a5)
		move.b	d3,-$6E9(a5)
		moveq	#2,d3
		move.b	d3,-$776(a5)
		move.b	d3,-$775(a5)
		movea.l	-$DB8(a5),a0
		ori.b	#4,$1F91(a0)
		move.b	#$88,d3
		move.b	d3,-$6ED(a5)
		move.b	d3,-$779(a5)
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function SetupHscx

; ---------------------------------------------------------------------------
aInithscx:	dc.b 136,'InitHSCX',0,0
aHscxB:		dc.b 16,'HSCX B',0,0    ; DATA XREF: SetupHscx+26o
aHscxA:		dc.b 'HSCX A',0,0       ; DATA XREF: SetupHscx+Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitHSCX:				; CODE XREF: DispatchEvent+50p
					; DispatchEvent+68p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		bra.s	loc_78DE
; ---------------------------------------------------------------------------

loc_78DC:				; CODE XREF: InitHSCX+1Cj
		addq.w	#2,a4

loc_78DE:				; CODE XREF: InitHSCX+Cj
		move.w	(a4),d3
		cmpi.w	#$4E75,d3
		beq.s	loc_78EC
		cmpi.w	#$4ED0,d3
		bne.s	loc_78DC

loc_78EC:				; CODE XREF: InitHSCX+16j
		movea.l	a4,a3
		addq.w	#2,a3
		move.b	(a3)+,d0
		moveq	#0,d5
		move.b	d0,d5
		move.l	#$80,d3	; '€'
		cmp.l	d3,d5
		blt.s	loc_7952
		cmp.l	d3,d5
		bne.s	loc_790C
		move.b	(a3)+,d0
		moveq	#0,d5
		move.b	d0,d5
		bra.s	loc_7912
; ---------------------------------------------------------------------------

loc_790C:				; CODE XREF: InitHSCX+34j
		andi.l	#$7F,d5	; ''

loc_7912:				; CODE XREF: InitHSCX+3Cj
		move.l	d5,d4

loc_7914:				; CODE XREF: InitHSCX+5Aj InitHSCX+68j
		subq.l	#1,d4
		cmpi.l	#1,d4
		ble.s	loc_7946
		movea.l	a3,a2
		adda.l	d4,a2
		move.b	(a2),d0
		moveq	#$5F,d3	; '_'
		cmp.b	d3,d0
		bne.s	loc_7914
		subq.l	#1,d4
		move.l	d4,d0
		add.l	a3,d0
		movea.l	d0,a0
		move.b	(a0),d0
		cmp.b	d3,d0
		bne.s	loc_7914
		move.l	d4,d5
		bra.s	loc_7946
; ---------------------------------------------------------------------------

loc_793C:				; CODE XREF: InitHSCX+82j
		move.b	(a3)+,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_7946:				; CODE XREF: InitHSCX+4Ej InitHSCX+6Cj
		subq.l	#1,d5
		cmpi.l	#0,d5
		bmi.s	loc_796A
		bra.s	loc_793C
; ---------------------------------------------------------------------------

loc_7952:				; CODE XREF: InitHSCX+30j
		moveq	#$40,d0	; '@'
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.w	arg_0+2(a6),-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp

loc_796A:				; CODE XREF: InitHSCX+80j
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function InitHSCX

; ---------------------------------------------------------------------------
aWriteproc:	dc.b 137,'WriteProc',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteProc:				; CODE XREF: ReturnMsgBuffer+26p
					; VoiceStart+18p ...
		link	a6,#0
		move.l	d3,-(sp)
		move.b	-$658(a5),d0
		bne.s	loc_79D4
		moveq	#$5F,d0	; '_'
		move.l	d0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$65C(a5)
		moveq	#1,d3
		move.b	d3,-$658(a5)
		move.l	-$D44(a5),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	d3,-$658(a5)
		move.l	-$D20(a5),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		pea	(asc_79E7+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_79D4:				; CODE XREF: WriteProc+Aj
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function WriteProc

; ---------------------------------------------------------------------------
aWritebegin:	dc.b 138,'WriteBegin',0,0
asc_79E7:	dc.b 6,' --- ',0        ; DATA XREF: WriteProc+4Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteBegin:				; CODE XREF: DisconnectModem:loc_27E0p
					; WriteDeviceProtocol+70p ...
		link	a6,#0
		pea	(aUnexpected+1)
		jsr	(WriteChar).l
		unlk	a6
		rts
; End of function WriteBegin

; ---------------------------------------------------------------------------
aWriteunexpected:dc.b 143,'WriteUnexpected',0
aUnexpected:	dc.b 12,'unexpected',0,0 ; DATA XREF: WriteBegin+4o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteUnexpected:			; CODE XREF: First+46p	VoiceStop+26p ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		move.b	-$658(a5),d0
		bne.s	loc_7A32
		jsr	(WriteProc).l
		bra.s	loc_7A8A
; ---------------------------------------------------------------------------

loc_7A32:				; CODE XREF: WriteUnexpected+Aj
		cmpi.b	#$5F,-$658(a5) ; '_'
		bcs.s	loc_7A8A
		jsr	(WritePString).l
		moveq	#$5F,d0	; '_'
		move.l	d0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,-$65C(a5)
		moveq	#1,d3
		move.b	d3,-$658(a5)
		move.l	-$D44(a5),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	d3,-$658(a5)
		move.l	-$D20(a5),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		pea	(asc_7ABB+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_7A8A:				; CODE XREF: WriteUnexpected+12j
					; WriteUnexpected+1Aj
		move.l	-$65C(a5),d0
		beq.s	loc_7AAA
		movea.l	-$65C(a5),a0
		moveq	#$1E,d0
		adda.l	d0,a0
		move.b	-$658(a5),d1
		addq.b	#1,-$658(a5)
		moveq	#0,d0
		move.b	d1,d0
		adda.l	d0,a0
		move.b	arg_0(a6),(a0)

loc_7AAA:				; CODE XREF: WriteUnexpected+70j
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function WriteUnexpected

; ---------------------------------------------------------------------------
aWritechar:	dc.b 137,'WriteChar',0
asc_7ABB:	dc.b 6,' -c- ',0        ; DATA XREF: WriteUnexpected+60o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteChar:				; CODE XREF: First+30p
					; DispatchEvent+44p ...

var_4		= -4
arg_0		=  8

		link	a6,#-4
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	a2,d0
		bne.s	loc_7AEA
		pea	(aNil+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_7AF4
; ---------------------------------------------------------------------------

loc_7ADE:				; CODE XREF: WriteChar+30j
		move.b	var_4(a6),-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_7AEA:				; CODE XREF: WriteChar+Cj
		move.b	(a2)+,d0
		move.b	d0,var_4(a6)
		tst.b	d0
		bne.s	loc_7ADE

loc_7AF4:				; CODE XREF: WriteChar+1Aj
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function WriteChar

; ---------------------------------------------------------------------------
aWritestring:	dc.b 139,'WriteString',0
aNil:		dc.b 6,'(nil)',0        ; DATA XREF: WriteChar+Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteString:				; CODE XREF: B_DISCONNECT+2Cp
					; DL_DATA_REQUEST+3Ap ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	a2,d0
		beq.s	loc_7B38
		move.b	(a2)+,d0
		moveq	#0,d3
		move.b	d0,d3
		bra.s	loc_7B30
; ---------------------------------------------------------------------------

loc_7B26:				; CODE XREF: WriteString+28j
		move.b	(a2)+,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_7B30:				; CODE XREF: WriteString+16j
		subq.w	#1,d3
		cmpi.w	#0,d3
		bpl.s	loc_7B26

loc_7B38:				; CODE XREF: WriteString+Ej
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function WriteString

; ---------------------------------------------------------------------------
aWritepstring:	dc.b 140,'WritePString',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WritePString:				; CODE XREF: First+10p	First+5Cp ...
		link	a6,#0
		move.b	-$658(a5),d0
		beq.s	loc_7B84
		move.l	-$65C(a5),d0
		beq.s	loc_7B7A
		move.b	-$658(a5),d0
		subq.b	#1,d0
		movea.l	-$65C(a5),a0
		move.b	d0,$1E(a0)
		move.l	-$65C(a5),-(sp)
		jsr	IdleMailbox
		addq.w	#4,sp

loc_7B7A:				; CODE XREF: WritePString+Ej
		moveq	#0,d0
		move.l	d0,-$65C(a5)
		clr.b	-$658(a5)

loc_7B84:				; CODE XREF: WritePString+8j
		unlk	a6
		rts
; End of function WritePString

; ---------------------------------------------------------------------------
aWriteline:	dc.b 137,'WriteLine',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteLine:				; CODE XREF: VoiceStart+54p
					; ResetModem+20p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2,-(sp)
		move.b	arg_0(a6),d3
		moveq	#0,d0
		move.b	d3,d0
		asr.l	#4,d0
		lea	-$66E(a5),a2
		move.b	(a2,d0.w),-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		moveq	#$F,d1
		and.b	d1,d3
		moveq	#0,d0
		move.b	d3,d0
		move.b	(a2,d0.w),-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function WriteLine

; ---------------------------------------------------------------------------
aWritebyte:	dc.b 137,'WriteByte',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteByte:				; CODE XREF: WriteHex+Cp WriteWord+Cp

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	arg_4(a6),d3
		bra.s	loc_7BFA
; ---------------------------------------------------------------------------

loc_7BF0:				; CODE XREF: WriteByte+24j
		move.b	(a2)+,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp

loc_7BFA:				; CODE XREF: WriteByte+10j
		subq.l	#1,d3
		cmpi.l	#0,d3
		bpl.s	loc_7BF0
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function WriteByte

; ---------------------------------------------------------------------------
aWritehex0:	dc.b 137,'WriteHex0',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteHex0:				; CODE XREF: First+54p
					; PH_DATA_REQUEST+16p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		subq.l	#1,arg_4(a6)
		move.l	arg_4(a6),d0
		bpl.s	loc_7C3C

loc_7C26:				; CODE XREF: WriteHex0+36j
		subq.l	#1,arg_4(a6)
		move.l	arg_4(a6),d0
		bmi.s	loc_7C50
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_7C3C:				; CODE XREF: WriteHex0+Cj
		movea.l	arg_0(a6),a0
		addq.l	#1,arg_0(a6)
		move.b	(a0),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		bra.s	loc_7C26
; ---------------------------------------------------------------------------

loc_7C50:				; CODE XREF: WriteHex0+16j
		unlk	a6
		rts
; End of function WriteHex0

; ---------------------------------------------------------------------------
aWritehex:	dc.b 136,'WriteHex',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteHex:				; CODE XREF: InitMemory+5Cp
					; InitMemory+74p ...

arg_0		=  8

		link	a6,#0
		moveq	#2,d0
		move.l	d0,-(sp)
		pea	arg_0(a6)
		jsr	(WriteByte).l
		unlk	a6
		rts
; End of function WriteHex

; ---------------------------------------------------------------------------
aWriteword:	dc.b 137,'WriteWord',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteWord:				; CODE XREF: First+3Ap	ConnectHscx+68p ...

arg_0		=  8

		link	a6,#0
		moveq	#4,d0
		move.l	d0,-(sp)
		pea	arg_0(a6)
		jsr	(WriteByte).l
		unlk	a6
		rts
; End of function WriteWord

; ---------------------------------------------------------------------------
aWritelong:	dc.b 137,'WriteLong',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteLong:				; CODE XREF: PH_INTERRUPT+14p
					; dl_cmd_resp_request+Cp ...

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	-$52(a5),d0
		beq.s	loc_7D00
		move.l	$10(a3),d3
		move.l	d3,var_8(a6)
		neg.l	d3
		move.l	d3,-(sp)
		movea.l	a3,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	var_8(a6),d0
		move.l	a2,var_4(a6)
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		moveq	#$2D,d0	; '-'
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	$14(a3),-(sp)
		movea.l	var_4(a6),a0
		move.l	a0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		jsr	(WritePString).l

loc_7D00:				; CODE XREF: WriteLong+10j
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function WriteLong

; ---------------------------------------------------------------------------
aWritemsg:	dc.b 136,'WriteMsg',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteMsg:				; DATA XREF: monitor_request+36o
					; monitor_request+DAo ...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function WriteMsg

; ---------------------------------------------------------------------------
aLogstring:	dc.b 137,'LogString',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

LogString:				; DATA XREF: LeoPrivateIrq+180o
					; HuntIrq+128o	...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function LogString

; ---------------------------------------------------------------------------
aLogint:	dc.b 134,'LogInt',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

LogInt:					; CODE XREF: WriteDeviceProtocol+28p
					; B_ATTACH+28p	...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	4(a2),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	$E(a2),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		jsr	(WritePString).l
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function LogInt

; ---------------------------------------------------------------------------
aWritedeviceprotocol:dc.b 147,'WriteDeviceProtocol',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteDeviceProtocol:			; DATA XREF: SendMessage+106o

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	-$656(a5),a3
		movea.l	$C(a4),a2
		movea.l	a2,a0
		addq.w	#8,a0
		move.l	a0,var_4(a6)
		bra.s	loc_7E2E
; ---------------------------------------------------------------------------

loc_7DE4:				; CODE XREF: WriteDeviceProtocol+6Aj
		movea.l	8(a3),a0
		cmpa.l	a2,a0
		bne.s	loc_7E2C
		move.l	a3,-(sp)
		jsr	(LogInt).l
		addq.w	#4,sp
		movea.l	var_4(a6),a0
		move.b	(a0),d0
		move.b	d0,$F(a3)
		move.l	a4,d0
		bne.s	loc_7E12
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4

loc_7E12:				; CODE XREF: WriteDeviceProtocol+3Cj
		move.l	$14(a3),d0
		move.l	d0,4(a4)
		move.l	a3,$C(a4)
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		moveq	#0,d0
		movea.l	d0,a4

loc_7E2C:				; CODE XREF: WriteDeviceProtocol+24j
		movea.l	(a3),a3

loc_7E2E:				; CODE XREF: WriteDeviceProtocol+1Cj
		move.l	a3,d0
		bne.s	loc_7DE4
		move.l	a4,d0
		beq.s	loc_7E46
		jsr	(WriteBegin).l
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_7E46:				; CODE XREF: WriteDeviceProtocol+6Ej
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function WriteDeviceProtocol

; ---------------------------------------------------------------------------
aB_attach:	dc.b 136,'B_ATTACH',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_ATTACH:				; DATA XREF: SendConnect1TR6SPV+38o
					; SendConnect1TR6SPV+66o ...

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	-$656(a5),a3
		movea.l	$C(a4),a2
		movea.l	a2,a0
		addq.w	#8,a0
		move.l	a0,var_4(a6)
		bra.s	loc_7EC2
; ---------------------------------------------------------------------------

loc_7E78:				; CODE XREF: B_ATTACH+6Aj
		movea.l	8(a3),a0
		cmpa.l	a2,a0
		bne.s	loc_7EC0
		move.l	a3,-(sp)
		jsr	(LogInt).l
		addq.w	#4,sp
		movea.l	var_4(a6),a0
		move.b	(a0),d0
		move.b	d0,$F(a3)
		move.l	a4,d0
		bne.s	loc_7EA6
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4

loc_7EA6:				; CODE XREF: B_ATTACH+3Cj
		move.l	$18(a3),d0
		move.l	d0,4(a4)
		move.l	a3,$C(a4)
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		moveq	#0,d0
		movea.l	d0,a4

loc_7EC0:				; CODE XREF: B_ATTACH+24j
		movea.l	(a3),a3

loc_7EC2:				; CODE XREF: B_ATTACH+1Cj
		move.l	a3,d0
		bne.s	loc_7E78
		move.l	a4,d0
		beq.s	loc_7EDA
		jsr	(WriteBegin).l
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_7EDA:				; CODE XREF: B_ATTACH+6Ej
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function B_ATTACH

; ---------------------------------------------------------------------------
aB_listen:	dc.b 136,'B_LISTEN',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_LISTEN:				; DATA XREF: A_CALL_CONTROL+74o
					; A_SETUP_1TR6+Co

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$C(a4),a2
		movea.l	-$656(a5),a3
		bra.s	loc_7F44
; ---------------------------------------------------------------------------

loc_7F04:				; CODE XREF: B_LISTEN+58j
		movea.l	8(a3),a0
		cmpa.l	a2,a0
		bne.s	loc_7F42
		move.l	a3,-(sp)
		jsr	(LogInt).l
		addq.w	#4,sp
		move.l	a4,d0
		bne.s	loc_7F28
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4

loc_7F28:				; CODE XREF: B_LISTEN+2Aj
		move.l	$1C(a3),d0
		move.l	d0,4(a4)
		move.l	a3,$C(a4)
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		moveq	#0,d0
		movea.l	d0,a4

loc_7F42:				; CODE XREF: B_LISTEN+1Cj
		movea.l	(a3),a3

loc_7F44:				; CODE XREF: B_LISTEN+14j
		move.l	a3,d0
		bne.s	loc_7F04
		move.l	a4,d0
		beq.s	loc_7F5C
		jsr	(WriteBegin).l
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_7F5C:				; CODE XREF: B_LISTEN+5Cj
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function B_LISTEN

; ---------------------------------------------------------------------------
aB_connect:	dc.b 137,'B_CONNECT',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_CONNECT:				; DATA XREF: A_CONNECT_ACKNOWLEDGE+Co
					; A_CALL_CLEAR_1TR6+Co	...

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$C(a4),a2
		movea.l	-$656(a5),a3
		bra.s	loc_7FD6
; ---------------------------------------------------------------------------

loc_7F86:				; CODE XREF: B_CONNECT+68j
		movea.l	8(a3),a0
		cmpa.l	a2,a0
		bne.s	loc_7FD4
		moveq	#0,d0
		move.l	d0,8(a3)
		tst.b	$F(a3)
		beq.s	loc_7FD4
		move.l	a3,-(sp)
		jsr	(LogInt).l
		addq.w	#4,sp
		clr.b	$F(a3)
		move.l	a4,d0
		bne.s	loc_7FBA
		moveq	#$10,d0
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4

loc_7FBA:				; CODE XREF: B_CONNECT+3Aj
		move.l	$20(a3),d0
		move.l	d0,4(a4)
		move.l	a3,$C(a4)
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		moveq	#0,d0
		movea.l	d0,a4

loc_7FD4:				; CODE XREF: B_CONNECT+1Cj
					; B_CONNECT+28j
		movea.l	(a3),a3

loc_7FD6:				; CODE XREF: B_CONNECT+14j
		move.l	a3,d0
		bne.s	loc_7F86
		moveq	#0,d0
		move.l	d0,$2E(a2)
		move.l	a4,d0
		beq.s	loc_7FEE
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_7FEE:				; CODE XREF: B_CONNECT+72j
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function B_CONNECT

; ---------------------------------------------------------------------------
aB_disconnect:	dc.b 140,'B_DISCONNECT',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_DISCONNECT:				; DATA XREF: dl_transition+1Ao

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a4
		move.b	$E(a4),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		moveq	#$20,d3	; ' '
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	8(a4),-(sp)
		jsr	(WriteString).l
		addq.w	#4,sp
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	$D(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#2,d3
		asl.l	d3,d0
		lea	-$64E(a5),a2
		move.l	(a2,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	(asc_80BD+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a4,a3
		moveq	#$C,d1
		adda.l	d1,a3
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	d3,d0
		move.l	(a2,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	(a3),d0
		move.b	d0,$D(a4)
		move.b	(a3),d3
		beq.s	loc_809A
		moveq	#4,d0
		cmp.b	d0,d3
		bcc.s	loc_809A
		clr.b	$E(a4)

loc_809A:				; CODE XREF: B_DISCONNECT+88j
					; B_DISCONNECT+8Ej
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function B_DISCONNECT

; ---------------------------------------------------------------------------
aDl_transition:	dc.b 141,'dl_transition',0
asc_80BD:	dc.b 6,' -> ',0,0       ; DATA XREF: B_DISCONNECT+5Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_transition:				; CODE XREF: MDL_UNITDATA_INDICATION+42p
					; MDL_UNITDATA_INDICATION+78p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	$C(a3),d0
		move.b	arg_4(a6),d3
		cmp.b	d3,d0
		beq.s	loc_80F0
		move.l	a3,-(sp)
		pea	(B_DISCONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	d3,$C(a3)

loc_80F0:				; CODE XREF: dl_transition+16j
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function dl_transition

; ---------------------------------------------------------------------------
aDl_transition_0:dc.b 141,'DL_transition',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_transition:				; CODE XREF: dl_set_datalink_able_to_establis+16p
					; dl_establish+98p ...

arg_0		=  8
arg_2		=  $A
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_815E
		jsr	(WriteProc).l
		moveq	#$FFFFFFFD,d0
		move.l	d0,$10(a2)
		move.b	arg_2(a6),$1B(a2)
		move.b	arg_4(a6),d3
		add.b	d3,d3
		addq.b	#1,d3
		move.b	d3,$1C(a2)
		move.b	arg_0(a6),$1D(a2)
		lea	(PH_INTERRUPT).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_815E:				; CODE XREF: DL_transition+1Cj
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function DL_transition

; ---------------------------------------------------------------------------
aDl_cmd_resp_request:dc.b 147,'dl_cmd_resp_request',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_cmd_resp_request:			; DATA XREF: MDL_ERROR_INDICATION+8Eo
					; MDL_ASSIGN_INDICATION+190o ...

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	a2,-(sp)
		jsr	(WriteLong).l
		addq.w	#4,sp
		move.b	#$FC,$1B(a2)
		move.b	#$FF,$1C(a2)
		move.b	#3,$1D(a2)
		moveq	#$FFFFFFFD,d0
		move.l	d0,$10(a2)
		lea	(PH_INTERRUPT).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function dl_cmd_resp_request

; ---------------------------------------------------------------------------
aMdl_unitdata_request:dc.b 148,'MDL_UNITDATA_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_UNITDATA_REQUEST:			; DATA XREF: dl_data_request:loc_82DAo

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a4
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,var_4(a6)
		tst.l	d0
		beq.w	loc_829E
		move.w	a2,d4
		moveq	#$1E,d1
		add.w	d1,d4
		sub.w	arg_0+2(a6),d4
		move.l	$14(a2),d1
		add.w	d1,d4
		ble.s	loc_8224
		move.w	d4,d0
		subq.w	#1,d0
		movea.l	a2,a0
		movea.l	var_4(a6),a1

loc_821E:				; CODE XREF: MDL_UNITDATA_REQUEST+46j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_821E

loc_8224:				; CODE XREF: MDL_UNITDATA_REQUEST+38j
		moveq	#$FFFFFFFC,d0
		movea.l	var_4(a6),a0
		move.l	d0,$10(a0)
		clr.b	$1A(a0)
		move.b	$E(a4),d3
		move.b	d3,d0
		add.b	d0,d3
		addq.b	#1,d3
		move.b	d3,$1B(a0)
		movea.l	a4,a3
		moveq	#$18,d0
		adda.l	d0,a3
		move.b	(a3),d0
		move.b	d0,$1C(a0)
		move.b	$16(a4),d0
		move.b	d0,$1D(a0)
		move.l	$1A(a0),d0
		move.l	d0,$1A(a2)
		lea	(PH_INTERRUPT).l,a1
		move.l	a1,4(a0)
		move.l	a0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	(a3),d0
		addq.b	#2,d0
		move.b	d0,(a3)
		move.b	$14(a4),d0
		moveq	#8,d1
		and.b	d1,d0
		bne.s	loc_829E
		movea.l	a4,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#$F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_829E:				; CODE XREF: MDL_UNITDATA_REQUEST+24j
					; MDL_UNITDATA_REQUEST+A4j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function MDL_UNITDATA_REQUEST

; ---------------------------------------------------------------------------
aDl_data_request:dc.b 143,'dl_data_request',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_data_request:			; DATA XREF: nl_transition+Ao

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$C(a4),a3
		cmpa.w	#0,a3
		bne.s	loc_82DA
		lea	-$510(a5),a3
		lea	-$510(a5),a0
		move.l	a0,$C(a4)

loc_82DA:				; CODE XREF: dl_data_request+14j
		lea	(MDL_UNITDATA_REQUEST).l,a0
		move.l	a0,4(a4)
		move.b	$C(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_832E
		moveq	#7,d1
		cmp.l	d1,d0
		beq.s	loc_8300
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_832E
		bra.s	loc_8342
; ---------------------------------------------------------------------------

loc_8300:				; CODE XREF: dl_data_request+3Ej
		movea.l	a3,a0
		moveq	#$1C,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a4,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_8352
		move.b	$14(a3),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_8322
		bra.s	loc_8352
; ---------------------------------------------------------------------------

loc_8322:				; CODE XREF: dl_data_request+66j
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		bra.s	loc_8352
; ---------------------------------------------------------------------------

loc_832E:				; CODE XREF: dl_data_request+38j
					; dl_data_request+44j
		movea.l	a3,a0
		moveq	#$1C,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a4,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		bra.s	loc_8352
; ---------------------------------------------------------------------------

loc_8342:				; CODE XREF: dl_data_request+46j
		jsr	(WriteBegin).l
		move.l	a4,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_8352:				; CODE XREF: dl_data_request+5Cj
					; dl_data_request+68j ...
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function dl_data_request

; ---------------------------------------------------------------------------
aDl_data_request_0:dc.b	143,'DL_DATA_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_DATA_REQUEST:			; CODE XREF: MDL_ASSIGN_INDICATION+10Ap
					; dl_establish+74p ...

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_2(a6),a3
		jsr	(WritePString).l
		pea	aMdl_error_indication_0	; "MDL_ERROR_INDICATION	("
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	arg_0(a6),-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		pea	(asc_8435+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	8(a3),-(sp)
		jsr	(WriteString).l
		addq.w	#4,sp
		moveq	#1,d0
		move.b	arg_0(a6),d2
		moveq	#$1F,d3
		and.b	d3,d2
		moveq	#0,d1
		move.b	d2,d1
		ext.l	d1
		asl.l	d1,d0
		andi.l	#$30198,d0
		beq.s	loc_8416
		cmpi.b	#$50,arg_0(a6) ; 'P'
		bne.s	loc_83D4
		clr.b	-$51A(a5)

loc_83D4:				; CODE XREF: DL_DATA_REQUEST+62j
		move.b	$C(a3),d0
		moveq	#4,d1
		cmp.b	d1,d0
		bcs.s	loc_83E8
		move.l	a3,-(sp)
		jsr	DL_RELEASE_REQUEST
		addq.w	#4,sp

loc_83E8:				; CODE XREF: DL_DATA_REQUEST+70j
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	a3,a0
		moveq	#$34,d0	; '4'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		clr.b	d0
		move.b	d0,$1A(a3)
		move.b	d0,$19(a3)
		move.b	d0,$15(a3)

loc_8416:				; CODE XREF: DL_DATA_REQUEST+5Aj
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function DL_DATA_REQUEST

; ---------------------------------------------------------------------------
aMdl_error_indication:dc.b 148,'MDL_ERROR_INDICATION',0,0
asc_8435:	dc.b 28,') ',0,0        ; DATA XREF: DL_DATA_REQUEST+2Ao
aMdl_error_indication_0:dc.b 'MDL_ERROR_INDICATION (',0,0 ; DATA XREF: DL_DATA_REQUEST+12o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_ERROR_INDICATION:			; CODE XREF: mdl_assign_indication+1Ep
					; mdl_assign_timer+46p

var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$14
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,var_10(a6)
		tst.l	d0
		beq.w	loc_84F4
		movea.l	d0,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		move.l	-$D1C(a5),d0
		addq.l	#1,-$D1C(a5)
		move.w	d0,var_14(a6)
		tst.w	d0
		bne.s	loc_8492
		moveq	#$FFFFFFFF,d0
		move.w	d0,var_14(a6)

loc_8492:				; CODE XREF: MDL_ERROR_INDICATION+38j
		move.b	#$F,(a4)
		move.b	var_14(a6),d0
		move.b	d0,1(a4)
		move.b	d0,$19(a3)
		move.b	var_14+1(a6),d0
		move.b	d0,2(a4)
		move.b	d0,$1A(a3)
		moveq	#1,d3
		move.b	d3,3(a4)
		movea.l	a4,a2
		addq.w	#4,a2
		move.l	a2,var_C(a6)
		move.l	a2,var_4(a6)
		move.b	(a2),d0
		ori.b	#$FE,d0
		move.b	d0,(a2)
		movea.l	var_4(a6),a0
		move.l	a0,var_8(a6)
		move.b	(a0),d0
		or.b	d3,d0
		move.b	d0,(a0)
		moveq	#5,d0
		movea.l	var_10(a6),a2
		move.l	d0,$14(a2)
		lea	(dl_cmd_resp_request).l,a0
		move.l	a0,4(a2)
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_84F4:				; CODE XREF: MDL_ERROR_INDICATION+20j
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#$1F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		move.b	-$4C6(a5),d0
		beq.s	loc_851E
		move.b	#1,$11(a3)

loc_851E:				; CODE XREF: MDL_ERROR_INDICATION+C4j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function MDL_ERROR_INDICATION

; ---------------------------------------------------------------------------
aMdl_assign_indication:dc.b 149,'mdl_assign_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

mdl_assign_indication:			; CODE XREF: dl_establish+58p

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		addq.b	#1,$15(a3)
		move.b	$15(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		subq.w	#3,d0
		tst.w	d0
		bpl.s	loc_8566
		move.l	a3,-(sp)
		jsr	MDL_ERROR_INDICATION
		addq.w	#4,sp
		bra.s	loc_857E
; ---------------------------------------------------------------------------

loc_8566:				; CODE XREF: mdl_assign_indication+1Aj
		move.l	a3,-(sp)
		jsr	MDL_REMOVE_REQUEST
		addq.w	#4,sp
		clr.b	d0
		move.b	d0,$1A(a3)
		move.b	d0,$19(a3)
		move.b	d0,$15(a3)

loc_857E:				; CODE XREF: mdl_assign_indication+26j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function mdl_assign_indication

; ---------------------------------------------------------------------------
aMdl_assign_timer:dc.b 144,'mdl_assign_timer',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

mdl_assign_timer:			; CODE XREF: MDL_UNITDATA_INDICATION+A0p
					; dl_timer_indication+7Cp

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		clr.b	d3
		move.b	d3,$1A(a3)
		move.b	d3,$19(a3)
		move.b	d3,$15(a3)
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_85CE
		clr.b	-(sp)
		move.l	a3,-(sp)
		jsr	MDL_ERROR_RESPONSE
		addq.w	#6,sp
		bra.s	loc_85E6
; ---------------------------------------------------------------------------

loc_85CE:				; CODE XREF: mdl_assign_timer+26j
		clr.b	d0
		move.b	d0,$1A(a3)
		move.b	d0,$19(a3)
		move.b	d0,$15(a3)
		move.l	a3,-(sp)
		jsr	MDL_ERROR_INDICATION
		addq.w	#4,sp

loc_85E6:				; CODE XREF: mdl_assign_timer+34j
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function mdl_assign_timer

; ---------------------------------------------------------------------------
aMdl_assign_indication_0:dc.b 149,'MDL_ASSIGN_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_ASSIGN_INDICATION:			; DATA XREF: dl_s_or_i_indication+110o

var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$10
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	-$518(a5),a4
		movea.l	arg_0(a6),a3
		moveq	#$1E,d0
		adda.l	d0,a3
		move.b	(a3),d0
		moveq	#$F,d1
		cmp.b	d1,d0
		bne.w	loc_87F2
		move.b	3(a3),d3
		moveq	#7,d0
		cmp.b	d0,d3
		bhi.s	loc_8634
		moveq	#0,d0
		move.b	d3,d0
		bra.s	loc_8636
; ---------------------------------------------------------------------------

loc_8634:				; CODE XREF: MDL_ASSIGN_INDICATION+26j
		moveq	#0,d0

loc_8636:				; CODE XREF: MDL_ASSIGN_INDICATION+2Cj
		asl.l	#2,d0
		lea	-$62A(a5),a0
		move.l	(a0,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	4(a3),d0
		lsr.b	#1,d0
		beq.w	loc_87DC
		move.b	#1,-$51A(a5)
		bra.w	loc_87DC
; ---------------------------------------------------------------------------

loc_865C:				; CODE XREF: MDL_ASSIGN_INDICATION+1E8j
		move.b	3(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_8686
		moveq	#3,d1
		cmp.l	d1,d0
		beq.w	loc_87D8
		moveq	#4,d1
		cmp.l	d1,d0
		beq.w	loc_871C
		moveq	#6,d1
		cmp.l	d1,d0
		beq.w	loc_87B0
		bra.w	loc_87D8
; ---------------------------------------------------------------------------

loc_8686:				; CODE XREF: MDL_ASSIGN_INDICATION+62j
		move.b	$C(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_86AA
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_86AA
		tst.l	d0
		beq.w	loc_87D8
		moveq	#1,d1
		cmp.l	d1,d0
		beq.w	loc_87D8
		bra.s	loc_86FA
; ---------------------------------------------------------------------------

loc_86AA:				; CODE XREF: MDL_ASSIGN_INDICATION+8Cj
					; MDL_ASSIGN_INDICATION+92j
		move.b	$19(a4),d0
		move.b	1(a3),d1
		cmp.b	d1,d0
		bne.w	loc_87D8
		move.b	$1A(a4),d0
		move.b	2(a3),d1
		cmp.b	d1,d0
		bne.w	loc_87D8
		clr.b	d0
		move.b	d0,$1A(a4)
		move.b	d0,$19(a4)
		move.b	d0,$15(a4)
		movea.l	a4,a0
		moveq	#$24,d0	; '$'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.b	4(a3),d0
		lsr.b	#1,d0
		move.b	d0,-(sp)
		move.l	a4,-(sp)
		jsr	MDL_ERROR_RESPONSE
		addq.w	#6,sp
		bra.w	loc_87D8
; ---------------------------------------------------------------------------

loc_86FA:				; CODE XREF: MDL_ASSIGN_INDICATION+A2j
		move.b	4(a3),d0
		lsr.b	#1,d0
		move.b	$E(a4),d1
		cmp.b	d1,d0
		bne.w	loc_87D8
		move.l	a4,-(sp)
		moveq	#$51,d0	; 'Q'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		bra.w	loc_87D8
; ---------------------------------------------------------------------------

loc_871C:				; CODE XREF: MDL_ASSIGN_INDICATION+70j
		move.b	$C(a4),d0
		moveq	#4,d1
		cmp.b	d1,d0
		bcs.w	loc_87D8
		move.b	4(a3),d3
		moveq	#1,d4
		lsr.b	d4,d3
		moveq	#$7F,d0	; ''
		cmp.b	d0,d3
		beq.s	loc_8740
		move.b	$E(a4),d0
		cmp.b	d0,d3
		bne.w	loc_87D8

loc_8740:				; CODE XREF: MDL_ASSIGN_INDICATION+12Ej
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,var_10(a6)
		tst.l	d0
		beq.s	loc_87AA
		moveq	#4,d0
		movea.l	var_C(a6),a0
		movea.l	var_10(a6),a2
		moveq	#$1E,d1
		adda.l	d1,a2
		movea.l	a2,a1

loc_8766:				; CODE XREF: MDL_ASSIGN_INDICATION+162j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_8766
		movea.l	a2,a3
		move.b	#5,3(a3)
		move.b	$E(a4),d0
		lsl.b	d4,d0
		movea.l	a3,a0
		addq.w	#4,a0
		move.l	a0,var_8(a6)
		move.b	(a0),d1
		andi.b	#1,d1
		or.b	d1,d0
		move.b	d0,(a0)
		moveq	#5,d0
		movea.l	var_10(a6),a0
		move.l	d0,$14(a0)
		lea	(dl_cmd_resp_request).l,a1
		move.l	a1,4(a0)
		move.l	a0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_87AA:				; CODE XREF: MDL_ASSIGN_INDICATION+14Ej
		movea.l	var_4(a6),a3
		bra.s	loc_87D8
; ---------------------------------------------------------------------------

loc_87B0:				; CODE XREF: MDL_ASSIGN_INDICATION+78j
		move.b	$C(a4),d0
		moveq	#4,d1
		cmp.b	d1,d0
		bcs.s	loc_87D8
		move.b	4(a3),d3
		lsr.b	#1,d3
		moveq	#$7F,d0	; ''
		cmp.b	d0,d3
		beq.s	loc_87CE
		move.b	$E(a4),d0
		cmp.b	d0,d3
		bne.s	loc_87D8

loc_87CE:				; CODE XREF: MDL_ASSIGN_INDICATION+1BEj
		move.l	a4,-(sp)
		jsr	DL_RELEASE_REQUEST
		addq.w	#4,sp

loc_87D8:				; CODE XREF: MDL_ASSIGN_INDICATION+68j
					; MDL_ASSIGN_INDICATION+7Cj ...
		movea.l	(a4),a4
		bra.s	loc_87EC
; ---------------------------------------------------------------------------

loc_87DC:				; CODE XREF: MDL_ASSIGN_INDICATION+48j
					; MDL_ASSIGN_INDICATION+52j
		movea.l	arg_0(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	a2,var_C(a6)
		move.l	a2,var_4(a6)

loc_87EC:				; CODE XREF: MDL_ASSIGN_INDICATION+1D4j
		move.l	a4,d0
		bne.w	loc_865C

loc_87F2:				; CODE XREF: MDL_ASSIGN_INDICATION+1Aj
		move.l	arg_0(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function MDL_ASSIGN_INDICATION

; ---------------------------------------------------------------------------
aMdl_unitdata_indication:dc.b 151,'MDL_UNITDATA_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_UNITDATA_INDICATION:		; DATA XREF: ph_persistant_deactivation:loc_2E7Ao
					; PH_ACTIVATE_REQUEST+40o

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	-$518(a5),a3
		jsr	(WriteProc).l
		bra.w	loc_88E0
; ---------------------------------------------------------------------------

loc_8834:				; CODE XREF: MDL_UNITDATA_INDICATION+C2j
		tst.b	$C(a3)
		bne.w	loc_88DE
		tst.b	$F(a3)
		bne.s	loc_8856
		tst.b	$10(a3)
		beq.s	loc_88A2
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		andi.b	#$80,d0
		bne.s	loc_88A2

loc_8856:				; CODE XREF: MDL_UNITDATA_INDICATION+20j
		tst.b	$E(a3)
		beq.s	loc_8892
		moveq	#4,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.b	-$4C6(a5),d0
		bne.s	loc_8880
		move.l	a3,-(sp)
		pea	(InitDLink).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8880:				; CODE XREF: MDL_UNITDATA_INDICATION+4Ej
		move.l	a3,-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_88DE
; ---------------------------------------------------------------------------

loc_8892:				; CODE XREF: MDL_UNITDATA_INDICATION+3Aj
		moveq	#3,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		bra.s	loc_88BE
; ---------------------------------------------------------------------------

loc_88A2:				; CODE XREF: MDL_UNITDATA_INDICATION+26j
					; MDL_UNITDATA_INDICATION+34j
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_88CA
		move.b	d1,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_88BE:				; CODE XREF: MDL_UNITDATA_INDICATION+80j
		move.l	a3,-(sp)
		jsr	mdl_assign_timer
		addq.w	#4,sp
		bra.s	loc_88DE
; ---------------------------------------------------------------------------

loc_88CA:				; CODE XREF: MDL_UNITDATA_INDICATION+8Ej
		tst.b	$E(a3)
		bne.s	loc_88DE
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_88DE:				; CODE XREF: MDL_UNITDATA_INDICATION+18j
					; MDL_UNITDATA_INDICATION+70j ...
		movea.l	(a3),a3

loc_88E0:				; CODE XREF: MDL_UNITDATA_INDICATION+10j
		move.l	a3,d0
		bne.w	loc_8834
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function MDL_UNITDATA_INDICATION

; ---------------------------------------------------------------------------
aPh_activate_indication_0:dc.b 150,'PH_ACTIVATE_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_ACTIVATE_INDICATION:			; DATA XREF: ph_transition+36o

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2,-(sp)
		movea.l	-$518(a5),a2
		jsr	(WriteProc).l
		clr.b	d3
		move.b	d3,-$51A(a5)
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$26,d1	; '&'
		cmp.b	d1,d0
		beq.w	loc_89DA
		move.b	d3,-$4C6(a5)
		bra.w	loc_89DA
; ---------------------------------------------------------------------------

loc_8942:				; CODE XREF: PH_ACTIVATE_INDICATION+CAj
		move.b	$C(a2),d0
		move.b	d0,var_4(a6)
		moveq	#4,d1
		cmp.b	d1,d0
		beq.s	loc_8960
		move.l	a2,-(sp)
		pea	(dl_user_connect_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8960:				; CODE XREF: PH_ACTIVATE_INDICATION+3Cj
		move.b	var_4(a6),d3
		moveq	#3,d0
		cmp.b	d0,d3
		beq.s	loc_8976
		moveq	#5,d0
		cmp.b	d0,d3
		beq.s	loc_8976
		moveq	#7,d0
		cmp.b	d0,d3
		bcs.s	loc_8988

loc_8976:				; CODE XREF: PH_ACTIVATE_INDICATION+56j
					; PH_ACTIVATE_INDICATION+5Cj
		move.l	a2,-(sp)
		pea	(DL_RELEASE_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_89A0
; ---------------------------------------------------------------------------

loc_8988:				; CODE XREF: PH_ACTIVATE_INDICATION+62j
		cmpi.b	#6,var_4(a6)
		bne.s	loc_89A0
		move.l	a2,-(sp)
		pea	(DL_ESTABLISH_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_89A0:				; CODE XREF: PH_ACTIVATE_INDICATION+74j
					; PH_ACTIVATE_INDICATION+7Cj
		clr.b	-(sp)
		move.l	a2,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.l	a2,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp
		movea.l	a2,a0
		moveq	#$24,d0	; '$'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		clr.b	d0
		move.b	d0,$1A(a2)
		move.b	d0,$19(a2)
		move.b	d0,$15(a2)
		move.b	d0,$F(a2)
		movea.l	(a2),a2

loc_89DA:				; CODE XREF: PH_ACTIVATE_INDICATION+24j
					; PH_ACTIVATE_INDICATION+2Cj
		move.l	a2,d0
		bne.w	loc_8942
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function PH_ACTIVATE_INDICATION

; ---------------------------------------------------------------------------
aPh_deactivate_indication_0:dc.b 152,'PH_DEACTIVATE_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_DEACTIVATE_INDICATION:		; CODE XREF: B_USAGECHANGE_INDICATION+Cp
					; CmdActiv+6p

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4/a3,-(sp)
		movea.l	-$518(a5),a3
		jsr	(WriteProc).l
		move.b	arg_0(a6),d4
		seq	d4
		neg.b	d4
		ext.w	d4
		ext.l	d4
		bra.s	loc_8A7E
; ---------------------------------------------------------------------------

loc_8A30:				; CODE XREF: PH_DEACTIVATE_INDICATION+70j
		move.b	arg_0(a6),d3
		move.b	d3,$10(a3)
		tst.b	d3
		beq.s	loc_8A58
		move.b	$C(a3),d0
		moveq	#7,d1
		cmp.b	d1,d0
		bcc.s	loc_8A58
		move.l	a3,-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_8A7C
; ---------------------------------------------------------------------------

loc_8A58:				; CODE XREF: PH_DEACTIVATE_INDICATION+2Aj
					; PH_DEACTIVATE_INDICATION+34j
		tst.l	d4
		beq.s	loc_8A7C
		move.b	$C(a3),d0
		moveq	#4,d1
		cmp.b	d1,d0
		bls.s	loc_8A7C
		tst.b	$E(a3)
		beq.s	loc_8A7C
		move.l	a3,-(sp)
		pea	(DL_ESTABLISH_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8A7C:				; CODE XREF: PH_DEACTIVATE_INDICATION+46j
					; PH_DEACTIVATE_INDICATION+4Aj	...
		movea.l	(a3),a3

loc_8A7E:				; CODE XREF: PH_DEACTIVATE_INDICATION+1Ej
		move.l	a3,d0
		bne.s	loc_8A30
		movem.l	(sp)+,d3-d4/a3
		unlk	a6
		rts
; End of function PH_DEACTIVATE_INDICATION

; ---------------------------------------------------------------------------
aDl_set_datalink_able_to_establi:dc.b 128,'!dl_set_datalink_able_to_establis',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_set_datalink_able_to_establis:	; CODE XREF: dl_establish+1B6p
					; dl_timer_indication+96p ...

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	$E(a3),-(sp)
		clr.b	-(sp)
		moveq	#$7F,d0	; ''
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp
		clr.b	d0
		move.b	d0,$16(a3)
		move.b	d0,$17(a3)
		move.b	d0,$18(a3)
		move.b	d0,$15(a3)
		move.b	d0,$14(a3)
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#$F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		moveq	#5,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function dl_set_datalink_able_to_establis

; ---------------------------------------------------------------------------
aDl_establish:	dc.b 140,'dl_establish',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_establish:				; DATA XREF: PH_DATA_INDICATION+1Ao

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		jsr	(WriteProc).l
		move.l	8(a3),-(sp)
		jsr	(WriteString).l
		addq.w	#4,sp
		move.b	$C(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_8B7C
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_8B7C
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_8B8A
		moveq	#6,d1
		cmp.l	d1,d0
		beq.s	loc_8BC8
		moveq	#7,d1
		cmp.l	d1,d0
		beq.w	loc_8C2E
		moveq	#8,d1
		cmp.l	d1,d0
		beq.w	loc_8C46
		bra.w	loc_8CEA
; ---------------------------------------------------------------------------

loc_8B7C:				; CODE XREF: dl_establish+2Ej
					; dl_establish+34j
		move.l	a3,-(sp)
		jsr	mdl_assign_indication
		addq.w	#4,sp
		bra.w	loc_8CF0
; ---------------------------------------------------------------------------

loc_8B8A:				; CODE XREF: dl_establish+3Aj
		move.b	$15(a3),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_8BB4
		move.l	a3,-(sp)
		moveq	#$47,d0	; 'G'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		move.l	a3,-(sp)
		pea	(DL_RELEASE_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_8BF0
; ---------------------------------------------------------------------------

loc_8BB4:				; CODE XREF: dl_establish+6Cj
		move.b	$E(a3),-(sp)
		clr.b	-(sp)
		moveq	#$7F,d0	; ''
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp
		bra.s	loc_8C18
; ---------------------------------------------------------------------------

loc_8BC8:				; CODE XREF: dl_establish+40j
		move.b	$15(a3),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_8C06
		move.l	a3,-(sp)
		moveq	#$48,d0	; 'H'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		move.l	a3,-(sp)
		pea	(DL_ESTABLISH_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8BF0:				; CODE XREF: dl_establish+8Cj
		moveq	#4,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		clr.b	$15(a3)
		bra.w	loc_8CF0
; ---------------------------------------------------------------------------

loc_8C06:				; CODE XREF: dl_establish+AAj
		move.b	$E(a3),-(sp)
		clr.b	-(sp)
		moveq	#$53,d0	; 'S'
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp

loc_8C18:				; CODE XREF: dl_establish+A0j
		moveq	#$F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		addq.b	#1,$15(a3)
		bra.w	loc_8CF0
; ---------------------------------------------------------------------------

loc_8C2E:				; CODE XREF: dl_establish+46j
		clr.b	$15(a3)
		moveq	#8,d3
		move.b	d3,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		ori.b	#8,$14(a3)

loc_8C46:				; CODE XREF: dl_establish+4Ej
		move.b	$15(a3),d0
		addq.b	#1,$15(a3)
		moveq	#3,d1
		cmp.b	d1,d0
		bcc.s	loc_8CBE
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a4
		cmpa.w	#0,a4
		beq.w	loc_8CF0
		moveq	#$FFFFFFFC,d0
		move.l	d0,$10(a4)
		clr.b	$1A(a4)
		move.b	$E(a3),d3
		move.b	d3,d0
		add.b	d0,d3
		addq.b	#1,d3
		move.b	d3,$1B(a4)
		move.b	#1,$1C(a4)
		move.b	$16(a3),d0
		addq.b	#1,d0
		move.b	d0,$1D(a4)
		lea	(PH_INTERRUPT).l,a0
		move.l	a0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		ori.b	#4,$14(a3)
		moveq	#$F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_8CF0
; ---------------------------------------------------------------------------

loc_8CBE:				; CODE XREF: dl_establish+12Cj
		move.l	a3,-(sp)
		moveq	#$49,d0	; 'I'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		moveq	#5,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.l	a3,-(sp)
		jsr	dl_set_datalink_able_to_establis
		addq.w	#4,sp
		clr.b	$F(a3)
		bra.s	loc_8CF0
; ---------------------------------------------------------------------------

loc_8CEA:				; CODE XREF: dl_establish+52j
		jsr	(WriteBegin).l

loc_8CF0:				; CODE XREF: dl_establish+60j
					; dl_establish+DCj ...
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function dl_establish

; ---------------------------------------------------------------------------
aDl_timer_indication:dc.b 147,'dl_timer_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_timer_indication:			; DATA XREF: MDL_UNITDATA_INDICATION+62o
					; PH_DEACTIVATE_INDICATION+38o	...

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		cmpa.w	#0,a3
		bne.s	loc_8D26
		lea	-$510(a5),a3

loc_8D26:				; CODE XREF: dl_timer_indication+12j
		move.l	8(a3),-(sp)
		jsr	(WriteString).l
		addq.w	#4,sp
		move.b	#1,$F(a3)
		move.b	$C(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_8D76
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_8D88
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_8D92
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_8DC0
		moveq	#4,d1
		cmp.l	d1,d0
		beq.s	loc_8DA2
		moveq	#7,d1
		cmp.l	d1,d0
		beq.s	loc_8DA2
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_8DA2
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_8DC0
		moveq	#6,d1
		cmp.l	d1,d0
		beq.s	loc_8DC0
		bra.s	loc_8DC0
; ---------------------------------------------------------------------------

loc_8D76:				; CODE XREF: dl_timer_indication+34j
		clr.l	-(sp)
		pea	(ph_persistant_deactivation).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_8DC0
; ---------------------------------------------------------------------------

loc_8D88:				; CODE XREF: dl_timer_indication+3Aj
		move.l	a3,-(sp)
		jsr	mdl_assign_timer
		addq.w	#4,sp

loc_8D92:				; CODE XREF: dl_timer_indication+40j
		moveq	#3,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		bra.s	loc_8DC0
; ---------------------------------------------------------------------------

loc_8DA2:				; CODE XREF: dl_timer_indication+4Cj
					; dl_timer_indication+52j ...
		move.l	a3,-(sp)
		jsr	dl_set_datalink_able_to_establis
		addq.w	#4,sp
		move.b	#1,$F(a3)
		moveq	#5,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_8DC0:				; CODE XREF: dl_timer_indication+46j
					; dl_timer_indication+5Ej ...
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function dl_timer_indication

; ---------------------------------------------------------------------------
aDl_establish_request:dc.b 148,'DL_ESTABLISH_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_ESTABLISH_REQUEST:			; DATA XREF: PH_DEACTIVATE_INDICATION+5Eo
					; T_305_1TR6+24o ...

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		cmpa.w	#0,a3
		bne.s	loc_8E04
		lea	-$510(a5),a3

loc_8E04:				; CODE XREF: DL_ESTABLISH_REQUEST+14j
		jsr	(WriteProc).l
		clr.b	$F(a3)
		move.b	$C(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_8E36
		moveq	#7,d1
		cmp.l	d1,d0
		beq.s	loc_8E36
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_8E36
		moveq	#6,d1
		cmp.l	d1,d0
		beq.s	loc_8E98
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_8E7A
		bra.s	loc_8E88
; ---------------------------------------------------------------------------

loc_8E36:				; CODE XREF: DL_ESTABLISH_REQUEST+30j
					; DL_ESTABLISH_REQUEST+36j ...
		moveq	#6,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.b	$E(a3),-(sp)
		clr.b	-(sp)
		moveq	#$53,d0	; 'S'
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#$F,d0
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		clr.b	$15(a3)
		bra.s	loc_8E98
; ---------------------------------------------------------------------------

loc_8E7A:				; CODE XREF: DL_ESTABLISH_REQUEST+48j
		moveq	#2,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_8E88:				; CODE XREF: DL_ESTABLISH_REQUEST+4Aj
		move.l	a3,-(sp)
		pea	(DL_ESTABLISH_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8E98:				; CODE XREF: DL_ESTABLISH_REQUEST+42j
					; DL_ESTABLISH_REQUEST+8Ej
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function DL_ESTABLISH_REQUEST

; ---------------------------------------------------------------------------
aDl_release_request:dc.b 146,'DL_RELEASE_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_RELEASE_REQUEST:			; CODE XREF: DL_DATA_REQUEST+74p
					; MDL_ASSIGN_INDICATION+1CAp

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		jsr	(WritePString).l
		tst.b	$E(a3)
		beq.s	loc_8F1E
		move.b	$C(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bls.s	loc_8EF4
		move.l	a3,-(sp)
		pea	(DL_RELEASE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8EF4:				; CODE XREF: DL_RELEASE_REQUEST+20j
		tst.b	$C(a3)
		beq.s	loc_8F08
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_8F08:				; CODE XREF: DL_RELEASE_REQUEST+36j
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		clr.b	$F(a3)
		bra.s	loc_8F94
; ---------------------------------------------------------------------------

loc_8F1E:				; CODE XREF: DL_RELEASE_REQUEST+16j
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		andi.b	#$82,d0
		beq.s	loc_8F52
		move.l	a3,-(sp)
		pea	(DL_RELEASE_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		tst.b	$C(a3)
		beq.s	loc_8F80
		moveq	#4,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		bra.s	loc_8F80
; ---------------------------------------------------------------------------

loc_8F52:				; CODE XREF: DL_RELEASE_REQUEST+68j
		move.b	$C(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bls.s	loc_8F6C
		move.l	a3,-(sp)
		pea	(DL_RELEASE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8F6C:				; CODE XREF: DL_RELEASE_REQUEST+98j
		tst.b	$C(a3)
		beq.s	loc_8F80
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_8F80:				; CODE XREF: DL_RELEASE_REQUEST+7Ej
					; DL_RELEASE_REQUEST+8Ej ...
		clr.b	$F(a3)
		move.l	a3,-(sp)
		pea	(dl_user_connect_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_8F94:				; CODE XREF: DL_RELEASE_REQUEST+5Aj
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function DL_RELEASE_REQUEST

; ---------------------------------------------------------------------------
aMdl_remove_request:dc.b 146,'MDL_REMOVE_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_REMOVE_REQUEST:			; CODE XREF: mdl_assign_indication+2Ap

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	a3,-(sp)
		pea	(DL_RELEASE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		tst.b	$C(a3)
		beq.s	loc_8FE0
		moveq	#1,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_8FE0:				; CODE XREF: MDL_REMOVE_REQUEST+1Ej
		clr.b	$F(a3)
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function MDL_REMOVE_REQUEST

; ---------------------------------------------------------------------------
aMdl_error_response:dc.b 146,'MDL_ERROR_RESPONSE',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_ERROR_RESPONSE:			; CODE XREF: mdl_assign_timer+2Cp
					; MDL_ASSIGN_INDICATION+E8p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	a3,a2
		moveq	#$C,d0
		adda.l	d0,a2
		move.b	(a2),d0
		moveq	#$E,d1
		and.b	d1,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.s	loc_904E
		move.b	arg_4(a6),$E(a3)
		move.b	(a2),d0
		addq.b	#2,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.b	(a2),d0
		moveq	#5,d1
		cmp.b	d1,d0
		bne.s	loc_9054
		move.l	a3,-(sp)
		jsr	dl_set_datalink_able_to_establis
		addq.w	#4,sp
		move.b	#1,$F(a3)
		bra.s	loc_9054
; ---------------------------------------------------------------------------

loc_904E:				; CODE XREF: MDL_ERROR_RESPONSE+1Cj
		jsr	(WriteBegin).l

loc_9054:				; CODE XREF: MDL_ERROR_RESPONSE+3Aj
					; MDL_ERROR_RESPONSE+4Cj
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function MDL_ERROR_RESPONSE

; ---------------------------------------------------------------------------
aMdl_assign_request:dc.b 146,'MDL_ASSIGN_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MDL_ASSIGN_REQUEST:			; CODE XREF: dl_nothing_to_do+78p
					; dl_u_indication+262p	...

arg_0		=  8

		link	a6,#0
		move.l	arg_0(a6),-(sp)
		jsr	dl_set_datalink_able_to_establis
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		clr.b	$F(a0)
		unlk	a6
		rts
; End of function MDL_ASSIGN_REQUEST

; ---------------------------------------------------------------------------
aDl_reestablish:dc.b 142,'dl_reestablish',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_reestablish:				; CODE XREF: dl_sabme_s4+Ap
					; dl_sabme_s4_f0+Cp

var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-4
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	#$F,var_4(a6)
		tst.b	$10(a3)
		beq.w	loc_913E
		move.l	a3,-(sp)
		pea	(DL_UNITDATA_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		pea	(nl_protocol_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4D,d1	; 'M'
		cmp.b	d1,d0
		bne.s	loc_910A
		move.l	#$9C,-(sp) ; 'œ'
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_9120
; ---------------------------------------------------------------------------

loc_910A:				; CODE XREF: dl_reestablish+56j
		move.l	#$1D4,-(sp)
		movea.l	a3,a0
		moveq	#$24,d0	; '$'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_9120:				; CODE XREF: dl_reestablish+68j
		move.l	a3,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp
		moveq	#7,d0
		move.b	d0,-(sp)
		move.l	a3,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		move.b	#$63,var_4(a6) ; 'c'

loc_913E:				; CODE XREF: dl_reestablish+16j
		move.b	$E(a3),-(sp)
		moveq	#2,d0
		move.b	d0,-(sp)
		move.b	var_4(a6),d0
		add.b	arg_4(a6),d0
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function dl_reestablish

; ---------------------------------------------------------------------------
aDl_sabme_s4:	dc.b 139,'dl_sabme_s4',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_sabme_s4:

arg_0		=  8

		link	a6,#0
		clr.b	-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	dl_reestablish
		unlk	a6
		rts
; End of function dl_sabme_s4

; ---------------------------------------------------------------------------
aDl_sabme_s4_f0:dc.b 142,'dl_sabme_s4_f0',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_sabme_s4_f0:

arg_0		=  8

		link	a6,#0
		moveq	#$10,d0
		move.b	d0,-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	dl_reestablish
		unlk	a6
		rts
; End of function dl_sabme_s4_f0

; ---------------------------------------------------------------------------
aDl_sabme_s4_f1:dc.b 142,'dl_sabme_s4_f1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_sabme_s4_f1:				; CODE XREF: PH_ACTIVATE_INDICATION+9Cp
					; dl_reestablish+82p ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	a4,a3
		moveq	#$1C,d0
		adda.l	d0,a3
		bra.s	loc_91DA
; ---------------------------------------------------------------------------

loc_91D0:				; CODE XREF: dl_sabme_s4_f1+2Ej
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_91DA:				; CODE XREF: dl_sabme_s4_f1+12j
		move.l	a3,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_91D0
		clr.b	d3
		move.b	d3,$14(a4)
		move.b	d3,$16(a4)
		move.b	d3,$17(a4)
		move.b	d3,$18(a4)
		move.b	d3,$15(a4)
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function dl_sabme_s4_f1

; ---------------------------------------------------------------------------
aDl_clear_queue:dc.b 142,'dl_clear_queue',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_clear_queue:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	a3,-(sp)
		pea	(DL_UNITDATA_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		pea	(nl_protocol_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4D,d1	; 'M'
		cmp.b	d1,d0
		bne.s	loc_9282
		move.l	#$9C,-(sp) ; 'œ'
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_9298
; ---------------------------------------------------------------------------

loc_9282:				; CODE XREF: dl_clear_queue+52j
		move.l	#$1D4,-(sp)
		movea.l	a3,a0
		moveq	#$24,d0	; '$'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_9298:				; CODE XREF: dl_clear_queue+64j
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function dl_clear_queue

; ---------------------------------------------------------------------------
aDl_sabme_s7_s8:dc.b 142,'dl_sabme_s7_s8',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_sabme_s7_s8:

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	a3,-(sp)
		pea	(DL_RELEASE_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d3
		moveq	#$55,d0	; 'U'
		cmp.b	d0,d3
		beq.s	loc_9302
		moveq	#$26,d0	; '&'
		cmp.b	d0,d3
		beq.s	loc_9302
		moveq	#$4D,d0	; 'M'
		cmp.b	d0,d3
		bne.s	loc_9312

loc_9302:				; CODE XREF: dl_sabme_s7_s8+42j
					; dl_sabme_s7_s8+48j
		move.l	a3,-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_9312:				; CODE XREF: dl_sabme_s7_s8+4Ej
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function dl_sabme_s7_s8

; ---------------------------------------------------------------------------
aDl_release_indication:dc.b 149,'dl_release_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_release_indication:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	a3,-(sp)
		pea	(DL_ESTABLISH_CONFIRM).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function dl_release_indication

; ---------------------------------------------------------------------------
aDl_release_confirm:dc.b 146,'dl_release_confirm',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_release_confirm:

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	8(a3),-(sp)
		jsr	(WriteString).l
		addq.w	#4,sp
		tst.b	$F(a3)
		beq.s	loc_93B6
		move.l	a3,-(sp)
		pea	(DL_ESTABLISH_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_93D6
; ---------------------------------------------------------------------------

loc_93B6:				; CODE XREF: dl_release_confirm+1Cj
		tst.l	$1C(a3)
		beq.s	loc_93D6
		move.l	a3,-(sp)
		pea	(DL_UNITDATA_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		jsr	dl_sabme_s4_f1
		addq.w	#4,sp

loc_93D6:				; CODE XREF: dl_release_confirm+2Ej
					; dl_release_confirm+34j
		move.l	a3,-(sp)
		pea	(nl_protocol_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.b	$F(a3)
		movea.l	$1C(a3),a4
		movea.l	a3,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	a4,d3
		beq.s	loc_9406
		moveq	#$F,d0
		bra.s	loc_9422
; ---------------------------------------------------------------------------

loc_9406:				; CODE XREF: dl_release_confirm+7Aj
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4D,d1	; 'M'
		cmp.b	d1,d0
		bne.s	loc_941C
		move.l	#$9C,d0	; 'œ'
		bra.s	loc_9422
; ---------------------------------------------------------------------------

loc_941C:				; CODE XREF: dl_release_confirm+8Cj
		move.l	#$1D4,d0

loc_9422:				; CODE XREF: dl_release_confirm+7Ej
					; dl_release_confirm+94j
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		cmpa.w	#0,a4
		beq.s	loc_943E
		move.l	d3,-(sp)
		jsr	(First).l
		addq.w	#4,sp

loc_943E:				; CODE XREF: dl_release_confirm+ACj
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function dl_release_confirm

; ---------------------------------------------------------------------------
aDl_ua_f1_s5:	dc.b 139,'dl_ua_f1_s5',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_ua_f1_s5:
		link	a6,#0
		unlk	a6
		rts
; End of function dl_ua_f1_s5

; ---------------------------------------------------------------------------
aDl_nothing_to_do:dc.b 144,'dl_nothing_to_do',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_nothing_to_do:			; DATA XREF: dl_s_or_i_indication+154o

var_4		= -4
var_3		= -3
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d4/a2-a4,-(sp)
		lea	-$60A(a5),a3
		movea.l	arg_0(a6),a2
		move.b	$1D(a2),d0
		move.b	d0,var_4(a6)
		moveq	#4,d0
		movea.l	$C(a2),a4
		move.b	$C(a4),d1
		subq.b	#4,d1
		asl.b	d1,d0
		addq.b	#1,d0
		move.b	d0,var_3(a6)
		move.b	$1B(a2),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_94AA
		addq.b	#1,var_3(a6)

loc_94AA:				; CODE XREF: dl_nothing_to_do+34j
		move.b	var_4(a6),d3
		moveq	#3,d4
		and.b	d4,d3
		cmp.b	d4,d3
		bne.s	loc_94FA
		move.b	var_4(a6),d3
		andi.b	#$EF,d3
		cmp.b	d4,d3
		beq.s	loc_94FA
		cmpi.b	#$87,d3
		beq.s	loc_94FA
		cmpi.b	#$AF,d3
		beq.s	loc_94FA
		movea.l	arg_0(a6),a0
		tst.l	$14(a0)
		beq.s	loc_94FA
		move.l	a4,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		move.l	a4,-(sp)
		jsr	MDL_ASSIGN_REQUEST
		addq.w	#4,sp
		bra.w	loc_958A
; ---------------------------------------------------------------------------

loc_94F4:				; CODE XREF: dl_nothing_to_do+9Cj
					; dl_nothing_to_do+BAj
		moveq	#$A,d0
		adda.l	d0,a3
		bra.s	loc_9502
; ---------------------------------------------------------------------------

loc_94FA:				; CODE XREF: dl_nothing_to_do+44j
					; dl_nothing_to_do+50j	...
		move.b	var_3(a6),d0
		moveq	#0,d3
		move.b	d0,d3

loc_9502:				; CODE XREF: dl_nothing_to_do+88j
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		and.l	d3,d0
		cmp.l	d3,d0
		bne.s	loc_94F4
		move.b	var_4(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		move.b	2(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		and.l	d1,d0
		move.b	1(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		cmp.l	d1,d0
		bne.s	loc_94F4
		move.b	5(a3),d3
		beq.s	loc_953E
		move.l	a4,-(sp)
		move.b	d3,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp

loc_953E:				; CODE XREF: dl_nothing_to_do+C0j
		move.b	4(a3),d3
		beq.s	loc_9550
		move.b	d3,-(sp)
		move.l	a4,-(sp)
		jsr	dl_transition
		addq.w	#6,sp

loc_9550:				; CODE XREF: dl_nothing_to_do+D2j
		move.l	6(a3),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		move.l	a4,-(sp)
		movea.l	6(a3),a0
		jsr	(a0)
		addq.w	#4,sp
		tst.b	3(a3)
		beq.s	loc_958A
		move.b	$E(a4),-(sp)
		moveq	#2,d0
		move.b	d0,-(sp)
		move.b	var_4(a6),d0
		moveq	#$10,d1
		and.b	d1,d0
		or.b	3(a3),d0
		move.b	d0,-(sp)
		jsr	DL_transition
		addq.w	#6,sp

loc_958A:				; CODE XREF: dl_nothing_to_do+80j
					; dl_nothing_to_do+FAj
		move.l	arg_0(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function dl_nothing_to_do

; ---------------------------------------------------------------------------
aDl_u_indication:dc.b 143,'dl_u_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_u_indication:			; DATA XREF: dl_s_or_i_indication+178o

var_4		= -4
var_2		= -2
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a4
		move.b	$14(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		move.w	d0,var_4(a6)
		clr.b	var_2(a6)
		lea	(GetMsgBuffer).l,a0
		move.l	a0,4(a2)
		move.b	$1D(a2),d0
		andi.b	#$FE,d0
		move.b	$17(a4),d1
		cmp.b	d1,d0
		beq.w	loc_969E
		movea.l	$1C(a4),a3
		moveq	#4,d0
		move.l	d0,-(sp)
		movea.l	a4,a0
		moveq	#$15,d1
		adda.l	d1,a0
		move.l	a0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp
		moveq	#$2D,d0	; '-'
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		cmpa.w	#0,a3
		beq.s	loc_962A
		moveq	#4,d0
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteHex0).l
		addq.w	#8,sp

loc_962A:				; CODE XREF: dl_u_indication+64j
		jsr	(WritePString).l
		movea.l	arg_0(a6),a0
		move.b	$1D(a0),d0
		andi.b	#$FE,d0
		move.b	$18(a4),d1
		cmp.b	d1,d0
		beq.s	loc_964A
		move.b	#$4A,var_2(a6) ; 'J'

loc_964A:				; CODE XREF: dl_u_indication+92j
		move.l	a3,d0
		beq.s	loc_9672
		move.b	$1C(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		addq.l	#2,d0
		andi.l	#$FE,d0	; 'þ'
		movea.l	arg_0(a6),a0
		move.b	$1D(a0),d2
		andi.b	#$FE,d2
		moveq	#0,d1
		move.b	d2,d1
		cmp.l	d1,d0
		beq.s	loc_967A

loc_9672:				; CODE XREF: dl_u_indication+9Cj
		move.b	#$4A,var_2(a6) ; 'J'
		bra.s	loc_969E
; ---------------------------------------------------------------------------

loc_967A:				; CODE XREF: dl_u_indication+C0j
		movea.l	a4,a2
		moveq	#$1C,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		addq.b	#2,$17(a4)
		ori.w	#$180,var_4(a6)

loc_969E:				; CODE XREF: dl_u_indication+38j
					; dl_u_indication+C8j
		movea.l	arg_0(a6),a2
		move.b	$1C(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.w	loc_977C
		tst.l	$14(a2)
		beq.s	loc_96BE
		move.b	#$4F,var_2(a6) ; 'O'
		bra.w	loc_97F0
; ---------------------------------------------------------------------------

loc_96BE:				; CODE XREF: dl_u_indication+102j
		ori.w	#$100,var_4(a6)
		movea.l	arg_0(a6),a0
		move.b	$1C(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_96E4
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_96EC
		moveq	#9,d1
		cmp.l	d1,d0
		beq.s	loc_9704
		bra.s	loc_9718
; ---------------------------------------------------------------------------

loc_96E4:				; CODE XREF: dl_u_indication+124j
		ori.w	#1,var_4(a6)
		bra.s	loc_9718
; ---------------------------------------------------------------------------

loc_96EC:				; CODE XREF: dl_u_indication+12Aj
		move.w	var_4(a6),d0
		moveq	#1,d1
		and.w	d1,d0
		beq.s	loc_9718
		ori.w	#$80,var_4(a6) ; '€'
		andi.w	#$FFFE,var_4(a6)
		bra.s	loc_9718
; ---------------------------------------------------------------------------

loc_9704:				; CODE XREF: dl_u_indication+130j
		ori.w	#$80,var_4(a6) ; '€'
		andi.w	#$FFFE,var_4(a6)
		move.b	$17(a4),d0
		move.b	d0,$18(a4)

loc_9718:				; CODE XREF: dl_u_indication+132j
					; dl_u_indication+13Aj	...
		movea.l	arg_0(a6),a2
		move.b	$1D(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.w	loc_97F0
		move.b	$1A(a2),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_973C
		ori.w	#$10,var_4(a6)
		bra.w	loc_97F0
; ---------------------------------------------------------------------------

loc_973C:				; CODE XREF: dl_u_indication+180j
		move.b	$C(a4),d0
		moveq	#8,d1
		cmp.b	d1,d0
		bne.s	loc_976C
		move.b	$17(a4),d0
		move.b	d0,$18(a4)
		moveq	#7,d0
		move.b	d0,-(sp)
		move.l	a4,-(sp)
		jsr	dl_transition
		addq.w	#6,sp
		andi.w	#$FFF3,var_4(a6)
		ori.w	#$80,var_4(a6) ; '€'
		bra.w	loc_97F0
; ---------------------------------------------------------------------------

loc_976C:				; CODE XREF: dl_u_indication+194j
		move.l	a4,-(sp)
		moveq	#$41,d0	; 'A'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		bra.s	loc_97F0
; ---------------------------------------------------------------------------

loc_977C:				; CODE XREF: dl_u_indication+FAj
		movea.l	arg_0(a6),a2
		move.b	$1A(a2),d0
		moveq	#2,d1
		and.b	d1,d0
		beq.s	loc_97EA
		ori.w	#$100,var_4(a6)
		move.b	$1D(a2),d0
		moveq	#1,d1
		and.b	d1,d0
		beq.s	loc_97A0
		ori.w	#$10,var_4(a6)

loc_97A0:				; CODE XREF: dl_u_indication+1E8j
		ori.w	#$20,var_4(a6) ; ' '
		movea.l	arg_0(a6),a2
		move.b	$1C(a2),d0
		move.b	$16(a4),d1
		cmp.b	d1,d0
		bne.s	loc_97CC
		lea	(dl_data_indication).l,a0
		move.l	a0,4(a2)
		addq.b	#2,$16(a4)
		andi.w	#$FFFD,var_4(a6)
		bra.s	loc_97F0
; ---------------------------------------------------------------------------

loc_97CC:				; CODE XREF: dl_u_indication+204j
		move.w	var_4(a6),d0
		moveq	#2,d1
		and.w	d1,d0
		bne.s	loc_97F0
		ori.w	#$202,var_4(a6)
		pea	(aRejectRecovery+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_97F0
; ---------------------------------------------------------------------------

loc_97EA:				; CODE XREF: dl_u_indication+1D8j
		move.b	#$4D,var_2(a6) ; 'M'

loc_97F0:				; CODE XREF: dl_u_indication+10Aj
					; dl_u_indication+174j	...
		move.b	var_2(a6),d0
		beq.s	loc_981E
		move.l	arg_0(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		move.l	a4,-(sp)
		move.b	var_2(a6),-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		move.l	a4,-(sp)
		jsr	MDL_ASSIGN_REQUEST
		addq.w	#4,sp
		bra.w	loc_9954
; ---------------------------------------------------------------------------

loc_981E:				; CODE XREF: dl_u_indication+244j
		tst.l	$1C(a4)
		beq.s	loc_982E
		move.w	var_4(a6),d0
		moveq	#5,d1
		and.w	d1,d0
		beq.s	loc_9834

loc_982E:				; CODE XREF: dl_u_indication+272j
		andi.w	#$FF7F,var_4(a6)

loc_9834:				; CODE XREF: dl_u_indication+27Cj
		move.b	$18(a4),d0
		move.b	$17(a4),d1
		cmp.b	d1,d0
		beq.s	loc_9846
		andi.w	#$FF7F,var_4(a6)

loc_9846:				; CODE XREF: dl_u_indication+28Ej
		move.w	var_4(a6),d0
		andi.w	#$80,d0	; '€'
		beq.s	loc_9856
		andi.w	#$FFDF,var_4(a6)

loc_9856:				; CODE XREF: dl_u_indication+29Ej
		move.w	var_4(a6),d3
		andi.w	#$230,d3
		beq.s	loc_98D6
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_98D0
		moveq	#$FFFFFFFC,d0
		move.l	d0,$10(a3)
		move.b	#2,$1A(a3)
		move.b	$E(a4),d3
		move.b	d3,d0
		add.b	d0,d3
		addq.b	#1,d3
		move.b	d3,$1B(a3)
		move.w	var_4(a6),d0
		andi.w	#$200,d0
		beq.s	loc_989E
		moveq	#9,d0
		bra.s	loc_98A0
; ---------------------------------------------------------------------------

loc_989E:				; CODE XREF: dl_u_indication+2E8j
		moveq	#1,d0

loc_98A0:				; CODE XREF: dl_u_indication+2ECj
		move.b	d0,$1C(a3)
		move.w	var_4(a6),d0
		moveq	#$10,d1
		and.w	d1,d0
		beq.s	loc_98B2
		moveq	#1,d0
		bra.s	loc_98B4
; ---------------------------------------------------------------------------

loc_98B2:				; CODE XREF: dl_u_indication+2FCj
		moveq	#0,d0

loc_98B4:				; CODE XREF: dl_u_indication+300j
		add.b	$16(a4),d0
		move.b	d0,$1D(a3)
		lea	(PH_INTERRUPT).l,a0
		move.l	a0,4(a3)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_98D0:				; CODE XREF: dl_u_indication+2C4j
		andi.w	#$FDCF,var_4(a6)

loc_98D6:				; CODE XREF: dl_u_indication+2AEj
		movea.l	$1C(a4),a3
		move.w	var_4(a6),d0
		andi.w	#$80,d0	; '€'
		beq.s	loc_98EE
		move.l	a3,-(sp)
		jsr	(First).l
		addq.w	#4,sp

loc_98EE:				; CODE XREF: dl_u_indication+332j
		move.w	var_4(a6),d3
		andi.w	#$100,d3
		beq.s	loc_9942
		movea.l	a4,a2
		moveq	#$24,d0	; '$'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	a3,d0
		bne.s	loc_9916
		move.w	var_4(a6),d0
		moveq	#5,d1
		and.w	d1,d0
		beq.s	loc_991A

loc_9916:				; CODE XREF: dl_u_indication+35Aj
		moveq	#$F,d0
		bra.s	loc_9936
; ---------------------------------------------------------------------------

loc_991A:				; CODE XREF: dl_u_indication+364j
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4D,d1	; 'M'
		cmp.b	d1,d0
		bne.s	loc_9930
		move.l	#$9C,d0	; 'œ'
		bra.s	loc_9936
; ---------------------------------------------------------------------------

loc_9930:				; CODE XREF: dl_u_indication+376j
		move.l	#$1D4,d0

loc_9936:				; CODE XREF: dl_u_indication+368j
					; dl_u_indication+37Ej
		move.l	d0,-(sp)
		move.l	a2,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_9942:				; CODE XREF: dl_u_indication+346j
		move.l	arg_0(a6),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		move.b	var_4+1(a6),$14(a4)

loc_9954:				; CODE XREF: dl_u_indication+26Aj
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function dl_u_indication

; ---------------------------------------------------------------------------
aDl_s_or_i_indication:dc.b 148,'dl_s_or_i_indication',0,0
aRejectRecovery:dc.b 16,'reject recovery',0 ; DATA XREF: dl_u_indication+22Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_s_or_i_indication:			; DATA XREF: IsacGetReceiveMsg:loc_3914o

var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$10
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	-$518(a5),a3
		move.b	$1F(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asr.l	#1,d0
		move.b	d0,var_10(a6)
		bra.s	loc_99A6
; ---------------------------------------------------------------------------

loc_99A4:				; CODE XREF: dl_s_or_i_indication+2Ej
					; dl_s_or_i_indication+38j
		movea.l	(a3),a3

loc_99A6:				; CODE XREF: dl_s_or_i_indication+1Ej
		move.l	a3,d0
		beq.s	loc_99BE
		move.b	$E(a3),d0
		cmp.b	var_10(a6),d0
		bne.s	loc_99A4
		move.b	$C(a3),d0
		moveq	#4,d1
		cmp.b	d1,d0
		bcs.s	loc_99A4

loc_99BE:				; CODE XREF: dl_s_or_i_indication+24j
		lea	(GetMsgBuffer).l,a0
		move.l	a0,4(a4)
		move.l	a3,$C(a4)
		move.b	$20(a4),d0
		moveq	#3,d3
		and.b	d3,d0
		cmp.b	d3,d0
		bne.s	loc_99E0
		moveq	#$FFFFFFFD,d0
		move.l	d0,$10(a4)
		bra.s	loc_99E6
; ---------------------------------------------------------------------------

loc_99E0:				; CODE XREF: dl_s_or_i_indication+52j
		moveq	#$FFFFFFFC,d0
		move.l	d0,$10(a4)

loc_99E6:				; CODE XREF: dl_s_or_i_indication+5Aj
		movea.l	a4,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	a2,var_4(a6)
		adda.l	$10(a4),a2
		move.l	a2,var_C(a6)
		movea.l	var_4(a6),a0
		move.l	a0,var_8(a6)
		move.l	$14(a4),d0
		move.w	d0,d3
		ble.s	loc_9A14
		move.w	d3,d0
		subq.w	#1,d0
		movea.l	a2,a1

loc_9A0E:				; CODE XREF: dl_s_or_i_indication+8Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_9A0E

loc_9A14:				; CODE XREF: dl_s_or_i_indication+82j
		move.l	$10(a4),d0
		add.l	d0,$14(a4)
		move.l	$14(a4),d0
		bpl.s	loc_9A32
		move.l	a3,-(sp)
		moveq	#$4E,d0	; 'N'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp
		bra.s	loc_9A4C
; ---------------------------------------------------------------------------

loc_9A32:				; CODE XREF: dl_s_or_i_indication+9Cj
		move.l	$14(a4),d0
		cmpi.l	#$104,d0
		ble.s	loc_9A6C
		move.l	a3,-(sp)
		moveq	#$4F,d0	; 'O'
		move.b	d0,-(sp)
		jsr	DL_DATA_REQUEST
		addq.w	#6,sp

loc_9A4C:				; CODE XREF: dl_s_or_i_indication+ACj
		move.l	a3,d0
		beq.w	loc_9B06
		move.b	$C(a3),d0
		moveq	#7,d1
		cmp.b	d1,d0
		bcs.w	loc_9B06
		move.l	a3,-(sp)
		jsr	MDL_ASSIGN_REQUEST
		addq.w	#4,sp
		bra.w	loc_9B06
; ---------------------------------------------------------------------------

loc_9A6C:				; CODE XREF: dl_s_or_i_indication+B8j
		move.l	$10(a4),d0
		moveq	#$FFFFFFFD,d1
		cmp.l	d1,d0
		bne.s	loc_9AE4
		move.b	$1B(a4),d0
		cmpi.b	#$FE,d0
		bne.s	loc_9AA0
		move.b	$1C(a4),d0
		cmpi.b	#$FF,d0
		bne.s	loc_9AA0
		move.b	$1D(a4),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_9AA0
		lea	(MDL_ASSIGN_INDICATION).l,a0
		move.l	a0,4(a4)
		bra.s	loc_9B06
; ---------------------------------------------------------------------------

loc_9AA0:				; CODE XREF: dl_s_or_i_indication+FAj
					; dl_s_or_i_indication+104j ...
		move.b	$1B(a4),d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.s	loc_9ACA
		move.b	$1C(a4),d0
		cmpi.b	#$FF,d0
		bne.s	loc_9ACA
		move.b	$1D(a4),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_9ACA
		lea	(DL_DATA_INDICATION).l,a0
		move.l	a0,4(a4)
		bra.s	loc_9B06
; ---------------------------------------------------------------------------

loc_9ACA:				; CODE XREF: dl_s_or_i_indication+124j
					; dl_s_or_i_indication+12Ej ...
		move.b	$1B(a4),d0
		andi.b	#$FD,d0
		bne.s	loc_9B06
		move.l	a3,d0
		beq.s	loc_9B06
		lea	(dl_nothing_to_do).l,a0
		move.l	a0,4(a4)
		bra.s	loc_9B06
; ---------------------------------------------------------------------------

loc_9AE4:				; CODE XREF: dl_s_or_i_indication+F0j
		move.b	$1A(a4),d0
		andi.b	#$FD,d0
		bne.s	loc_9B06
		move.l	a3,d0
		beq.s	loc_9B06
		move.b	$C(a3),d0
		moveq	#7,d1
		cmp.b	d1,d0
		bcs.s	loc_9B06
		lea	(dl_u_indication).l,a0
		move.l	a0,4(a4)

loc_9B06:				; CODE XREF: dl_s_or_i_indication+CAj
					; dl_s_or_i_indication+D6j ...
		move.l	a4,-(sp)
		jsr	(WriteLong).l
		addq.w	#4,sp
		move.l	a4,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function dl_s_or_i_indication

; ---------------------------------------------------------------------------
aPh_data_indication:dc.b 146,'PH_DATA_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PH_DATA_INDICATION:			; CODE XREF: addresserror+66p
		link	a6,#0
		moveq	#$43,d0	; 'C'
		clr.b	d1
		lea	-$510(a5),a0

loc_9B44:				; CODE XREF: PH_DATA_INDICATION+Ej
		move.b	d1,(a0)+
		dbf	d0,loc_9B44
		lea	(aGlobal+1),a0
		move.l	a0,-$508(a5)
		lea	(dl_establish).l,a0
		move.l	a0,-$4E8(a5)
		lea	-$510(a5),a0
		move.l	a0,-$4E0(a5)
		pea	-$518(a5)
		pea	-$510(a5)
		jsr	(SetupIO).l
		unlk	a6
		rts
; End of function PH_DATA_INDICATION

; ---------------------------------------------------------------------------
aInitdlink:	dc.b 137,'InitDLink',0
aGlobal:	dc.b 8,6,'Global',0     ; DATA XREF: PH_DATA_INDICATION+12o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitDLink:				; DATA XREF: MDL_UNITDATA_INDICATION+52o

var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$10
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		move.l	d0,var_10(a6)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a4
		cmpa.w	#0,a4
		beq.s	loc_9C1A
		movea.l	a4,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		move.b	#$F,(a3)
		clr.b	d0
		move.b	d0,2(a3)
		move.b	d0,1(a3)
		move.b	#7,3(a3)
		movea.l	var_10(a6),a0
		move.b	$E(a0),d0
		lsl.b	#1,d0
		movea.l	a3,a2
		addq.w	#4,a2
		move.l	a2,var_C(a6)
		move.l	a2,var_4(a6)
		move.b	(a2),d1
		andi.b	#1,d1
		or.b	d1,d0
		move.b	d0,(a2)
		movea.l	var_4(a6),a0
		move.l	a0,var_8(a6)
		move.b	(a0),d0
		ori.b	#1,d0
		move.b	d0,(a0)
		moveq	#5,d0
		move.l	d0,$14(a4)
		lea	(dl_cmd_resp_request).l,a0
		move.l	a0,4(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_9C20
; ---------------------------------------------------------------------------

loc_9C1A:				; CODE XREF: InitDLink+28j
		jsr	(WriteBegin).l

loc_9C20:				; CODE XREF: InitDLink+8Ej
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function InitDLink

; ---------------------------------------------------------------------------
aTei_verify_request:dc.b 146,'TEI_VERIFY_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

TEI_VERIFY_REQUEST:			; CODE XREF: WriteCRef+18p
					; update_call+110p

arg_0		=  8

		link	a6,#0
		moveq	#$5B,d0	; '['
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	arg_0(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		pea	(asc_9C7F+1)
		jsr	(WriteChar).l
		unlk	a6
		rts
; End of function TEI_VERIFY_REQUEST

; ---------------------------------------------------------------------------
aWritecref:	dc.b 137,'WriteCRef',0
asc_9C7F:	dc.b 4,'] ',0,0         ; DATA XREF: TEI_VERIFY_REQUEST+1Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

WriteCRef:				; DATA XREF: T_REQUEST+BAo

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d0
		move.l	d0,var_4(a6)
		move.b	var_4+1(a6),-(sp)
		jsr	TEI_VERIFY_REQUEST
		addq.w	#2,sp
		move.b	var_4+2(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#2,d3
		asl.l	d3,d0
		lea	-$4C4(a5),a3
		move.l	(a3,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	(asc_9D03+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	var_4+3(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	d3,d0
		move.l	(a3,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function WriteCRef

; ---------------------------------------------------------------------------
aNl_transition:	dc.b 141,'nl_transition',0
asc_9D03:	dc.b 6,' -> ',0,0       ; DATA XREF: WriteCRef+3Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_transition:				; CODE XREF: CheckInfo1TR6+4Ep
					; SendClearEDSS1+6Cp ...

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		lea	(dl_data_request).l,a0
		move.l	a0,4(a3)
		move.b	-$4C8(a5),d0
		beq.s	loc_9D30
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		bra.s	loc_9D4E
; ---------------------------------------------------------------------------

loc_9D30:				; CODE XREF: nl_transition+18j
		clr.l	-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		pea	-$208(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_9D4E:				; CODE XREF: nl_transition+24j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function nl_transition

; ---------------------------------------------------------------------------
aSendmsgbuffer:	dc.b 141,'SendMsgBuffer',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendMsgBuffer:				; CODE XREF: CheckComprehension+Ep
					; CheckChannel+Ep ...

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		movem.l	d3-d7/a2-a4,-(sp)
		movea.l	arg_2(a6),a2
		clr.w	d6
		clr.w	d5
		movea.l	a2,a3
		moveq	#$22,d0	; '"'
		adda.l	d0,a3
		movea.l	a2,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		adda.l	$14(a2),a4
		move.w	arg_0(a6),d0
		moveq	#0,d7
		move.w	d0,d7
		bra.s	loc_9DD6
; ---------------------------------------------------------------------------

loc_9D8E:				; CODE XREF: SendMsgBuffer+74j
		move.b	(a3)+,d0
		moveq	#0,d4
		move.b	d0,d4
		add.w	d5,d4
		move.w	d6,d5
		move.w	d4,d0
		move.w	d0,d1
		ext.l	d1
		cmp.l	d7,d1
		bne.s	loc_9DA6
		move.l	a3,d0
		bra.s	loc_9DDC
; ---------------------------------------------------------------------------

loc_9DA6:				; CODE XREF: SendMsgBuffer+3Cj
		move.w	d4,d0
		andi.w	#$80,d0	; '€'
		bne.s	loc_9DB8
		move.b	(a3)+,d1
		moveq	#0,d0
		move.b	d1,d0
		adda.l	d0,a3
		bra.s	loc_9DD6
; ---------------------------------------------------------------------------

loc_9DB8:				; CODE XREF: SendMsgBuffer+48j
		move.w	d4,d3
		andi.w	#$F0,d3	; 'ð'
		cmpi.w	#$90,d3	; ''
		bne.s	loc_9DD6
		move.w	d4,d5
		moveq	#7,d0
		and.w	d0,d5
		moveq	#8,d3
		asl.w	d3,d5
		move.w	d4,d0
		and.w	d3,d0
		bne.s	loc_9DD6
		move.w	d5,d6

loc_9DD6:				; CODE XREF: SendMsgBuffer+28j
					; SendMsgBuffer+52j ...
		cmpa.l	a4,a3
		blt.s	loc_9D8E
		moveq	#0,d0

loc_9DDC:				; CODE XREF: SendMsgBuffer+40j
		movem.l	(sp)+,d3-d7/a2-a4
		unlk	a6
		rts
; End of function SendMsgBuffer

; ---------------------------------------------------------------------------
aScanie:	dc.b 134,'ScanIE',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ScanIE:					; CODE XREF: CheckNumber1TR6+20p
					; update_call+A2p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3-d6/a2-a4,-(sp)
		movea.l	arg_4(a6),a2
		clr.w	d6
		clr.w	d5
		movea.l	a2,a3
		moveq	#$22,d0	; '"'
		adda.l	d0,a3
		movea.l	a2,a4
		moveq	#$1E,d0
		adda.l	d0,a4
		adda.l	$14(a2),a4
		bra.w	loc_9EAC
; ---------------------------------------------------------------------------

loc_9E12:				; CODE XREF: ScanIE+C0j
		move.b	(a3)+,d0
		moveq	#0,d4
		move.b	d0,d4
		add.w	d5,d4
		move.w	d6,d5
		moveq	#$7F,d0	; ''
		cmp.w	d0,d4
		beq.s	loc_9E78
		move.w	d4,d0
		andi.w	#$F0,d0	; 'ð'
		bne.s	loc_9E7C
		move.w	d4,d0
		move.w	d0,d1
		ext.l	d1
		cmpi.l	#$601,d1
		beq.s	loc_9E46
		moveq	#4,d2
		cmp.l	d2,d1
		beq.s	loc_9E7C
		moveq	#8,d2
		cmp.l	d2,d1
		beq.s	loc_9E7C
		bra.s	loc_9E54
; ---------------------------------------------------------------------------

loc_9E46:				; CODE XREF: ScanIE+48j
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#$4A,d2	; 'J'
		cmp.b	d2,d1
		beq.s	loc_9E7C

loc_9E54:				; CODE XREF: ScanIE+56j
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#$4B,d2	; 'K'
		cmp.b	d2,d1
		bne.s	loc_9E6E
		movea.l	arg_0(a6),a0
		move.b	#$63,7(a0) ; 'c'
		bra.s	loc_9E78
; ---------------------------------------------------------------------------

loc_9E6E:				; CODE XREF: ScanIE+72j
		movea.l	arg_0(a6),a0
		move.b	#$60,7(a0) ; '`'

loc_9E78:				; CODE XREF: ScanIE+32j ScanIE+7Ej
		clr.b	d0
		bra.s	loc_9EB4
; ---------------------------------------------------------------------------

loc_9E7C:				; CODE XREF: ScanIE+3Aj ScanIE+4Ej ...
		move.w	d4,d1
		andi.w	#$80,d1	; '€'
		bne.s	loc_9E8E
		move.b	(a3)+,d2
		moveq	#0,d1
		move.b	d2,d1
		adda.l	d1,a3
		bra.s	loc_9EAC
; ---------------------------------------------------------------------------

loc_9E8E:				; CODE XREF: ScanIE+94j
		move.w	d4,d3
		andi.w	#$F0,d3	; 'ð'
		cmpi.w	#$90,d3	; ''
		bne.s	loc_9EAC
		move.w	d4,d5
		moveq	#7,d1
		and.w	d1,d5
		moveq	#8,d3
		asl.w	d3,d5
		move.w	d4,d1
		and.w	d3,d1
		bne.s	loc_9EAC
		move.w	d5,d6

loc_9EAC:				; CODE XREF: ScanIE+20j ScanIE+9Ej ...
		cmpa.l	a4,a3
		blt.w	loc_9E12
		moveq	#1,d0

loc_9EB4:				; CODE XREF: ScanIE+8Cj
		movem.l	(sp)+,d3-d6/a2-a4
		unlk	a6
		rts
; End of function ScanIE

; ---------------------------------------------------------------------------
aCheckcomprehension:dc.b 146,'CheckComprehension',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckComprehension:			; CODE XREF: GetChannel+14p
					; SendMessage+16p ...

var_4		= -4
arg_4		=  $C

		link	a6,#-4
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#$18,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_9F42
		move.b	(a2)+,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_9F3E
		move.b	(a2),d0
		andi.b	#$F4,d0
		cmpi.b	#$80,d0
		bne.s	loc_9F3E
		move.b	(a2),d1
		moveq	#3,d2
		and.b	d2,d1
		move.b	d1,var_4(a6)
		moveq	#0,d0
		move.b	d1,d0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_9F2A
		tst.l	d0
		beq.s	loc_9F38
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_9F38
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_9F38
		bra.s	loc_9F3E
; ---------------------------------------------------------------------------

loc_9F2A:				; CODE XREF: CheckComprehension+44j
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		andi.b	#$80,d0
		beq.s	loc_9F3E

loc_9F38:				; CODE XREF: CheckComprehension+48j
					; CheckComprehension+4Ej ...
		move.b	var_4(a6),d0
		bra.s	loc_9F44
; ---------------------------------------------------------------------------

loc_9F3E:				; CODE XREF: CheckComprehension+24j
					; CheckComprehension+30j ...
		moveq	#$FFFFFFFF,d0
		bra.s	loc_9F44
; ---------------------------------------------------------------------------

loc_9F42:				; CODE XREF: CheckComprehension+1Cj
		moveq	#$FFFFFFFE,d0

loc_9F44:				; CODE XREF: CheckComprehension+6Aj
					; CheckComprehension+6Ej
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CheckComprehension

; ---------------------------------------------------------------------------
aGetchannel:	dc.b 138,'GetChannel',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

GetChannel:				; CODE XREF: CheckNumber1TR6+38p
					; A_SETUP_EDSS1+2Cp

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	d0,a2
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckComprehension
		addq.w	#8,sp
		move.b	d0,d1
		move.b	d1,8(a3)
		move.l	a2,d0
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_9FA2
		moveq	#$FFFFFFFE,d1
		cmp.l	d1,d0
		beq.s	loc_9FAA
		cmpi.l	#$FE,d0	; 'þ'
		beq.s	loc_9FAA
		cmpi.l	#$FF,d0
		beq.s	loc_9FB2
		moveq	#$FFFFFFFF,d1
		cmp.l	d1,d0
		beq.s	loc_9FB2
		bra.s	loc_9FB8
; ---------------------------------------------------------------------------

loc_9FA2:				; CODE XREF: GetChannel+2Aj
		move.b	#$22,7(a3) ; '"'
		bra.s	loc_9FB8
; ---------------------------------------------------------------------------

loc_9FAA:				; CODE XREF: GetChannel+30j
					; GetChannel+38j
		move.b	#$60,7(a3) ; '`'
		bra.s	loc_9FB8
; ---------------------------------------------------------------------------

loc_9FB2:				; CODE XREF: GetChannel+40j
					; GetChannel+46j
		move.b	#$64,7(a3) ; 'd'

loc_9FB8:				; CODE XREF: GetChannel+48j
					; GetChannel+50j ...
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function GetChannel

; ---------------------------------------------------------------------------
aCheckchannel:	dc.b 140,'CheckChannel',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckChannel:				; CODE XREF: A_CONNECT+88p
					; A_CALL_CLEAR_1TR6+20p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#8,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_9FFE
		move.b	(a2)+,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bcs.s	loc_9FFE
		move.b	(a2),d0
		moveq	#$70,d1	; 'p'
		and.b	d1,d0
		beq.s	loc_A010

loc_9FFE:				; CODE XREF: CheckChannel+1Cj
					; CheckChannel+24j
		movea.l	arg_0(a6),a0
		move.b	7(a0),d0
		sne	d0
		neg.b	d0
		ext.w	d0
		ext.l	d0
		bra.s	loc_A02A
; ---------------------------------------------------------------------------

loc_A010:				; CODE XREF: CheckChannel+2Cj
		move.b	(a2)+,d0
		cmpi.b	#$80,d0
		bcc.s	loc_A01A
		addq.w	#1,a2

loc_A01A:				; CODE XREF: CheckChannel+46j
		move.b	(a2),d0
		moveq	#$7F,d1	; ''
		and.b	d1,d0
		movea.l	arg_0(a6),a0
		move.b	d0,7(a0)
		moveq	#1,d0

loc_A02A:				; CODE XREF: CheckChannel+3Ej
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CheckChannel

; ---------------------------------------------------------------------------
aCheckcauseedss1:dc.b 143,'CheckCauseEDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckCauseEDSS1:			; CODE XREF: A_CONNECT_ACKNOWLEDGE+2Ap

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#8,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_A074
		tst.b	(a2)
		beq.s	loc_A074
		move.b	1(a2),d0
		ori.b	#$80,d0
		movea.l	arg_0(a6),a0
		move.b	d0,7(a0)

loc_A074:				; CODE XREF: CheckCauseEDSS1+1Cj
					; CheckCauseEDSS1+20j
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CheckCauseEDSS1

; ---------------------------------------------------------------------------
aCheckcause1tr6:dc.b 142,'CheckCause1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckCause1TR6:				; CODE XREF: A_SETUP_EDSS1+82p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#$20,d0	; ' '
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_A0C6
		move.b	(a2)+,d0
		moveq	#4,d1
		cmp.b	d1,d0
		bne.s	loc_A0C6
		tst.b	(a2)+
		bne.s	loc_A0C6
		move.b	(a2),d3
		moveq	#$1D,d0
		cmp.b	d0,d3
		beq.s	loc_A0CA
		moveq	#$1F,d0
		cmp.b	d0,d3
		beq.s	loc_A0CA

loc_A0C6:				; CODE XREF: CheckCause1TR6+1Ej
					; CheckCause1TR6+26j ...
		moveq	#0,d0
		bra.s	loc_A0CC
; ---------------------------------------------------------------------------

loc_A0CA:				; CODE XREF: CheckCause1TR6+32j
					; CheckCause1TR6+38j
		moveq	#1,d0

loc_A0CC:				; CODE XREF: CheckCause1TR6+3Cj
		movea.l	arg_0(a6),a0
		move.b	d0,$32(a0)
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function CheckCause1TR6

; ---------------------------------------------------------------------------
aCheck1tr6spv:	dc.b 140,'Check1TR6SPV',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Check1TR6SPV:				; CODE XREF: A_INFO+10p A_STATUS+Cp

arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#$14,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_A10E
		tst.b	(a2)+
		bne.s	loc_A112

loc_A10E:				; CODE XREF: Check1TR6SPV+1Cj
		moveq	#1,d0
		bra.s	loc_A11C
; ---------------------------------------------------------------------------

loc_A112:				; CODE XREF: Check1TR6SPV+20j
		move.b	(a2),d0
		sne	d0
		neg.b	d0
		ext.w	d0
		ext.l	d0

loc_A11C:				; CODE XREF: Check1TR6SPV+24j
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function Check1TR6SPV

; ---------------------------------------------------------------------------
aCheckstate:	dc.b 138,'CheckState',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckState:				; CODE XREF: CheckLLC+294p

var_4		= -4
var_3		= -3
arg_0		=  8
arg_4		=  $C

		link	a6,#-4
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		move.l	arg_4(a6),-(sp)
		moveq	#$7C,d0	; '|'
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a4
		pea	(aCheckllc_0+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		cmpa.w	#0,a4
		beq.w	loc_A28A
		move.b	(a4)+,d0
		move.b	d0,var_4(a6)
		moveq	#2,d1
		cmp.b	d1,d0
		bcs.w	loc_A28A
		move.b	#$30,var_3(a6) ; '0'
		movea.l	a2,a3
		moveq	#9,d0
		adda.l	d0,a3
		bra.w	loc_A266
; ---------------------------------------------------------------------------

loc_A180:				; CODE XREF: CheckState+13Aj
		move.b	var_4(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	var_3(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.b	var_3(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$50,d1	; 'P'
		cmp.l	d1,d0
		beq.s	loc_A1C4
		moveq	#$51,d1	; 'Q'
		cmp.l	d1,d0
		beq.s	loc_A1E0
		moveq	#$53,d1	; 'S'
		cmp.l	d1,d0
		beq.w	loc_A244
		bra.w	loc_A244
; ---------------------------------------------------------------------------

loc_A1C4:				; CODE XREF: CheckState+80j
		move.b	(a4),d0
		moveq	#$7F,d1	; ''
		and.b	d1,d0
		moveq	#$21,d1	; '!'
		cmp.b	d1,d0
		bne.s	loc_A244
		move.b	(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.w	loc_A28A
		move.b	#$80,(a3)
		bra.s	loc_A244
; ---------------------------------------------------------------------------

loc_A1E0:				; CODE XREF: CheckState+86j
		move.b	(a3),d0
		cmpi.b	#$80,d0
		bne.w	loc_A28A
		move.b	(a4),d1
		moveq	#$1F,d2
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_A214
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_A21A
		moveq	#$B,d1
		cmp.l	d1,d0
		beq.s	loc_A220
		moveq	#$D,d1
		cmp.l	d1,d0
		beq.s	loc_A226
		moveq	#$F,d1
		cmp.l	d1,d0
		beq.s	loc_A22C
		bra.s	loc_A230
; ---------------------------------------------------------------------------

loc_A214:				; CODE XREF: CheckState+C8j
		move.b	#$85,(a3)
		bra.s	loc_A230
; ---------------------------------------------------------------------------

loc_A21A:				; CODE XREF: CheckState+CEj
		move.b	#$86,(a3)
		bra.s	loc_A230
; ---------------------------------------------------------------------------

loc_A220:				; CODE XREF: CheckState+D4j
		move.b	#$87,(a3)
		bra.s	loc_A230
; ---------------------------------------------------------------------------

loc_A226:				; CODE XREF: CheckState+DAj
		move.b	#$88,(a3)
		bra.s	loc_A230
; ---------------------------------------------------------------------------

loc_A22C:				; CODE XREF: CheckState+E0j
		move.b	#$21,(a3) ; '!'

loc_A230:				; CODE XREF: CheckState+E2j
					; CheckState+E8j ...
		move.b	(a3),d0
		cmpi.b	#$80,d0
		bls.s	loc_A244
		move.b	(a4),d0
		moveq	#$60,d1	; '`'
		and.b	d1,d0
		moveq	#$40,d1	; '@'
		cmp.b	d1,d0
		bne.s	loc_A278

loc_A244:				; CODE XREF: CheckState+8Cj
					; CheckState+90j ...
		move.b	(a4)+,d0
		andi.b	#$80,d0
		beq.s	loc_A25E
		move.b	var_3(a6),d0
		andi.b	#$F0,d0
		moveq	#$10,d1
		add.b	d1,d0
		move.b	d0,var_3(a6)
		bra.s	loc_A262
; ---------------------------------------------------------------------------

loc_A25E:				; CODE XREF: CheckState+11Aj
		addq.b	#1,var_3(a6)

loc_A262:				; CODE XREF: CheckState+12Cj
		subq.b	#1,var_4(a6)

loc_A266:				; CODE XREF: CheckState+4Cj
		move.b	var_4(a6),d0
		bne.w	loc_A180
		move.b	9(a2),d0
		cmpi.b	#$80,d0
		bne.s	loc_A27E

loc_A278:				; CODE XREF: CheckState+112j
		clr.b	9(a2)
		bra.s	loc_A28A
; ---------------------------------------------------------------------------

loc_A27E:				; CODE XREF: CheckState+146j
		moveq	#$D,d0
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_A28A:				; CODE XREF: CheckState+2Ej
					; CheckState+3Cj ...
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function CheckState

; ---------------------------------------------------------------------------
aCheckllc:	dc.b 136,'CheckLLC',0,0
aCheckllc_0:	dc.b 14,'--- CheckLLC ',0 ; DATA XREF: CheckState+1Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckLLC:				; CODE XREF: CheckNumber1TR6+2Cp

var_8		= -8
var_7		= -7
var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-8
		movem.l	d3/a2-a4,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#4,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a4
		pea	(aCheckbearer+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		cmpa.w	#0,a4
		beq.s	loc_A2E4
		move.b	(a4)+,d0
		move.b	d0,var_8(a6)
		moveq	#2,d1
		cmp.b	d1,d0
		bcc.s	loc_A2F2

loc_A2E4:				; CODE XREF: CheckLLC+2Aj
		movea.l	arg_0(a6),a0
		move.b	#$60,7(a0) ; '`'
		bra.w	loc_A548
; ---------------------------------------------------------------------------

loc_A2F2:				; CODE XREF: CheckLLC+36j
		move.b	#$30,var_7(a6) ; '0'
		movea.l	arg_0(a6),a3
		moveq	#9,d0
		adda.l	d0,a3
		bra.w	loc_A50C
; ---------------------------------------------------------------------------

loc_A304:				; CODE XREF: CheckLLC+264j
		move.b	var_8(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	var_7(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.b	var_7(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$30,d1	; '0'
		cmp.l	d1,d0
		beq.s	loc_A36A
		moveq	#$40,d1	; '@'
		cmp.l	d1,d0
		beq.w	loc_A3DA
		moveq	#$41,d1	; 'A'
		cmp.l	d1,d0
		beq.w	loc_A3CC
		moveq	#$42,d1	; 'B'
		cmp.l	d1,d0
		beq.w	loc_A3DA
		moveq	#$50,d1	; 'P'
		cmp.l	d1,d0
		beq.w	loc_A3EC
		moveq	#$51,d1	; 'Q'
		cmp.l	d1,d0
		beq.w	loc_A47C
		moveq	#$53,d1	; 'S'
		cmp.l	d1,d0
		beq.w	loc_A4EA
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A36A:				; CODE XREF: CheckLLC+88j
		move.b	(a4),d3
		moveq	#$60,d0	; '`'
		move.w	d3,var_4(a6)
		and.b	d0,d3
		bne.w	loc_A52E
		move.w	var_4(a6),d1
		moveq	#$1F,d2
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		tst.l	d0
		beq.s	loc_A3A4
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_A3AC
		moveq	#$10,d1
		cmp.l	d1,d0
		beq.s	loc_A3B4
		moveq	#$11,d1
		cmp.l	d1,d0
		beq.s	loc_A3BC
		moveq	#$18,d1
		cmp.l	d1,d0
		beq.s	loc_A3C4
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3A4:				; CODE XREF: CheckLLC+DAj
		move.b	#$F0,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3AC:				; CODE XREF: CheckLLC+E0j
		move.b	#1,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3B4:				; CODE XREF: CheckLLC+E6j
		move.b	#$E0,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3BC:				; CODE XREF: CheckLLC+ECj
		move.b	#$F2,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3C4:				; CODE XREF: CheckLLC+F2j
		move.b	#$F3,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A3CC:				; CODE XREF: CheckLLC+96j
		move.b	(a4),d0
		moveq	#$6F,d1	; 'o'
		and.b	d1,d0
		beq.w	loc_A4EA
		bra.w	loc_A4E0
; ---------------------------------------------------------------------------

loc_A3DA:				; CODE XREF: CheckLLC+8Ej CheckLLC+9Ej
		move.b	(a4),d0
		moveq	#$7F,d1	; ''
		and.b	d1,d0
		moveq	#$10,d1
		cmp.b	d1,d0
		beq.w	loc_A4EA
		bra.w	loc_A4E0
; ---------------------------------------------------------------------------

loc_A3EC:				; CODE XREF: CheckLLC+A6j
		move.b	(a4),d1
		moveq	#$7F,d2	; ''
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$21,d1	; '!'
		cmp.l	d1,d0
		beq.s	loc_A43A
		moveq	#$22,d1	; '"'
		cmp.l	d1,d0
		beq.s	loc_A44C
		moveq	#$23,d1	; '#'
		cmp.l	d1,d0
		beq.s	loc_A44C
		moveq	#$25,d1	; '%'
		cmp.l	d1,d0
		beq.s	loc_A470
		moveq	#$24,d1	; '$'
		cmp.l	d1,d0
		beq.w	loc_A4E0
		moveq	#$26,d1	; '&'
		cmp.l	d1,d0
		beq.w	loc_A4E0
		moveq	#$27,d1	; '''
		cmp.l	d1,d0
		beq.w	loc_A4E0
		moveq	#$28,d1	; '('
		cmp.l	d1,d0
		beq.w	loc_A4E0
		moveq	#$29,d1	; ')'
		cmp.l	d1,d0
		beq.w	loc_A4E0
		bra.w	loc_A52E
; ---------------------------------------------------------------------------

loc_A43A:				; CODE XREF: CheckLLC+14Ej
		move.b	(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.w	loc_A52E
		move.b	#$80,(a3)
		bra.w	loc_A4EA
; ---------------------------------------------------------------------------

loc_A44C:				; CODE XREF: CheckLLC+154j
					; CheckLLC+15Aj
		move.b	(a3),d0
		cmpi.b	#$C0,d0
		bcs.s	loc_A46C
		move.b	(a4),d0
		moveq	#1,d1
		and.b	d1,d0
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d1
		moveq	#1,d2
		and.b	d2,d1
		cmp.b	d1,d0
		bne.w	loc_A4EA

loc_A46C:				; CODE XREF: CheckLLC+1A6j
		bra.w	loc_A52E
; ---------------------------------------------------------------------------

loc_A470:				; CODE XREF: CheckLLC+160j
		move.b	(a3),d0
		cmpi.b	#$F2,d0
		beq.s	loc_A4EA
		bra.w	loc_A52E
; ---------------------------------------------------------------------------

loc_A47C:				; CODE XREF: CheckLLC+AEj
		move.b	(a3),d0
		cmpi.b	#$80,d0
		bne.w	loc_A548
		move.b	(a4),d1
		moveq	#$1F,d2
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_A4B0
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_A4B6
		moveq	#$B,d1
		cmp.l	d1,d0
		beq.s	loc_A4BC
		moveq	#$D,d1
		cmp.l	d1,d0
		beq.s	loc_A4C2
		moveq	#$F,d1
		cmp.l	d1,d0
		beq.s	loc_A4C8
		bra.s	loc_A4CC
; ---------------------------------------------------------------------------

loc_A4B0:				; CODE XREF: CheckLLC+1E8j
		move.b	#$85,(a3)
		bra.s	loc_A4CC
; ---------------------------------------------------------------------------

loc_A4B6:				; CODE XREF: CheckLLC+1EEj
		move.b	#$86,(a3)
		bra.s	loc_A4CC
; ---------------------------------------------------------------------------

loc_A4BC:				; CODE XREF: CheckLLC+1F4j
		move.b	#$87,(a3)
		bra.s	loc_A4CC
; ---------------------------------------------------------------------------

loc_A4C2:				; CODE XREF: CheckLLC+1FAj
		move.b	#$88,(a3)
		bra.s	loc_A4CC
; ---------------------------------------------------------------------------

loc_A4C8:				; CODE XREF: CheckLLC+200j
		move.b	#$21,(a3) ; '!'

loc_A4CC:				; CODE XREF: CheckLLC+202j
					; CheckLLC+208j ...
		move.b	(a3),d0
		cmpi.b	#$80,d0
		bls.s	loc_A4EA
		move.b	(a4),d0
		moveq	#$60,d1	; '`'
		and.b	d1,d0
		moveq	#$40,d1	; '@'
		cmp.b	d1,d0
		beq.s	loc_A4EA

loc_A4E0:				; CODE XREF: CheckLLC+12Aj
					; CheckLLC+13Cj ...
		movea.l	arg_0(a6),a0
		clr.b	9(a0)
		bra.s	loc_A548
; ---------------------------------------------------------------------------

loc_A4EA:				; CODE XREF: CheckLLC+B6j CheckLLC+BAj ...
		move.b	(a4)+,d0
		andi.b	#$80,d0
		beq.s	loc_A504
		move.b	var_7(a6),d0
		andi.b	#$F0,d0
		moveq	#$10,d1
		add.b	d1,d0
		move.b	d0,var_7(a6)
		bra.s	loc_A508
; ---------------------------------------------------------------------------

loc_A504:				; CODE XREF: CheckLLC+244j
		addq.b	#1,var_7(a6)

loc_A508:				; CODE XREF: CheckLLC+256j
		subq.b	#1,var_8(a6)

loc_A50C:				; CODE XREF: CheckLLC+54j
		move.b	var_8(a6),d0
		bne.w	loc_A304
		moveq	#$D,d0
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	arg_0(a6),a2
		move.b	9(a2),d0
		cmpi.b	#$80,d0
		bne.s	loc_A53A

loc_A52E:				; CODE XREF: CheckLLC+C8j
					; CheckLLC+18Aj ...
		movea.l	arg_0(a6),a0
		move.b	#$64,7(a0) ; 'd'
		bra.s	loc_A548
; ---------------------------------------------------------------------------

loc_A53A:				; CODE XREF: CheckLLC+280j
		move.l	arg_4(a6),-(sp)
		move.l	a2,-(sp)
		jsr	CheckState
		addq.w	#8,sp

loc_A548:				; CODE XREF: CheckLLC+42j
					; CheckLLC+1D6j ...
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function CheckLLC

; ---------------------------------------------------------------------------
aCheckbearer_0:	dc.b 139,'CheckBearer',0
aCheckbearer:	dc.b 18,'--- CheckBearer ',0,0 ; DATA XREF: CheckLLC+1Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckBearer:				; CODE XREF: A_SETUP_EDSS1+20p

var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-4
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	arg_4(a6),-(sp)
		move.w	#$601,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a4
		cmpa.w	#0,a4
		beq.w	loc_A654
		move.b	(a4)+,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.w	loc_A654
		move.b	(a4)+,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_A5C6
		moveq	#7,d1
		cmp.l	d1,d0
		beq.s	loc_A5C6
		moveq	#1,d1
		cmp.l	d1,d0
		beq.w	loc_A63A
		moveq	#2,d1
		cmp.l	d1,d0
		beq.w	loc_A64A
		bra.w	loc_A650
; ---------------------------------------------------------------------------

loc_A5C6:				; CODE XREF: CheckBearer+3Aj
					; CheckBearer+40j
		move.b	#1,9(a3)
		move.b	(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		cmpi.l	#$A9,d0	; '©'
		beq.s	loc_A5F4
		cmpi.l	#$C4,d0	; 'Ä'
		beq.s	loc_A5FC
		cmpi.l	#$C5,d0	; 'Å'
		beq.s	loc_A604
		cmpi.l	#$C7,d0	; 'Ç'
		beq.s	loc_A60C
		bra.s	loc_A614
; ---------------------------------------------------------------------------

loc_A5F4:				; CODE XREF: CheckBearer+68j
		ori.b	#$20,9(a3) ; ' '
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A5FC:				; CODE XREF: CheckBearer+70j
		move.b	#$85,9(a3)
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A604:				; CODE XREF: CheckBearer+78j
		move.b	#$86,9(a3)
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A60C:				; CODE XREF: CheckBearer+80j
		move.b	#$87,9(a3)
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A614:				; CODE XREF: CheckBearer+82j
		move.b	(a4),d3
		move.w	d3,var_4(a6)
		andi.b	#$C0,d3
		move.b	#$C0,d0
		cmp.b	d0,d3
		beq.s	loc_A634
		move.w	var_4(a6),d0
		andi.b	#$E0,d0
		cmpi.b	#$A0,d0
		bne.s	loc_A650

loc_A634:				; CODE XREF: CheckBearer+B4j
		clr.b	9(a3)
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A63A:				; CODE XREF: CheckBearer+46j
		move.b	(a4),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_A64A
		move.b	#$F0,9(a3)
		bra.s	loc_A650
; ---------------------------------------------------------------------------

loc_A64A:				; CODE XREF: CheckBearer+4Ej
					; CheckBearer+D0j
		move.b	#$E0,9(a3)

loc_A650:				; CODE XREF: CheckBearer+52j
					; CheckBearer+8Aj ...
		moveq	#1,d0
		bra.s	loc_A656
; ---------------------------------------------------------------------------

loc_A654:				; CODE XREF: CheckBearer+22j
					; CheckBearer+2Cj
		clr.b	d0

loc_A656:				; CODE XREF: CheckBearer+E2j
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function CheckBearer

; ---------------------------------------------------------------------------
aCheckservice:	dc.b 140,'CheckService',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckService:				; CODE XREF: update_call+B4p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_4(a6),a2
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4A,d1	; 'J'
		cmp.b	d1,d0
		bne.s	loc_A6E2
		move.l	a2,-(sp)
		move.w	#$601,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.w	loc_A874
		moveq	#0,d4
		move.b	(a3)+,d0
		moveq	#0,d5
		move.b	d0,d5
		subq.l	#1,d5
		addq.w	#1,a3
		bra.s	loc_A6D0
; ---------------------------------------------------------------------------

loc_A6AE:				; CODE XREF: CheckService+6Aj
		move.l	d4,d0
		move.l	d0,d1
		mulu.w	#$A,d0
		swap	d1
		mulu.w	#$A,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		move.b	(a3)+,d2
		moveq	#$F,d3
		and.b	d3,d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,d4

loc_A6D0:				; CODE XREF: CheckService+3Ej
		subq.l	#1,d5
		cmpi.l	#0,d5
		bpl.s	loc_A6AE
		tst.l	d4
		beq.w	loc_A874
		bra.s	loc_A75E
; ---------------------------------------------------------------------------

loc_A6E2:				; CODE XREF: CheckService+18j
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_A76A
		move.l	a2,-(sp)
		moveq	#$20,d0	; ' '
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.w	loc_A874
		tst.b	(a3)+
		bne.w	loc_A874
		move.b	(a3)+,d0
		moveq	#$32,d1	; '2'
		cmp.b	d1,d0
		bne.w	loc_A874
		move.b	(a3)+,d0
		moveq	#$34,d1	; '4'
		cmp.b	d1,d0
		bne.w	loc_A874
		move.b	(a3)+,d0
		moveq	#$2A,d1	; '*'
		cmp.b	d1,d0
		bne.w	loc_A874
		move.b	(a3)+,d0
		moveq	#0,d3
		move.b	d0,d3
		move.b	(a3)+,d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		add.l	d0,d3
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		add.l	d0,d3
		beq.w	loc_A874
		movea.l	arg_0(a6),a0
		move.l	$34(a0),d0
		cmp.l	d3,d0
		beq.w	loc_A874
		bra.w	loc_A85A
; ---------------------------------------------------------------------------

loc_A75E:				; CODE XREF: CheckService+72j
		movea.l	arg_0(a6),a0
		move.l	d4,$34(a0)
		bra.w	loc_A862
; ---------------------------------------------------------------------------

loc_A76A:				; CODE XREF: CheckService+80j
		move.l	a2,-(sp)
		moveq	#$1C,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.w	loc_A874
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	a3,d0
		movea.l	d0,a4
		addq.w	#1,a4
		addq.w	#1,a3
		move.b	(a3)+,d0
		cmpi.b	#$91,d0
		bne.w	loc_A874
		move.b	(a3)+,d0
		cmpi.b	#$A1,d0
		bne.w	loc_A874
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	a3,d0
		movea.l	d0,a0
		addq.w	#1,a0
		cmpa.l	a4,a0
		bne.w	loc_A874
		addq.w	#1,a3
		move.b	(a3)+,d0
		moveq	#2,d3
		cmp.b	d3,d0
		bne.w	loc_A874
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	a3,d0
		movea.l	d0,a0
		addq.w	#1,a0
		move.l	a0,d0
		movea.l	d0,a3
		cmp.l	a4,d0
		bge.w	loc_A874
		move.b	(a3)+,d0
		cmp.b	d3,d0
		bne.w	loc_A874
		move.b	(a3)+,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.w	loc_A874
		move.b	(a3),d3
		moveq	#$22,d0	; '"'
		cmp.b	d0,d3
		beq.s	loc_A7F8
		moveq	#$24,d0	; '$'
		cmp.b	d0,d3
		bne.s	loc_A874

loc_A7F8:				; CODE XREF: CheckService+182j
					; CheckService+198j
		addq.w	#1,a3
		move.l	a4,d3
		cmpa.l	d3,a3
		bge.s	loc_A808
		move.b	(a3),d0
		cmpi.b	#$A1,d0
		bne.s	loc_A7F8

loc_A808:				; CODE XREF: CheckService+190j
		addq.w	#1,a3
		move.b	(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	a3,d0
		cmp.l	d3,d0
		bge.s	loc_A874
		addq.w	#1,a3
		move.b	(a3)+,d0
		moveq	#$30,d1	; '0'
		cmp.b	d1,d0
		bne.s	loc_A874
		addq.w	#1,a3
		move.b	(a3)+,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.s	loc_A874
		move.b	(a3)+,d0
		moveq	#0,d4
		move.b	d0,d4
		moveq	#0,d3
		bra.s	loc_A842
; ---------------------------------------------------------------------------

loc_A834:				; CODE XREF: CheckService+1DAj
		move.l	d3,d0
		asl.l	#8,d0
		move.l	d0,d3
		move.b	(a3)+,d1
		moveq	#0,d0
		move.b	d1,d0
		add.l	d0,d3

loc_A842:				; CODE XREF: CheckService+1C4j
		subq.w	#1,d4
		cmpi.w	#0,d4
		bpl.s	loc_A834
		tst.l	d3
		beq.s	loc_A874
		movea.l	arg_0(a6),a0
		move.l	$34(a0),d0
		cmp.l	d3,d0
		beq.s	loc_A874

loc_A85A:				; CODE XREF: CheckService+ECj
		movea.l	arg_0(a6),a0
		move.l	d3,$34(a0)

loc_A862:				; CODE XREF: CheckService+F8j
		move.l	arg_0(a6),-(sp)
		pea	(NL_CALL_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_A874:				; CODE XREF: CheckService+2Ej
					; CheckService+6Ej ...
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function CheckService

; ---------------------------------------------------------------------------
aCheckinfoedss1:dc.b 142,'CheckInfoEDSS1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckInfoEDSS1:				; CODE XREF: update_call+CCp

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3-d5/a2,-(sp)
		move.l	arg_4(a6),-(sp)
		move.w	#$602,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_A906
		moveq	#0,d4
		move.b	(a2)+,d0
		moveq	#0,d5
		move.b	d0,d5
		subq.l	#1,d5
		addq.w	#1,a2
		bra.s	loc_A8DE
; ---------------------------------------------------------------------------

loc_A8BC:				; CODE XREF: CheckInfoEDSS1+58j
		move.l	d4,d0
		move.l	d0,d1
		mulu.w	#$A,d0
		swap	d1
		mulu.w	#$A,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		move.b	(a2)+,d2
		moveq	#$F,d3
		and.b	d3,d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,d4

loc_A8DE:				; CODE XREF: CheckInfoEDSS1+2Cj
		subq.l	#1,d5
		cmpi.l	#0,d5
		bpl.s	loc_A8BC
		tst.l	d4
		beq.s	loc_A906
		movea.l	arg_0(a6),a0
		move.l	d4,$34(a0)
		move.l	arg_0(a6),-(sp)
		pea	(NL_CALL_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_A906:				; CODE XREF: CheckInfoEDSS1+1Ej
					; CheckInfoEDSS1+5Cj
		movem.l	(sp)+,d3-d5/a2
		unlk	a6
		rts
; End of function CheckInfoEDSS1

; ---------------------------------------------------------------------------
aCheckinfo1tr6:	dc.b 141,'CheckInfo1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckInfo1TR6:				; CODE XREF: A_CALL_CLEAR_1TR6+72p
					; A_INFO+28p ...

arg_0		=  8
arg_2		=  $A
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_A974
		moveq	#7,d0
		lea	-$470(a5),a0
		movea.l	a2,a1
		moveq	#$1E,d1
		adda.l	d1,a1

loc_A946:				; CODE XREF: CheckInfo1TR6+2Aj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_A946
		move.b	arg_0(a6),$20(a2)
		move.b	arg_2(a6),$21(a2)
		move.b	arg_4(a6),d0
		ori.b	#$80,d0
		move.b	d0,$25(a2)
		moveq	#8,d0
		move.l	d0,$14(a2)
		move.l	a2,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_A974:				; CODE XREF: CheckInfo1TR6+1Aj
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CheckInfo1TR6

; ---------------------------------------------------------------------------
aSendclearedss1:dc.b 142,'SendClearEDSS1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendClearEDSS1:				; CODE XREF: SendMessage+EEp
					; A_UNEXPECTED_EDSS1+1Cp ...

arg_0		=  8
arg_2		=  $A
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a3,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_AA00
		moveq	#6,d0
		lea	-$468(a5),a0
		movea.l	a3,a1
		moveq	#$1E,d1
		adda.l	d1,a1

loc_A9B6:				; CODE XREF: SendClearEDSS1+2Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_A9B6
		move.b	arg_0(a6),$20(a3)
		move.b	arg_2(a6),$21(a3)
		move.b	arg_4(a6),d3
		moveq	#$7F,d0	; ''
		and.b	d0,d3
		beq.s	loc_A9EC
		move.b	#1,$23(a3)
		move.b	arg_4(a6),d0
		ori.b	#$80,d0
		move.b	d0,$24(a3)
		moveq	#7,d0
		move.l	d0,$14(a3)
		bra.s	loc_A9F6
; ---------------------------------------------------------------------------

loc_A9EC:				; CODE XREF: SendClearEDSS1+44j
		clr.b	$23(a3)
		moveq	#6,d0
		move.l	d0,$14(a3)

loc_A9F6:				; CODE XREF: SendClearEDSS1+5Ej
		move.l	a3,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_AA00:				; CODE XREF: SendClearEDSS1+1Cj
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function SendClearEDSS1

; ---------------------------------------------------------------------------
aSendclear1tr6:	dc.b 141,'SendClear1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendClear1TR6:				; CODE XREF: SendMessage+C2p
					; A_CALL_CONTROL+38p ...

arg_0		=  8
arg_2		=  $A
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_AA6E
		moveq	#$A,d0
		lea	-$460(a5),a0
		movea.l	a2,a1
		moveq	#$1E,d1
		adda.l	d1,a1

loc_AA40:				; CODE XREF: SendClear1TR6+2Aj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_AA40
		move.b	arg_0(a6),$20(a2)
		move.b	arg_4(a6),d0
		ori.b	#$80,d0
		move.b	d0,$25(a2)
		move.b	arg_2(a6),$28(a2)
		moveq	#$B,d0
		move.l	d0,$14(a2)
		move.l	a2,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_AA6E:				; CODE XREF: SendClear1TR6+1Aj
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function SendClear1TR6

; ---------------------------------------------------------------------------
aSendstatus:	dc.b 138,'SendSTATUS',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendSTATUS:				; CODE XREF: A_CONNECT_ACKNOWLEDGE+40p
					; A_CALL_CLEAR_1TR6+3Ap ...

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		move.l	a2,-(sp)
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_AAC6
		move.b	-$4CC(a5),$1E(a2)
		move.b	#1,$1F(a2)
		move.b	arg_0(a6),$20(a2)
		move.b	arg_2(a6),$21(a2)
		moveq	#4,d0
		move.l	d0,$14(a2)
		move.l	a2,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_AAC6:				; CODE XREF: SendSTATUS+1Aj
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function SendSTATUS

; ---------------------------------------------------------------------------
aSendmessage:	dc.b 139,'SendMessage',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendMessage:				; CODE XREF: A_CALL_CONTROL+56p

var_4		= -4
var_3		= -3
arg_0		=  8
arg_4		=  $C
arg_8		=  $10

		link	a6,#-4
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		clr.b	var_4(a6)
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckComprehension
		addq.w	#8,sp
		move.b	d0,var_3(a6)
		cmpi.b	#4,arg_8(a6)
		bne.s	loc_AB14
		move.l	a3,-(sp)
		pea	(NL_CHARGE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_AB14:				; CODE XREF: SendMessage+28j
		move.b	5(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		beq.s	loc_AB48
		move.b	var_3(a6),d3
		cmpi.b	#$FE,d3
		beq.s	loc_AB30
		move.b	8(a3),d0
		cmp.b	d3,d0
		bne.s	loc_AB3A

loc_AB30:				; CODE XREF: SendMessage+4Cj
		move.b	arg_8(a6),6(a3)
		bra.w	loc_ABEE
; ---------------------------------------------------------------------------

loc_AB3A:				; CODE XREF: SendMessage+54j
		move.b	#$64,var_4(a6) ; 'd'
		move.b	arg_8(a6),6(a3)
		bra.s	loc_AB7A
; ---------------------------------------------------------------------------

loc_AB48:				; CODE XREF: SendMessage+42j
		move.b	var_3(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		cmpi.l	#$FE,d0	; 'þ'
		beq.s	loc_AB6C
		tst.l	d0
		beq.s	loc_AB74
		moveq	#3,d1
		cmp.l	d1,d0
		beq.s	loc_AB74
		cmpi.l	#$FF,d0
		beq.s	loc_AB74
		bra.s	loc_AB7A
; ---------------------------------------------------------------------------

loc_AB6C:				; CODE XREF: SendMessage+7Cj
		move.b	#$60,var_4(a6) ; '`'
		bra.s	loc_AB7A
; ---------------------------------------------------------------------------

loc_AB74:				; CODE XREF: SendMessage+80j
					; SendMessage+86j ...
		move.b	#$64,var_4(a6) ; 'd'

loc_AB7A:				; CODE XREF: SendMessage+6Cj
					; SendMessage+90j ...
		move.b	var_4(a6),d0
		beq.s	loc_ABD2
		movea.l	a3,a0
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_ABA6
		move.b	var_4(a6),d0
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp
		bra.s	loc_ABEE
; ---------------------------------------------------------------------------

loc_ABA6:				; CODE XREF: SendMessage+AEj
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$F0,d0
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp
		bra.s	loc_ABEE
; ---------------------------------------------------------------------------

loc_ABD2:				; CODE XREF: SendMessage+A4j
		move.b	var_3(a6),8(a3)
		move.b	arg_8(a6),6(a3)
		move.l	a3,-(sp)
		pea	(WriteDeviceProtocol).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_ABEE:				; CODE XREF: SendMessage+5Cj
					; SendMessage+CAj ...
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function SendMessage

; ---------------------------------------------------------------------------
aA_call_control:dc.b 142,'A_CALL_CONTROL',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_CALL_CONTROL:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_AC48
		move.l	arg_4(a6),-(sp)
		move.w	#$677,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		tst.l	d0
		beq.s	loc_AC48
		moveq	#$63,d0	; 'c'
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp

loc_AC48:				; CODE XREF: A_CALL_CONTROL+16j
					; A_CALL_CONTROL+2Aj
		move.b	5(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_AC6A
		clr.b	-(sp)
		moveq	#$A,d0
		move.b	d0,-(sp)
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	SendMessage
		lea	$C(sp),sp
		bra.s	loc_AC70
; ---------------------------------------------------------------------------

loc_AC6A:				; CODE XREF: A_CALL_CONTROL+48j
		move.b	#$A,6(a3)

loc_AC70:				; CODE XREF: A_CALL_CONTROL+60j
		move.b	6(a3),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_AC9A
		move.l	a3,-(sp)
		pea	(B_LISTEN).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		pea	(NL_ALERT_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_AC9A:				; CODE XREF: A_CALL_CONTROL+70j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function A_CALL_CONTROL

; ---------------------------------------------------------------------------
aA_connect:	dc.b 137,'A_CONNECT',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_CONNECT:

var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-4
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4B,d1	; 'K'
		cmp.b	d1,d0
		bne.s	loc_AD20
		clr.b	var_4(a6)
		move.l	arg_4(a6),-(sp)
		moveq	#$1E,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_ACEA
		move.b	#$60,var_4(a6) ; '`'
		bra.s	loc_AD04
; ---------------------------------------------------------------------------

loc_ACEA:				; CODE XREF: A_CONNECT+34j
		move.b	(a2)+,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.s	loc_ACFE
		move.b	(a2),d0
		andi.b	#$90,d0
		cmpi.b	#$80,d0
		beq.s	loc_AD04

loc_ACFE:				; CODE XREF: A_CONNECT+44j
		move.b	#$64,var_4(a6) ; 'd'

loc_AD04:				; CODE XREF: A_CONNECT+3Cj
					; A_CONNECT+50j
		move.b	var_4(a6),d0
		beq.s	loc_AD58
		move.b	var_4(a6),-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp
		bra.s	loc_AD58
; ---------------------------------------------------------------------------

loc_AD20:				; CODE XREF: A_CONNECT+18j
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_AD58
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckChannel
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_AD58
		moveq	#$64,d0	; 'd'
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp
		clr.b	7(a3)

loc_AD58:				; CODE XREF: A_CONNECT+5Cj
					; A_CONNECT+72j ...
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function A_CONNECT

; ---------------------------------------------------------------------------
aA_progress:	dc.b 138,'A_PROGRESS',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_PROGRESS:				; CODE XREF: CheckNumber1TR6+4Ep
					; CheckNumber1TR6+7Ep

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_6		=  $E

		link	a6,#-4
		movem.l	d3-d4/a2-a3,-(sp)
		movea.l	arg_6(a6),a0
		addq.w	#1,a0
		move.l	a0,var_4(a6)
		move.l	arg_0(a6),-(sp)
		move.w	arg_4(a6),-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_ADF8
		move.b	(a2)+,d0
		moveq	#0,d3
		move.b	d0,d3
		moveq	#2,d0
		cmp.l	d0,d3
		blt.s	loc_ADF8
		movea.l	a2,a3
		adda.l	d3,a3
		move.b	(a2)+,d0
		moveq	#0,d4
		move.b	d0,d4
		move.l	d4,d0
		andi.l	#$80,d0	; '€'
		bne.s	loc_ADBA
		addq.w	#1,a2

loc_ADBA:				; CODE XREF: A_PROGRESS+48j
		move.l	d4,d0
		moveq	#$70,d1	; 'p'
		and.l	d1,d0
		asr.l	#4,d0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_ADD0
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_ADDC
		bra.s	loc_ADF4
; ---------------------------------------------------------------------------

loc_ADD0:				; CODE XREF: A_PROGRESS+58j
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	#$2B,(a0) ; '+'

loc_ADDC:				; CODE XREF: A_PROGRESS+5Ej
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	#$2B,(a0) ; '+'
		bra.s	loc_ADF4
; ---------------------------------------------------------------------------

loc_ADEA:				; CODE XREF: A_PROGRESS+88j
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	(a2)+,(a0)

loc_ADF4:				; CODE XREF: A_PROGRESS+60j
					; A_PROGRESS+7Aj
		cmpa.l	a3,a2
		blt.s	loc_ADEA

loc_ADF8:				; CODE XREF: A_PROGRESS+28j
					; A_PROGRESS+34j
		move.b	var_4+3(a6),d0
		sub.b	arg_6+3(a6),d0
		subq.b	#1,d0
		movea.l	arg_6(a6),a0
		move.b	d0,(a0)
		movem.l	(sp)+,d3-d4/a2-a3
		unlk	a6
		rts
; End of function A_PROGRESS

; ---------------------------------------------------------------------------
aChecknumber:	dc.b 139,'CheckNumber',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckNumber:				; CODE XREF: CheckNumber1TR6+66p
					; CheckNumber1TR6+96p

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_6		=  $E

		link	a6,#-4
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_6(a6),a0
		addq.w	#1,a0
		move.l	a0,var_4(a6)
		move.l	arg_0(a6),-(sp)
		move.w	arg_4(a6),-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_AE76
		move.b	(a2)+,d0
		moveq	#0,d3
		move.b	d0,d3
		moveq	#2,d0
		cmp.l	d0,d3
		blt.s	loc_AE76
		movea.l	a2,a3
		adda.l	d3,a3
		addq.w	#1,a2
		movea.l	a2,a0
		move.b	(a0),d0
		moveq	#$50,d1	; 'P'
		cmp.b	d1,d0
		bne.s	loc_AE72
		addq.w	#1,a2
		bra.s	loc_AE72
; ---------------------------------------------------------------------------

loc_AE68:				; CODE XREF: CheckNumber+56j
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	(a2)+,(a0)

loc_AE72:				; CODE XREF: CheckNumber+44j
					; CheckNumber+48j
		cmpa.l	a3,a2
		blt.s	loc_AE68

loc_AE76:				; CODE XREF: CheckNumber+28j
					; CheckNumber+34j
		move.b	var_4+3(a6),d0
		sub.b	arg_6+3(a6),d0
		subq.b	#1,d0
		movea.l	arg_6(a6),a0
		move.b	d0,(a0)
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function CheckNumber

; ---------------------------------------------------------------------------
aChecksubaddress:dc.b 143,'CheckSubaddress',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckSubaddress:			; CODE XREF: A_SETUP_EDSS1+5Cp
					; A_SETUP_EDSS1+74p

var_4		= -4
arg_0		=  8
arg_4		=  $C
arg_6		=  $E

		link	a6,#-4
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_6(a6),a0
		addq.w	#1,a0
		move.l	a0,var_4(a6)
		move.l	arg_0(a6),-(sp)
		move.w	arg_4(a6),-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_AEF4
		move.b	(a2)+,d0
		moveq	#0,d3
		move.b	d0,d3
		moveq	#2,d0
		cmp.l	d0,d3
		blt.s	loc_AEF4
		movea.l	a2,a3
		adda.l	d3,a3
		move.b	(a2)+,d0
		andi.b	#$80,d0
		bne.s	loc_AEF0
		addq.w	#1,a2
		bra.s	loc_AEF0
; ---------------------------------------------------------------------------

loc_AEE6:				; CODE XREF: CheckSubaddress+52j
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	(a2)+,(a0)

loc_AEF0:				; CODE XREF: CheckSubaddress+40j
					; CheckSubaddress+44j
		cmpa.l	a3,a2
		blt.s	loc_AEE6

loc_AEF4:				; CODE XREF: CheckSubaddress+28j
					; CheckSubaddress+34j
		move.b	var_4+3(a6),d0
		sub.b	arg_6+3(a6),d0
		subq.b	#1,d0
		movea.l	arg_6(a6),a0
		move.b	d0,(a0)
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function CheckSubaddress

; ---------------------------------------------------------------------------
aChecknumber1tr6:dc.b 143,'CheckNumber1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CheckNumber1TR6:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	arg_4(a6),a4
		move.b	4(a3),d0
		andi.b	#$80,d0
		beq.w	loc_AFF6
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	ScanIE
		addq.w	#8,sp
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	CheckLLC
		addq.w	#8,sp
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	GetChannel
		addq.w	#8,sp
		movea.l	a3,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$70,d0	; 'p'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	A_PROGRESS
		lea	$A(sp),sp
		movea.l	a3,a0
		moveq	#$7C,d0	; '|'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$71,d0	; 'q'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	CheckNumber
		lea	$A(sp),sp
		movea.l	a3,a0
		moveq	#$3A,d0	; ':'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6C,d0	; 'l'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	A_PROGRESS
		lea	$A(sp),sp
		movea.l	a3,a0
		moveq	#$50,d0	; 'P'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6D,d0	; 'm'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	CheckNumber
		lea	$A(sp),sp
		move.b	#6,6(a3)
		move.l	a3,-(sp)
		move.b	7(a3),d0
		moveq	#$60,d1	; '`'
		cmp.b	d1,d0
		bcs.s	loc_AFD8
		lea	(NL_DISCONNECT_REQUEST).l,a0
		bra.s	loc_AFEC
; ---------------------------------------------------------------------------

loc_AFD8:				; CODE XREF: CheckNumber1TR6+B0j
		tst.b	9(a3)
		beq.s	loc_AFE6
		lea	(Connect2nd).l,a0
		bra.s	loc_AFEC
; ---------------------------------------------------------------------------

loc_AFE6:				; CODE XREF: CheckNumber1TR6+BEj
		lea	(NL_BUSY_REQUEST).l,a0

loc_AFEC:				; CODE XREF: CheckNumber1TR6+B8j
					; CheckNumber1TR6+C6j
		move.l	a0,-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_AFF6:				; CODE XREF: CheckNumber1TR6+18j
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function CheckNumber1TR6

; ---------------------------------------------------------------------------
aA_setup_edss1:	dc.b 141,'A_SETUP_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_SETUP_EDSS1:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	arg_4(a6),a4
		move.b	4(a3),d0
		andi.b	#$80,d0
		beq.w	loc_B0D2
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	CheckBearer
		addq.w	#8,sp
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	GetChannel
		addq.w	#8,sp
		move.b	8(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_B05C
		moveq	#2,d1
		cmp.l	d1,d0
		beq.s	loc_B05C
		move.b	#$BB,7(a3)

loc_B05C:				; CODE XREF: A_SETUP_EDSS1+40j
					; A_SETUP_EDSS1+46j
		movea.l	a3,a2
		moveq	#$66,d0	; 'f'
		adda.l	d0,a2
		move.l	a2,-(sp)
		moveq	#$70,d0	; 'p'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	CheckSubaddress
		lea	$A(sp),sp
		movea.l	a3,a0
		moveq	#$3A,d0	; ':'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6C,d0	; 'l'
		move.w	d0,-(sp)
		move.l	a4,-(sp)
		jsr	CheckSubaddress
		lea	$A(sp),sp
		move.l	a4,-(sp)
		move.l	a3,-(sp)
		jsr	CheckCause1TR6
		addq.w	#8,sp
		tst.b	7(a3)
		beq.s	loc_B0B6
		move.b	#6,6(a3)
		move.l	a3,-(sp)
		pea	(NL_DISCONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_B0D2
; ---------------------------------------------------------------------------

loc_B0B6:				; CODE XREF: A_SETUP_EDSS1+8Ej
		tst.b	9(a3)
		beq.s	loc_B0D2
		move.b	#6,6(a3)
		move.l	a3,-(sp)
		pea	(Connect2nd).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B0D2:				; CODE XREF: A_SETUP_EDSS1+18j
					; A_SETUP_EDSS1+A6j ...
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function A_SETUP_EDSS1

; ---------------------------------------------------------------------------
aA_setup_1tr6:	dc.b 140,'A_SETUP_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_SETUP_1TR6:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	a2,-(sp)
		pea	(B_LISTEN).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$A,6(a2)
		move.l	a2,-(sp)
		pea	(NL_ALERT_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_SETUP_1TR6

; ---------------------------------------------------------------------------
aA_connect_acknowledge:dc.b 149,'A_CONNECT_ACKNOWLEDGE',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_CONNECT_ACKNOWLEDGE:

arg_0		=  8
arg_4		=  $C
arg_8		=  $10
arg_A		=  $12

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	5(a3),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bcc.s	loc_B16A
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckCauseEDSS1
		addq.w	#8,sp

loc_B16A:				; CODE XREF: A_CONNECT_ACKNOWLEDGE+22j
		move.b	arg_A(a6),d0
		beq.s	loc_B180
		move.b	arg_A(a6),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp

loc_B180:				; CODE XREF: A_CONNECT_ACKNOWLEDGE+36j
		move.b	arg_8(a6),d0
		move.b	d0,6(a3)
		tst.b	d0
		beq.s	loc_B19C
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B19C:				; CODE XREF: A_CONNECT_ACKNOWLEDGE+52j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function A_CONNECT_ACKNOWLEDGE

; ---------------------------------------------------------------------------
aA_call_clear_1tr6:dc.b	145,'A_CALL_CLEAR_1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_CALL_CLEAR_1TR6:

arg_0		=  8
arg_4		=  $C
arg_8		=  $10
arg_A		=  $12

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	arg_4(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckChannel
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_B1FA
		move.b	arg_A(a6),d0
		beq.s	loc_B1FA
		move.b	arg_A(a6),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp
		bra.s	loc_B230
; ---------------------------------------------------------------------------

loc_B1FA:				; CODE XREF: A_CALL_CLEAR_1TR6+2Aj
					; A_CALL_CLEAR_1TR6+30j
		move.b	arg_A(a6),d0
		beq.s	loc_B230
		move.l	arg_4(a6),-(sp)
		moveq	#8,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		tst.l	d0
		beq.s	loc_B218
		moveq	#$64,d0	; 'd'
		bra.s	loc_B21A
; ---------------------------------------------------------------------------

loc_B218:				; CODE XREF: A_CALL_CLEAR_1TR6+5Cj
		moveq	#$60,d0	; '`'

loc_B21A:				; CODE XREF: A_CALL_CLEAR_1TR6+60j
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		move.b	arg_A(a6),-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp

loc_B230:				; CODE XREF: A_CALL_CLEAR_1TR6+42j
					; A_CALL_CLEAR_1TR6+48j
		move.b	arg_8(a6),d0
		move.b	d0,6(a3)
		tst.b	d0
		beq.s	loc_B24C
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B24C:				; CODE XREF: A_CALL_CLEAR_1TR6+84j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function A_CALL_CLEAR_1TR6

; ---------------------------------------------------------------------------
aA_call_clear_edss1:dc.b 146,'A_CALL_CLEAR_EDSS1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_CALL_CLEAR_EDSS1:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#$27,d0	; '''
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_B2CC
		move.b	(a2)+,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bcs.s	loc_B2CC
		move.b	(a2),d1
		moveq	#$7F,d2	; ''
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$79,d1	; 'y'
		cmp.l	d1,d0
		beq.s	loc_B2A6
		moveq	#$7A,d1	; 'z'
		cmp.l	d1,d0
		beq.s	loc_B2BA
		bra.s	loc_B2CC
; ---------------------------------------------------------------------------

loc_B2A6:				; CODE XREF: A_CALL_CLEAR_EDSS1+34j
		move.l	arg_0(a6),-(sp)
		pea	(nl_suspend_resume_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_B2CC
; ---------------------------------------------------------------------------

loc_B2BA:				; CODE XREF: A_CALL_CLEAR_EDSS1+3Aj
		move.l	arg_0(a6),-(sp)
		pea	(NL_SUSPENDED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B2CC:				; CODE XREF: A_CALL_CLEAR_EDSS1+1Cj
					; A_CALL_CLEAR_EDSS1+24j ...
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_CALL_CLEAR_EDSS1

; ---------------------------------------------------------------------------
aA_notify_edss1:dc.b 142,'A_NOTIFY_EDSS1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_NOTIFY_EDSS1:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		move.l	arg_4(a6),-(sp)
		moveq	#8,d0
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_B348
		move.b	(a2)+,d0
		moveq	#2,d1
		cmp.b	d1,d0
		bcs.s	loc_B348
		move.b	(a2),d1
		moveq	#$7F,d2	; ''
		and.b	d2,d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$72,d1	; 'r'
		cmp.l	d1,d0
		beq.s	loc_B322
		moveq	#$73,d1	; 's'
		cmp.l	d1,d0
		beq.s	loc_B336
		bra.s	loc_B348
; ---------------------------------------------------------------------------

loc_B322:				; CODE XREF: A_NOTIFY_EDSS1+34j
		move.l	arg_0(a6),-(sp)
		pea	(nl_suspend_resume_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_B348
; ---------------------------------------------------------------------------

loc_B336:				; CODE XREF: A_NOTIFY_EDSS1+3Aj
		move.l	arg_0(a6),-(sp)
		pea	(NL_SUSPENDED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B348:				; CODE XREF: A_NOTIFY_EDSS1+1Cj
					; A_NOTIFY_EDSS1+24j ...
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_NOTIFY_EDSS1

; ---------------------------------------------------------------------------
aA_notify_1tr6:	dc.b 141,'A_NOTIFY_1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_NOTIFY_1TR6:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		moveq	#$1E,d0
		move.b	d0,-(sp)
		movea.l	arg_0(a6),a2
		move.b	5(a2),-(sp)
		move.b	4(a2),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_NOTIFY_1TR6

; ---------------------------------------------------------------------------
aA_status_enquiry:dc.b 144,'A_STATUS_ENQUIRY',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_STATUS_ENQUIRY:
		link	a6,#0
		unlk	a6
		rts
; End of function A_STATUS_ENQUIRY

; ---------------------------------------------------------------------------
aA_info:	dc.b 134,'A_INFO',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_INFO:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	arg_4(a6),-(sp)
		move.l	a2,-(sp)
		jsr	Check1TR6SPV
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_B3D8
		moveq	#$65,d0	; 'e'
		move.b	d0,-(sp)
		moveq	#$5A,d0	; 'Z'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp

loc_B3D8:				; CODE XREF: A_INFO+1Aj
		move.l	arg_4(a6),-(sp)
		move.l	a2,-(sp)
		jsr	CheckChannel
		addq.w	#8,sp
		tst.b	7(a2)
		bne.s	loc_B3F2
		move.b	#$65,7(a2) ; 'e'

loc_B3F2:				; CODE XREF: A_INFO+42j
		clr.b	6(a2)
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_INFO

; ---------------------------------------------------------------------------
aA_status:	dc.b 136,'A_STATUS',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_STATUS:

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		move.l	arg_4(a6),-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	Check1TR6SPV
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_B428
		movea.l	arg_0(a6),a0
		clr.b	6(a0)

loc_B428:				; CODE XREF: A_STATUS+16j
		unlk	a6
		rts
; End of function A_STATUS

; ---------------------------------------------------------------------------
aA_status_u_release_request:dc.b 154,'A_STATUS_U_RELEASE_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_STATUS_U_RELEASE_REQUEST:
		link	a6,#0
		unlk	a6
		rts
; End of function A_STATUS_U_RELEASE_REQUEST

; ---------------------------------------------------------------------------
aA_ignore:	dc.b 136,'A_IGNORE',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_IGNORE:
		link	a6,#0
		unlk	a6
		rts
; End of function A_IGNORE

; ---------------------------------------------------------------------------
aA_facility:	dc.b 138,'A_FACILITY',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_FACILITY:				; DATA XREF: update_call:loc_C2D2o

arg_0		=  8
arg_8		=  $10
arg_A		=  $12

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		cmpi.b	#$7D,arg_A(a6) ; '}'
		bne.s	loc_B49C
		moveq	#$63,d0	; 'c'
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp
		bra.s	loc_B4E0
; ---------------------------------------------------------------------------

loc_B49C:				; CODE XREF: A_FACILITY+10j
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$63,d0	; 'c'
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		move.b	arg_A(a6),-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		move.b	arg_8(a6),d0
		move.b	d0,6(a3)
		tst.b	d0
		beq.s	loc_B4E0
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_B4E0:				; CODE XREF: A_FACILITY+26j
					; A_FACILITY+5Aj
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function A_FACILITY

; ---------------------------------------------------------------------------
aA_comprehension_error:dc.b 149,'A_COMPREHENSION_ERROR',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_COMPREHENSION_ERROR:

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		tst.b	5(a3)
		bne.s	loc_B524
		moveq	#$51,d0	; 'Q'
		move.b	d0,-(sp)
		moveq	#$5A,d0	; 'Z'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		bra.s	loc_B538
; ---------------------------------------------------------------------------

loc_B524:				; CODE XREF: A_COMPREHENSION_ERROR+Ej
		moveq	#$62,d0	; 'b'
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp

loc_B538:				; CODE XREF: A_COMPREHENSION_ERROR+24j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function A_COMPREHENSION_ERROR

; ---------------------------------------------------------------------------
aA_unexpected_edss1:dc.b 146,'A_UNEXPECTED_EDSS1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_UNEXPECTED_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		tst.b	5(a2)
		bne.s	loc_B578
		move.b	#$F0,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp

loc_B578:				; CODE XREF: A_UNEXPECTED_EDSS1+Ej
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function A_UNEXPECTED_EDSS1

; ---------------------------------------------------------------------------
aA_unexpected_1tr6:dc.b	145,'A_UNEXPECTED_1TR6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

A_UNEXPECTED_1TR6:			; CODE XREF: AddSubAddress+1BCp
					; AddSubAddress+1DEp ...

var_8		= -8
var_4		= -4
arg_0		=  8
arg_5		=  $D
arg_6		=  $E

		link	a6,#-8
		movem.l	d3/a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	arg_6(a6),d0
		move.l	d0,var_8(a6)
		cmpi.b	#$41,-$4CC(a5) ; 'A'
		bne.s	loc_B5B6
		move.l	#$A1,d1	; '¡'
		bra.s	loc_B5D2
; ---------------------------------------------------------------------------

loc_B5B6:				; CODE XREF: A_UNEXPECTED_1TR6+1Aj
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#$4A,d2	; 'J'
		cmp.b	d2,d1
		bne.s	loc_B5CC
		move.l	#$80,d1	; '€'
		bra.s	loc_B5D2
; ---------------------------------------------------------------------------

loc_B5CC:				; CODE XREF: A_UNEXPECTED_1TR6+30j
		move.l	#$81,d1	; ''

loc_B5D2:				; CODE XREF: A_UNEXPECTED_1TR6+22j
					; A_UNEXPECTED_1TR6+38j
		move.b	d1,var_4(a6)
		addq.l	#1,arg_6(a6)
		movea.l	arg_6(a6),a0
		movea.l	d0,a1
		move.b	(a1),d0
		moveq	#0,d1
		move.b	d0,d1
		ext.l	d1
		adda.l	d1,a0
		move.l	a0,var_8(a6)
		movea.l	arg_6(a6),a0
		move.b	(a0),d0
		moveq	#$2B,d3	; '+'
		cmp.b	d3,d0
		bne.s	loc_B61A
		addq.l	#1,arg_6(a6)
		movea.l	arg_6(a6),a0
		move.b	(a0),d0
		cmp.b	d3,d0
		bne.s	loc_B614
		ori.b	#$10,var_4(a6)
		addq.l	#1,arg_6(a6)
		bra.s	loc_B61A
; ---------------------------------------------------------------------------

loc_B614:				; CODE XREF: A_UNEXPECTED_1TR6+74j
		ori.b	#$20,var_4(a6) ; ' '

loc_B61A:				; CODE XREF: A_UNEXPECTED_1TR6+66j
					; A_UNEXPECTED_1TR6+80j
		move.b	arg_5(a6),(a2)+
		move.b	var_8+3(a6),d0
		sub.b	arg_6+3(a6),d0
		addq.b	#1,d0
		move.b	d0,(a2)+
		move.b	var_4(a6),(a2)+
		bra.s	loc_B63C
; ---------------------------------------------------------------------------

loc_B630:				; CODE XREF: A_UNEXPECTED_1TR6+B2j
		movea.l	arg_6(a6),a0
		addq.l	#1,arg_6(a6)
		move.b	(a0),d0
		move.b	d0,(a2)+

loc_B63C:				; CODE XREF: A_UNEXPECTED_1TR6+9Cj
		move.l	arg_6(a6),d0
		cmp.l	var_8(a6),d0
		blt.s	loc_B630
		move.l	a2,d0
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function A_UNEXPECTED_1TR6

; ---------------------------------------------------------------------------
aAddnumber:	dc.b 137,'AddNumber',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AddNumber:				; CODE XREF: AddSubAddress+1FEp
					; AddSubAddress+23Ep

var_4		= -4
arg_0		=  8
arg_5		=  $D
arg_6		=  $E

		link	a6,#-4
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	arg_6(a6),a3
		move.b	(a3)+,d1
		moveq	#0,d0
		move.b	d1,d0
		ext.l	d0
		move.l	d0,var_4(a6)
		move.b	arg_5(a6),(a2)+
		move.b	var_4+3(a6),d0
		addq.b	#2,d0
		move.b	d0,(a2)+
		move.b	#$80,(a2)+
		move.b	#$50,(a2)+ ; 'P'
		bra.s	loc_B690
; ---------------------------------------------------------------------------

loc_B68E:				; CODE XREF: AddNumber+40j
		move.b	(a3)+,(a2)+

loc_B690:				; CODE XREF: AddNumber+30j
		subq.l	#1,var_4(a6)
		cmpi.l	#0,var_4(a6)
		bpl.s	loc_B68E
		move.l	a2,d0
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function AddNumber

; ---------------------------------------------------------------------------
aAddsubaddress:	dc.b 141,'AddSubaddress',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

AddSubAddress:				; CODE XREF: SendSetup+18p
					; T_303_2_EDSS1+16p

var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$14
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		move.l	d0,var_14(a6)
		tst.l	d0
		beq.w	loc_BB24
		movea.l	d0,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		move.b	-$4CC(a5),(a3)+
		move.b	#1,(a3)+
		move.b	4(a4),d0
		move.b	d0,(a3)+
		move.b	#5,(a3)+
		cmpi.b	#8,-$4CC(a5)
		bne.w	loc_B828
		move.b	#4,(a3)+
		move.b	9(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		cmpi.l	#$F2,d0	; 'ò'
		beq.s	loc_B724
		cmpi.l	#$F3,d0	; 'ó'
		beq.s	loc_B738
		cmpi.l	#$F7,d0	; '÷'
		beq.s	loc_B76E
		bra.s	loc_B744
; ---------------------------------------------------------------------------

loc_B724:				; CODE XREF: AddSubAddress+58j
		move.b	#3,(a3)+
		move.b	#$91,(a3)+
		move.b	#$90,(a3)+
		move.b	#$A5,(a3)+
		bra.w	loc_B828
; ---------------------------------------------------------------------------

loc_B738:				; CODE XREF: AddSubAddress+60j
		move.b	#2,(a3)+
		move.b	#$98,(a3)+
		bra.w	loc_B7F2
; ---------------------------------------------------------------------------

loc_B744:				; CODE XREF: AddSubAddress+6Aj
		move.b	9(a4),d3
		cmpi.b	#$C0,d3
		bcc.w	loc_B7F8
		moveq	#$20,d0	; ' '
		and.b	d0,d3
		beq.s	loc_B76E
		move.b	#4,(a3)+
		move.b	#$88,(a3)+
		move.b	#$90,(a3)+
		move.b	#$21,(a3)+ ; '!'
		move.b	#$8F,(a3)+
		bra.w	loc_B828
; ---------------------------------------------------------------------------

loc_B76E:				; CODE XREF: AddSubAddress+68j
					; AddSubAddress+9Cj
		move.b	9(a4),d3
		cmpi.b	#$80,d3
		bls.s	loc_B7EA
		cmpi.b	#$C0,d3
		bcc.s	loc_B7EA
		lea	-$28C(a5),a2
		moveq	#7,d0
		move.w	d0,var_10(a6)
		bra.s	loc_B78C
; ---------------------------------------------------------------------------

loc_B78A:				; CODE XREF: AddSubAddress+F6j
		addq.w	#4,a2

loc_B78C:				; CODE XREF: AddSubAddress+D0j
		subq.w	#1,var_10(a6)
		move.w	var_10(a6),d0
		clr.w	d3
		cmp.w	d3,d0
		bmi.s	loc_B7B0
		movea.l	(a2),a0
		move.b	(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		ext.l	d1
		move.b	9(a4),d4
		moveq	#0,d2
		move.b	d4,d2
		cmp.l	d2,d1
		bne.s	loc_B78A

loc_B7B0:				; CODE XREF: AddSubAddress+E0j
		cmp.w	d3,d0
		bmi.s	loc_B828
		movea.l	(a2),a0
		addq.w	#1,a0
		move.l	a0,var_C(a6)
		addq.l	#1,var_C(a6)
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		move.w	d0,var_10(a6)
		move.b	var_10+1(a6),(a3)+
		bra.s	loc_B7DC
; ---------------------------------------------------------------------------

loc_B7D0:				; CODE XREF: AddSubAddress+130j
		movea.l	var_C(a6),a0
		addq.l	#1,var_C(a6)
		move.b	(a0),d0
		move.b	d0,(a3)+

loc_B7DC:				; CODE XREF: AddSubAddress+116j
		subq.w	#1,var_10(a6)
		cmpi.w	#0,var_10(a6)
		bmi.s	loc_B828
		bra.s	loc_B7D0
; ---------------------------------------------------------------------------

loc_B7EA:				; CODE XREF: AddSubAddress+BEj
					; AddSubAddress+C4j
		move.b	#2,(a3)+
		move.b	#$88,(a3)+

loc_B7F2:				; CODE XREF: AddSubAddress+88j
		move.b	#$90,(a3)+
		bra.s	loc_B828
; ---------------------------------------------------------------------------

loc_B7F8:				; CODE XREF: AddSubAddress+94j
		move.b	#3,(a3)+
		move.b	9(a4),d0
		cmpi.b	#$E0,d0
		bls.s	loc_B80C
		move.b	#$80,(a3)+
		bra.s	loc_B810
; ---------------------------------------------------------------------------

loc_B80C:				; CODE XREF: AddSubAddress+14Cj
		move.b	#$90,(a3)+

loc_B810:				; CODE XREF: AddSubAddress+152j
		move.b	#$90,(a3)+
		move.b	#$A3,d0
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d1
		moveq	#1,d2
		and.b	d2,d1
		sub.b	d1,d0
		move.b	d0,(a3)+

loc_B828:				; CODE XREF: AddSubAddress+42j
					; AddSubAddress+7Cj ...
		cmpi.b	#$41,-$4CC(a5) ; 'A'
		bne.s	loc_B84A
		tst.b	$32(a4)
		beq.s	loc_B84A
		move.b	#$20,(a3)+ ; ' '
		move.b	#4,(a3)+
		clr.b	d3
		move.b	d3,(a3)+
		move.b	#$1F,(a3)+
		move.b	d3,(a3)+
		move.b	d3,(a3)+

loc_B84A:				; CODE XREF: AddSubAddress+176j
					; AddSubAddress+17Cj
		cmpi.b	#$41,-$4CC(a5) ; 'A'
		bne.s	loc_B882
		movea.l	a4,a2
		moveq	#$67,d0	; 'g'
		adda.l	d0,a2
		bra.s	loc_B85E
; ---------------------------------------------------------------------------

loc_B85A:				; CODE XREF: AddSubAddress+1ACj
		move.b	#$30,(a2)+ ; '0'

loc_B85E:				; CODE XREF: AddSubAddress+1A0j
		move.b	(a2),d0
		moveq	#$2B,d1	; '+'
		cmp.b	d1,d0
		beq.s	loc_B85A
		movea.l	a4,a0
		moveq	#$38,d0	; '8'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6C,d0	; 'l'
		move.w	d0,-(sp)
		move.l	a3,-(sp)
		jsr	A_UNEXPECTED_1TR6
		lea	$A(sp),sp
		movea.l	d0,a3
		bra.s	loc_B8C2
; ---------------------------------------------------------------------------

loc_B882:				; CODE XREF: AddSubAddress+198j
		tst.b	$3A(a4)
		beq.s	loc_B8A2
		movea.l	a4,a0
		moveq	#$3A,d0	; ':'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6C,d0	; 'l'
		move.w	d0,-(sp)
		move.l	a3,-(sp)
		jsr	A_UNEXPECTED_1TR6
		lea	$A(sp),sp
		movea.l	d0,a3

loc_B8A2:				; CODE XREF: AddSubAddress+1CEj
		tst.b	$50(a4)
		beq.s	loc_B8C2
		movea.l	a4,a0
		moveq	#$50,d0	; 'P'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$6D,d0	; 'm'
		move.w	d0,-(sp)
		move.l	a3,-(sp)
		jsr	AddNumber
		lea	$A(sp),sp
		movea.l	d0,a3

loc_B8C2:				; CODE XREF: AddSubAddress+1C8j
					; AddSubAddress+1EEj
		tst.b	$66(a4)
		beq.s	loc_B8E2
		movea.l	a4,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$70,d0	; 'p'
		move.w	d0,-(sp)
		move.l	a3,-(sp)
		jsr	A_UNEXPECTED_1TR6
		lea	$A(sp),sp
		movea.l	d0,a3

loc_B8E2:				; CODE XREF: AddSubAddress+20Ej
		tst.b	$7C(a4)
		beq.s	loc_B902
		movea.l	a4,a0
		moveq	#$7C,d0	; '|'
		adda.l	d0,a0
		move.l	a0,-(sp)
		moveq	#$71,d0	; 'q'
		move.w	d0,-(sp)
		move.l	a3,-(sp)
		jsr	AddNumber
		lea	$A(sp),sp
		movea.l	d0,a3

loc_B902:				; CODE XREF: AddSubAddress+22Ej
		lea	-$28C(a5),a2
		moveq	#7,d0
		move.w	d0,var_8(a6)
		bra.s	loc_B910
; ---------------------------------------------------------------------------

loc_B90E:				; CODE XREF: AddSubAddress+27Aj
		addq.w	#4,a2

loc_B910:				; CODE XREF: AddSubAddress+254j
		subq.w	#1,var_8(a6)
		move.w	var_8(a6),d0
		clr.w	d3
		cmp.w	d3,d0
		bmi.s	loc_B934
		movea.l	(a2),a0
		move.b	(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		ext.l	d1
		move.b	9(a4),d4
		moveq	#0,d2
		move.b	d4,d2
		cmp.l	d2,d1
		bne.s	loc_B90E

loc_B934:				; CODE XREF: AddSubAddress+264j
		cmp.w	d3,d0
		bmi.s	loc_B970
		movea.l	(a2),a0
		addq.w	#1,a0
		move.l	a0,var_4(a6)
		addq.l	#1,var_4(a6)
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		move.w	d0,var_8(a6)
		move.b	#$7C,(a3)+ ; '|'
		move.b	var_8+1(a6),(a3)+
		bra.s	loc_B964
; ---------------------------------------------------------------------------

loc_B958:				; CODE XREF: AddSubAddress+2B6j
		movea.l	var_4(a6),a0
		addq.l	#1,var_4(a6)
		move.b	(a0),d0
		move.b	d0,(a3)+

loc_B964:				; CODE XREF: AddSubAddress+29Ej
		subq.w	#1,var_8(a6)
		cmpi.w	#0,var_8(a6)
		bpl.s	loc_B958

loc_B970:				; CODE XREF: AddSubAddress+27Ej
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_B9B4
		move.b	9(a4),d3
		cmpi.b	#$F0,d3
		bcs.s	loc_B99A
		cmpi.b	#$F2,d3
		bhi.s	loc_B99A
		move.b	#$7D,(a3)+ ; '}'
		move.b	#2,(a3)+
		move.b	#$91,(a3)+
		move.b	#$81,(a3)+
		bra.s	loc_B9B4
; ---------------------------------------------------------------------------

loc_B99A:				; CODE XREF: AddSubAddress+2C8j
					; AddSubAddress+2CEj
		move.b	9(a4),d0
		cmpi.b	#$C1,d0
		bne.s	loc_B9B4
		move.b	#$7D,(a3)+ ; '}'
		move.b	#2,(a3)+
		move.b	#$91,(a3)+
		move.b	#$84,(a3)+

loc_B9B4:				; CODE XREF: AddSubAddress+2BEj
					; AddSubAddress+2E0j ...
		cmpi.b	#$41,-$4CC(a5) ; 'A'
		bne.w	loc_BADA
		move.b	#$9E,(a3)+
		move.b	#1,(a3)+
		move.b	#2,(a3)+
		move.b	9(a4),d0
		cmpi.b	#$C0,d0
		bcc.w	loc_BA76
		move.b	#7,(a3)+
		move.b	9(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#5,d1
		cmp.l	d1,d0
		beq.s	loc_BA1E
		moveq	#6,d1
		cmp.l	d1,d0
		beq.s	loc_BA26
		moveq	#$C,d1
		cmp.l	d1,d0
		beq.s	loc_BA2E
		cmpi.l	#$83,d0	; 'ƒ'
		beq.s	loc_BA38
		cmpi.l	#$84,d0	; '„'
		beq.s	loc_BA40
		cmpi.l	#$85,d0	; '…'
		beq.s	loc_BA48
		cmpi.l	#$86,d0	; '†'
		beq.s	loc_BA50
		cmpi.l	#$87,d0	; '‡'
		beq.s	loc_BA58
		bra.s	loc_BA5E
; ---------------------------------------------------------------------------

loc_BA1E:				; CODE XREF: AddSubAddress+32Ej
		move.b	#$81,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA26:				; CODE XREF: AddSubAddress+334j
		move.b	#$82,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA2E:				; CODE XREF: AddSubAddress+33Aj
		move.b	#5,-1(a3)
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA38:				; CODE XREF: AddSubAddress+342j
		move.b	#$C0,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA40:				; CODE XREF: AddSubAddress+34Aj
		move.b	#$C3,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA48:				; CODE XREF: AddSubAddress+352j
		move.b	#$C4,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA50:				; CODE XREF: AddSubAddress+35Aj
		move.b	#$C5,(a3)+
		bra.w	loc_BADA
; ---------------------------------------------------------------------------

loc_BA58:				; CODE XREF: AddSubAddress+362j
		move.b	#$C7,(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BA5E:				; CODE XREF: AddSubAddress+364j
		move.b	9(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		beq.s	loc_BA70
		move.l	#$A9,d0	; '©'
		bra.s	loc_BA72
; ---------------------------------------------------------------------------

loc_BA70:				; CODE XREF: AddSubAddress+3AEj
		moveq	#0,d0

loc_BA72:				; CODE XREF: AddSubAddress+3B6j
		move.b	d0,(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BA76:				; CODE XREF: AddSubAddress+31Aj
		move.b	9(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		cmpi.l	#$F0,d0	; 'ð'
		beq.s	loc_BAA8
		cmpi.l	#$F1,d0	; 'ñ'
		beq.s	loc_BAA8
		cmpi.l	#$C0,d0	; 'À'
		beq.s	loc_BAB0
		cmpi.l	#$F2,d0	; 'ò'
		beq.s	loc_BABA
		cmpi.l	#$F7,d0	; '÷'
		beq.s	loc_BAC4
		bra.s	loc_BACC
; ---------------------------------------------------------------------------

loc_BAA8:				; CODE XREF: AddSubAddress+3CCj
					; AddSubAddress+3D4j
		moveq	#1,d3
		move.b	d3,(a3)+
		move.b	d3,(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BAB0:				; CODE XREF: AddSubAddress+3DCj
		move.b	#1,(a3)+
		move.b	#2,(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BABA:				; CODE XREF: AddSubAddress+3E4j
		move.b	#1,(a3)+
		move.b	#3,(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BAC4:				; CODE XREF: AddSubAddress+3ECj
		move.b	#7,(a3)+
		clr.b	(a3)+
		bra.s	loc_BADA
; ---------------------------------------------------------------------------

loc_BACC:				; CODE XREF: AddSubAddress+3EEj
		move.b	#$10,(a3)+
		move.b	9(a4),d0
		moveq	#3,d1
		and.b	d1,d0
		move.b	d0,(a3)+

loc_BADA:				; CODE XREF: AddSubAddress+302j
					; AddSubAddress+36Aj ...
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_BAF4
		movea.l	-$DB8(a5),a0
		move.b	$1F91(a0),d0
		andi.b	#$80,d0
		beq.s	loc_BAF4
		move.b	#$A1,(a3)+

loc_BAF4:				; CODE XREF: AddSubAddress+428j
					; AddSubAddress+436j
		move.l	a3,d0
		movea.l	var_14(a6),a2
		moveq	#$1E,d1
		adda.l	d1,a2
		sub.l	a2,d0
		movea.l	var_14(a6),a0
		move.l	d0,$14(a0)
		move.l	a0,-(sp)
		jsr	nl_transition
		addq.w	#4,sp
		move.b	#1,6(a4)
		move.l	a4,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		bra.s	loc_BB2A
; ---------------------------------------------------------------------------

loc_BB24:				; CODE XREF: AddSubAddress+20j
		jsr	(WriteBegin).l

loc_BB2A:				; CODE XREF: AddSubAddress+46Aj
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function AddSubAddress

; ---------------------------------------------------------------------------
aSendsetup:	dc.b 137,'SendSetup',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendSetup:				; CODE XREF: scan_calls_waiting:loc_BBB8p
					; dl_data_indication+86p ...
		link	a6,#0
		move.l	a3,-(sp)
		movea.l	-$210(a5),a3
		bra.s	loc_BB60
; ---------------------------------------------------------------------------

loc_BB4A:				; CODE XREF: SendSetup+24j
		move.b	5(a3),d0
		moveq	#$14,d1
		cmp.b	d1,d0
		bne.s	loc_BB5E
		move.l	a3,-(sp)
		jsr	AddSubAddress
		addq.w	#4,sp

loc_BB5E:				; CODE XREF: SendSetup+14j
		movea.l	(a3),a3

loc_BB60:				; CODE XREF: SendSetup+Aj
		move.l	a3,d0
		bne.s	loc_BB4A
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function SendSetup

; ---------------------------------------------------------------------------
aScan_calls_waiting:dc.b 146,'scan_calls_waiting',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

scan_calls_waiting:			; CODE XREF: T_REQUEST_2+34p
					; DL_UNITDATA_INDICATION+10p ...
		link	a6,#0
		movem.l	d3-d4,-(sp)
		move.b	#1,-$4C8(a5)
		move.b	-$4CC(a5),d0
		bne.s	loc_BBB8
		moveq	#$10,d0
		move.b	d0,-(sp)
		moveq	#$4D,d3	; 'M'
		move.b	d3,-(sp)
		moveq	#$7F,d4	; ''
		move.b	d4,-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		clr.b	-(sp)
		move.b	d3,-(sp)
		move.b	d4,-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp
		bra.s	loc_BBBE
; ---------------------------------------------------------------------------

loc_BBB8:				; CODE XREF: scan_calls_waiting+12j
		jsr	SendSetup

loc_BBBE:				; CODE XREF: scan_calls_waiting+36j
		movem.l	(sp)+,d3-d4
		unlk	a6
		rts
; End of function scan_calls_waiting

; ---------------------------------------------------------------------------
aDl_connected:	dc.b 140,'dl_connected',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_connected:				; CODE XREF: DL_ESTABLISH_CONFIRM+12p
					; DL_RELEASE_CONFIRM+28p ...
		link	a6,#0
		move.l	a2,-(sp)
		clr.b	-$4C8(a5)
		bra.s	loc_BBEC
; ---------------------------------------------------------------------------

loc_BBE2:				; CODE XREF: dl_connected+28j
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_BBEC:				; CODE XREF: dl_connected+Aj
		pea	-$208(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_BBE2
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function dl_connected

; ---------------------------------------------------------------------------
aDl_clear:	dc.b 136,'dl_clear',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_clear:				; DATA XREF: T_303_2_EDSS1+1Eo

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		moveq	#$66,d0	; 'f'
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	d0,7(a2)
		move.b	d0,-(sp)
		moveq	#$5A,d0	; 'Z'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		clr.b	6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function dl_clear

; ---------------------------------------------------------------------------
aT_303_2_edss1:	dc.b 141,'T_303_2_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_303_2_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		jsr	(WriteProc).l
		move.l	a2,-(sp)
		jsr	AddSubAddress
		addq.w	#4,sp
		lea	(dl_clear).l,a0
		move.l	a0,$E(a2)
		moveq	#$3E,d0	; '>'
		move.l	d0,-(sp)
		movea.l	a2,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_303_2_EDSS1

; ---------------------------------------------------------------------------
aT_303_edss1:	dc.b 139,'T_303_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_303_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	4(a2),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp
		move.b	#$66,7(a2) ; 'f'
		move.b	#$B,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_303_EDSS1

; ---------------------------------------------------------------------------
aT_303_1tr6:	dc.b 138,'T_303_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_303_1TR6:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	7(a2),-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		move.b	#$13,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_303_1TR6

; ---------------------------------------------------------------------------
aT_305_edss1:	dc.b 139,'T_305_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_305_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	7(a2),-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp
		move.b	#$13,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_305_EDSS1

; ---------------------------------------------------------------------------
aT_305_1tr6:	dc.b 138,'T_305_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_305_1TR6:				; DATA XREF: T_308_2+2Co
					; T_308_EDSS1+24o

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		clr.b	6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		move.l	-$210(a5),d0
		bne.s	loc_BDB2
		clr.l	-(sp)
		pea	(DL_ESTABLISH_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_BDB2:				; CODE XREF: T_305_1TR6+20j
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_305_1TR6

; ---------------------------------------------------------------------------
aT_308_2:	dc.b 135,'T_308_2',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_308_2:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		jsr	(WriteProc).l
		moveq	#$66,d0	; 'f'
		move.b	d0,7(a2)
		move.b	d0,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		lea	(T_305_1TR6).l,a0
		move.l	a0,$E(a2)
		moveq	#$3E,d0	; '>'
		move.l	d0,-(sp)
		movea.l	a2,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_308_2

; ---------------------------------------------------------------------------
aT_308_edss1:	dc.b 139,'T_308_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_308_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		jsr	(WriteProc).l
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp
		lea	(T_305_1TR6).l,a0
		move.l	a0,$E(a2)
		moveq	#$3E,d0	; '>'
		move.l	d0,-(sp)
		movea.l	a2,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_308_EDSS1

; ---------------------------------------------------------------------------
aT_308_1tr6:	dc.b 138,'T_308_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_308_1TR6:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.l	a2,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$66,d0	; 'f'
		move.b	d0,7(a2)
		move.b	d0,-(sp)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		move.b	#$B,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_308_1TR6

; ---------------------------------------------------------------------------
aT_313_edss1:	dc.b 139,'T_313_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_313_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.l	a2,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$12,d0
		move.b	d0,7(a2)
		move.b	d0,-(sp)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		move.b	#$B,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_313_EDSS1

; ---------------------------------------------------------------------------
aT_301_edss1:	dc.b 139,'T_301_EDSS1',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_301_EDSS1:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.l	a2,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$12,7(a2)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp
		move.b	#$B,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_301_EDSS1

; ---------------------------------------------------------------------------
aT_301_1tr6:	dc.b 138,'T_301_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_301_1TR6:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.l	a2,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a2),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp
		move.b	#$B,6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_301_1TR6

; ---------------------------------------------------------------------------
aT_313_1tr6:	dc.b 138,'T_313_1TR6',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_313_1TR6:				; DATA XREF: T_REQUEST_2+14o

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		move.b	#$66,7(a2) ; 'f'
		clr.b	6(a2)
		move.l	a2,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_313_1TR6

; ---------------------------------------------------------------------------
aT_request_2:	dc.b 139,'T_REQUEST_2',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_REQUEST_2:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		jsr	(WriteProc).l
		lea	(T_313_1TR6).l,a0
		move.l	a0,$E(a2)
		move.l	#$EA,-(sp) ; 'ê'
		movea.l	a2,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		jsr	scan_calls_waiting
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function T_REQUEST_2

; ---------------------------------------------------------------------------
aT_request:	dc.b 137,'T_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

T_REQUEST:				; CODE XREF: AddSubAddress+462p
					; dl_clear+2Cp	...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		jsr	(WriteProc).l
		move.b	6(a3),d0
		move.b	5(a3),d1
		cmp.b	d1,d0
		beq.w	loc_C11E
		movea.l	-$216(a5),a4
		tst.l	$E(a3)
		beq.s	loc_C094
		movea.l	a3,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		bra.s	loc_C094
; ---------------------------------------------------------------------------

loc_C092:				; CODE XREF: T_REQUEST+48j
		addq.w	#6,a4

loc_C094:				; CODE XREF: T_REQUEST+28j
					; T_REQUEST+3Aj
		move.b	(a4),d3
		beq.s	loc_C0A0
		move.b	6(a3),d0
		cmp.b	d0,d3
		bne.s	loc_C092

loc_C0A0:				; CODE XREF: T_REQUEST+40j
		tst.b	d3
		bne.s	loc_C0AC
		moveq	#0,d0
		move.l	d0,$E(a3)
		bra.s	loc_C0EC
; ---------------------------------------------------------------------------

loc_C0AC:				; CODE XREF: T_REQUEST+4Cj
		move.l	2(a4),d0
		move.l	d0,$E(a3)
		move.l	a3,$16(a3)
		move.b	1(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,d1
		mulu.w	#$FA,d0	; 'ú'
		swap	d1
		mulu.w	#$FA,d1	; 'ú'
		swap	d1
		clr.w	d1
		add.l	d1,d0
		moveq	#$10,d1
		jsr	main
		move.l	d0,-(sp)
		movea.l	a3,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_C0EC:				; CODE XREF: T_REQUEST+54j
		move.b	4(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		move.b	5(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		asl.l	#8,d1
		add.l	d1,d0
		move.b	6(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(WriteCRef).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_C11E:				; CODE XREF: T_REQUEST+1Cj
		tst.b	6(a3)
		bne.s	loc_C176
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		pea	-$210(a5)
		move.l	a3,-(sp)
		jsr	(Enqueue).l
		addq.w	#8,sp
		move.l	a3,-(sp)
		pea	(B_ERROR_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	-$210(a5),d0
		bne.s	loc_C176
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4E,d1	; 'N'
		cmp.b	d1,d0
		bne.s	loc_C176
		clr.l	-(sp)
		pea	(DL_ESTABLISH_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_C176:				; CODE XREF: T_REQUEST+CCj
					; T_REQUEST+100j ...
		move.b	6(a3),d0
		move.b	d0,5(a3)
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function T_REQUEST

; ---------------------------------------------------------------------------
aUpdate_call:	dc.b 139,'update_call',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

update_call:				; CODE XREF: process_global+30p
					; process_global+4Cp

var_C		= -$C
var_B		= -$B
var_8		= -8
var_4		= -4
arg_0		=  8
arg_4		=  $C

		link	a6,#-$C
		movem.l	d3-d6/a2-a4,-(sp)
		movea.l	arg_4(a6),a4
		movea.l	arg_0(a6),a2
		move.b	$21(a2),d0
		moveq	#0,d5
		move.b	d0,d5
		move.b	$20(a2),d0
		eori.b	#$80,d0
		move.b	d0,var_C(a6)
		clr.b	var_B(a6)
		movea.l	-$210(a5),a3
		bra.s	loc_C1C4
; ---------------------------------------------------------------------------

loc_C1C2:				; CODE XREF: update_call+3Cj
					; update_call+46j
		movea.l	(a3),a3

loc_C1C4:				; CODE XREF: update_call+2Cj
		move.l	a3,d0
		beq.s	loc_C1DC
		move.b	4(a3),d0
		cmp.b	var_C(a6),d0
		bne.s	loc_C1C2
		move.b	5(a3),d0
		moveq	#$14,d1
		cmp.b	d1,d0
		beq.s	loc_C1C2

loc_C1DC:				; CODE XREF: update_call+32j
		move.l	a3,d0
		bne.s	loc_C228
		move.l	#$92,-(sp) ; '’'
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.w	loc_C334
		move.l	a3,var_8(a6)
		clr.b	d3
		move.b	d3,var_4(a6)
		move.w	#$92,d6	; '’'
		move.w	#$91,d0	; '‘'
		move.b	d3,d1
		movea.l	a3,a0

loc_C20E:				; CODE XREF: update_call+7Cj
		move.b	d1,(a0)+
		dbf	d0,loc_C20E
		move.b	var_C(a6),4(a3)
		pea	-$210(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp

loc_C228:				; CODE XREF: update_call+4Aj
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_C25A
		move.l	arg_0(a6),-(sp)
		move.l	a3,-(sp)
		jsr	ScanIE
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_C252
		move.l	arg_0(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckService
		addq.w	#8,sp
		bra.s	loc_C268
; ---------------------------------------------------------------------------

loc_C252:				; CODE XREF: update_call+ACj
		move.b	#1,var_B(a6)
		bra.s	loc_C268
; ---------------------------------------------------------------------------

loc_C25A:				; CODE XREF: update_call+9Aj
		move.l	arg_0(a6),-(sp)
		move.l	a3,-(sp)
		jsr	CheckInfoEDSS1
		addq.w	#8,sp

loc_C268:				; CODE XREF: update_call+BCj
					; update_call+C4j
		moveq	#1,d4
		move.b	5(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	d0,d4
		bra.s	loc_C27A
; ---------------------------------------------------------------------------

loc_C276:				; CODE XREF: update_call+F4j
					; update_call+FCj
		moveq	#$C,d0
		adda.l	d0,a4

loc_C27A:				; CODE XREF: update_call+E0j
		move.b	(a4),d3
		moveq	#0,d0
		move.b	d3,d0
		cmp.l	d5,d0
		beq.s	loc_C28A
		cmpi.b	#$FF,d3
		bne.s	loc_C276

loc_C28A:				; CODE XREF: update_call+EEj
		move.l	2(a4),d0
		and.l	d4,d0
		beq.s	loc_C276
		movea.l	6(a4),a2
		move.l	a2,-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		move.b	var_C(a6),-(sp)
		jsr	TEI_VERIFY_REQUEST
		addq.w	#2,sp
		move.b	var_B(a6),d0
		beq.s	loc_C2E4
		tst.b	$B(a4)
		beq.s	loc_C2E4
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4B,d1	; 'K'
		cmp.b	d1,d0
		bne.s	loc_C2D2
		move.b	$B(a4),d0
		moveq	#$7D,d1	; '}'
		cmp.b	d1,d0
		bne.s	loc_C2D2
		bra.s	loc_C2E4
; ---------------------------------------------------------------------------

loc_C2D2:				; CODE XREF: update_call+130j
					; update_call+13Aj
		lea	(A_FACILITY).l,a2
		moveq	#$2A,d0	; '*'
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp

loc_C2E4:				; CODE XREF: update_call+11Cj
					; update_call+122j ...
		move.b	$B(a4),-(sp)
		move.b	$A(a4),-(sp)
		move.l	arg_0(a6),-(sp)
		move.l	a3,-(sp)
		jsr	(a2)
		lea	$C(sp),sp
		move.b	var_B(a6),d0
		beq.s	loc_C32A
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$4B,d1	; 'K'
		cmp.b	d1,d0
		bne.s	loc_C32A
		move.b	$B(a4),d0
		moveq	#$7D,d1	; '}'
		cmp.b	d1,d0
		bne.s	loc_C32A
		moveq	#$63,d0	; 'c'
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp

loc_C32A:				; CODE XREF: update_call+168j
					; update_call+176j ...
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp

loc_C334:				; CODE XREF: update_call+60j
		movem.l	(sp)+,d3-d6/a2-a4
		unlk	a6
		rts
; End of function update_call

; ---------------------------------------------------------------------------
aProcess_message:dc.b 143,'process_message',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

process_message:			; CODE XREF: process_restart+24p

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	-$210(a5),a3
		clr.b	var_4(a6)
		move.l	arg_0(a6),-(sp)
		moveq	#$79,d0	; 'y'
		move.w	d0,-(sp)
		jsr	SendMsgBuffer
		addq.w	#6,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_C3C2
		move.b	(a2)+,d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_C3C2
		move.b	(a2),d0
		cmpi.b	#$80,d0
		bne.s	loc_C3C2
		move.l	arg_0(a6),-(sp)
		clr.l	-(sp)
		jsr	CheckComprehension
		addq.w	#8,sp
		move.b	d0,var_4(a6)
		bra.s	loc_C3C2
; ---------------------------------------------------------------------------

loc_C39A:				; CODE XREF: process_message+82j
		movea.l	(a3),a4
		tst.l	d3
		bne.s	loc_C3AA
		move.b	8(a3),d0
		cmp.b	var_4(a6),d0
		bne.s	loc_C3BE

loc_C3AA:				; CODE XREF: process_message+50j
		clr.b	6(a3)
		move.b	#$F0,7(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp

loc_C3BE:				; CODE XREF: process_message+5Aj
		movea.l	a4,a3
		bra.s	loc_C3CE
; ---------------------------------------------------------------------------

loc_C3C2:				; CODE XREF: process_message+26j
					; process_message+2Ej ...
		move.b	var_4(a6),d3
		seq	d3
		neg.b	d3
		ext.w	d3
		ext.l	d3

loc_C3CE:				; CODE XREF: process_message+72j
		move.l	a3,d0
		bne.s	loc_C39A
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_C44A
		movea.l	a3,a2
		moveq	#$1E,d3
		adda.l	d3,a2
		move.b	#8,(a2)+
		moveq	#1,d4
		move.b	d4,(a2)+
		movea.l	arg_0(a6),a0
		move.b	$20(a0),d0
		eori.b	#$80,d0
		move.b	d0,(a2)+
		move.b	#$4E,(a2)+ ; 'N'
		move.b	#$18,(a2)+
		move.b	d4,(a2)+
		move.b	var_4(a6),d5
		ori.b	#$88,d5
		move.b	d5,(a2)+
		move.b	#$79,(a2)+ ; 'y'
		move.b	d4,(a2)+
		move.b	var_4(a6),d0
		beq.s	loc_C42C
		move.l	#$80,d0	; '€'
		bra.s	loc_C432
; ---------------------------------------------------------------------------

loc_C42C:				; CODE XREF: process_message+D4j
		move.l	#$86,d0	; '†'

loc_C432:				; CODE XREF: process_message+DCj
		move.b	d0,(a2)+
		move.l	a2,d0
		movea.l	a3,a0
		adda.l	d3,a0
		sub.l	a0,d0
		move.l	d0,$14(a3)
		move.l	a3,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_C44A:				; CODE XREF: process_message+98j
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function process_message

; ---------------------------------------------------------------------------
aProcess_restart:dc.b 143,'process_restart',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

process_restart:			; CODE XREF: process_global+3Cp

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		cmpi.b	#4,-$504(a5)
		bcs.s	loc_C490
		move.b	-$502(a5),d0
		bne.s	loc_C490
		movea.l	arg_0(a6),a2
		move.b	$21(a2),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_C490
		move.l	a2,-(sp)
		jsr	process_message
		addq.w	#4,sp

loc_C490:				; CODE XREF: process_restart+Cj
					; process_restart+12j ...
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function process_restart

; ---------------------------------------------------------------------------
aProcess_global:dc.b 142,'process_global',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

process_global:				; CODE XREF: dl_data_indication+9Ep

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	-$4CC(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_C4C8
		moveq	#$41,d1	; 'A'
		cmp.l	d1,d0
		beq.s	loc_C4EE
		bra.s	loc_C4FC
; ---------------------------------------------------------------------------

loc_C4C8:				; CODE XREF: process_global+16j
		move.b	$20(a3),d0
		moveq	#$7F,d1	; ''
		and.b	d1,d0
		beq.s	loc_C4E2
		pea	-$454(a5)
		move.l	a3,-(sp)
		jsr	update_call
		addq.w	#8,sp
		bra.s	loc_C4FC
; ---------------------------------------------------------------------------

loc_C4E2:				; CODE XREF: process_global+28j
		move.l	a3,-(sp)
		jsr	process_restart
		addq.w	#4,sp
		bra.s	loc_C4FC
; ---------------------------------------------------------------------------

loc_C4EE:				; CODE XREF: process_global+1Cj
		pea	-$358(a5)
		move.l	a3,-(sp)
		jsr	update_call
		addq.w	#8,sp

loc_C4FC:				; CODE XREF: process_global+1Ej
					; process_global+38j ...
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function process_global

; ---------------------------------------------------------------------------
aDl_data_indication:dc.b 146,'dl_data_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_data_indication:			; CODE XREF: DL_DATA_INDICATION+2Ap
					; DATA XREF: dl_u_indication+206o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a3
		move.b	$1E(a3),d0
		moveq	#$40,d1	; '@'
		cmp.b	d1,d0
		beq.s	loc_C534
		jsr	(WriteProc).l

loc_C534:				; CODE XREF: dl_data_indication+14j
		move.l	$14(a3),d0
		moveq	#4,d1
		cmp.l	d1,d0
		blt.w	loc_C5BE
		move.b	$1F(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_C5BE
		move.b	-$4CC(a5),d0
		bne.s	loc_C5A4
		move.b	$1E(a3),d3
		moveq	#8,d0
		cmp.b	d0,d3
		beq.s	loc_C560
		moveq	#$41,d0	; 'A'
		cmp.b	d0,d3
		bne.s	loc_C5A4

loc_C560:				; CODE XREF: dl_data_indication+40j
		move.b	$1E(a3),d0
		moveq	#8,d1
		cmp.b	d1,d0
		bne.s	loc_C574
		lea	-$26A(a5),a0
		move.l	a0,-$216(a5)
		bra.s	loc_C57C
; ---------------------------------------------------------------------------

loc_C574:				; CODE XREF: dl_data_indication+50j
		lea	-$240(a5),a0
		move.l	a0,-$216(a5)

loc_C57C:				; CODE XREF: dl_data_indication+5Aj
		move.b	$1E(a3),d1
		move.b	d1,-$4CC(a5)
		moveq	#0,d0
		move.b	d1,d0
		move.l	d0,-(sp)
		pea	(NL_RELEASE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	-$4C8(a5),d0
		beq.s	loc_C5A4
		jsr	SendSetup

loc_C5A4:				; CODE XREF: dl_data_indication+36j
					; dl_data_indication+46j ...
		move.b	-$4CC(a5),d0
		beq.s	loc_C5BE
		move.b	$1E(a3),d0
		cmp.b	-$4CC(a5),d0
		bne.s	loc_C5BE
		move.l	a3,-(sp)
		jsr	process_global
		addq.w	#4,sp

loc_C5BE:				; CODE XREF: dl_data_indication+24j
					; dl_data_indication+30j ...
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function dl_data_indication

; ---------------------------------------------------------------------------
aDl_data_indication_0:dc.b 146,'DL_DATA_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_DATA_INDICATION:			; DATA XREF: dl_s_or_i_indication+13Ao

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$14(a3),d0
		moveq	#4,d1
		cmp.l	d1,d0
		blt.s	loc_C61A
		move.b	$1F(a3),d0
		moveq	#1,d1
		cmp.b	d1,d0
		bne.s	loc_C61A
		move.b	$21(a3),d0
		moveq	#5,d1
		cmp.b	d1,d0
		bne.s	loc_C61A
		move.l	a3,-(sp)
		jsr	dl_data_indication
		addq.w	#4,sp
		bra.s	loc_C624
; ---------------------------------------------------------------------------

loc_C61A:				; CODE XREF: DL_DATA_INDICATION+12j
					; DL_DATA_INDICATION+1Cj ...
		move.l	a3,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp

loc_C624:				; CODE XREF: DL_DATA_INDICATION+32j
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function DL_DATA_INDICATION

; ---------------------------------------------------------------------------
aDl_unitdata_indication:dc.b 150,'DL_UNITDATA_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_UNITDATA_INDICATION:			; DATA XREF: dl_reestablish+1Co
					; dl_clear_queue+Eo ...

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	-$210(a5),a3
		jsr	(WriteProc).l
		jsr	scan_calls_waiting
		bra.s	loc_C6CA
; ---------------------------------------------------------------------------

loc_C65C:				; CODE XREF: DL_UNITDATA_INDICATION+88j
		move.b	5(a3),d0
		moveq	#2,d1
		cmp.b	d1,d0
		bne.s	loc_C6C8
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_C698
		moveq	#$29,d0	; ')'
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		bra.s	loc_C6A8
; ---------------------------------------------------------------------------

loc_C698:				; CODE XREF: DL_UNITDATA_INDICATION+38j
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp

loc_C6A8:				; CODE XREF: DL_UNITDATA_INDICATION+52j
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$B,6(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp

loc_C6C8:				; CODE XREF: DL_UNITDATA_INDICATION+20j
		movea.l	(a3),a3

loc_C6CA:				; CODE XREF: DL_UNITDATA_INDICATION+16j
		move.l	a3,d0
		bne.s	loc_C65C
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function DL_UNITDATA_INDICATION

; ---------------------------------------------------------------------------
aDl_establish_indication:dc.b 151,'DL_ESTABLISH_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_ESTABLISH_INDICATION:		; DATA XREF: dl_release_confirm+20o

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	-$210(a5),a3
		jsr	(WriteProc).l
		jsr	scan_calls_waiting
		bra.s	loc_C71E
; ---------------------------------------------------------------------------

loc_C714:				; CODE XREF: DL_ESTABLISH_INDICATION+36j
		move.l	a2,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_C71E:				; CODE XREF: DL_ESTABLISH_INDICATION+18j
		pea	-$208(a5)
		jsr	(Inqueue).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		bne.s	loc_C714
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_C78E
		bra.s	loc_C78A
; ---------------------------------------------------------------------------

loc_C73C:				; CODE XREF: DL_ESTABLISH_INDICATION+92j
		move.b	5(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_C788
		moveq	#7,d1
		cmp.l	d1,d0
		beq.s	loc_C788
		moveq	#8,d1
		cmp.l	d1,d0
		beq.s	loc_C788
		moveq	#$A,d1
		cmp.l	d1,d0
		beq.s	loc_C75E
		bra.s	loc_C774
; ---------------------------------------------------------------------------

loc_C75E:				; CODE XREF: DL_ESTABLISH_INDICATION+60j
		movea.l	a3,a0
		moveq	#$A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#0,d0
		move.l	d0,$E(a3)

loc_C774:				; CODE XREF: DL_ESTABLISH_INDICATION+62j
		moveq	#$1F,d0
		move.b	d0,-(sp)
		move.b	5(a3),-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClear1TR6
		addq.w	#6,sp

loc_C788:				; CODE XREF: DL_ESTABLISH_INDICATION+4Ej
					; DL_ESTABLISH_INDICATION+54j ...
		movea.l	(a3),a3

loc_C78A:				; CODE XREF: DL_ESTABLISH_INDICATION+40j
		move.l	a3,d0
		bne.s	loc_C73C

loc_C78E:				; CODE XREF: DL_ESTABLISH_INDICATION+3Ej
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function DL_ESTABLISH_INDICATION

; ---------------------------------------------------------------------------
aDl_establish_confirm:dc.b 148,'DL_ESTABLISH_CONFIRM',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_ESTABLISH_CONFIRM:			; CODE XREF: DL_RELEASE_CONFIRM+1Ap
					; DATA XREF: PH_ACTIVATE_INDICATION+80o ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	-$210(a5),a3
		jsr	(WriteProc).l
		jsr	dl_connected
		bra.s	loc_C7F8
; ---------------------------------------------------------------------------

loc_C7D4:				; CODE XREF: DL_ESTABLISH_CONFIRM+40j
		movea.l	(a3),a4
		move.b	5(a3),d0
		moveq	#6,d1
		cmp.b	d1,d0
		bne.s	loc_C7E2
		bra.s	loc_C7F6
; ---------------------------------------------------------------------------

loc_C7E2:				; CODE XREF: DL_ESTABLISH_CONFIRM+24j
		clr.b	6(a3)
		move.b	#$26,7(a3) ; '&'
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp

loc_C7F6:				; CODE XREF: DL_ESTABLISH_CONFIRM+26j
		movea.l	a4,a3

loc_C7F8:				; CODE XREF: DL_ESTABLISH_CONFIRM+18j
		move.l	a3,d0
		bne.s	loc_C7D4
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function DL_ESTABLISH_CONFIRM

; ---------------------------------------------------------------------------
aDl_release_confirm_0:dc.b 146,'DL_RELEASE_CONFIRM',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_RELEASE_CONFIRM:			; DATA XREF: PH_ACTIVATE_INDICATION+66o
					; dl_establish+7Eo ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		jsr	(WriteProc).l
		cmpi.b	#8,-$4CC(a5)
		beq.s	loc_C84A
		move.l	arg_0(a6),-(sp)
		jsr	DL_ESTABLISH_CONFIRM
		addq.w	#4,sp
		bra.s	loc_C87E
; ---------------------------------------------------------------------------

loc_C84A:				; CODE XREF: DL_RELEASE_CONFIRM+14j
		movea.l	-$210(a5),a3
		jsr	dl_connected
		bra.s	loc_C86E
; ---------------------------------------------------------------------------

loc_C856:				; CODE XREF: DL_RELEASE_CONFIRM+4Aj
		movea.l	(a3),a4
		clr.b	6(a3)
		move.b	#$26,7(a3) ; '&'
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	a4,a3

loc_C86E:				; CODE XREF: DL_RELEASE_CONFIRM+2Ej
		move.l	a3,d0
		bne.s	loc_C856
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_C87E:				; CODE XREF: DL_RELEASE_CONFIRM+22j
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function DL_RELEASE_CONFIRM

; ---------------------------------------------------------------------------
aDl_release_indication_0:dc.b 149,'DL_RELEASE_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DL_RELEASE_INDICATION:			; DATA XREF: DL_RELEASE_REQUEST+24o
					; DL_RELEASE_REQUEST+9Co ...

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	-$210(a5),a3
		jsr	(WriteProc).l
		jsr	dl_connected
		bra.s	loc_C8D0
; ---------------------------------------------------------------------------

loc_C8B8:				; CODE XREF: DL_RELEASE_INDICATION+34j
		movea.l	(a3),a4
		clr.b	6(a3)
		move.b	#$26,7(a3) ; '&'
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		movea.l	a4,a3

loc_C8D0:				; CODE XREF: DL_RELEASE_INDICATION+18j
		move.l	a3,d0
		bne.s	loc_C8B8
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function DL_RELEASE_INDICATION

; ---------------------------------------------------------------------------
aDl_tei_fail_indication:dc.b 150,'dl_tei_fail_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_tei_fail_indication:			; DATA XREF: checkblacklisted+22Eo
					; NL_ALERT_INDICATION+8Eo

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.b	5(a3),d0
		moveq	#$14,d1
		cmp.b	d1,d0
		bne.s	loc_C98E
		tst.b	4(a3)
		bne.s	loc_C946
		addq.b	#1,-$212(a5)
		move.b	-$212(a5),d0
		moveq	#$3F,d1	; '?'
		and.b	d1,d0
		moveq	#$20,d1	; ' '
		add.b	d1,d0
		move.b	d0,4(a3)
		pea	(aAutomaticCref+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_C946:				; CODE XREF: dl_tei_fail_indication+22j
		clr.b	5(a3)
		move.b	#$14,6(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		pea	-$210(a5)
		move.l	a3,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		move.b	-$4C8(a5),d0
		beq.s	loc_C97C
		move.b	-$4CC(a5),d0
		beq.s	loc_C97C
		jsr	SendSetup
		bra.s	loc_C994
; ---------------------------------------------------------------------------

loc_C97C:				; CODE XREF: dl_tei_fail_indication+6Aj
					; dl_tei_fail_indication+70j
		clr.l	-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_C994
; ---------------------------------------------------------------------------

loc_C98E:				; CODE XREF: dl_tei_fail_indication+1Cj
		jsr	(WriteBegin).l

loc_C994:				; CODE XREF: dl_tei_fail_indication+78j
					; dl_tei_fail_indication+8Aj
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function dl_tei_fail_indication

; ---------------------------------------------------------------------------
aNl_call_request:dc.b 143,'NL_CALL_REQUEST',0
aAutomaticCref:	dc.b 16,'automatic cref',0,0 ; DATA XREF: dl_tei_fail_indication+38o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CALL_REQUEST:			; CODE XREF: SendConnect1TR6SPV+7Cp
					; NL_CONNECT_REQUEST+36p

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		movem.l	d3/a2,-(sp)
		pea	(aSendalertorconnectwithchan+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_CA2A
		move.b	-$4CC(a5),$1E(a2)
		moveq	#1,d3
		move.b	d3,$1F(a2)
		move.b	arg_0(a6),$20(a2)
		move.b	arg_2(a6),$21(a2)
		move.b	#$18,$22(a2)
		move.b	d3,$23(a2)
		move.b	#$89,$24(a2)
		moveq	#7,d0
		move.l	d0,$14(a2)
		move.l	a2,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_CA2A:				; CODE XREF: NL_CALL_REQUEST+28j
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function NL_CALL_REQUEST

; ---------------------------------------------------------------------------
aSendalertorconnectwithchan_0:dc.b 154,'SendAlertOrConnectWithChan',0,0
aSendalertorconnectwithchan:dc.b ' --- SendAlertOrConnectWithChan',0,0
					; DATA XREF: NL_CALL_REQUEST+8o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendAlertOrConnectWithChan:		; CODE XREF: SendConnect1TR6SPV+4Ap

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		pea	(aSendconnect1tr6spv+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	#$104,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	d0,a2
		cmpa.w	#0,a2
		beq.s	loc_CACE
		movea.l	a2,a3
		moveq	#$1E,d0
		adda.l	d0,a3
		move.l	#$41010007,(a3)+
		move.l	#$2004001F,(a3)+
		move.l	#$2004,(a3)+
		move.l	#$1D0000,(a3)
		move.b	arg_0(a6),$20(a2)
		moveq	#$10,d0
		move.l	d0,$14(a2)
		move.l	a2,-(sp)
		jsr	nl_transition
		addq.w	#4,sp

loc_CACE:				; CODE XREF: SendAlertOrConnectWithChan+28j
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function SendAlertOrConnectWithChan

; ---------------------------------------------------------------------------
aSendconnect1tr6spv_0:dc.b 146,'SendConnect1TR6SPV',0,0
aSendconnect1tr6spv:dc.b 24,'--- SendConnect1TR6SPV',0,0
					; DATA XREF: SendAlertOrConnectWithChan+8o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendConnect1TR6SPV:			; DATA XREF: ScanDevice+19Ao
					; MailboxEvent+1Ao

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.b	5(a3),d3

loc_CB1E:
		moveq	#6,d0
		cmp.b	d0,d3
		beq.s	loc_CB2C
		moveq	#7,d0
		cmp.b	d0,d3
		bne.w	loc_CBBC

loc_CB2C:				; CODE XREF: SendConnect1TR6SPV+1Ej
		cmpi.b	#$41,-$4CC(a5) ; 'A'
		bne.s	loc_CB58
		tst.b	$32(a3)
		beq.s	loc_CB58
		move.l	a3,-(sp)
		pea	(B_ATTACH).l

loc_CB42:
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_CB4A:
		move.b	4(a3),-(sp)
		jsr	SendAlertOrConnectWithChan
		addq.w	#2,sp
		bra.s	loc_CBAA
; ---------------------------------------------------------------------------

loc_CB58:				; CODE XREF: SendConnect1TR6SPV+2Ej
					; SendConnect1TR6SPV+34j
		move.b	8(a3),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_CB8A
		move.b	#1,8(a3)
		move.l	a3,-(sp)
		pea	(B_ATTACH).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#7,d0
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	NL_CALL_REQUEST
		addq.w	#4,sp
		bra.s	loc_CBAA
; ---------------------------------------------------------------------------

loc_CB8A:				; CODE XREF: SendConnect1TR6SPV+5Cj
		move.l	a3,-(sp)
		pea	(B_ATTACH).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#7,d0
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp

loc_CBAA:				; CODE XREF: SendConnect1TR6SPV+52j
					; SendConnect1TR6SPV+84j
		move.b	#8,6(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		bra.s	loc_CBC2
; ---------------------------------------------------------------------------

loc_CBBC:				; CODE XREF: SendConnect1TR6SPV+24j
		jsr	(WriteBegin).l

loc_CBC2:				; CODE XREF: SendConnect1TR6SPV+B6j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function SendConnect1TR6SPV

; ---------------------------------------------------------------------------
aNl_connect_request:dc.b 146,'NL_CONNECT_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CONNECT_REQUEST:			; DATA XREF: CmdSetWaitForCallUpdateState+2Co
					; IndicateCall+16o ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.b	5(a3),d0
		moveq	#6,d1
		cmp.b	d1,d0
		bne.s	loc_CC5E
		move.b	8(a3),d0
		moveq	#3,d1
		cmp.b	d1,d0
		bne.s	loc_CC2C
		moveq	#1,d3
		move.b	d3,8(a3)
		move.b	d3,-(sp)
		move.b	4(a3),-(sp)
		jsr	NL_CALL_REQUEST
		addq.w	#4,sp
		bra.s	loc_CC3C
; ---------------------------------------------------------------------------

loc_CC2C:				; CODE XREF: NL_CONNECT_REQUEST+28j
		moveq	#1,d0
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp

loc_CC3C:				; CODE XREF: NL_CONNECT_REQUEST+3Ej
		move.b	#7,6(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		move.l	a3,-(sp)
		pea	(NL_CHARGE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_CC64
; ---------------------------------------------------------------------------

loc_CC5E:				; CODE XREF: NL_CONNECT_REQUEST+1Ej
		jsr	(WriteBegin).l

loc_CC64:				; CODE XREF: NL_CONNECT_REQUEST+70j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function NL_CONNECT_REQUEST

; ---------------------------------------------------------------------------
aNl_alert_request:dc.b 144,'NL_ALERT_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_ALERT_REQUEST:			; DATA XREF: CmdConnect+28o
					; NL_DISCONNECT_INDICATION+74o	...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	5(a3),d3
		beq.s	loc_CD22
		moveq	#$14,d0
		cmp.b	d0,d3
		bne.s	loc_CCC4
		clr.b	6(a3)
		bra.s	loc_CD16
; ---------------------------------------------------------------------------

loc_CCC4:				; CODE XREF: NL_ALERT_REQUEST+30j
		move.b	5(a3),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bhi.s	loc_CD22
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_CCF0
		moveq	#$10,d0
		move.b	d0,7(a3)
		move.b	d0,-(sp)
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		bra.s	loc_CD00
; ---------------------------------------------------------------------------

loc_CCF0:				; CODE XREF: NL_ALERT_REQUEST+48j
		moveq	#$45,d0	; 'E'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendSTATUS
		addq.w	#4,sp

loc_CD00:				; CODE XREF: NL_ALERT_REQUEST+62j
		move.l	a3,-(sp)
		pea	(NL_RESUMED_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	#$B,6(a3)

loc_CD16:				; CODE XREF: NL_ALERT_REQUEST+36j
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		bra.s	loc_CD28
; ---------------------------------------------------------------------------

loc_CD22:				; CODE XREF: NL_ALERT_REQUEST+2Aj
					; NL_ALERT_REQUEST+40j
		jsr	(WriteBegin).l

loc_CD28:				; CODE XREF: NL_ALERT_REQUEST+94j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function NL_ALERT_REQUEST

; ---------------------------------------------------------------------------
aNl_disconnect_request:dc.b 149,'NL_DISCONNECT_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_DISCONNECT_REQUEST:			; DATA XREF: CheckNumber1TR6+B2o
					; A_SETUP_EDSS1+98o ...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.l	a3,-(sp)
		pea	(B_CONNECT).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	5(a3),d3
		moveq	#6,d0
		cmp.b	d0,d3
		beq.s	loc_CD8A
		moveq	#7,d0
		cmp.b	d0,d3
		bne.s	loc_CDD8

loc_CD8A:				; CODE XREF: NL_DISCONNECT_REQUEST+2Ej
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_CDB4
		move.b	7(a3),d3
		beq.s	loc_CD9E
		moveq	#0,d0
		move.b	d3,d0
		bra.s	loc_CDA0
; ---------------------------------------------------------------------------

loc_CD9E:				; CODE XREF: NL_DISCONNECT_REQUEST+42j
		moveq	#$11,d0

loc_CDA0:				; CODE XREF: NL_DISCONNECT_REQUEST+48j
		move.b	d0,-(sp)
		moveq	#$5A,d0	; 'Z'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		bra.s	loc_CDC8
; ---------------------------------------------------------------------------

loc_CDB4:				; CODE XREF: NL_DISCONNECT_REQUEST+3Cj
		move.b	#$BB,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp

loc_CDC8:				; CODE XREF: NL_DISCONNECT_REQUEST+5Ej
		clr.b	6(a3)
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		bra.s	loc_CDDE
; ---------------------------------------------------------------------------

loc_CDD8:				; CODE XREF: NL_DISCONNECT_REQUEST+34j
		jsr	(WriteBegin).l

loc_CDDE:				; CODE XREF: NL_DISCONNECT_REQUEST+82j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function NL_DISCONNECT_REQUEST

; ---------------------------------------------------------------------------
aNl_busy_request:dc.b 143,'NL_BUSY_REQUEST',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_BUSY_REQUEST:			; DATA XREF: CheckNumber1TR6:loc_AFE6o
					; CmdDisco+28o	...

arg_0		=  8

		link	a6,#0
		movem.l	d3/a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		jsr	(WriteProc).l
		move.b	5(a3),d3
		moveq	#6,d0
		cmp.b	d0,d3
		beq.s	loc_CE2A
		moveq	#7,d0
		cmp.b	d0,d3
		bne.s	loc_CE82

loc_CE2A:				; CODE XREF: NL_BUSY_REQUEST+1Ej
		cmpi.b	#4,-$504(a5)
		bcs.s	loc_CE72
		move.b	-$502(a5),d0
		bne.s	loc_CE72
		cmpi.b	#8,-$4CC(a5)
		bne.s	loc_CE56
		moveq	#$58,d0	; 'X'
		move.b	d0,-(sp)
		moveq	#$5A,d0	; 'Z'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	CheckInfo1TR6
		addq.w	#6,sp
		bra.s	loc_CE72
; ---------------------------------------------------------------------------

loc_CE56:				; CODE XREF: NL_BUSY_REQUEST+3Aj
		move.b	#$BE,-(sp)
		moveq	#$4D,d0	; 'M'
		move.b	d0,-(sp)
		move.b	4(a3),-(sp)
		jsr	SendClearEDSS1
		addq.w	#6,sp
		move.b	#$13,6(a3)
		bra.s	loc_CE76
; ---------------------------------------------------------------------------

loc_CE72:				; CODE XREF: NL_BUSY_REQUEST+2Cj
					; NL_BUSY_REQUEST+32j ...
		clr.b	6(a3)

loc_CE76:				; CODE XREF: NL_BUSY_REQUEST+6Cj
		move.l	a3,-(sp)
		jsr	T_REQUEST
		addq.w	#4,sp
		bra.s	loc_CE88
; ---------------------------------------------------------------------------

loc_CE82:				; CODE XREF: NL_BUSY_REQUEST+24j
		jsr	(WriteBegin).l

loc_CE88:				; CODE XREF: NL_BUSY_REQUEST+7Cj
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3
		unlk	a6
		rts
; End of function NL_BUSY_REQUEST

; ---------------------------------------------------------------------------
aNl_clear_request:dc.b 144,'NL_CLEAR_REQUEST',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CLEAR_REQUEST:			; DATA XREF: addresserror:loc_FBEEo

arg_0		=  8

		link	a6,#0
		clr.b	-$4CA(a5)
		jsr	(WriteProc).l
		move.b	-$4CC(a5),d0
		bne.s	loc_CECC
		lea	-$252(a5),a0
		move.l	a0,-$216(a5)

loc_CECC:				; CODE XREF: NL_CLEAR_REQUEST+12j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function NL_CLEAR_REQUEST

; ---------------------------------------------------------------------------
aNl_set_bilingual:dc.b 144,'nl_set_bilingual',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_set_bilingual:			; CODE XREF: nl_set_protocol+8p
					; nl_set_1tr6+8p ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		jsr	(WriteProc).l
		move.b	arg_0(a6),d3
		move.b	d3,-$4CA(a5)
		move.b	d3,-$4CC(a5)
		moveq	#0,d0
		move.b	d3,d0
		move.l	d0,-(sp)
		pea	(NL_RELEASE_INDICATION).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function nl_set_bilingual

; ---------------------------------------------------------------------------
aNl_set_protocol:dc.b 143,'nl_set_protocol',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_set_protocol:			; DATA XREF: addresserror:loc_FBE6o

arg_0		=  8

		link	a6,#0
		moveq	#$41,d0	; 'A'
		move.b	d0,-(sp)
		jsr	nl_set_bilingual
		addq.w	#2,sp
		lea	-$240(a5),a0
		move.l	a0,-$216(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function nl_set_protocol

; ---------------------------------------------------------------------------
aNl_set_1tr6:	dc.b 139,'nl_set_1tr6',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_set_1tr6:				; DATA XREF: addresserror:loc_FBF6o

arg_0		=  8

		link	a6,#0
		moveq	#8,d0
		move.b	d0,-(sp)
		jsr	nl_set_bilingual
		addq.w	#2,sp
		lea	-$26A(a5),a0
		move.l	a0,-$216(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function nl_set_1tr6

; ---------------------------------------------------------------------------
aNl_set_edss1:	dc.b 140,'nl_set_edss1',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_set_edss1:				; DATA XREF: addresserror:loc_FBDEo

arg_0		=  8

		link	a6,#0
		moveq	#8,d0
		move.b	d0,-(sp)
		jsr	nl_set_bilingual
		addq.w	#2,sp
		lea	-$270(a5),a0
		move.l	a0,-$216(a5)
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function nl_set_edss1

; ---------------------------------------------------------------------------
aNl_set_japan:	dc.b 140,'nl_set_japan',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_set_japan:				; CODE XREF: addresserror+6Cp
		link	a6,#0
		jsr	InitDNet
		unlk	a6
		rts
; End of function nl_set_japan

; ---------------------------------------------------------------------------
aInitdnet:	dc.b 136,'InitDNet',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitDNet:				; CODE XREF: nl_set_japan+4p

var_4		= -4

		link	a6,#-4
		movem.l	d3/a2,-(sp)
		movea.l	-$DB8(a5),a2
		move.b	$1F93(a2),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_D006
		moveq	#$10,d0
		bra.s	loc_D008
; ---------------------------------------------------------------------------

loc_D006:				; CODE XREF: InitDNet+14j
		moveq	#0,d0

loc_D008:				; CODE XREF: InitDNet+18j
		moveq	#$C,d1
		or.l	d1,d0
		move.l	d0,-$43A(a5)
		move.b	$1F93(a2),d3
		moveq	#$4B,d0	; 'K'
		cmp.b	d0,d3
		beq.s	loc_D01E
		moveq	#0,d3
		bra.s	loc_D020
; ---------------------------------------------------------------------------

loc_D01E:				; CODE XREF: InitDNet+2Cj
		moveq	#1,d3

loc_D020:				; CODE XREF: InitDNet+30j
		move.l	d3,d3
		neg.l	d3
		subx.l	d3,d3
		addq.l	#1,d3
		move.l	d3,var_4(a6)
		asl.l	#8,d3
		move.l	var_4(a6),d0
		asl.l	#2,d0
		ori.l	#$98,d0	; '˜'
		or.l	d0,d3
		ori.l	#$C00,d3
		ori.l	#$1000,d3
		move.l	d3,-$386(a5)
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function InitDNet

; ---------------------------------------------------------------------------
a_stidnet_c_:	dc.b 139,'_STIDNet_c_',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

_STIDNet_c_:				; CODE XREF: IdleMailbox:loc_D368p
					; pstrneq+8p ...

var_4		= -4

		link	a6,#-4
		movem.l	d3-d5,-(sp)
		move.l	-$1FC(a5),d0
		bne.s	loc_D088
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5

loc_D088:				; CODE XREF: _STIDNet_c_+Cj
		move.l	-$1FC(a5),d0
		bne.s	loc_D0A0
		moveq	#0,d0
		bra.s	loc_D0D0
; ---------------------------------------------------------------------------

loc_D092:				; CODE XREF: _STIDNet_c_+52j
		move.w	-$1FE(a5),d0
		addq.w	#1,d0
		moveq	#$1F,d1
		and.w	d1,d0
		move.w	d0,-$1FE(a5)

loc_D0A0:				; CODE XREF: _STIDNet_c_+2Aj
		moveq	#1,d3
		move.w	-$1FE(a5),d5
		moveq	#0,d4
		move.w	d5,d4
		asl.l	d4,d3
		move.l	d3,var_4(a6)
		and.l	-$1FC(a5),d3
		beq.s	loc_D092
		move.l	var_4(a6),d0
		eor.l	d0,-$1FC(a5)
		move.w	-$1FE(a5),d1
		addq.w	#1,-$1FE(a5)
		moveq	#0,d0
		move.w	d1,d0
		asl.l	#8,d0
		add.l	-$DB8(a5),d0

loc_D0D0:				; CODE XREF: _STIDNet_c_+2Ej
		movem.l	(sp)+,d3-d5
		unlk	a6
		rts
; End of function _STIDNet_c_

; ---------------------------------------------------------------------------
aGetmailboxbuffer:dc.b 144,'GetMailboxBuffer',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

GetMailboxBuffer:			; CODE XREF: SendStatusBuffer+74p
					; CmdBusy+19Ap	...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		moveq	#1,d3
		move.l	arg_0(a6),d0
		andi.l	#$1F00,d0
		asr.l	#8,d0
		asl.l	d0,d3
		move.l	d3,d0
		andi.l	#$C0000000,d0
		beq.s	loc_D120
		pea	(aFreeError+1)
		pea	(WriteMsg).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_D124
; ---------------------------------------------------------------------------

loc_D120:				; CODE XREF: GetMailboxBuffer+1Ej
		or.l	d3,-$1FC(a5)

loc_D124:				; CODE XREF: GetMailboxBuffer+32j
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function GetMailboxBuffer

; ---------------------------------------------------------------------------
aFreemailboxbuffer:dc.b	145,'FreeMailboxBuffer',0
aFreeError:	dc.b 20,'--- FREE ERROR ---',0,0 ; DATA XREF: GetMailboxBuffer+20o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

FreeMailboxBuffer:			; CODE XREF: SendMailbox+20p
					; IdleMailbox+70p ...

var_4		= -4
var_3		= -3
var_2		= -2
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d4/a2,-(sp)
		movea.l	-$DB8(a5),a2
		move.b	$1F02(a2),d0
		move.b	d0,var_4(a6)
		addq.b	#4,d0
		moveq	#$7C,d1	; '|'
		and.b	d1,d0
		move.b	d0,var_2(a6)
		move.b	$1F00(a2),d0
		move.b	d0,var_3(a6)
		bra.s	loc_D1BC
; ---------------------------------------------------------------------------

loc_D17A:				; CODE XREF: FreeMailboxBuffer+72j
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		movea.l	-$DB8(a5),a0
		move.b	$1F00(a0),d0
		move.b	d0,var_3(a6)
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		movea.l	-$DAC(a5),a0
		move.b	#8,$1C(a0)
		movea.l	-$DB8(a5),a0
		addq.b	#1,$1F08(a0)
		move.w	d3,d0
		move	d0,sr

loc_D1BC:				; CODE XREF: FreeMailboxBuffer+26j
		move.b	var_2(a6),d3
		cmp.b	var_3(a6),d3
		beq.s	loc_D17A
		move.l	arg_0(a6),d4
		movea.l	-$DB8(a5),a0
		lea	$1E00(a0),a0
		moveq	#0,d0
		move.b	d3,d0
		adda.l	d0,a0
		move.l	d4,(a0)
		movea.l	-$DB8(a5),a0
		move.b	var_2(a6),$1F02(a0)
		move.b	-$200(a5),d0
		beq.s	loc_D20C
		tst.l	d4
		bpl.s	loc_D20C
		move	sr,d0
		ori	#$700,sr
		move.w	d0,d3
		movea.l	-$DAC(a5),a0
		move.b	#8,$1C(a0)
		movea.l	-$DB8(a5),a0
		addq.b	#1,$1F08(a0)
		move.w	d3,d0
		move	d0,sr

loc_D20C:				; CODE XREF: FreeMailboxBuffer+96j
					; FreeMailboxBuffer+9Aj
		movem.l	(sp)+,d3-d4/a2
		unlk	a6
		rts
; End of function FreeMailboxBuffer

; ---------------------------------------------------------------------------
aSendmailbox:	dc.b 139,'SendMailbox',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendMailbox:				; CODE XREF: pstrneq+64p

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		move.b	arg_0(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		addi.l	#-$74000000,d0
		move.l	arg_2(a6),d1
		andi.l	#$1F00,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		unlk	a6
		rts
; End of function SendMailbox

; ---------------------------------------------------------------------------
aSendstatusbuffer:dc.b 144,'SendStatusBuffer',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

SendStatusBuffer:			; CODE XREF: _STIDNet_c_+Ep
					; _STIDNet_c_+1Ap ...

var_8		= -8
var_7		= -7
var_4		= -4

		link	a6,#-8
		movem.l	d3-d4/a2,-(sp)
		movea.l	-$DB8(a5),a2
		move.b	$1F04(a2),d0
		move.b	d0,var_8(a6)
		move.b	$1F06(a2),d0
		move.b	d0,var_7(a6)
		moveq	#$21,d4	; '!'
		bra.s	loc_D2EE
; ---------------------------------------------------------------------------

loc_D280:				; CODE XREF: SendStatusBuffer+9Ej
		move.b	#1,-$200(a5)
		movea.l	-$DB8(a5),a2
		lea	$1E80(a2),a2
		move.b	var_8(a6),d1
		addq.b	#4,d1
		moveq	#$7C,d2	; '|'
		and.b	d2,d1
		move.b	d1,var_8(a6)
		moveq	#0,d0
		move.b	d1,d0
		move.l	a2,var_4(a6)
		adda.l	d0,a2
		move.l	(a2),d3
		movea.l	var_4(a6),a0
		moveq	#0,d0
		move.b	d1,d0
		adda.l	d0,a0
		move.l	#$4000000,(a0)
		movea.l	-$DB8(a5),a0
		move.b	var_8(a6),$1F04(a0)
		move.l	d3,d0
		andi.l	#$7F000000,d0
		cmpi.l	#$C000000,d0
		bne.s	loc_D2DE
		move.l	d3,-(sp)
		jsr	GetMailboxBuffer
		addq.w	#4,sp
		bra.s	loc_D2EE
; ---------------------------------------------------------------------------

loc_D2DE:				; CODE XREF: SendStatusBuffer+70j
		move.l	d3,-(sp)
		pea	(MacWriteSingle).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_D2EE:				; CODE XREF: SendStatusBuffer+1Ej
					; SendStatusBuffer+7Cj
		move.b	var_8(a6),d0
		cmp.b	var_7(a6),d0
		beq.s	loc_D300
		subq.w	#1,d4
		cmpi.w	#0,d4
		bgt.s	loc_D280

loc_D300:				; CODE XREF: SendStatusBuffer+96j
		movem.l	(sp)+,d3-d4/a2
		unlk	a6
		rts
; End of function SendStatusBuffer

; ---------------------------------------------------------------------------
aPollmailbox:	dc.b 139,'PollMailbox',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

PollMailbox:				; DATA XREF: Trace+Eo

arg_0		=  8

		link	a6,#0
		jsr	SendStatusBuffer
		move.l	arg_0(a6),-(sp)
		jsr	(PostEvent).l
		unlk	a6
		rts
; End of function PollMailbox

; ---------------------------------------------------------------------------
aIdlemailbox:	dc.b 139,'IdleMailbox',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IdleMailbox:				; CODE XREF: WritePString+22p

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		move.b	-$52(a5),d0
		beq.s	loc_D3B4
		bra.s	loc_D368
; ---------------------------------------------------------------------------

loc_D350:				; CODE XREF: IdleMailbox+38j
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5
		jsr	SendStatusBuffer
		move.l	-$D28(a5),d0
		movea.l	d0,a5

loc_D368:				; CODE XREF: IdleMailbox+12j
		jsr	_STIDNet_c_
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_D350
		movea.l	a4,a2
		moveq	#$1E,d0
		adda.l	d0,a2
		move.l	a2,var_4(a6)
		move.b	$1E(a4),d0
		moveq	#0,d3
		move.b	d0,d3
		addq.w	#1,d3
		tst.w	d3
		ble.s	loc_D39C
		move.w	d3,d0
		subq.w	#1,d0
		movea.l	a2,a0
		movea.l	a3,a1

loc_D396:				; CODE XREF: IdleMailbox+5Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_D396

loc_D39C:				; CODE XREF: IdleMailbox+50j
		move.l	a3,d0
		andi.l	#$1F00,d0
		addi.l	#-$60000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_D3B4:				; CODE XREF: IdleMailbox+10j
		move.l	a4,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function IdleMailbox

; ---------------------------------------------------------------------------
aTrace:		dc.b 133,'Trace',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Trace:					; CODE XREF: InitializeCommon+106p
		link	a6,#0
		move.l	#$3FFFFF00,-$1FC(a5)
		clr.l	-(sp)
		pea	(PollMailbox).l
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function Trace

; ---------------------------------------------------------------------------
aInitmailbox:	dc.b 139,'InitMailbox',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitMailbox:				; CODE XREF: updateblacklist+2Ap
					; removeblacklist+46p ...

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	arg_4(a6),a3
		move.b	(a2),d0
		moveq	#0,d3
		move.b	d0,d3
		ext.l	d3
		addq.l	#1,d3

loc_D414:				; CODE XREF: InitMailbox+2Aj
		subq.l	#1,d3
		cmpi.l	#0,d3
		bmi.s	loc_D42A
		move.b	(a2)+,d0
		move.b	(a3)+,d1
		cmp.b	d1,d0
		beq.s	loc_D414
		moveq	#1,d0
		bra.s	loc_D42C
; ---------------------------------------------------------------------------

loc_D42A:				; CODE XREF: InitMailbox+22j
		clr.b	d0

loc_D42C:				; CODE XREF: InitMailbox+2Ej
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function InitMailbox

; ---------------------------------------------------------------------------
aPstrneq:	dc.b 135,'pstrneq',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

pstrneq:
		link	a6,#0
		movem.l	d3-d4/a3-a4,-(sp)
		jsr	_STIDNet_c_
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_D4AA
		movea.l	-$C(a5),a0
		movea.l	a3,a1
		addq.w	#1,a1

loc_D45C:				; CODE XREF: pstrneq+20j
		move.b	(a0)+,(a1)+
		bne.s	loc_D45C
		subq.l	#1,a1
		movea.l	a1,a4
		movea.l	-$DB8(a5),a0
		tst.b	$1F93(a0)
		beq.s	loc_D488
		lea	(aX+1),a0
		movea.l	a4,a1

loc_D474:				; CODE XREF: pstrneq+38j
		move.b	(a0)+,(a1)+
		bne.s	loc_D474
		subq.l	#1,a1
		movea.l	a1,a4
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		move.b	d0,-2(a4)

loc_D488:				; CODE XREF: pstrneq+2Ej
		move.l	a4,d4
		sub.l	a3,d4
		subq.l	#1,d4
		moveq	#$15,d3
		cmp.l	d3,d4
		ble.s	loc_D498
		move.l	d3,d0
		bra.s	loc_D49A
; ---------------------------------------------------------------------------

loc_D498:				; CODE XREF: pstrneq+54j
		move.l	d4,d0

loc_D49A:				; CODE XREF: pstrneq+58j
		move.b	d0,(a3)
		move.l	a3,-(sp)
		moveq	#$11,d0
		move.b	d0,-(sp)
		jsr	SendMailbox
		addq.w	#6,sp

loc_D4AA:				; CODE XREF: pstrneq+14j
		movem.l	(sp)+,d3-d4/a3-a4
		unlk	a6
		rts
; End of function pstrneq

; ---------------------------------------------------------------------------
aCmdversion:	dc.b 138,'CmdVersion',0,0
aX:		dc.b 6,' (x)',0,0       ; DATA XREF: pstrneq+30o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdVersion:				; DATA XREF: DeviceUsage+A2o

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d0
		move.w	d0,-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CmdVersion

; ---------------------------------------------------------------------------
aDeviceusage:	dc.b 139,'DeviceUsage',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

DeviceUsage:				; CODE XREF: UpdateUse+4p
					; B_USAGECHANGE_INDICATION+14p	...

var_C		= -$C
var_B		= -$B
var_A		= -$A
var_8		= -8
var_4		= -4

		link	a6,#-$C
		movem.l	d3-d5/a3,-(sp)
		clr.b	d3
		move.b	d3,var_C(a6)
		move.b	d3,var_B(a6)
		movea.l	-$656(a5),a3
		move.b	d3,var_A(a6)
		bra.s	loc_D534
; ---------------------------------------------------------------------------

loc_D518:				; CODE XREF: DeviceUsage+3Aj
		tst.l	8(a3)
		beq.s	loc_D532
		move.b	$10(a3),d0
		or.b	d0,var_C(a6)
		move.b	$11(a3),d0
		or.b	d0,var_B(a6)
		addq.b	#1,var_A(a6)

loc_D532:				; CODE XREF: DeviceUsage+20j
		movea.l	(a3),a3

loc_D534:				; CODE XREF: DeviceUsage+1Aj
		move.l	a3,d0
		bne.s	loc_D518
		cmpi.b	#1,var_A(a6)
		bls.s	loc_D546
		move.b	#$FF,var_B(a6)

loc_D546:				; CODE XREF: DeviceUsage+42j
		move.b	var_C(a6),d3
		cmp.b	-$56(a5),d3
		bne.s	loc_D55A
		move.b	var_B(a6),d0
		cmp.b	-$58(a5),d0
		beq.s	loc_D5AC

loc_D55A:				; CODE XREF: DeviceUsage+52j
		move.b	d3,-$56(a5)
		move.b	var_B(a6),d4
		move.b	d4,-$58(a5)
		moveq	#0,d5
		move.b	d3,d5
		asl.l	#8,d5
		moveq	#0,d3
		move.b	d4,d3
		move.l	d3,var_8(a6)
		moveq	#$10,d0
		asl.l	d0,d3
		move.l	d5,var_4(a6)
		add.l	d3,d5
		addi.l	#-$74000000,d5
		moveq	#$2A,d0	; '*'
		add.l	d0,d5
		move.l	d5,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	var_4(a6),d0
		move.l	var_8(a6),d1
		add.l	d1,d0
		move.l	d0,-(sp)
		pea	(CmdVersion).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_D5AC:				; CODE XREF: DeviceUsage+5Cj
		jsr	(WriteProc).l
		movem.l	(sp)+,d3-d5/a3
		unlk	a6
		rts
; End of function DeviceUsage

; ---------------------------------------------------------------------------
aUpdateuse:	dc.b 137,'UpdateUse',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

UpdateUse:				; DATA XREF: ModemSignal+42o

arg_0		=  8

		link	a6,#0
		jsr	DeviceUsage
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function UpdateUse

; ---------------------------------------------------------------------------
aB_usagechange_indication:dc.b 152,'B_USAGECHANGE_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_USAGECHANGE_INDICATION:
		link	a6,#0
		clr.b	-$54(a5)
		moveq	#1,d0
		move.b	d0,-(sp)
		jsr	PH_DEACTIVATE_INDICATION
		addq.w	#2,sp
		jsr	DeviceUsage
		unlk	a6
		rts
; End of function B_USAGECHANGE_INDICATION

; ---------------------------------------------------------------------------
aCmdactiv:	dc.b 136,'CmdActiv',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdActiv:
		link	a6,#0
		clr.b	-(sp)
		jsr	PH_DEACTIVATE_INDICATION
		addq.w	#2,sp
		jsr	DeviceUsage
		unlk	a6
		rts
; End of function CmdActiv

; ---------------------------------------------------------------------------
aCmddeactiv:	dc.b 138,'CmdDeactiv',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdDeactiv:
		link	a6,#0
		move.l	d3,-(sp)
		clr.b	d3
		move.b	d3,-$56(a5)
		cmpi.b	#4,-$504(a5)
		bhi.s	loc_D674
		clr.l	-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	d3,-$54(a5)
		bra.s	loc_D68C
; ---------------------------------------------------------------------------

loc_D674:				; CODE XREF: CmdDeactiv+12j
		move.b	-$54(a5),d1
		moveq	#0,d0
		move.b	d1,d0
		addi.l	#-$74000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_D68C:				; CODE XREF: CmdDeactiv+28j
		jsr	DeviceUsage
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function CmdDeactiv

; ---------------------------------------------------------------------------
aCmdsetwaitforcallupdatestate:dc.b 156,'CmdSetWaitForCallUpdateState',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdSetWaitForCallUpdateState:

arg_0		=  8

		link	a6,#0
		movem.l	a2/a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$18(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_D6F4
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		tst.b	d0
		beq.s	loc_D6FA
		move.l	$18(a4),-(sp)
		pea	(NL_CONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_D6FA
; ---------------------------------------------------------------------------

loc_D6F4:				; CODE XREF: CmdSetWaitForCallUpdateState+14j
		jsr	(WriteBegin).l

loc_D6FA:				; CODE XREF: CmdSetWaitForCallUpdateState+26j
					; CmdSetWaitForCallUpdateState+3Aj
		move.l	$1C(a4),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		jsr	DeviceUsage
		movem.l	(sp)+,a2/a4
		unlk	a6
		rts
; End of function CmdSetWaitForCallUpdateState

; ---------------------------------------------------------------------------
aCmdalert:	dc.b 136,'CmdAlert',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdAlert:				; CODE XREF: checkblacklisted+24Ap
					; Connect2nd+F8p

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2,-(sp)
		movea.l	-$656(a5),a2
		bra.s	loc_D73E
; ---------------------------------------------------------------------------

loc_D73C:				; CODE XREF: CmdAlert+1Ej CmdAlert+26j ...
		movea.l	(a2),a2

loc_D73E:				; CODE XREF: CmdAlert+Cj
		move.l	a2,d0
		beq.s	loc_D75C
		move.b	$C(a2),d0
		move.b	arg_0(a6),d3
		cmp.b	d3,d0
		bhi.s	loc_D73C
		move.b	$D(a2),d0
		cmp.b	d3,d0
		bcs.s	loc_D73C
		tst.l	8(a2)
		bne.s	loc_D73C

loc_D75C:				; CODE XREF: CmdAlert+12j
		move.l	a2,d0
		movem.l	(sp)+,d3/a2
		unlk	a6
		rts
; End of function CmdAlert

; ---------------------------------------------------------------------------
aScandevice:	dc.b 138,'ScanDevice',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

ScanDevice:

var_C		= -$C
var_8		= -8
var_4		= -4
var_3		= -3
arg_0		=  8

		link	a6,#-$C
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$18(a2),a4
		move.l	$1C(a2),d0
		move.l	d0,var_C(a6)
		move.l	#$132,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		move.l	d0,var_8(a6)
		movea.l	-$656(a5),a3
		movea.l	var_C(a6),a0
		move.b	3(a0),d0
		move.b	d0,var_4(a6)
		move.b	#$21,var_3(a6) ; '!'
		movea.l	$18(a2),a0
		moveq	#$1A,d1
		adda.l	d1,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		cmpi.b	#$F0,var_4(a6)
		bls.s	loc_D7D8
		moveq	#7,d0
		move.b	d0,9(a4)
		move.b	d0,var_4(a6)

loc_D7D8:				; CODE XREF: ScanDevice+58j
		jsr	DeviceUsage
		move.b	5(a4),d3
		moveq	#6,d0
		cmp.b	d0,d3
		beq.s	loc_D82E
		moveq	#7,d0
		cmp.b	d0,d3
		beq.s	loc_D82E
		jsr	(WriteBegin).l
		bra.w	loc_D9B0
; ---------------------------------------------------------------------------

loc_D7F8:				; CODE XREF: ScanDevice+BCj
		move.b	$C(a3),d0
		move.b	var_4(a6),d3
		cmp.b	d3,d0
		bhi.s	loc_D82C
		move.b	$D(a3),d0
		cmp.b	d3,d0
		bcs.s	loc_D82C
		tst.l	8(a3)
		bne.s	loc_D826
		move.b	$10(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		move.b	-$58(a5),d2
		moveq	#0,d1
		move.b	d2,d1
		and.l	d1,d0
		beq.s	loc_D832

loc_D826:				; CODE XREF: ScanDevice+9Cj
		move.b	#$22,var_3(a6) ; '"'

loc_D82C:				; CODE XREF: ScanDevice+8Ej
					; ScanDevice+96j
		movea.l	(a3),a3

loc_D82E:				; CODE XREF: ScanDevice+72j
					; ScanDevice+78j
		move.l	a3,d0
		bne.s	loc_D7F8

loc_D832:				; CODE XREF: ScanDevice+B0j
		jsr	(WriteProc).l
		move.l	a4,d0
		beq.w	loc_D964
		move.l	var_8(a6),d0
		beq.w	loc_D964
		move.l	var_C(a6),d0
		beq.w	loc_D964
		move.w	#$131,d0
		clr.b	d1
		movea.l	var_8(a6),a0

loc_D858:				; CODE XREF: ScanDevice+E6j
		move.b	d1,(a0)+
		dbf	d0,loc_D858
		move.w	#$F7,d0	; '÷'
		movea.l	var_C(a6),a0
		movea.l	var_8(a6),a1
		moveq	#$3A,d1	; ':'
		adda.l	d1,a1

loc_D86E:				; CODE XREF: ScanDevice+FCj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_D86E
		move.b	4(a4),d0
		movea.l	var_8(a6),a0
		move.b	d0,4(a0)
		move.l	a0,$2A(a4)
		move.l	a4,8(a0)
		cmpi.b	#5,var_4(a6)
		beq.s	loc_D894
		moveq	#0,d0
		bra.s	loc_D896
; ---------------------------------------------------------------------------

loc_D894:				; CODE XREF: ScanDevice+11Aj
		moveq	#1,d0

loc_D896:				; CODE XREF: ScanDevice+11Ej
		move.l	d0,d0
		movea.l	$2A(a4),a0
		move.b	d0,5(a0)
		move.l	a3,d0
		beq.s	loc_D91E
		move.l	4(a3),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		lea	-$B7C(a5),a0
		cmpa.l	a0,a3
		bne.s	loc_D8CA
		movea.l	var_C(a6),a0
		moveq	#$5E,d0	; '^'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(addparm).l
		addq.w	#4,sp

loc_D8CA:				; CODE XREF: ScanDevice+142j
		move.l	a3,$2E(a4)
		move.l	a4,8(a3)
		cmpi.b	#5,var_4(a6)
		bne.s	loc_D8E0
		move.b	#1,var_4(a6)

loc_D8E0:				; CODE XREF: ScanDevice+164j
		move.b	var_4(a6),d3
		moveq	#$FFFFFFDF,d0
		and.b	d0,d3
		moveq	#2,d0
		cmp.b	d0,d3
		beq.s	loc_D8F4
		moveq	#4,d0
		cmp.b	d0,d3
		bne.s	loc_D904

loc_D8F4:				; CODE XREF: ScanDevice+178j
		move.b	9(a4),d0
		moveq	#$20,d1	; ' '
		and.b	d1,d0
		or.b	var_4(a6),d0
		move.b	d0,9(a4)

loc_D904:				; CODE XREF: ScanDevice+17Ej
		move.b	9(a4),d0
		move.b	d0,$E(a3)
		move.l	a4,-(sp)
		pea	(SendConnect1TR6SPV).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_D990
; ---------------------------------------------------------------------------

loc_D91E:				; CODE XREF: ScanDevice+12Ej
		move.b	9(a4),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.l	a4,-(sp)
		pea	(NL_DISCONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		andi.l	#$FF0000,d0
		addi.l	#-$74000000,d0
		move.b	var_3(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		bra.s	loc_D990
; ---------------------------------------------------------------------------

loc_D964:				; CODE XREF: ScanDevice+C6j
					; ScanDevice+CEj ...
		jsr	(WriteBegin).l
		move.l	a4,d0
		beq.s	loc_D97E
		move.l	a4,-(sp)
		pea	(NL_DISCONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_D97E:				; CODE XREF: ScanDevice+1F8j
		move.l	var_8(a6),d0
		beq.s	loc_D990
		move.l	var_8(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_D990:				; CODE XREF: ScanDevice+1A8j
					; ScanDevice+1EEj ...
		move.l	var_C(a6),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		jsr	DeviceUsage

loc_D9B0:				; CODE XREF: ScanDevice+80j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function ScanDevice

; ---------------------------------------------------------------------------
aCmdconnect:	dc.b 138,'CmdConnect',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdConnect:

arg_0		=  8

		link	a6,#0
		movem.l	a2/a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$18(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_D9FE
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	$18(a4),-(sp)
		pea	(NL_ALERT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_DA1E
; ---------------------------------------------------------------------------

loc_D9FE:				; CODE XREF: CmdConnect+14j
		jsr	(WriteBegin).l
		move.l	$C(a4),d0
		andi.l	#$FF0000,d0
		addi.l	#-$73FFFFEC,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_DA1E:				; CODE XREF: CmdConnect+36j
		jsr	DeviceUsage
		movem.l	(sp)+,a2/a4
		unlk	a6
		rts
; End of function CmdConnect

; ---------------------------------------------------------------------------
aCmddisco:	dc.b 136,'CmdDisco',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdDisco:

arg_0		=  8

		link	a6,#0
		movem.l	a2/a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$18(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_DA70
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	$18(a4),-(sp)
		pea	(NL_BUSY_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_DA76
; ---------------------------------------------------------------------------

loc_DA70:				; CODE XREF: CmdDisco+14j
		jsr	(WriteBegin).l

loc_DA76:				; CODE XREF: CmdDisco+36j
		jsr	DeviceUsage
		movem.l	(sp)+,a2/a4
		unlk	a6
		rts
; End of function CmdDisco

; ---------------------------------------------------------------------------
aCmdclear:	dc.b 136,'CmdClear',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdClear:

arg_0		=  8

		link	a6,#0
		movem.l	a2/a4,-(sp)
		movea.l	arg_0(a6),a4
		movea.l	$18(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_DAC8
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.l	$18(a4),-(sp)
		pea	(NL_DISCONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_DACE
; ---------------------------------------------------------------------------

loc_DAC8:				; CODE XREF: CmdClear+14j
		jsr	(WriteBegin).l

loc_DACE:				; CODE XREF: CmdClear+36j
		jsr	DeviceUsage
		movem.l	(sp)+,a2/a4
		unlk	a6
		rts
; End of function CmdClear

; ---------------------------------------------------------------------------
aCmdbusy:	dc.b 135,'CmdBusy',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdBusy:				; DATA XREF: IndicateCall+40o
					; Connect2nd:loc_EF50o	...

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a4
		moveq	#0,d0
		movea.l	d0,a3
		move.b	-$200(a5),d0
		beq.w	loc_DC5E
		jsr	_STIDNet_c_
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.w	loc_DC5E
		movea.l	-$656(a5),a2
		move.b	9(a4),d0
		move.b	d0,var_4(a6)
		move.b	d0,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		cmpi.b	#$E0,var_4(a6)
		bcc.s	loc_DB5E
		bra.s	loc_DB40
; ---------------------------------------------------------------------------

loc_DB3E:				; CODE XREF: CmdBusy+68j CmdBusy+70j
		movea.l	(a2),a2

loc_DB40:				; CODE XREF: CmdBusy+56j
		move.l	a2,d0
		beq.s	loc_DB58
		move.b	$C(a2),d0
		move.b	var_4(a6),d3
		cmp.b	d3,d0
		bhi.s	loc_DB3E
		move.b	$D(a2),d0
		cmp.b	d3,d0
		bcs.s	loc_DB3E

loc_DB58:				; CODE XREF: CmdBusy+5Cj
		move.l	a2,d0
		beq.w	loc_DC5E

loc_DB5E:				; CODE XREF: CmdBusy+54j
		move.w	#$F7,d0	; '÷'
		clr.b	d1
		movea.l	a3,a0

loc_DB66:				; CODE XREF: CmdBusy+82j
		move.b	d1,(a0)+
		dbf	d0,loc_DB66
		moveq	#$2B,d0	; '+'
		movea.l	a4,a2
		moveq	#$66,d1	; 'f'
		adda.l	d1,a2
		movea.l	a2,a0
		movea.l	a3,a1
		addq.w	#6,a1

loc_DB7A:				; CODE XREF: CmdBusy+96j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_DB7A
		moveq	#$2B,d0	; '+'
		movea.l	a4,a0
		moveq	#$3A,d1	; ':'
		adda.l	d1,a0
		movea.l	a3,a1
		moveq	#$32,d1	; '2'
		adda.l	d1,a1

loc_DB8E:				; CODE XREF: CmdBusy+AAj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_DB8E
		movea.l	a3,a0
		moveq	#$33,d0	; '3'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$2D,d3	; '-'
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	a3,a0
		moveq	#$49,d0	; 'I'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	a3,a0
		addq.w	#7,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	a3,a0
		moveq	#$1D,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		jsr	(WritePString).l
		move.b	(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		ext.l	d0
		adda.l	d0,a2
		move.b	(a2),d0
		moveq	#$30,d1	; '0'
		or.b	d1,d0
		move.b	d0,5(a3)
		move.b	var_4(a6),3(a3)
		move.b	7(a4),d0
		move.b	d0,2(a3)
		move.b	d0,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		movea.l	a4,a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		move.b	4(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		move.l	a3,d1
		andi.l	#$1F00,d1
		add.l	d1,d0
		addi.l	#-$73FFFFE8,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		bra.s	loc_DC98
; ---------------------------------------------------------------------------

loc_DC5E:				; CODE XREF: CmdBusy+18j CmdBusy+28j ...
		pea	(aNoResources+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a4,-(sp)
		pea	(NL_BUSY_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.l	a3,d0
		beq.s	loc_DC88
		move.l	a3,-(sp)
		jsr	GetMailboxBuffer
		addq.w	#4,sp

loc_DC88:				; CODE XREF: CmdBusy+196j
		movea.l	a4,a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp

loc_DC98:				; CODE XREF: CmdBusy+176j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function CmdBusy

; ---------------------------------------------------------------------------
aIndicatecall:	dc.b 140,'IndicateCall',0,0
aNoResources:	dc.b 14,'no resources',0,0 ; DATA XREF: CmdBusy:loc_DC5Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

IndicateCall:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		tst.l	$18(a4)
		beq.s	loc_DCE4
		move.l	$18(a4),-(sp)
		pea	(NL_CONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_DCEA
; ---------------------------------------------------------------------------

loc_DCE4:				; CODE XREF: IndicateCall+10j
		jsr	(WriteBegin).l

loc_DCEA:				; CODE XREF: IndicateCall+24j
		jsr	DeviceUsage
		movea.l	a4,a2
		moveq	#$18,d0
		adda.l	d0,a2
		movea.l	(a2),a3
		cmpa.w	#0,a3
		beq.s	loc_DD24
		lea	(CmdBusy).l,a0
		move.l	a0,$1E(a3)
		move.l	(a2),d0
		movea.l	(a2),a0
		move.l	d0,$26(a0)
		moveq	#$4E,d0	; 'N'
		move.l	d0,-(sp)
		movea.l	(a2),a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp

loc_DD24:				; CODE XREF: IndicateCall+3Ej
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function IndicateCall

; ---------------------------------------------------------------------------
aCmdalertagain:	dc.b 141,'CmdAlertAgain',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdAlertAgain:				; DATA XREF: BlackList+72o
					; updateblacklist+3Eo ...

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d4/a3,-(sp)
		lea	-$178(a5),a3
		move.l	-$D44(a5),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		clr.w	d0
		move.w	d0,var_4(a6)
		bra.s	loc_DDD0
; ---------------------------------------------------------------------------

loc_DD5C:				; CODE XREF: CmdAlertAgain+9Aj
		tst.w	(a3)
		beq.s	loc_DDC8
		jsr	(WritePString).l
		move.b	var_4+1(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		movea.l	a3,a0
		addq.w	#3,a0
		move.l	a0,-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	(asc_DDF7+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		clr.w	d4
		bra.s	loc_DDC2
; ---------------------------------------------------------------------------

loc_DD9C:				; CODE XREF: CmdAlertAgain+8Aj
		move.w	d4,d0
		move.w	d0,d1
		ext.l	d1
		asl.l	#2,d1
		add.l	a3,d1
		movea.l	d1,a0
		move.l	$18(a0),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		addq.w	#1,d4

loc_DDC2:				; CODE XREF: CmdAlertAgain+5Ej
		move.w	(a3),d0
		cmp.w	d4,d0
		bgt.s	loc_DD9C

loc_DDC8:				; CODE XREF: CmdAlertAgain+22j
		moveq	#$24,d0	; '$'
		adda.l	d0,a3
		addq.w	#1,var_4(a6)

loc_DDD0:				; CODE XREF: CmdAlertAgain+1Ej
		cmpi.w	#8,var_4(a6)
		bcs.s	loc_DD5C
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d4/a3
		unlk	a6
		rts
; End of function CmdAlertAgain

; ---------------------------------------------------------------------------
aIblacklist:	dc.b '‰BlackList',0
asc_DDF7:	dc.b 6,' --- ',0        ; DATA XREF: CmdAlertAgain+50o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

BlackList:				; CODE XREF: enterblacklist+12p

var_8		= -8
var_4		= -4

		link	a6,#-8
		movem.l	d3-d5/a3-a4,-(sp)
		moveq	#8,d5
		lea	-$178(a5),a4
		clr.b	var_8(a6)
		bra.s	loc_DE5C
; ---------------------------------------------------------------------------

loc_DE12:				; CODE XREF: BlackList+68j
		moveq	#0,d3
		move.l	d3,var_4(a6)
		movea.l	a4,a3
		moveq	#$18,d0
		adda.l	d0,a3
		move.l	d3,d4
		bra.s	loc_DE4A
; ---------------------------------------------------------------------------

loc_DE22:				; CODE XREF: BlackList+54j
		move.l	d4,d0
		add.l	a3,d0
		movea.l	d0,a0
		move.l	(a0),d3
		cmp.l	-$D44(a5),d3
		bcs.s	loc_DE42
		move.l	var_4(a6),d0
		addq.l	#1,var_4(a6)
		asl.l	#2,d0
		add.l	a3,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		bra.s	loc_DE48
; ---------------------------------------------------------------------------

loc_DE42:				; CODE XREF: BlackList+30j
		move.b	#1,var_8(a6)

loc_DE48:				; CODE XREF: BlackList+42j
		addq.l	#4,d4

loc_DE4A:				; CODE XREF: BlackList+22j
		move.w	(a4),d0
		ext.l	d0
		asl.l	#2,d0
		cmp.l	d4,d0
		bgt.s	loc_DE22
		move.w	var_4+2(a6),(a4)
		moveq	#$24,d0	; '$'
		adda.l	d0,a4

loc_DE5C:				; CODE XREF: BlackList+12j
		subq.w	#1,d5
		cmpi.w	#0,d5
		bmi.s	loc_DE68
		tst.w	(a4)
		bne.s	loc_DE12

loc_DE68:				; CODE XREF: BlackList+64j
		move.b	var_8(a6),d0
		beq.s	loc_DE7E
		clr.l	-(sp)
		pea	(CmdAlertAgain).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_DE7E:				; CODE XREF: BlackList+6Ej
		movem.l	(sp)+,d3-d5/a3-a4
		unlk	a6
		rts
; End of function BlackList

; ---------------------------------------------------------------------------
aUpdateblacklist:dc.b 143,'updateblacklist',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

updateblacklist:			; CODE XREF: NL_ALERT_INDICATION+4Ap
					; NL_DISCONNECT_INDICATION+BAp

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		moveq	#8,d4
		lea	-$178(a5),a3
		lea	-$176(a5),a2
		bra.s	loc_DEB6
; ---------------------------------------------------------------------------

loc_DEB0:				; CODE XREF: updateblacklist+34j
		moveq	#$24,d3	; '$'
		adda.l	d3,a2
		adda.l	d3,a3

loc_DEB6:				; CODE XREF: updateblacklist+16j
		subq.w	#1,d4
		clr.w	d3
		cmp.w	d3,d4
		bmi.s	loc_DECE
		move.l	a4,-(sp)
		move.l	a2,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_DEB0

loc_DECE:				; CODE XREF: updateblacklist+24j
		cmp.w	d3,d4
		bmi.s	loc_DED4
		move.w	d3,(a3)

loc_DED4:				; CODE XREF: updateblacklist+38j
		clr.l	-(sp)
		pea	(CmdAlertAgain).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function updateblacklist

; ---------------------------------------------------------------------------
aRemoveblacklist:dc.b 143,'removeblacklist',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

removeblacklist:			; CODE XREF: enterblacklist+ACp
					; NL_ALERT_INDICATION+72p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		moveq	#8,d5
		lea	-$178(a5),a3
		moveq	#0,d0
		movea.l	d0,a4
		moveq	#$FFFFFFFF,d4
		bra.s	loc_DF34
; ---------------------------------------------------------------------------

loc_DF18:				; CODE XREF: removeblacklist+50j
		move.l	a4,d0
		bne.s	loc_DF24
		tst.w	(a3)
		bne.s	loc_DF24
		moveq	#0,d4
		movea.l	a3,a4

loc_DF24:				; CODE XREF: removeblacklist+1Cj
					; removeblacklist+20j
		move.l	$18(a3),d3
		cmp.l	d4,d3
		bcc.s	loc_DF30
		move.l	d3,d4
		movea.l	a3,a4

loc_DF30:				; CODE XREF: removeblacklist+2Cj
		moveq	#$24,d0	; '$'
		adda.l	d0,a3

loc_DF34:				; CODE XREF: removeblacklist+18j
		subq.w	#1,d5
		clr.w	d3
		cmp.w	d3,d5
		bmi.s	loc_DF50
		move.l	a2,-(sp)
		movea.l	a3,a0
		addq.w	#2,a0
		move.l	a0,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_DF18

loc_DF50:				; CODE XREF: removeblacklist+3Cj
		cmp.w	d3,d5
		bmi.s	loc_DF68
		move.w	(a3),d0
		addq.w	#1,(a3)
		ext.l	d0
		asl.l	#2,d0
		add.l	a3,d0
		movea.l	d0,a0
		move.l	arg_4(a6),$18(a0)
		bra.s	loc_DF80
; ---------------------------------------------------------------------------

loc_DF68:				; CODE XREF: removeblacklist+54j
		moveq	#$15,d0
		movea.l	a2,a0
		movea.l	a4,a1
		addq.w	#2,a1

loc_DF70:				; CODE XREF: removeblacklist+74j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_DF70
		move.l	arg_4(a6),$18(a4)
		moveq	#1,d0
		move.w	d0,(a4)

loc_DF80:				; CODE XREF: removeblacklist+68j
		clr.l	-(sp)
		pea	(CmdAlertAgain).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function removeblacklist

; ---------------------------------------------------------------------------
aEnterblacklist:dc.b 142,'enterblacklist',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

enterblacklist:				; CODE XREF: checkblacklisted+B0p

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		moveq	#8,d4
		lea	-$178(a5),a4
		jsr	BlackList
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$58,d1	; 'X'
		cmp.l	d1,d0
		beq.s	loc_DFDE
		moveq	#$4A,d1	; 'J'
		cmp.l	d1,d0
		beq.s	loc_E022
		bra.w	loc_E05E
; ---------------------------------------------------------------------------

loc_DFDE:				; CODE XREF: enterblacklist+28j
		move.b	arg_4(a6),d3
		cmpi.b	#$C0,d3
		bcs.s	loc_E05E
		cmpi.b	#$E0,d3
		bhi.s	loc_E05E
		bra.s	loc_DFF8
; ---------------------------------------------------------------------------

loc_DFF0:				; CODE XREF: enterblacklist+68j
		moveq	#$24,d3	; '$'
		adda.l	d3,a2
		adda.l	d3,a4
		bra.s	loc_DFFC
; ---------------------------------------------------------------------------

loc_DFF8:				; CODE XREF: enterblacklist+44j
		lea	-$176(a5),a2

loc_DFFC:				; CODE XREF: enterblacklist+4Cj
		subq.w	#1,d4
		clr.w	d3
		cmp.w	d3,d4
		bmi.s	loc_E014
		move.l	a3,-(sp)
		move.l	a2,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_DFF0

loc_E014:				; CODE XREF: enterblacklist+58j
		cmp.w	d3,d4
		bmi.s	loc_E05E
		move.w	(a4),d0
		moveq	#2,d1
		cmp.w	d1,d0
		blt.s	loc_E05E
		bra.s	loc_E044
; ---------------------------------------------------------------------------

loc_E022:				; CODE XREF: enterblacklist+2Ej
		move.l	a3,-(sp)
		pea	-$176(a5)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		beq.s	loc_E03C
		clr.w	d0
		move.w	d0,-$178(a5)
		bra.s	loc_E048
; ---------------------------------------------------------------------------

loc_E03C:				; CODE XREF: enterblacklist+88j
		cmpi.w	#2,-$178(a5)
		blt.s	loc_E048

loc_E044:				; CODE XREF: enterblacklist+76j
		moveq	#1,d0
		bra.s	loc_E060
; ---------------------------------------------------------------------------

loc_E048:				; CODE XREF: enterblacklist+90j
					; enterblacklist+98j
		move.l	-$D44(a5),d0
		addi.l	#$AFC,d0
		move.l	d0,-(sp)
		move.l	a3,-(sp)
		jsr	removeblacklist
		addq.w	#8,sp

loc_E05E:				; CODE XREF: enterblacklist+30j
					; enterblacklist+3Cj ...
		clr.b	d0

loc_E060:				; CODE XREF: enterblacklist+9Cj
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function enterblacklist

; ---------------------------------------------------------------------------
aCheckblacklisted:dc.b 144,'checkblacklisted',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

checkblacklisted:

var_14		= -$14
var_10		= -$10
var_C		= -$C
var_8		= -8
var_7		= -7
var_4		= -4
arg_0		=  8

		link	a6,#-$14
		movem.l	d3-d5/a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$1C(a3),d0
		move.l	d0,var_14(a6)
		move.l	#$92,-(sp) ; '’'
		jsr	(TimerEvent).l
		addq.w	#4,sp
		move.l	d0,var_10(a6)
		move.l	#$132,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		move.l	d0,var_C(a6)
		movea.l	-$656(a5),a4
		move.b	#$21,var_7(a6) ; '!'
		movea.l	var_14(a6),a0
		move.b	3(a0),d0
		move.b	d0,var_8(a6)
		cmpi.b	#$F0,d0
		bls.s	loc_E0D6
		move.b	#7,var_8(a6)

loc_E0D6:				; CODE XREF: checkblacklisted+52j
		jsr	DeviceUsage
		bra.s	loc_E114
; ---------------------------------------------------------------------------

loc_E0DE:				; CODE XREF: checkblacklisted+9Aj
		move.b	$C(a4),d0
		move.b	var_8(a6),d3
		cmp.b	d3,d0
		bhi.s	loc_E112
		move.b	$D(a4),d0
		cmp.b	d3,d0
		bcs.s	loc_E112
		tst.l	8(a4)
		bne.s	loc_E10C
		move.b	$10(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		move.b	-$58(a5),d2
		moveq	#0,d1
		move.b	d2,d1
		and.l	d1,d0
		beq.s	loc_E118

loc_E10C:				; CODE XREF: checkblacklisted+7Aj
		move.b	#$22,var_7(a6) ; '"'

loc_E112:				; CODE XREF: checkblacklisted+6Cj
					; checkblacklisted+74j
		movea.l	(a4),a4

loc_E114:				; CODE XREF: checkblacklisted+60j
		move.l	a4,d0
		bne.s	loc_E0DE

loc_E118:				; CODE XREF: checkblacklisted+8Ej
		jsr	(WriteProc).l
		movea.l	var_14(a6),a2
		move.b	3(a2),-(sp)
		moveq	#$32,d0	; '2'
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	enterblacklist
		addq.w	#6,sp
		tst.b	d0
		beq.s	loc_E15E
		pea	(aBlacklisted+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#0,d0
		movea.l	d0,a4
		move.b	#$E,var_7(a6)
		clr.l	-(sp)
		pea	(CmdAlertAgain).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_E15E:				; CODE XREF: checkblacklisted+BAj
		move.l	var_10(a6),d0
		beq.w	loc_E340
		move.l	var_C(a6),d0
		beq.w	loc_E340
		move.l	a4,d0
		beq.w	loc_E340
		move.l	$C(a3),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.w	#$91,d0	; '‘'
		clr.b	d1
		movea.l	var_10(a6),a0

loc_E18A:				; CODE XREF: checkblacklisted+110j
		move.b	d1,(a0)+
		dbf	d0,loc_E18A
		move.w	#$131,d0
		clr.b	d1
		movea.l	var_C(a6),a0

loc_E19A:				; CODE XREF: checkblacklisted+120j
		move.b	d1,(a0)+
		dbf	d0,loc_E19A
		move.w	#$F7,d0	; '÷'
		movea.l	var_14(a6),a0
		movea.l	var_C(a6),a1
		moveq	#$3A,d3	; ':'
		adda.l	d3,a1

loc_E1B0:				; CODE XREF: checkblacklisted+136j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E1B0
		movea.l	var_C(a6),a0
		move.l	var_10(a6),8(a0)
		movea.l	var_10(a6),a1
		move.l	a0,$2A(a1)
		move.l	$C(a3),d0
		moveq	#$10,d1
		asr.l	d1,d0
		move.b	d0,4(a1)
		move.b	d0,4(a0)
		move.b	var_8(a6),d4
		moveq	#5,d0
		cmp.b	d0,d4
		beq.s	loc_E1E6
		moveq	#0,d0
		bra.s	loc_E1E8
; ---------------------------------------------------------------------------

loc_E1E6:				; CODE XREF: checkblacklisted+164j
		moveq	#1,d0

loc_E1E8:				; CODE XREF: checkblacklisted+168j
		move.l	d0,d0
		move.b	d0,5(a0)
		move.l	a4,$2E(a1)
		move.l	a4,$10(a0)
		move.l	a1,8(a4)
		move.b	#1,$38(a1)
		movea.l	var_14(a6),a0
		move.b	5(a0),d0
		moveq	#$30,d1	; '0'
		or.b	d1,d0
		move.b	d0,$39(a1)
		moveq	#$2B,d0	; '+'
		addq.w	#6,a0
		adda.l	d3,a1

loc_E216:				; CODE XREF: checkblacklisted+19Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E216
		moveq	#$2B,d0	; '+'
		movea.l	var_14(a6),a0
		moveq	#$32,d1	; '2'
		adda.l	d1,a0
		movea.l	var_10(a6),a1
		moveq	#$66,d1	; 'f'
		adda.l	d1,a1

loc_E22E:				; CODE XREF: checkblacklisted+1B4j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E22E
		movea.l	var_14(a6),a0
		move.b	4(a0),d0
		movea.l	var_10(a6),a1
		move.b	d0,$32(a1)
		move.b	3(a0),d0
		move.b	d0,9(a1)
		move.b	d4,$E(a4)
		lea	-$B7C(a5),a2
		cmpa.l	a2,a4
		bne.s	loc_E284
		move.b	$A1(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		move.b	$C2(a0),d2
		moveq	#0,d1
		move.b	d2,d1
		and.l	d1,d0
		beq.s	loc_E272
		move.b	#$C1,9(a1)

loc_E272:				; CODE XREF: checkblacklisted+1EEj
		movea.l	var_14(a6),a0
		moveq	#$5E,d0	; '^'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(addparm).l
		addq.w	#4,sp

loc_E284:				; CODE XREF: checkblacklisted+1DAj
		move.l	4(a4),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d3	; ' '
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		moveq	#$14,d4
		movea.l	var_10(a6),a2
		move.b	d4,5(a2)
		move.l	var_10(a6),-(sp)
		pea	(dl_tei_fail_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move.b	var_8(a6),d0
		moveq	#5,d5
		cmp.b	d5,d0
		bne.w	loc_E3A4
		move.b	d5,-(sp)
		jsr	CmdAlert
		addq.w	#2,sp
		move.l	d0,var_4(a6)
		tst.l	d0
		beq.s	loc_E328
		move.w	#$91,d0	; '‘'
		movea.l	a2,a0
		movea.l	d0,a2
		movea.l	a0,a3
		move.l	#$92,-(sp) ; '’'
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4
		movea.l	a4,a1
		movea.l	a3,a0
		move.l	a2,d0

loc_E2F6:				; CODE XREF: checkblacklisted+27Cj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E2F6
		movea.l	var_C(a6),a2
		move.l	a4,$C(a2)
		moveq	#6,d0
		move.b	d0,9(a4)
		movea.l	var_4(a6),a0
		move.b	d0,$E(a0)
		add.b	d3,4(a4)
		move.l	a0,$2E(a4)
		move.l	a4,8(a0)
		move.l	a0,$14(a2)
		move.b	d4,5(a4)
		bra.s	loc_E3A4
; ---------------------------------------------------------------------------

loc_E328:				; CODE XREF: checkblacklisted+258j
		moveq	#3,d0
		movea.l	var_10(a6),a0
		move.b	d0,9(a0)
		move.b	d0,$E(a4)
		movea.l	var_C(a6),a0
		clr.b	5(a0)
		bra.s	loc_E3A4
; ---------------------------------------------------------------------------

loc_E340:				; CODE XREF: checkblacklisted+E6j
					; checkblacklisted+EEj	...
		move.l	$C(a3),d0
		andi.l	#$FF0000,d0
		addi.l	#-$74000000,d0
		move.b	var_7(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	var_10(a6),d0
		beq.s	loc_E378
		move.l	var_10(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		bra.s	loc_E384
; ---------------------------------------------------------------------------

loc_E378:				; CODE XREF: checkblacklisted+2ECj
		pea	aCallNil	; "call	nil"
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_E384:				; CODE XREF: checkblacklisted+2FAj
		move.l	var_C(a6),d0
		beq.s	loc_E398
		move.l	var_C(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		bra.s	loc_E3A4
; ---------------------------------------------------------------------------

loc_E398:				; CODE XREF: checkblacklisted+30Cj
		pea	aConnectionNil	; "connection nil"
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_E3A4:				; CODE XREF: checkblacklisted+244j
					; checkblacklisted+2AAj ...
		move.l	var_14(a6),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		jsr	DeviceUsage
		movem.l	(sp)+,d3-d5/a2-a4
		unlk	a6
		rts
; End of function checkblacklisted

; ---------------------------------------------------------------------------
aCmddial:	dc.b 135,'CmdDial',0
aBlacklisted:	dc.b 38,'blacklisted',0 ; DATA XREF: checkblacklisted+BCo
aCallNil:	dc.b 'call nil',0,0     ; DATA XREF: checkblacklisted:loc_E378o
aConnectionNil:	dc.b 'connection nil',0,0 ; DATA XREF: checkblacklisted:loc_E398o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdDial:

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		movea.l	arg_0(a6),a3
		movea.l	$18(a3),a4
		cmpa.w	#0,a4
		beq.s	loc_E458
		move.b	5(a4),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_E458
		move.b	9(a4),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		movea.l	$18(a3),a0
		move.b	9(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		cmpi.l	#$E0,d0	; 'à'
		beq.s	loc_E446
		cmpi.l	#$F0,d0	; 'ð'
		beq.s	loc_E446
		bra.s	loc_E458
; ---------------------------------------------------------------------------

loc_E446:				; CODE XREF: CmdDial+3Ej CmdDial+46j
		move.l	$C(a3),-(sp)
		pea	(VoiceStart).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_E458:				; CODE XREF: CmdDial+14j CmdDial+1Ej ...
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function CmdDial

; ---------------------------------------------------------------------------
aCmdbcontrol:	dc.b 139,'CmdBControl',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdBControl:

arg_0		=  8

		link	a6,#0
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		asr.l	#8,d0
		move.b	d0,-$52(a5)
		clr.l	-(sp)
		pea	(InitMemory).l
		jsr	(SendEvent).l
		unlk	a6
		rts
; End of function CmdBControl

; ---------------------------------------------------------------------------
aCmdtrace:	dc.b 136,'CmdTrace',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdTrace:

arg_0		=  8

		link	a6,#0
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		asr.l	#8,d0
		move.b	d0,-$DBA(a5)
		unlk	a6
		rts
; End of function CmdTrace

; ---------------------------------------------------------------------------
aCmdnewleo:	dc.b 137,'CmdNewLeo',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdNewLeo:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$10(a0),a2
		cmpa.w	#0,a2
		beq.s	loc_E4DA
		moveq	#1,d0
		move.w	d0,$20(a2)

loc_E4DA:				; CODE XREF: CmdNewLeo+12j
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function CmdNewLeo

; ---------------------------------------------------------------------------
aCmdblockescape:dc.b 142,'CmdBlockEscape',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

CmdBlockEscape:

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	d3-d4/a2-a3,-(sp)
		movea.l	arg_0(a6),a3
		moveq	#$10,d4
		move.l	$C(a3),d3
		move.b	d3,var_4(a6)
		move.l	d3,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		lea	-$198(a5),a2

loc_E516:				; CODE XREF: CmdBlockEscape+34j
		subq.w	#6,a2
		subq.l	#1,d4
		moveq	#0,d3
		cmp.l	d3,d4
		bmi.s	loc_E528
		move.b	(a2),d0
		cmp.b	var_4(a6),d0
		bne.s	loc_E516

loc_E528:				; CODE XREF: CmdBlockEscape+2Cj
		cmp.l	d3,d4
		bmi.s	loc_E558
		move.l	d4,d0
		move.l	d0,d1
		mulu.w	#6,d0
		swap	d1
		mulu.w	#6,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		lea	-$1F6(a5),a0
		move.l	(a0,d0.w),d0
		move.l	d0,4(a3)
		move.l	a3,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		bra.s	loc_E55E
; ---------------------------------------------------------------------------

loc_E558:				; CODE XREF: CmdBlockEscape+38j
		jsr	(WriteBegin).l

loc_E55E:				; CODE XREF: CmdBlockEscape+64j
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3-d4/a2-a3
		unlk	a6
		rts
; End of function CmdBlockEscape

; ---------------------------------------------------------------------------
aMaccommand:	dc.b 138,'MacCommand',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacCommand:

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$10(a2),a3
		movea.l	$14(a2),a4
		cmpa.w	#0,a4
		beq.s	loc_E5A2
		tst.l	8(a4)
		bne.s	loc_E5A2
		moveq	#0,d0
		movea.l	d0,a4

loc_E5A2:				; CODE XREF: MacCommand+18j
					; MacCommand+1Ej
		move.l	a3,d0
		beq.s	loc_E5B0
		move.l	a4,d0
		beq.s	loc_E5B0
		tst.l	$2E(a3)
		bne.s	loc_E5D4

loc_E5B0:				; CODE XREF: MacCommand+26j
					; MacCommand+2Aj
		jsr	(WriteBegin).l
		movea.l	arg_0(a6),a0
		move.l	$C(a0),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		pea	(aConnectionDeviceReadmsgNil+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		bra.s	loc_E60E
; ---------------------------------------------------------------------------

loc_E5D4:				; CODE XREF: MacCommand+30j
		move.l	$28(a4),d0
		movea.l	a3,a2
		moveq	#$2E,d1	; '.'
		adda.l	d1,a2
		movea.l	(a2),a0
		move.l	d0,4(a0)
		move.l	(a2),-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		movea.l	a3,a0
		moveq	#$32,d0	; '2'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,(a2)
		tst.l	d0
		beq.s	loc_E60E
		move.l	d0,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_E60E:				; CODE XREF: MacCommand+54j
					; MacCommand+84j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function MacCommand

; ---------------------------------------------------------------------------
aMacreaddone:	dc.b 139,'MacReadDone',0
aConnectionDeviceReadmsgNil:dc.b 32,' connection/device/readmsg nil',0,0
					; DATA XREF: MacCommand+48o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacReadDone:

arg_0		=  8

		link	a6,#0
		jsr	(WriteBegin).l
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		unlk	a6
		rts
; End of function MacReadDone

; ---------------------------------------------------------------------------
aMacnothing:	dc.b 138,'MacNothing',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacNothing:

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),-(sp)
		jsr	GetMailboxBuffer
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function MacNothing

; ---------------------------------------------------------------------------
aMacbufferreturn:dc.b 143,'MacBufferReturn',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacBufferReturn:			; DATA XREF: b_data_indication+56o

var_10		= -$10
var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$10
		movem.l	d3-d6/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		moveq	#$14,d0
		adda.l	d0,a2
		move.l	a2,var_C(a6)
		movea.l	arg_0(a6),a4
		moveq	#$10,d0
		adda.l	d0,a4
		movea.l	arg_0(a6),a0
		moveq	#$1E,d0
		adda.l	d0,a0
		move.l	a0,var_8(a6)
		movea.l	arg_0(a6),a0
		moveq	#$C,d0
		adda.l	d0,a0
		move.l	a0,var_4(a6)
		bra.w	loc_E7E0
; ---------------------------------------------------------------------------

loc_E6E6:				; CODE XREF: MacBufferReturn+14Ej
		move.l	a3,d3
		andi.l	#$1F00,d3
		move.l	var_10(a6),d4
		move.l	#$100,d5
		cmp.l	d5,d4
		bgt.w	loc_E788
		movea.l	arg_0(a6),a4
		moveq	#$1E,d0
		adda.l	d0,a4
		movea.l	arg_0(a6),a0
		adda.l	$10(a0),a4
		move.w	var_10+2(a6),d6
		ble.s	loc_E722
		move.w	d6,d0
		subq.w	#1,d0
		movea.l	a4,a0
		movea.l	a3,a1

loc_E71C:				; CODE XREF: MacBufferReturn+70j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E71C

loc_E722:				; CODE XREF: MacBufferReturn+64j
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a1
		movea.l	8(a1),a1
		move.b	4(a1),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		tst.w	$18(a0)
		beq.s	loc_E758
		move.l	$14(a0),d1
		cmp.l	d5,d1
		bgt.s	loc_E750
		move.l	#$AC000000,d1
		bra.s	loc_E756
; ---------------------------------------------------------------------------

loc_E750:				; CODE XREF: MacBufferReturn+98j
		move.l	#$A8000000,d1

loc_E756:				; CODE XREF: MacBufferReturn+A0j
		bra.s	loc_E76E
; ---------------------------------------------------------------------------

loc_E758:				; CODE XREF: MacBufferReturn+90j
		move.l	$14(a0),d1
		cmp.l	d5,d1
		bgt.s	loc_E768
		move.l	#$9C000000,d1
		bra.s	loc_E76E
; ---------------------------------------------------------------------------

loc_E768:				; CODE XREF: MacBufferReturn+B0j
		move.l	#$98000000,d1

loc_E76E:				; CODE XREF: MacBufferReturn:loc_E756j
					; MacBufferReturn+B8j
		add.l	d1,d0
		add.l	d3,d0
		andi.l	#$FF,d4
		add.l	d4,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		bra.w	loc_E80C
; ---------------------------------------------------------------------------

loc_E788:				; CODE XREF: MacBufferReturn+4Cj
		move.w	#$FF,d0
		move.l	(a4),d1
		add.l	var_8(a6),d1
		movea.l	d1,a0
		movea.l	a3,a1

loc_E796:				; CODE XREF: MacBufferReturn+EAj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E796
		movea.l	var_4(a6),a0
		movea.l	(a0),a0
		movea.l	8(a0),a0
		move.b	4(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		tst.l	(a4)
		beq.s	loc_E7BE
		move.l	#$94000000,d1
		bra.s	loc_E7C4
; ---------------------------------------------------------------------------

loc_E7BE:				; CODE XREF: MacBufferReturn+106j
		move.l	#$10000000,d1

loc_E7C4:				; CODE XREF: MacBufferReturn+10Ej
		add.l	d1,d0
		move.l	a3,d1
		andi.l	#$1F00,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		addi.l	#$100,(a4)

loc_E7E0:				; CODE XREF: MacBufferReturn+34j
		movea.l	var_C(a6),a0
		move.l	(a0),d0
		sub.l	(a4),d0
		move.l	d0,var_10(a6)
		tst.l	d0
		beq.s	loc_E800
		jsr	_STIDNet_c_
		movea.l	d0,a3
		cmpa.w	#0,a3
		bne.w	loc_E6E6

loc_E800:				; CODE XREF: MacBufferReturn+140j
		move.l	arg_0(a6),-(sp)
		jsr	(PostEvent).l
		addq.w	#4,sp

loc_E80C:				; CODE XREF: MacBufferReturn+D6j
		movem.l	(sp)+,d3-d6/a2-a4
		unlk	a6
		rts
; End of function MacBufferReturn

; ---------------------------------------------------------------------------
aB_data_indication:dc.b	145,'b_data_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

b_data_indication:

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a4
		moveq	#0,d0
		move.l	d0,var_4(a6)
		movea.l	$C(a4),a3
		cmpa.w	#0,a3
		beq.s	loc_E856
		tst.l	8(a3)
		beq.s	loc_E856
		movea.l	8(a3),a0
		move.l	$2A(a0),d0
		move.l	d0,var_4(a6)

loc_E856:				; CODE XREF: b_data_indication+1Aj
					; b_data_indication+20j
		move.l	$14(a4),d0
		ble.s	loc_E862
		move.l	var_4(a6),d0
		bne.s	loc_E878

loc_E862:				; CODE XREF: b_data_indication+32j
		jsr	(WriteBegin).l
		jsr	(WritePString).l
		move.l	$28(a3),d0
		move.l	d0,4(a4)
		bra.s	loc_E8AC
; ---------------------------------------------------------------------------

loc_E878:				; CODE XREF: b_data_indication+38j
		moveq	#0,d0
		move.l	d0,$10(a4)
		lea	(MacBufferReturn).l,a0
		move.l	a0,4(a4)
		movea.l	var_4(a6),a2
		tst.l	$2E(a2)
		beq.s	loc_E8A4
		moveq	#$32,d0	; '2'
		adda.l	d0,a2
		move.l	a2,-(sp)
		move.l	a4,-(sp)
		jsr	(SetupIO).l
		addq.w	#8,sp
		bra.s	loc_E8B6
; ---------------------------------------------------------------------------

loc_E8A4:				; CODE XREF: b_data_indication+68j
		movea.l	var_4(a6),a0
		move.l	a4,$2E(a0)

loc_E8AC:				; CODE XREF: b_data_indication+4Ej
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_E8B6:				; CODE XREF: b_data_indication+7Aj
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function b_data_indication

; ---------------------------------------------------------------------------
aB_data_indication_0:dc.b 145,'B_DATA_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_DATA_INDICATION:			; DATA XREF: VoiceControl:loc_131Co

arg_0		=  8

		link	a6,#0
		movem.l	a3-a4,-(sp)
		moveq	#0,d0
		movea.l	d0,a3
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a4
		tst.l	8(a4)
		beq.s	loc_E8FA
		movea.l	8(a4),a0
		movea.l	$2A(a0),a3
		cmpa.w	#0,a3
		bne.s	loc_E902

loc_E8FA:				; CODE XREF: B_DATA_INDICATION+18j
		jsr	(WriteBegin).l
		bra.s	loc_E936
; ---------------------------------------------------------------------------

loc_E902:				; CODE XREF: B_DATA_INDICATION+26j
		addq.w	#1,$24(a3)
		move.w	$24(a3),d0
		tst.b	$12(a4)
		beq.s	loc_E91A
		move.w	$22(a3),d1
		cmp.w	d1,d0
		bne.s	loc_E91A
		bra.s	loc_E936
; ---------------------------------------------------------------------------

loc_E91A:				; CODE XREF: B_DATA_INDICATION+3Cj
					; B_DATA_INDICATION+44j
		move.b	4(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$7C000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_E936:				; CODE XREF: B_DATA_INDICATION+2Ej
					; B_DATA_INDICATION+46j
		move.l	arg_0(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movem.l	(sp)+,a3-a4
		unlk	a6
		rts
; End of function B_DATA_INDICATION

; ---------------------------------------------------------------------------
aB_data_confirm:dc.b 142,'B_DATA_CONFIRM',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_DATA_CONFIRM:				; CODE XREF: MacWriteMiddle+28p

var_4		= -4
arg_0		=  8

		link	a6,#-4
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$1C(a3),d0
		move.l	d0,var_4(a6)
		movea.l	$10(a3),a4
		cmpa.w	#0,a4
		beq.s	loc_E9A2
		movea.l	$2A(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_E9E0
		movea.l	a2,a4
		moveq	#$1E,d1
		adda.l	d1,a4
		adda.l	$14(a2),a4
		addi.l	#$100,$14(a2)
		move.l	$14(a2),d1
		cmpi.l	#$FA0,d1
		ble.s	loc_E9AA

loc_E9A2:				; CODE XREF: B_DATA_CONFIRM+1Cj
		jsr	(WriteBegin).l
		bra.s	loc_E9BA
; ---------------------------------------------------------------------------

loc_E9AA:				; CODE XREF: B_DATA_CONFIRM+44j
		move.w	#$FF,d0
		movea.l	var_4(a6),a0
		movea.l	a4,a1

loc_E9B4:				; CODE XREF: B_DATA_CONFIRM+5Aj
		move.b	(a0)+,(a1)+
		dbf	d0,loc_E9B4

loc_E9BA:				; CODE XREF: B_DATA_CONFIRM+4Cj
		move.l	$1C(a3),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		bra.s	loc_E9EA
; ---------------------------------------------------------------------------

loc_E9E0:				; CODE XREF: B_DATA_CONFIRM+26j
		move.l	a3,-(sp)
		jsr	(PostEvent).l
		addq.w	#4,sp

loc_E9EA:				; CODE XREF: B_DATA_CONFIRM+82j
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function B_DATA_CONFIRM

; ---------------------------------------------------------------------------
aMacwritemiddle:dc.b 142,'MacWriteMiddle',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacWriteMiddle:

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		tst.l	$10(a3)
		beq.s	loc_EA2A
		move.l	#$FA0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	$10(a3),a0
		move.l	d0,$2A(a0)

loc_EA2A:				; CODE XREF: MacWriteMiddle+Ej
		move.l	a3,-(sp)
		jsr	B_DATA_CONFIRM
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function MacWriteMiddle

; ---------------------------------------------------------------------------
aMacwritefirst:	dc.b 141,'MacWriteFirst',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacWriteFirst:				; CODE XREF: MacWriteLast+28p

var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$C
		movem.l	d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$1C(a2),a3
		move.l	$C(a2),d0
		move.w	d0,d4
		andi.w	#$FF,d4
		move.l	$10(a2),d0
		move.l	d0,var_C(a6)
		tst.l	d0
		bne.s	loc_EA98
		move.l	$1C(a2),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		bra.w	loc_EC26
; ---------------------------------------------------------------------------

loc_EA98:				; CODE XREF: MacWriteFirst+24j
		movea.l	var_C(a6),a0
		move.l	$2A(a0),d0
		move.l	d0,var_8(a6)
		tst.w	d4
		bne.s	loc_EAAC
		move.w	#$100,d4

loc_EAAC:				; CODE XREF: MacWriteFirst+5Cj
		move.l	var_8(a6),d0
		beq.w	loc_EC1A
		movea.l	var_8(a6),a2
		moveq	#$1E,d0
		adda.l	d0,a2
		movea.l	var_8(a6),a0
		adda.l	$14(a0),a2
		movea.l	arg_0(a6),a0
		move.l	$14(a0),d0
		move.l	d0,var_4(a6)
		tst.l	d0
		beq.s	loc_EAE2
		movea.l	d0,a0
		tst.l	8(a0)
		bne.s	loc_EAE2
		moveq	#0,d0
		move.l	d0,var_4(a6)

loc_EAE2:				; CODE XREF: MacWriteFirst+88j
					; MacWriteFirst+90j
		movea.l	var_8(a6),a0
		move.w	d4,d1
		moveq	#0,d0
		move.w	d1,d0
		add.l	d0,$14(a0)
		move.l	$14(a0),d0
		cmpi.l	#$FA0,d0
		ble.s	loc_EB04
		jsr	(WriteBegin).l
		bra.s	loc_EB16
; ---------------------------------------------------------------------------

loc_EB04:				; CODE XREF: MacWriteFirst+B0j
		tst.w	d4
		ble.s	loc_EB16
		move.w	d4,d0
		subq.w	#1,d0
		movea.l	a3,a0
		movea.l	a2,a1

loc_EB10:				; CODE XREF: MacWriteFirst+C8j
		move.b	(a0)+,(a1)+
		dbf	d0,loc_EB10

loc_EB16:				; CODE XREF: MacWriteFirst+B8j
					; MacWriteFirst+BCj
		movea.l	arg_0(a6),a2
		move.l	$1C(a2),d0
		andi.l	#$1F00,d0
		addi.l	#-$78000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	var_C(a6),d0
		beq.s	loc_EBBA
		move.l	var_4(a6),d0
		beq.s	loc_EBBA
		movea.l	var_8(a6),a3
		move.l	var_4(a6),$C(a3)
		movea.l	var_4(a6),a4
		move.l	$24(a4),d0
		move.l	d0,4(a3)
		movea.l	$10(a2),a0
		move.w	$20(a0),d0
		move.w	d0,$18(a3)
		clr.w	d0
		movea.l	$10(a2),a0
		move.w	d0,$20(a0)
		move.l	a3,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp
		tst.b	$12(a4)
		beq.s	loc_EBB0
		movea.l	var_C(a6),a0
		move.w	$22(a0),d0
		move.w	$24(a0),d1
		cmp.w	d1,d0
		bne.s	loc_EBB0
		move.l	$C(a2),d0
		andi.l	#$FF0000,d0
		addi.l	#-$7C000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_EBB0:				; CODE XREF: MacWriteFirst+13Aj
					; MacWriteFirst+14Aj
		movea.l	var_C(a6),a0
		addq.w	#1,$22(a0)
		bra.s	loc_EC26
; ---------------------------------------------------------------------------

loc_EBBA:				; CODE XREF: MacWriteFirst+F8j
					; MacWriteFirst+FEj
		movea.l	arg_0(a6),a0
		move.l	$C(a0),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.l	var_C(a6),d0
		bne.s	loc_EBDC
		pea	(aNoConnection+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_EBDC:				; CODE XREF: MacWriteFirst+184j
		move.l	var_4(a6),d0
		bne.s	loc_EBEE
		pea	aNoDevice	; "no device"
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_EBEE:				; CODE XREF: MacWriteFirst+196j
		move.l	var_8(a6),-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		movea.l	arg_0(a6),a0
		move.l	$C(a0),d0
		andi.l	#$FF0000,d0
		addi.l	#-$7C000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		bra.s	loc_EC26
; ---------------------------------------------------------------------------

loc_EC1A:				; CODE XREF: MacWriteFirst+66j
		move.l	arg_0(a6),-(sp)
		jsr	(PostEvent).l
		addq.w	#4,sp

loc_EC26:				; CODE XREF: MacWriteFirst+4Aj
					; MacWriteFirst+16Ej ...
		movem.l	(sp)+,d4/a2-a4
		unlk	a6
		rts
; End of function MacWriteFirst

; ---------------------------------------------------------------------------
aMacwritelast:	dc.b 140,'MacWriteLast',0,0
aNoConnection:	dc.b 24,'no connection',0 ; DATA XREF: MacWriteFirst+186o
aNoDevice:	dc.b 'no device',0      ; DATA XREF: MacWriteFirst+198o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacWriteLast:

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		tst.l	$10(a3)
		beq.s	loc_EC7C
		move.l	#$FA0,-(sp)
		jsr	(receiveV110frame).l
		addq.w	#4,sp
		movea.l	$10(a3),a0
		move.l	d0,$2A(a0)

loc_EC7C:				; CODE XREF: MacWriteLast+Ej
		move.l	a3,-(sp)
		jsr	MacWriteFirst
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function MacWriteLast

; ---------------------------------------------------------------------------
aMacwritesingle:dc.b 142,'MacWriteSingle',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MacWriteSingle:				; DATA XREF: SendStatusBuffer+80o

var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$C
		movem.l	d3-d4/a2-a4,-(sp)
		moveq	#$20,d0	; ' '
		move.l	d0,-(sp)
		jsr	(TimerEvent).l
		addq.w	#4,sp
		movea.l	d0,a4
		moveq	#0,d0
		movea.l	d0,a3
		moveq	#0,d0
		move.l	d0,var_C(a6)
		move.l	d0,var_8(a6)
		movea.l	arg_0(a6),a2
		move.l	$C(a2),d4
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		cmpa.w	#0,a4
		bne.s	loc_ECE4
		jsr	(WriteBegin).l
		bra.w	loc_ED62
; ---------------------------------------------------------------------------

loc_ECE4:				; CODE XREF: MacWriteSingle+3Aj
		move.l	d4,d3
		moveq	#$1A,d0
		asr.l	d0,d3
		moveq	#7,d0
		and.l	d0,d3
		asl.l	#2,d3
		lea	-$198(a5),a0
		move.l	(a0,d3.w),d0
		move.l	d0,4(a4)
		move.l	d4,d0
		moveq	#$10,d1
		asr.l	d1,d0
		move.b	d0,var_4(a6)
		tst.b	d0
		beq.s	loc_ED34
		movea.l	-$210(a5),a3
		bra.s	loc_ED12
; ---------------------------------------------------------------------------

loc_ED10:				; CODE XREF: MacWriteSingle+80j
		movea.l	(a3),a3

loc_ED12:				; CODE XREF: MacWriteSingle+70j
		move.l	a3,d0
		beq.s	loc_ED20
		move.b	4(a3),d0
		cmp.b	var_4(a6),d0
		bne.s	loc_ED10

loc_ED20:				; CODE XREF: MacWriteSingle+76j
		move.l	a3,d0
		beq.s	loc_ED34
		move.l	$2E(a3),d0
		move.l	d0,var_C(a6)
		move.l	$2A(a3),d0
		move.l	d0,var_8(a6)

loc_ED34:				; CODE XREF: MacWriteSingle+6Aj
					; MacWriteSingle+84j
		move.l	a3,$18(a4)
		move.l	var_C(a6),$14(a4)
		move.l	var_8(a6),$10(a4)
		move.l	d4,d3
		andi.l	#$1F00,d3
		add.l	-$DB8(a5),d3
		move.l	d3,$1C(a4)
		move.l	d4,$C(a4)
		move.l	a4,-(sp)
		jsr	(DispatchEvent).l
		addq.w	#4,sp

loc_ED62:				; CODE XREF: MacWriteSingle+42j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function MacWriteSingle

; ---------------------------------------------------------------------------
aMailboxevent:	dc.b 140,'MailboxEvent',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

MailboxEvent:				; DATA XREF: Connect2nd+138o

arg_0		=  8

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		movea.l	$2E(a2),a0
		move.b	#6,$E(a0)
		move.l	a2,-(sp)
		pea	(SendConnect1TR6SPV).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function MailboxEvent

; ---------------------------------------------------------------------------
aConnect2nd:	dc.b 138,'Connect2nd',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

Connect2nd:				; DATA XREF: CheckNumber1TR6+C0o
					; A_SETUP_EDSS1+B6o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a4
		jsr	(WriteProc).l
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.b	9(a4),d0
		moveq	#$7F,d1	; ''
		cmp.b	d1,d0
		bhi.w	loc_EF50
		movea.l	-$210(a5),a3
		movea.l	a4,a2
		moveq	#$3A,d0	; ':'
		adda.l	d0,a2
		bra.w	loc_EE82
; ---------------------------------------------------------------------------

loc_EDF0:				; CODE XREF: Connect2nd+CEj
		cmpa.l	a4,a3
		beq.w	loc_EE80
		move.b	4(a3),d0
		cmpi.b	#$80,d0
		bcs.w	loc_EE80
		tst.l	$2A(a3)
		beq.s	loc_EE80
		movea.l	a3,a0
		moveq	#$3A,d0	; ':'
		adda.l	d0,a0
		move.l	a0,-(sp)
		move.l	a2,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_EE80
		movea.l	a3,a0
		moveq	#$50,d3	; 'P'
		adda.l	d3,a0
		move.l	a0,-(sp)
		movea.l	a4,a0
		adda.l	d3,a0
		move.l	a0,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_EE80
		movea.l	a3,a0
		moveq	#$66,d3	; 'f'
		adda.l	d3,a0
		move.l	a0,-(sp)
		movea.l	a4,a0
		adda.l	d3,a0
		move.l	a0,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_EE80
		movea.l	a3,a0
		moveq	#$7C,d3	; '|'
		adda.l	d3,a0
		move.l	a0,-(sp)
		movea.l	a4,a0
		adda.l	d3,a0
		move.l	a0,-(sp)
		jsr	InitMailbox
		addq.w	#8,sp
		tst.b	d0
		bne.s	loc_EE80
		movea.l	$2E(a3),a0
		move.b	$13(a0),d3
		moveq	#$16,d0
		cmp.b	d0,d3
		beq.s	loc_EE88
		moveq	#$20,d0	; ' '
		cmp.b	d0,d3
		beq.s	loc_EE88

loc_EE80:				; CODE XREF: Connect2nd+3Cj
					; Connect2nd+48j ...
		movea.l	(a3),a3

loc_EE82:				; CODE XREF: Connect2nd+36j
		move.l	a3,d0
		bne.w	loc_EDF0

loc_EE88:				; CODE XREF: Connect2nd+C2j
					; Connect2nd+C8j
		move.l	a3,d0
		beq.w	loc_EF50
		pea	(aBundle?+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	$2A(a3),a2
		tst.b	5(a2)
		beq.s	loc_EF12
		tst.b	7(a4)
		bne.s	loc_EF12
		moveq	#6,d0
		move.b	d0,-(sp)
		jsr	CmdAlert
		addq.w	#2,sp
		movea.l	d0,a3
		cmpa.w	#0,a3
		beq.s	loc_EF12
		pea	aY		; " -y"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a4,$C(a2)
		move.l	a2,$2A(a4)
		move.l	a3,$2E(a4)
		move.l	a3,$14(a2)
		move.l	a4,8(a3)
		move.l	a4,-(sp)
		pea	(NL_CONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		lea	(MailboxEvent).l,a0
		move.l	a0,$1E(a4)
		move.l	a4,$26(a4)
		moveq	#$4E,d0	; 'N'
		move.l	d0,-(sp)
		movea.l	a4,a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(EventLoop).l
		addq.w	#8,sp
		bra.s	loc_EF6E
; ---------------------------------------------------------------------------

loc_EF12:				; CODE XREF: Connect2nd+ECj
					; Connect2nd+F2j ...
		pea	aN		; " -n"
		jsr	(WriteChar).l
		addq.w	#4,sp
		tst.b	5(a2)
		beq.s	loc_EF3E
		move.b	7(a4),d0
		moveq	#$22,d1	; '"'
		cmp.b	d1,d0
		bne.s	loc_EF3E
		clr.b	7(a4)
		pea	aWasCw		; " was	CW"
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_EF3E:				; CODE XREF: Connect2nd+16Cj
					; Connect2nd+176j
		move.l	a4,-(sp)
		pea	(NL_DISCONNECT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_EF6E
; ---------------------------------------------------------------------------

loc_EF50:				; CODE XREF: Connect2nd+28j
					; Connect2nd+D4j
		lea	(CmdBusy).l,a0
		move.l	a0,$1E(a4)
		move.l	a4,$26(a4)
		movea.l	a4,a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(First).l
		addq.w	#4,sp

loc_EF6E:				; CODE XREF: Connect2nd+15Aj
					; Connect2nd+198j
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function Connect2nd

; ---------------------------------------------------------------------------
aNl_call_indication:dc.b 146,'NL_CALL_INDICATION',0,0
aBundle?:	dc.b 24,'bundle?',0     ; DATA XREF: Connect2nd+D8o
aY:		dc.b ' -y',0            ; DATA XREF: Connect2nd+108o
aN:		dc.b ' -n',0            ; DATA XREF: Connect2nd:loc_EF12o
aWasCw:		dc.b ' was CW',0        ; DATA XREF: Connect2nd+17Co

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CALL_INDICATION:			; DATA XREF: CheckService+1F8o
					; CheckInfoEDSS1+6Ao

var_C		= -$C
var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-$C
		movem.l	d3/a3-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		movea.l	$2A(a3),a4
		cmpa.w	#0,a4
		beq.w	loc_F0BE
		jsr	_STIDNet_c_
		move.l	d0,var_C(a6)
		jsr	(WriteProc).l
		movea.l	8(a4),a0
		cmpa.l	a3,a0
		bne.s	loc_EFE0
		move.l	$34(a3),d0
		move.l	d0,$18(a4)

loc_EFE0:				; CODE XREF: NL_CALL_INDICATION+32j
		movea.l	$C(a4),a0
		cmpa.l	a3,a0
		bne.s	loc_EFF0
		move.l	$34(a3),d0
		move.l	d0,$1C(a4)

loc_EFF0:				; CODE XREF: NL_CALL_INDICATION+42j
		move.l	var_C(a6),d0
		beq.w	loc_F0BE
		move.l	var_C(a6),var_8(a6)
		moveq	#1,d0
		move.l	d0,var_4(a6)
		move.l	$18(a4),d3
		add.l	$1C(a4),d3
		move.l	d3,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		bra.s	loc_F032
; ---------------------------------------------------------------------------

loc_F018:				; CODE XREF: NL_CALL_INDICATION+A8j
		move.l	var_4(a6),d0
		move.l	d0,d1
		mulu.w	#$A,d0
		swap	d1
		mulu.w	#$A,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		move.l	d0,var_4(a6)

loc_F032:				; CODE XREF: NL_CALL_INDICATION+72j
		move.l	var_4(a6),d0
		move.l	d0,d1
		mulu.w	#$A,d0
		swap	d1
		mulu.w	#$A,d1
		swap	d1
		clr.w	d1
		add.l	d1,d0
		cmp.l	d3,d0
		bgt.s	loc_F080
		bra.s	loc_F018
; ---------------------------------------------------------------------------

loc_F04E:				; CODE XREF: NL_CALL_INDICATION+E0j
		move.w	var_4+2(a6),d1
		move.l	d3,d0
		divs.w	d1,d0
		moveq	#$30,d1	; '0'
		add.b	d1,d0
		addq.l	#1,var_8(a6)
		movea.l	var_8(a6),a0
		move.b	d0,(a0)
		move.w	var_4+2(a6),d1
		move.l	d3,d0
		divs.w	d1,d0
		swap	d0
		ext.l	d0
		move.l	d0,d3
		moveq	#$A,d1
		move.l	var_4(a6),d0
		divs.w	d1,d0
		ext.l	d0
		move.l	d0,var_4(a6)

loc_F080:				; CODE XREF: NL_CALL_INDICATION+A6j
		move.l	var_4(a6),d0
		bne.s	loc_F04E
		move.b	var_8+3(a6),d0
		sub.b	var_C+3(a6),d0
		movea.l	var_C(a6),a0
		move.b	d0,(a0)
		move.b	4(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d3
		asl.l	d3,d0
		addi.l	#-$74000000,d0
		move.l	var_C(a6),d1
		andi.l	#$1F00,d1
		add.l	d1,d0
		add.l	d3,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F0BE:				; CODE XREF: NL_CALL_INDICATION+18j
					; NL_CALL_INDICATION+50j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a3-a4
		unlk	a6
		rts
; End of function NL_CALL_INDICATION

; ---------------------------------------------------------------------------
aNl_charge_indication:dc.b 148,'NL_CHARGE_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CHARGE_INDICATION:			; DATA XREF: SendMessage+2Co
					; NL_CONNECT_REQUEST+62o

arg_0		=  8

		link	a6,#0
		movem.l	d3/a2-a3,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		jsr	(WriteProc).l
		move.b	4(a3),d3
		cmpi.b	#$80,d3
		bhi.s	loc_F10E
		moveq	#0,d0
		bra.s	loc_F110
; ---------------------------------------------------------------------------

loc_F10E:				; CODE XREF: NL_CHARGE_INDICATION+1Ej
		moveq	#1,d0

loc_F110:				; CODE XREF: NL_CHARGE_INDICATION+22j
		move.l	d0,d0
		moveq	#0,d1
		move.b	d3,d1
		moveq	#$10,d2
		asl.l	d2,d1
		addi.l	#-$74000000,d1
		add.l	d1,d0
		beq.s	loc_F128
		moveq	#$30,d0	; '0'
		bra.s	loc_F12A
; ---------------------------------------------------------------------------

loc_F128:				; CODE XREF: NL_CHARGE_INDICATION+38j
		moveq	#$B,d0

loc_F12A:				; CODE XREF: NL_CHARGE_INDICATION+3Cj
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a3
		unlk	a6
		rts
; End of function NL_CHARGE_INDICATION

; ---------------------------------------------------------------------------
aNl_alert_indication:dc.b 147,'NL_ALERT_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_ALERT_INDICATION:			; DATA XREF: A_CALL_CONTROL+84o
					; A_SETUP_1TR6+22o

arg_0		=  8

		link	a6,#0
		movem.l	a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a2
		movea.l	$2A(a2),a3
		movea.l	$2E(a2),a4
		jsr	(WriteProc).l
		move.b	4(a2),d0
		cmpi.b	#$80,d0
		bcc.s	loc_F1D6
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$4A,d1	; 'J'
		cmp.l	d1,d0
		beq.s	loc_F19E
		moveq	#$58,d1	; 'X'
		cmp.l	d1,d0
		beq.s	loc_F1B0
		bra.s	loc_F1D6
; ---------------------------------------------------------------------------

loc_F19E:				; CODE XREF: NL_ALERT_INDICATION+38j
		movea.l	a2,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	updateblacklist
		addq.w	#4,sp
		bra.s	loc_F1D6
; ---------------------------------------------------------------------------

loc_F1B0:				; CODE XREF: NL_ALERT_INDICATION+3Ej
		move.b	9(a2),d0
		cmpi.b	#$C0,d0
		bne.s	loc_F1D6
		move.l	-$D44(a5),d0
		addi.l	#$5265C,d0
		move.l	d0,-(sp)
		movea.l	a2,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	removeblacklist
		addq.w	#8,sp

loc_F1D6:				; CODE XREF: NL_ALERT_INDICATION+26j
					; NL_ALERT_INDICATION+40j ...
		move.b	4(a2),d0
		moveq	#$40,d1	; '@'
		cmp.b	d1,d0
		bcc.s	loc_F1F8
		tst.l	$C(a3)
		beq.s	loc_F1F8
		move.l	$C(a3),-(sp)
		pea	(dl_tei_fail_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp

loc_F1F8:				; CODE XREF: NL_ALERT_INDICATION+82j
					; NL_ALERT_INDICATION+88j
		move.l	a3,d0
		bne.s	loc_F208
		move.b	4(a2),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp

loc_F208:				; CODE XREF: NL_ALERT_INDICATION+9Ej
		move.b	$E(a4),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	4(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		addi.l	#-$74000000,d0
		move.b	$13(a4),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a4
		unlk	a6
		rts
; End of function NL_ALERT_INDICATION

; ---------------------------------------------------------------------------
aNl_connect_indication:dc.b 149,'NL_CONNECT_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_CONNECT_INDICATION:			; CODE XREF: nl_suspend_resume_indication+Cp
					; NL_SUSPENDED_INDICATION+Cp

arg_0		=  8
arg_4		=  $C

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		movea.l	$2A(a3),a2
		jsr	(WriteProc).l
		move.b	5(a3),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_F2B6
		cmpa.w	#0,a2
		beq.s	loc_F2B6
		move.b	4(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$74000000,d0
		move.b	arg_4(a6),d2
		moveq	#0,d1
		move.b	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F2B6:				; CODE XREF: NL_CONNECT_INDICATION+22j
					; NL_CONNECT_INDICATION+28j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function NL_CONNECT_INDICATION

; ---------------------------------------------------------------------------
aNl_suspend_resume_indication:dc.b 156,'nl_suspend_resume_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_suspend_resume_indication:		; DATA XREF: A_CALL_CLEAR_EDSS1+42o
					; A_NOTIFY_EDSS1+42o

arg_0		=  8

		link	a6,#0
		moveq	#$28,d0	; '('
		move.b	d0,-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	NL_CONNECT_INDICATION
		unlk	a6
		rts
; End of function nl_suspend_resume_indication

; ---------------------------------------------------------------------------
aNl_suspended_indication:dc.b 151,'NL_SUSPENDED_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_SUSPENDED_INDICATION:		; DATA XREF: A_CALL_CLEAR_EDSS1+56o
					; A_NOTIFY_EDSS1+56o

arg_0		=  8

		link	a6,#0
		moveq	#3,d0
		move.b	d0,-(sp)
		move.l	arg_0(a6),-(sp)
		jsr	NL_CONNECT_INDICATION
		unlk	a6
		rts
; End of function NL_SUSPENDED_INDICATION

; ---------------------------------------------------------------------------
aNl_resumed_indication:dc.b 149,'NL_RESUMED_INDICATION',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_RESUMED_INDICATION:			; DATA XREF: SendMessage+CEo
					; A_CONNECT_ACKNOWLEDGE+56o ...

arg_0		=  8

		link	a6,#0
		movem.l	a2-a3,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a3
		movea.l	$2A(a3),a2
		jsr	(WriteProc).l
		cmpa.w	#0,a2
		beq.s	loc_F3AE
		movea.l	$C(a2),a0
		cmpa.l	a3,a0
		bne.s	loc_F38E
		movea.l	8(a2),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_F38E
		movea.l	$10(a2),a0
		move.b	$13(a0),d0
		moveq	#$16,d1
		cmp.b	d1,d0
		bne.s	loc_F38E
		bra.s	loc_F3AE
; ---------------------------------------------------------------------------

loc_F38E:				; CODE XREF: NL_RESUMED_INDICATION+26j
					; NL_RESUMED_INDICATION+34j ...
		move.b	4(a2),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$74000000,d0
		moveq	#$17,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F3AE:				; CODE XREF: NL_RESUMED_INDICATION+1Ej
					; NL_RESUMED_INDICATION+44j
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,a2-a3
		unlk	a6
		rts
; End of function NL_RESUMED_INDICATION

; ---------------------------------------------------------------------------
aNl_disconnect_indication:dc.b 152,'NL_DISCONNECT_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_DISCONNECT_INDICATION:		; DATA XREF: VoiceStart+8Ao
					; CheckLeo+58o

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3/a2-a4,-(sp)
		movea.l	arg_0(a6),a0
		movea.l	$C(a0),a0
		move.l	a0,var_8(a6)
		movea.l	8(a0),a4
		movea.l	$2A(a4),a3
		move.b	$13(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		move.w	d0,var_4(a6)
		move.l	4(a0),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.b	var_4+1(a6),-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		cmpa.w	#0,a4
		bne.s	loc_F43A
		jsr	(WriteBegin).l
		bra.w	loc_F56C
; ---------------------------------------------------------------------------

loc_F43A:				; CODE XREF: NL_DISCONNECT_INDICATION+50j
		move.w	var_4(a6),d3
		moveq	#4,d0
		cmp.w	d0,d3
		beq.s	loc_F450
		moveq	#$22,d0	; '"'
		cmp.w	d0,d3
		beq.s	loc_F450
		moveq	#8,d0
		cmp.w	d0,d3
		bne.s	loc_F466

loc_F450:				; CODE XREF: NL_DISCONNECT_INDICATION+64j
					; NL_DISCONNECT_INDICATION+6Aj
		move.l	a4,-(sp)
		pea	(NL_ALERT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		moveq	#$17,d0
		move.w	d0,var_4(a6)

loc_F466:				; CODE XREF: NL_DISCONNECT_INDICATION+70j
		cmpi.w	#3,var_4(a6)
		bne.s	loc_F4A0
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$58,d1	; 'X'
		cmp.b	d1,d0
		bne.s	loc_F4A0
		move.b	4(a4),d0
		cmpi.b	#$80,d0
		bcc.s	loc_F4A0
		move.b	9(a4),d0
		cmpi.b	#$C0,d0
		bne.s	loc_F4A0
		movea.l	a4,a0
		moveq	#$66,d0	; 'f'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	updateblacklist
		addq.w	#4,sp

loc_F4A0:				; CODE XREF: NL_DISCONNECT_INDICATION+8Ej
					; NL_DISCONNECT_INDICATION+9Cj	...
		cmpi.w	#3,var_4(a6)
		bne.s	loc_F508
		move.l	a3,d0
		beq.s	loc_F508
		movea.l	$C(a3),a2
		cmpa.w	#0,a2
		beq.s	loc_F508
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		tst.b	d0
		bne.s	loc_F508
		moveq	#0,d3
		movea.l	$14(a3),a0
		move.l	d3,8(a0)
		move.l	d3,$14(a3)
		movea.l	a3,a2
		moveq	#$C,d0
		adda.l	d0,a2
		movea.l	(a2),a0
		move.l	d3,$2E(a0)
		lea	(CmdBusy).l,a0
		movea.l	(a2),a1
		move.l	a0,$1E(a1)
		move.l	(a2),d0
		movea.l	(a2),a0
		move.l	d0,$26(a0)
		movea.l	(a2),a0
		moveq	#$1A,d0
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		move.l	d3,(a2)

loc_F508:				; CODE XREF: NL_DISCONNECT_INDICATION+C8j
					; NL_DISCONNECT_INDICATION+CCj	...
		move.b	5(a4),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		beq.s	loc_F536
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d0
		moveq	#$46,d1	; 'F'
		cmp.b	d1,d0
		bne.s	loc_F56C
		movea.l	var_8(a6),a0
		move.b	$E(a0),d0
		cmpi.b	#$C0,d0
		bne.s	loc_F56C
		cmpi.w	#3,var_4(a6)
		bne.s	loc_F56C

loc_F536:				; CODE XREF: NL_DISCONNECT_INDICATION+132j
		movea.l	var_8(a6),a0
		move.b	$E(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		asl.l	#8,d0
		move.b	4(a3),d2
		moveq	#0,d1
		move.b	d2,d1
		moveq	#$10,d2
		asl.l	d2,d1
		add.l	d1,d0
		addi.l	#-$74000000,d0
		move.w	var_4(a6),d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F56C:				; CODE XREF: NL_DISCONNECT_INDICATION+58j
					; NL_DISCONNECT_INDICATION+140j ...
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movem.l	(sp)+,d3/a2-a4
		unlk	a6
		rts
; End of function NL_DISCONNECT_INDICATION

; ---------------------------------------------------------------------------
aB_error_indication:dc.b 146,'B_ERROR_INDICATION',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

B_ERROR_INDICATION:			; DATA XREF: T_REQUEST+EEo

var_8		= -8
var_4		= -4
arg_0		=  8

		link	a6,#-8
		movem.l	d3-d4/a2-a4,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	$C(a2),a3
		movea.l	$2A(a3),a4
		cmpa.w	#0,a4
		beq.w	loc_F72E
		movea.l	$C(a4),a0
		cmpa.l	a3,a0
		bne.s	loc_F62C
		movea.l	8(a4),a0
		move.b	5(a0),d0
		moveq	#$A,d1
		cmp.b	d1,d0
		bne.s	loc_F62C
		movea.l	$10(a4),a0
		move.b	$13(a0),d0
		moveq	#$16,d1
		cmp.b	d1,d0
		bne.s	loc_F62C
		movea.l	$10(a4),a0
		move.l	a0,var_8(a6)
		move.b	#$21,$13(a0) ; '!'
		move.l	var_8(a6),$C(a2)
		move.l	$1C(a0),d0
		move.l	d0,4(a2)
		move.l	a2,-(sp)
		jsr	(First).l
		addq.w	#4,sp
		movea.l	var_8(a6),a0
		move.b	#6,$13(a0)
		moveq	#0,d3
		move.l	d3,$C(a4)
		movea.l	$14(a4),a0
		move.l	d3,8(a0)
		move.l	d3,$2A(a3)
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		jsr	DeviceUsage
		bra.w	loc_F78A
; ---------------------------------------------------------------------------

loc_F62C:				; CODE XREF: B_ERROR_INDICATION+22j
					; B_ERROR_INDICATION+30j ...
		move.b	4(a4),d0
		move.b	d0,var_4(a6)
		move.w	6(a4),d3
		beq.s	loc_F63E
		move.w	d3,d4
		bra.s	loc_F658
; ---------------------------------------------------------------------------

loc_F63E:				; CODE XREF: B_ERROR_INDICATION+A2j
		move.b	7(a3),d3
		moveq	#0,d4
		move.b	d3,d4
		asl.w	#8,d4
		addq.w	#4,d4
		move.b	d3,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.w	d4,6(a4)

loc_F658:				; CODE XREF: B_ERROR_INDICATION+A6j
		movea.l	$2E(a4),a2
		cmpa.w	#0,a2
		beq.s	loc_F684
		move.l	a2,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_F684
; ---------------------------------------------------------------------------

loc_F66E:				; CODE XREF: B_ERROR_INDICATION+F6j
		move.l	a2,-(sp)
		jsr	(Inqueue).l
		addq.w	#4,sp
		move.l	d0,-(sp)
		jsr	(GetMsgBuffer).l
		addq.w	#4,sp
		bra.s	loc_F68A
; ---------------------------------------------------------------------------

loc_F684:				; CODE XREF: B_ERROR_INDICATION+CAj
					; B_ERROR_INDICATION+D6j
		movea.l	a4,a2
		moveq	#$32,d0	; '2'
		adda.l	d0,a2

loc_F68A:				; CODE XREF: B_ERROR_INDICATION+ECj
		tst.l	(a2)
		bne.s	loc_F66E
		moveq	#0,d3
		move.l	d3,$2E(a4)
		movea.l	8(a4),a0
		cmpa.l	a3,a0
		bne.s	loc_F6A2
		move.l	d3,8(a4)
		bra.s	loc_F6BE
; ---------------------------------------------------------------------------

loc_F6A2:				; CODE XREF: B_ERROR_INDICATION+104j
		movea.l	$C(a4),a0
		cmpa.l	a3,a0
		bne.s	loc_F6B2
		moveq	#0,d0
		move.l	d0,$C(a4)
		bra.s	loc_F6BE
; ---------------------------------------------------------------------------

loc_F6B2:				; CODE XREF: B_ERROR_INDICATION+112j
		pea	(aUnknownCall+1)
		jsr	(WriteChar).l
		addq.w	#4,sp

loc_F6BE:				; CODE XREF: B_ERROR_INDICATION+10Aj
					; B_ERROR_INDICATION+11Aj
		movea.l	8(a4),a2
		cmpa.w	#0,a2
		bne.s	loc_F6CE
		tst.l	$C(a4)
		beq.s	loc_F6FE

loc_F6CE:				; CODE XREF: B_ERROR_INDICATION+130j
		moveq	#$17,d4
		cmpa.w	#0,a2
		beq.s	loc_F6EA
		move.l	8(a4),-(sp)
		pea	(NL_ALERT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_F708
; ---------------------------------------------------------------------------

loc_F6EA:				; CODE XREF: B_ERROR_INDICATION+13Ej
		move.l	$C(a4),-(sp)
		pea	(NL_ALERT_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		bra.s	loc_F708
; ---------------------------------------------------------------------------

loc_F6FE:				; CODE XREF: B_ERROR_INDICATION+136j
		move.l	a4,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_F708:				; CODE XREF: B_ERROR_INDICATION+152j
					; B_ERROR_INDICATION+166j
		move.b	var_4(a6),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$74000000,d0
		move.w	d4,d2
		moveq	#0,d1
		move.w	d2,d1
		add.l	d1,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		bra.s	loc_F758
; ---------------------------------------------------------------------------

loc_F72E:				; CODE XREF: B_ERROR_INDICATION+18j
		pea	aUnknownConnection ; "unknown connection"
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	4(a3),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$10,d1
		asl.l	d1,d0
		addi.l	#-$74000000,d0
		addq.l	#4,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F758:				; CODE XREF: B_ERROR_INDICATION+196j
		movea.l	a3,a2
		moveq	#$1A,d0
		adda.l	d0,a2
		move.l	a2,-(sp)
		jsr	(StartTimer).l
		addq.w	#4,sp
		moveq	#0,d0
		move.l	d0,$2A(a3)
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		jsr	DeviceUsage
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp

loc_F78A:				; CODE XREF: B_ERROR_INDICATION+92j
		movem.l	(sp)+,d3-d4/a2-a4
		unlk	a6
		rts
; End of function B_ERROR_INDICATION

; ---------------------------------------------------------------------------
aNl_release_indication:dc.b 149,'NL_RELEASE_INDICATION',0
aUnknownCall:	dc.b '"unknown call',0,0 ; DATA XREF: B_ERROR_INDICATION:loc_F6B2o
aUnknownConnection:dc.b	'unknown connection',0,0 ; DATA XREF: B_ERROR_INDICATION:loc_F72Eo

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

NL_RELEASE_INDICATION:			; DATA XREF: dl_data_indication+72o
					; nl_set_bilingual+1Eo

arg_0		=  8

		link	a6,#0
		move.l	a3,-(sp)
		movea.l	arg_0(a6),a3
		move.l	$C(a3),d0
		move.b	d0,-(sp)
		jsr	(WriteLine).l
		addq.w	#2,sp
		move.l	$C(a3),d0
		moveq	#$41,d1	; 'A'
		cmp.l	d1,d0
		bne.s	loc_F7FA
		movea.l	-$DB8(a5),a0
		andi.b	#$F7,$1F91(a0)
		bra.s	loc_F804
; ---------------------------------------------------------------------------

loc_F7FA:				; CODE XREF: NL_RELEASE_INDICATION+20j
		movea.l	-$DB8(a5),a0
		ori.b	#8,$1F91(a0)

loc_F804:				; CODE XREF: NL_RELEASE_INDICATION+2Cj
		move.l	a3,-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		movea.l	(sp)+,a3
		unlk	a6
		rts
; End of function NL_RELEASE_INDICATION

; ---------------------------------------------------------------------------
aNl_protocol_indication:dc.b 150,'nl_protocol_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

nl_protocol_indication:			; DATA XREF: dl_reestablish+2Co
					; dl_clear_queue+1Eo ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		move.b	-$54(a5),d0
		moveq	#1,d3
		cmp.b	d3,d0
		beq.s	loc_F856
		move.b	d3,-$54(a5)
		moveq	#0,d0
		move.b	d3,d0
		addi.l	#-$74000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F856:				; CODE XREF: nl_protocol_indication+Ej
		jsr	(WriteProc).l
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function nl_protocol_indication

; ---------------------------------------------------------------------------
aDl_user_connect_indication:dc.b 154,'dl_user_connect_indication',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_user_connect_indication:		; DATA XREF: PH_ACTIVATE_INDICATION+40o
					; DL_RELEASE_REQUEST+C4o ...

arg_0		=  8

		link	a6,#0
		move.l	d3,-(sp)
		move.b	-$54(a5),d0
		moveq	#7,d3
		cmp.b	d3,d0
		beq.s	loc_F8B4
		move.b	d3,-$54(a5)
		moveq	#0,d0
		move.b	d3,d0
		addi.l	#-$74000000,d0
		move.l	d0,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp

loc_F8B4:				; CODE XREF: dl_user_connect_indication+Ej
		jsr	(WriteProc).l
		move.l	arg_0(a6),-(sp)
		jsr	(Alloc).l
		addq.w	#4,sp
		move.l	(sp)+,d3
		unlk	a6
		rts
; End of function dl_user_connect_indication

; ---------------------------------------------------------------------------
aDl_user_disconnect_indication:dc.b 157,'dl_user_disconnect_indication',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dl_user_disconnect_indication:		; CODE XREF: InitializeCommon+10Cp
		link	a6,#0
		movea.l	-$DB8(a5),a0
		andi.b	#$DB,$1F91(a0)
		jsr	DeviceUsage
		unlk	a6
		rts
; End of function dl_user_disconnect_indication

; ---------------------------------------------------------------------------
aInitcommands:	dc.b 140,'InitCommands',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitCommands:				; CODE XREF: First+62p
					; DispatchEvent+76p ...
		link	a6,#0
		movem.l	d3-d4/a3,-(sp)
		move.l	a6,d0
		movea.l	d0,a3
		moveq	#$F,d4
		bra.s	loc_F970
; ---------------------------------------------------------------------------

loc_F924:				; CODE XREF: InitCommands+68j
		pea	(aStacktrace_0+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a3,-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		moveq	#$20,d3	; ' '
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	4(a3),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	4(a3),-(sp)
		jsr	(InitHSCX).l
		addq.w	#4,sp
		jsr	(WritePString).l
		movea.l	(a3),a3

loc_F970:				; CODE XREF: InitCommands+Ej
		subq.l	#1,d4
		cmpi.l	#0,d4
		bmi.s	loc_F97E
		move.l	a3,d0
		bne.s	loc_F924

loc_F97E:				; CODE XREF: InitCommands+64j
		move.l	#$A4000000,-(sp)
		jsr	FreeMailboxBuffer
		addq.w	#4,sp
		clr.b	-$52(a5)
		movem.l	(sp)+,d3-d4/a3
		unlk	a6
		rts
; End of function InitCommands

; ---------------------------------------------------------------------------
aStacktrace:	dc.b 138,'stacktrace',0,0
aStacktrace_0:	dc.b 14,'stacktrace: ',0,0 ; DATA XREF: InitCommands:loc_F924o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

stacktrace:				; CODE XREF: commonexception+Cp
					; exception+Cp

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		jsr	(WritePString).l
		move.w	arg_0(a6),d1
		moveq	#0,d0
		move.w	d1,d0
		asl.l	#2,d0
		lea	-$50(a5),a0
		move.l	(a0,d0.w),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	(aAt+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	arg_2(a6),-(sp)
		jsr	(WriteWord).l
		unlk	a6
		rts
; End of function stacktrace

; ---------------------------------------------------------------------------
aBeginexception:dc.b 142,'beginexception',0,0
aAt:		dc.b 6,' at ',0,0       ; DATA XREF: stacktrace+24o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

beginexception:				; CODE XREF: dumpline+36p dumpline+52p ...

arg_0		=  8

		link	a6,#0
		movem.l	d4/a2,-(sp)
		movea.l	arg_0(a6),a2
		movea.l	arg_0(a6),a0
		moveq	#$20,d0	; ' '
		adda.l	d0,a0
		move.l	a0,d4
		bra.s	loc_FA3A
; ---------------------------------------------------------------------------

loc_FA22:				; CODE XREF: beginexception+32j
		moveq	#$20,d0	; ' '
		move.b	d0,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	(a2),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		addq.w	#4,a2

loc_FA3A:				; CODE XREF: beginexception+16j
		cmp.l	a2,d4
		bgt.s	loc_FA22
		jsr	(WritePString).l
		movem.l	(sp)+,d4/a2
		unlk	a6
		rts
; End of function beginexception

; ---------------------------------------------------------------------------
aDumpline:	dc.b 136,'dumpline',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

dumpline:				; CODE XREF: commonexception+1Cp
					; exception+34p

arg_0		=  8
arg_2		=  $A

		link	a6,#0
		move.l	a2,-(sp)
		movea.l	arg_2(a6),a2
		pea	aSr		; " SR="
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.w	arg_0(a6),-(sp)
		jsr	(WriteHex).l
		addq.w	#2,sp
		jsr	(WritePString).l
		pea	aD0__d7		; "D0..D7="
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	a2,-(sp)
		jsr	beginexception
		addq.w	#4,sp
		pea	aA0__a7		; "A0..A7="
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a2,a0
		moveq	#$20,d0	; ' '
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	beginexception
		addq.w	#4,sp
		pea	(a______+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		movea.l	a2,a0
		moveq	#$40,d0	; '@'
		adda.l	d0,a0
		move.l	a0,-(sp)
		jsr	beginexception
		addq.w	#4,sp
		jsr	InitCommands
		clr.l	-(sp)
		pea	(InitMemory).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.l	-(sp)
		pea	(DL_ESTABLISH_REQUEST).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function dumpline

; ---------------------------------------------------------------------------
aCommonexception:dc.b 143,'commonexception',0
a______:	dc.b 30,'......=',0     ; DATA XREF: dumpline+5Ao
aA0__a7:	dc.b 'A0..A7=',0        ; DATA XREF: dumpline+3Eo
aD0__d7:	dc.b 'D0..D7=',0        ; DATA XREF: dumpline+28o
aSr:		dc.b ' SR=',0,0         ; DATA XREF: dumpline+Ao

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

commonexception:			; CODE XREF: exc_IllegalInstruction+28p
					; exc_ZeroDivide+2Ap

arg_0		=  8
arg_42		=  $4A
arg_44		=  $4C
arg_46		=  $4E

		link	a6,#0
		move.l	arg_46(a6),-(sp)
		move.w	arg_42(a6),-(sp)
		jsr	stacktrace
		addq.w	#6,sp
		pea	arg_0(a6)
		move.w	arg_44(a6),-(sp)
		jsr	dumpline
		unlk	a6
		rts
; End of function commonexception

; ---------------------------------------------------------------------------
aException:	dc.b 137,'exception',0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

exception:				; CODE XREF: exc_BusError+10p
					; exc_AddressError+10p

arg_0		=  8
arg_42		=  $4A
arg_46		=  $4E
arg_4C		=  $54
arg_4E		=  $56

		link	a6,#0
		move.l	arg_4E(a6),-(sp)
		move.w	arg_42(a6),-(sp)
		jsr	stacktrace
		addq.w	#6,sp
		pea	(aAccess+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	arg_46(a6),-(sp)
		jsr	(WriteWord).l
		addq.w	#4,sp
		pea	arg_0(a6)
		move.w	arg_4C(a6),-(sp)
		jsr	dumpline
		unlk	a6
		rts
; End of function exception

; ---------------------------------------------------------------------------
aAdresserror:	dc.b 139,'adresserror',0
aAccess:	dc.b 10,' access ',0,0  ; DATA XREF: exception+14o

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

addresserror:				; CODE XREF: InitializeCommon+138p
		link	a6,#0
		move.l	a2,-(sp)
		movea.l	-$DB8(a5),a0
		move.b	$1F93(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#$4A,d1	; 'J'
		cmp.l	d1,d0
		beq.s	loc_FBDE
		moveq	#$44,d1	; 'D'
		cmp.l	d1,d0
		beq.s	loc_FBE6
		moveq	#$4E,d1	; 'N'
		cmp.l	d1,d0
		beq.s	loc_FBEE
		moveq	#$42,d1	; 'B'
		cmp.l	d1,d0
		beq.s	loc_FBEE
		bra.s	loc_FBF6
; ---------------------------------------------------------------------------

loc_FBDE:				; CODE XREF: addresserror+16j
		lea	(nl_set_edss1).l,a2
		bra.s	loc_FBFC
; ---------------------------------------------------------------------------

loc_FBE6:				; CODE XREF: addresserror+1Cj
		lea	(nl_set_protocol).l,a2
		bra.s	loc_FBFC
; ---------------------------------------------------------------------------

loc_FBEE:				; CODE XREF: addresserror+22j
					; addresserror+28j
		lea	(NL_CLEAR_REQUEST).l,a2
		bra.s	loc_FBFC
; ---------------------------------------------------------------------------

loc_FBF6:				; CODE XREF: addresserror+2Aj
		lea	(nl_set_1tr6).l,a2

loc_FBFC:				; CODE XREF: addresserror+32j
					; addresserror+3Aj ...
		clr.l	-(sp)
		move.l	a2,-(sp)
		jsr	(SendEvent).l
		addq.w	#8,sp
		clr.l	-(sp)
		pea	(dl_timer_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		jsr	PH_DATA_INDICATION
		jsr	nl_set_japan
		movea.l	(sp)+,a2
		unlk	a6
		rts
; End of function addresserror

; ---------------------------------------------------------------------------
aInitializecommon:dc.b 144,'InitializeCommon',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: bp-based frame

InitializeCommon:			; CODE XREF: initial_PC+46p
					; initial_PC+6Ap ...

arg_0		=  8

		link	a6,#0
		movem.l	d3-d4,-(sp)
		move.w	arg_0(a6),d4
		move.w	d4,-$12(a5)
		movea.l	#$3FFFE,a0
		move.b	(a0),d1
		moveq	#0,d0
		move.b	d1,d0
		moveq	#9,d1
		cmp.l	d1,d0
		beq.s	loc_FC7A
		moveq	#$A,d1
		cmp.l	d1,d0
		beq.s	loc_FC7A
		moveq	#$B,d1
		cmp.l	d1,d0
		beq.s	loc_FC7A
		moveq	#$C,d1
		cmp.l	d1,d0
		beq.s	loc_FC7A
		moveq	#$D,d1
		cmp.l	d1,d0
		beq.s	loc_FC7A
		bra.s	loc_FCD6
; ---------------------------------------------------------------------------

loc_FC7A:				; CODE XREF: InitializeCommon+20j
					; InitializeCommon+26j	...
		tst.w	d4
		bne.s	loc_FCCC
		moveq	#$FFFFFFFE,d0
		movea.l	d0,a0
		move.b	#6,(a0)
		moveq	#$FFFFFFFA,d0
		movea.l	d0,a0
		move.w	#$A0A,(a0)
		moveq	#0,d3
		moveq	#$FFFFFFE4,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFE0,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFDC,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFD8,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFD4,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFD0,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFCC,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFC8,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFC4,d0
		movea.l	d0,a0
		move.l	d3,(a0)
		moveq	#$FFFFFFC0,d0
		movea.l	d0,a0
		move.l	d3,(a0)

loc_FCCC:				; CODE XREF: InitializeCommon+3Ej
		move.l	#$FFFFF7E1,-$DA8(a5)
		bra.s	loc_FCDE
; ---------------------------------------------------------------------------

loc_FCD6:				; CODE XREF: InitializeCommon+3Aj
		move.l	#$40001,-$DA8(a5)

loc_FCDE:				; CODE XREF: InitializeCommon+96j
		move.l	#$40001,-$DAC(a5)
		move.w	d4,d1
		moveq	#0,d0
		move.w	d1,d0
		tst.l	d0
		beq.s	loc_FCF8
		moveq	#1,d1
		cmp.l	d1,d0
		beq.s	loc_FD12
		bra.s	loc_FD38
; ---------------------------------------------------------------------------

loc_FCF8:				; CODE XREF: InitializeCommon+B0j
		move.l	#$50001,-$DB0(a5)
		move.l	#$58001,-$DB4(a5)
		move.l	#$26000,-$DB8(a5)
		bra.s	loc_FD38
; ---------------------------------------------------------------------------

loc_FD12:				; CODE XREF: InitializeCommon+B6j
		move.l	#$60001,-$DB0(a5)
		move.l	#$68001,-$DB4(a5)
		move.l	#$24000,-$DB8(a5)
		moveq	#$10,d0
		sub.l	d0,-$DA8(a5)
		move.l	#$DCBA,-$D1C(a5)

loc_FD38:				; CODE XREF: InitializeCommon+B8j
					; InitializeCommon+D2j
		move.l	a5,d0
		move.l	d0,-(sp)
		jsr	(Free).l
		addq.w	#4,sp
		jsr	Trace
		jsr	dl_user_disconnect_indication
		tst.w	d4
		bne.s	loc_FD5A
		jsr	(UartTimer).l

loc_FD5A:				; CODE XREF: InitializeCommon+114j
		jsr	(ph_loop_off).l
		move.w	d4,-(sp)
		jsr	(SetupHscx).l
		addq.w	#2,sp
		jsr	(ModemResponse).l
		jsr	(monitor_voice_indication).l
		jsr	addresserror
		movem.l	(sp)+,d3-d4
		unlk	a6
		rts
; End of function InitializeCommon

; ---------------------------------------------------------------------------
aInitializexl:	dc.b 140,'InitializeXL',0,0,0

; =============== S U B	R O U T	I N E =======================================

; Attributes: noreturn bp-based	frame

InitializeXL:				; CODE XREF: exc_BusError+18j
					; exc_AddressError+18j	...
		link	a6,#0
		move.l	d3,-(sp)
		lea	(InitializeXL).l,a0
		move.l	a0,-$D20(a5)
		jsr	(WritePString).l
		move.l	-$10(a5),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		moveq	#$3A,d3	; ':'
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	-$C(a5),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		pea	(asc_FE31+1)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.l	-8(a5),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		move.b	d3,-(sp)
		jsr	(WriteUnexpected).l
		addq.w	#2,sp
		move.l	-4(a5),-(sp)
		jsr	(WriteChar).l
		addq.w	#4,sp
		jsr	(WritePString).l
		clr.l	-(sp)
		pea	(dl_user_connect_indication).l
		jsr	(SendEvent).l
		addq.w	#8,sp
		move	sr,d0
		ori	#$700,sr
		andi.w	#$F0FF,d0
		move	d0,sr
		jsr	(IdleEvent).l
; End of function InitializeXL

; ---------------------------------------------------------------------------
		move.l	(sp)+,d3
		unlk	a6
		rts
; ---------------------------------------------------------------------------
aMain:		dc.b 132,'main',0,0
asc_FE31:	dc.b 4,' - ',0          ; DATA XREF: InitializeXL+3Ao
		dc.b '"/',0
		dc.b 4,' /',0,8
; ---------------------------------------------------------------------------

main:					; CODE XREF: sendframe+7Ep
					; SendRRPoll+B0p ...
		lea	loc_FE4A,a0
		movea.w	#2,a1
; ---------------------------------------------------------------------------
		dc.b $4E ; N
		dc.b $F0 ; ð
		dc.b $92 ; ’
		dc.b $FE ; þ
; ---------------------------------------------------------------------------

loc_FE4A:				; DATA XREF: ROM:maino
		bra.s	loc_FE52
; ---------------------------------------------------------------------------
		dc.b $4C ; L
		dc.b $41 ; A
		dc.b   8
		dc.b   1
; ---------------------------------------------------------------------------
		rts
; ---------------------------------------------------------------------------

loc_FE52:				; CODE XREF: ROM:loc_FE4Aj
		jsr	sub_FE78
		move.l	d1,d0
		rts
; ---------------------------------------------------------------------------
		move.l	4(sp),d1
		move.l	8(sp),d0
		lea	loc_FE6E,a0
		movea.w	#2,a1
; ---------------------------------------------------------------------------
		dc.b $4E ; N
		dc.b $F0 ; ð
		dc.b $92 ; ’
		dc.b $FE ; þ
; ---------------------------------------------------------------------------

loc_FE6E:				; DATA XREF: ROM:0000FE62o
		bra.s	sub_FE78
; ---------------------------------------------------------------------------
		dc.b $4C ; L
		dc.b $41 ; A
		dc.b   8
		dc.b   1
; ---------------------------------------------------------------------------
		exg	d1,d0
		rts

; =============== S U B	R O U T	I N E =======================================


sub_FE78:				; CODE XREF: ROM:loc_FE52p
					; ROM:loc_FE6Ej
		tst.l	d0
		bmi.s	loc_FE90
		tst.l	d1
		bmi.s	loc_FE86
		jsr	sub_FEC8
		rts
; ---------------------------------------------------------------------------

loc_FE86:				; CODE XREF: sub_FE78+6j
		neg.l	d1
		jsr	sub_FEC8
		neg.l	d1
		rts
; ---------------------------------------------------------------------------

loc_FE90:				; CODE XREF: sub_FE78+2j
		neg.l	d0
		tst.l	d1
		bmi.s	loc_FEA0
		jsr	sub_FEC8
		neg.l	d0
		neg.l	d1
		rts
; ---------------------------------------------------------------------------

loc_FEA0:				; CODE XREF: sub_FE78+1Cj
		neg.l	d1
		jsr	sub_FEC8
		neg.l	d0
		rts
; End of function sub_FE78

; ---------------------------------------------------------------------------
		move.l	4(sp),d1
		move.l	8(sp),d0
		lea	loc_FEBE,a0
		movea.w	#2,a1
; ---------------------------------------------------------------------------
		dc.b $4E ; N
		dc.b $F0 ; ð
		dc.b $92 ; ’
		dc.b $FE ; þ
; ---------------------------------------------------------------------------

loc_FEBE:				; DATA XREF: ROM:0000FEB2o
		bra.s	sub_FEC8
; ---------------------------------------------------------------------------
		dc.b $4C ; L
		dc.b $41 ; A
		dc.b   0
		dc.b   1
; ---------------------------------------------------------------------------
		exg	d1,d0
		rts

; =============== S U B	R O U T	I N E =======================================


sub_FEC8:				; CODE XREF: sub_FE78+8p sub_FE78+10p	...
		move.w	d1,-(sp)
		swap	d1
		tst.w	d1
		bne.s	loc_FEEC
		move.l	d0,d1
		clr.w	d1
		swap	d1
		beq.s	loc_FEE2
		divu.w	(sp),d1
		swap	d1
		swap	d0
		move.w	d1,d0
		swap	d0

loc_FEE2:				; CODE XREF: sub_FEC8+Ej
		divu.w	(sp)+,d0
		move.w	d0,d1
		clr.w	d0
		swap	d0
		rts
; ---------------------------------------------------------------------------

loc_FEEC:				; CODE XREF: sub_FEC8+6j
		swap	d1
		move.w	d2,(sp)
		move.l	d3,-(sp)
		move.w	d0,d2
		move.l	d1,d3
		moveq	#1,d1
		clr.w	d0
		swap	d0
		bne.s	loc_FF0A
		swap	d0
		move.w	d2,d0
		moveq	#0,d1
		bra.s	loc_FF1C
; ---------------------------------------------------------------------------

loc_FF06:				; CODE XREF: sub_FEC8+48j
		add.w	d1,d1
		bcs.s	loc_FF1C

loc_FF0A:				; CODE XREF: sub_FEC8+34j sub_FEC8+52j
		add.w	d2,d2
		addx.l	d0,d0
		cmp.l	d3,d0
		bcs.s	loc_FF06
		sub.l	d3,d0
		add.w	d1,d1
		bset	#0,d1
		bcc.s	loc_FF0A

loc_FF1C:				; CODE XREF: sub_FEC8+3Cj sub_FEC8+40j
		move.l	(sp)+,d3
		move.w	(sp)+,d2
		rts
; End of function sub_FEC8


; =============== S U B	R O U T	I N E =======================================


sub_FF22:				; CODE XREF: initial_PC+34p
					; initial_PC+58p ...
		jsr	sub_FF5E
		addi.l	#$20,d0	; ' '
		rts
; End of function sub_FF22


; =============== S U B	R O U T	I N E =======================================


sub_FF2E:				; CODE XREF: initial_PC+3Ep
					; initial_PC+62p ...

arg_0		=  4

		move.l	a5,-(sp)
		move.l	a5,d0
		btst	#0,d0
		bne.s	loc_FF44
		movea.l	4+arg_0(sp),a0
		moveq	#7,d0

loc_FF3E:				; CODE XREF: sub_FF2E+12j
		move.l	(a5)+,(a0)+
		dbf	d0,loc_FF3E

loc_FF44:				; CODE XREF: sub_FF2E+8j
		movea.l	4+arg_0(sp),a5
		jsr	sub_FF66
		movea.l	(sp)+,a5
		rts
; End of function sub_FF2E

; ---------------------------------------------------------------------------
		move.l	a5,d0
		movea.l	4(sp),a5
		rts
; ---------------------------------------------------------------------------
		movea.l	4(sp),a5
		rts

; =============== S U B	R O U T	I N E =======================================


sub_FF5E:				; CODE XREF: sub_FF22p
		lea	off_10114,a0
		move.l	(a0),d0
		rts
; End of function sub_FF5E


; =============== S U B	R O U T	I N E =======================================


sub_FF66:				; CODE XREF: sub_FF2E+1Ap
		movem.l	d1-a4,-(sp)
		lea	$10114,a4
		move.w	UserInterrupt_0x118-off_10114(a4),d0
		subq.w	#1,d0
		beq.s	loc_FF7A
		moveq	#$FFFFFFFF,d0
		bra.s	loc_FFAC
; ---------------------------------------------------------------------------

loc_FF7A:				; CODE XREF: sub_FF66+Ej
		movea.l	a5,a3
		suba.l	(a4),a3
		move.l	a3,-(sp)
		move.l	(a4),-(sp)
		bsr.w	relocate_world
		move.l	8(a4),d0
		pea	(a4,d0.l)
		move.l	a3,-(sp)
		bsr.w	_DATAINIT
		addq.w	#8,sp
		move.l	$C(a4),d0
		pea	(a4,d0.l)
		move.l	a3,-(sp)
		move.l	a5,-(sp)
		bsr.w	get_rl
		lea	$C(sp),sp
		moveq	#0,d0

loc_FFAC:				; CODE XREF: sub_FF66+12j
		movem.l	(sp)+,d1-a4
		rts
; End of function sub_FF66

; ---------------------------------------------------------------------------
a_datainit:	dc.b 128,9,'_DATAINIT',0,0,0

; =============== S U B	R O U T	I N E =======================================


_DATAINIT:				; CODE XREF: sub_FF66+2Ap

arg_0		=  4
arg_4		=  8

		movea.l	arg_0(sp),a1
		movea.l	arg_4(sp),a0
		movem.l	d3-d4,-(sp)

loc_FFCC:				; CODE XREF: _DATAINIT+44j
		moveq	#1,d3
		moveq	#0,d1
		move.b	(a0)+,d1
		move.l	d1,d2
		andi.w	#$F,d1
		bne.s	loc_FFE4
		bsr.w	uncompress_world
		move.l	d0,d1
		beq.s	loc_10006
		bra.s	loc_FFE6
; ---------------------------------------------------------------------------

loc_FFE4:				; CODE XREF: _DATAINIT+18j
		add.w	d1,d1

loc_FFE6:				; CODE XREF: _DATAINIT+22j
		andi.w	#$F0,d2	; 'ð'
		bne.s	loc_FFF4
		bsr.w	uncompress_world
		move.l	d0,d2
		bra.s	loc_FFF6
; ---------------------------------------------------------------------------

loc_FFF4:				; CODE XREF: _DATAINIT+2Aj
		lsr.w	#3,d2

loc_FFF6:				; CODE XREF: _DATAINIT+32j
					; _DATAINIT+42j
		adda.l	d2,a1
		move.l	d1,d4

loc_FFFA:				; CODE XREF: _DATAINIT+3Ej
		move.b	(a0)+,(a1)+
		subq.l	#1,d4
		bne.s	loc_FFFA
		subq.l	#1,d3
		bne.s	loc_FFF6
		bra.s	loc_FFCC
; ---------------------------------------------------------------------------

loc_10006:				; CODE XREF: _DATAINIT+20j
		movem.l	(sp)+,d3-d4
		rts
; End of function _DATAINIT

; ---------------------------------------------------------------------------
aUncompress_world:dc.b 128,$10,'uncompress_world',0,0

; =============== S U B	R O U T	I N E =======================================


uncompress_world:			; CODE XREF: _DATAINIT+1Ap
					; _DATAINIT+2Cp ...
		moveq	#0,d0
		move.b	(a0)+,d0
		bpl.s	locret_10068
		btst	#6,d0
		beq.s	loc_10060
		btst	#5,d0
		beq.s	loc_10052
		btst	#4,d0
		beq.s	loc_10042
		bsr.s	uncompress_world
		move.l	d0,d3
		bsr.s	uncompress_world
		exg	d0,d3
		rts
; ---------------------------------------------------------------------------

loc_10042:				; CODE XREF: uncompress_world+16j
		move.b	(a0)+,d0
		asl.l	#8,d0
		move.b	(a0)+,d0
		asl.l	#8,d0
		move.b	(a0)+,d0
		asl.l	#8,d0
		move.b	(a0)+,d0
		rts
; ---------------------------------------------------------------------------

loc_10052:				; CODE XREF: uncompress_world+10j
		andi.b	#$1F,d0
		asl.l	#8,d0
		move.b	(a0)+,d0
		asl.l	#8,d0
		move.b	(a0)+,d0
		rts
; ---------------------------------------------------------------------------

loc_10060:				; CODE XREF: uncompress_world+Aj
		andi.b	#$3F,d0	; '?'
		asl.l	#8,d0
		move.b	(a0)+,d0

locret_10068:				; CODE XREF: uncompress_world+4j
		rts
; End of function uncompress_world

; ---------------------------------------------------------------------------
aGet_rl:	dc.b 128,6,'get_rl',0,0

; =============== S U B	R O U T	I N E =======================================


get_rl:					; CODE XREF: sub_FF66+3Cp

arg_0		=  4
arg_4		=  8
arg_8		=  $C

		move.l	arg_0(sp),d1
		movea.l	arg_4(sp),a1
		movea.l	arg_8(sp),a0

loc_10080:				; CODE XREF: get_rl+46j
		moveq	#1,d2
		moveq	#0,d0
		move.b	(a0)+,d0
		beq.s	loc_10094
		bpl.s	loc_100B0
		bclr	#7,d0
		lsl.l	#8,d0
		move.b	(a0)+,d0
		bra.s	loc_100B0
; ---------------------------------------------------------------------------

loc_10094:				; CODE XREF: get_rl+12j
		move.b	(a0)+,d0
		beq.s	locret_100BC
		bpl.s	loc_100A8
		lsl.l	#8,d0
		move.b	(a0)+,d0
		lsl.l	#8,d0
		move.b	(a0)+,d0
		lsl.l	#8,d0
		move.b	(a0)+,d0
		bra.s	loc_100B0
; ---------------------------------------------------------------------------

loc_100A8:				; CODE XREF: get_rl+24j
		move.l	d0,d2
		bsr.w	uncompress_world
		exg	d0,d2

loc_100B0:				; CODE XREF: get_rl+14j get_rl+1Ej ...
		add.l	d0,d0

loc_100B2:				; CODE XREF: get_rl+44j
		adda.l	d0,a1
		add.l	d1,(a1)
		subq.l	#1,d2
		bne.s	loc_100B2
		bra.s	loc_10080
; ---------------------------------------------------------------------------

locret_100BC:				; CODE XREF: get_rl+22j
		rts
; End of function get_rl

; ---------------------------------------------------------------------------
aRelocate_world:dc.b 128,$E,'relocate_world',0,0

; =============== S U B	R O U T	I N E =======================================


relocate_world:				; CODE XREF: sub_FF66+1Cp
		moveq	#0,d2
		movea.l	(sp)+,a0
		move.l	(sp)+,d0
		movea.l	(sp)+,a1
		beq.s	loc_10102

loc_100DA:				; CODE XREF: relocate_world+16j
		move.w	a1,d1
		andi.w	#3,d1
		beq.s	loc_100EA
		move.b	d2,(a1)+
		subq.l	#1,d0
		bne.s	loc_100DA
		bra.s	loc_10102
; ---------------------------------------------------------------------------

loc_100EA:				; CODE XREF: relocate_world+10j
		move.l	d0,d1
		lsr.l	#2,d1
		beq.s	loc_100F6

loc_100F0:				; CODE XREF: relocate_world+24j
		move.l	d2,(a1)+
		subq.l	#1,d1
		bne.s	loc_100F0

loc_100F6:				; CODE XREF: relocate_world+1Ej
		andi.w	#3,d0
		bra.s	loc_100FE
; ---------------------------------------------------------------------------

loc_100FC:				; CODE XREF: relocate_world:loc_100FEj
		move.b	d2,(a1)+

loc_100FE:				; CODE XREF: relocate_world+2Aj
		dbf	d0,loc_100FC

loc_10102:				; CODE XREF: relocate_world+8j
					; relocate_world+18j
		jmp	(a0)
; End of function relocate_world

; ---------------------------------------------------------------------------
aZerobuffer:	dc.b 128,$A
		dc.b 'ZEROBUFFER',0,0,0,0
off_10114:	dc.l loc_1314		; DATA XREF: sub_FF5Eo
word_10118:	dc.w 1			; DATA XREF: sub_FF66+8r
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b $14
		dc.b   0
		dc.b   0
		dc.b  $D
		dc.b $43 ; C
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   4
		dc.b   0
aLeovoice:	dc.b 'LeoVoice'
		dc.b $11
aOk:		dc.b 'OK'
		dc.b $16
aConnect:	dc.b 'CONNECT'
		dc.b   0
aRing:		dc.b 'RING'
		dc.b $15
aNo:		dc.b 'NO'
		dc.b $20
aCarrier:	dc.b 'CARRIER'
		dc.b $1E
aError:		dc.b 'ERROR'
		dc.b   0
aFcon:		dc.b '+FCON'
		dc.b   0
aNo_0:		dc.b 'NO'
		dc.b $20
aDialtone:	dc.b 'DIALTONE'
		dc.b   0
aBusy:		dc.b 'BUSY'
		dc.b $10
a6no:		dc.b '6NO'
		dc.b $20
aAnswer:	dc.b 'ANSWER'
		dc.b   0
aFhng:		dc.b '+FHNG:'
		dc.b $20
		dc.b   0
aModem:		dc.b 'Modem'
		dc.b   0
aDeactivated:	dc.b 'Deactivated'
		dc.b   0
aActivate:	dc.b 'Activate'
		dc.b $20
aRequested:	dc.b 'Requested'
		dc.b $10
a2deactivate:	dc.b '2Deactivate'
		dc.b $20
aIndication:	dc.b 'Indication'
		dc.b   0
aActivated:	dc.b 'Activated'
		dc.b   0
aDeactivate:	dc.b 'Deactivate'
		dc.b $20
aRequest:	dc.b 'request'
		dc.b $10
aV?1:		dc.b 'V? 1'
		dc.b   0
aTestModeAcknowlegde:dc.b 'Test Mode Acknowlegde'
		dc.b   0
a?3:		dc.b '? 3'
		dc.b   0
aSignalOutOfSynch:dc.b 'Signal out of synch'
		dc.b   0
a?5:		dc.b '? 5'
		dc.b   0
aInterruptPinActivated:dc.b 'Interrupt Pin activated'
		dc.b   0
aPowerUp:	dc.b 'Power up'
		dc.b $19
aActivationRequest:dc.b	'Activation request'
		dc.b $1F
aActivationRequestRemoteLoop:dc.b 'Activation request remote loop'
		dc.b $10
aActivationRequestLocalLoop:dc.b '"Activation request local loop'
		dc.b   0
a?11:		dc.b '? 11'
		dc.b $10
aXactivationIndication:dc.b 'XActivation indication'
		dc.b   0
aActivationIndicationRemoteLoop:dc.b 'Activation indication remote loop'
		dc.b   0
aActivationIndicationLocalLoop:dc.b 'Activation indication local loop'
		dc.b $10
aLdeactivateConfirmation:dc.b 'LDeactivate confirmation'
		dc.b   0
aTooManyInterruptsProcessedButNo:dc.b 'too many interrupts, processed but not traced'
		dc.b   0
aLoopA:		dc.b 'Loop A'
		dc.b $13
aLoopB:		dc.b 'Loop B'
		dc.b $19
aD:		dc.b 'D'
		dc.b $14
aH:		dc.b 'H'
		dc.b $FF
aJ:		dc.b 'J'
		dc.b $FF
aN_0:		dc.b 'N'
		dc.b $FF
		dc.b $44 ; D
		dc.b $E4 ; ä
aOff:		dc.b 'Off'
		dc.b   0
aHunt:		dc.b 'Hunt'
		dc.b $12
aHdlc:		dc.b 'Hdlc'
		dc.b $17
aLeo:		dc.b 'Leo'
		dc.b   0
aX75:		dc.b 'X75'
		dc.b   0
aLeo1st:	dc.b 'Leo1st'
		dc.b $13
aLeo2nd:	dc.b 'Leo2nd'
		dc.b $10
a_octet:	dc.b '.Octet'
		dc.b   0
aV_110:		dc.b 'V.110'
		dc.b   0
aPhysical_layer_down:dc.b 'PHYSICAL_LAYER_DOWN'
		dc.b   0
aTei_unassigned:dc.b 'TEI_UNASSIGNED'
		dc.b $10
aAssign_awaiting_tei:dc.b '*ASSIGN_AWAITING_TEI'
		dc.b   0
aEstablish_awaiting_tei:dc.b 'ESTABLISH_AWAITING_TEI'
		dc.b $16
aTei_assigned:	dc.b 'TEI_ASSIGNED'
		dc.b $1B
aAwaiting_establishment:dc.b 'AWAITING_ESTABLISHMENT'
		dc.b $18
aAwaiting_release:dc.b 'AWAITING_RELEASE'
		dc.b $1B
aMultiframe_established:dc.b 'MULTIFRAME_ESTABLISHED'
		dc.b $17
aTimer_recovery:dc.b 'TIMER_RECOVERY'
		dc.b $1C
aUnknown:	dc.b 'UNKNOWN'
		dc.b   0
aRequest_0:	dc.b 'REQUEST'
		dc.b   0
aAssigned:	dc.b 'ASSIGNED'
		dc.b $13
aDenied:	dc.b 'DENIED'
		dc.b $1E
aCheckRequest:	dc.b 'CHECK REQUEST'
		dc.b   0
aCheckResponse:	dc.b 'CHECK RESPONSE'
		dc.b $10
		dc.b $F0 ; ð
		dc.b   6
		dc.b   2
aRemoveverify:	dc.b 'REMOVEVERIFY'
		dc.b $12
aNull:		dc.b 'NULL'
		dc.b $17
aCall_initiated:dc.b 'CALL_INITIATED'
		dc.b $10
a_overlap_sending:dc.b '.OVERLAP_SENDING'
		dc.b   0
aCall_proceeding:dc.b 'CALL_PROCEEDING'
		dc.b   0
aCall_delivered:dc.b 'CALL_DELIVERED'
		dc.b $16
aCall_present:	dc.b 'CALL_PRESENT'
		dc.b $1F
aCall_received:	dc.b 'CALL_RECEIVED'
		dc.b   0
aConnnect_request:dc.b 'CONNNECT_REQUEST'
		dc.b $13
aActive:	dc.b 'ACTIVE'
		dc.b $19
aDisconnect_request:dc.b 'DISCONNECT_REQUEST'
		dc.b $10
a4disconnect_indication:dc.b '4DISCONNECT_INDICATION'
		dc.b   0
aRelease_request:dc.b 'RELEASE_REQUEST'
		dc.b   0
aCall_requested:dc.b 'CALL_REQUESTED'
		dc.b $10
		dc.b $F0 ; ð
		dc.b   8
		dc.b   7
		dc.b $82 ; ‚
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $41 ; A
		dc.b $20
		dc.b $BB ; »
		dc.b $83 ; ƒ
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $42 ; B
		dc.b $20
		dc.b $BB ; »
		dc.b $84 ; „
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $43 ; C
		dc.b $20
		dc.b $BB ; »
		dc.b $85 ; …
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $45 ; E
		dc.b $20
		dc.b $BB ; »
		dc.b $86 ; †
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $48 ; H
		dc.b $40 ; @
		dc.b $BB ; »
		dc.b $87 ; ‡
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $21 ; !
		dc.b $4B ; K
		dc.b $60 ; `
		dc.b $BB ; »
		dc.b $88 ; ˆ
		dc.b   6
		dc.b $88 ; ˆ
		dc.b $90 ; 
		dc.b $27 ; '
		dc.b $4D ; M
		dc.b   0
		dc.b $BB ; »
		dc.b $10
		dc.b $20
aNilEvent:	dc.b '(nil) event'
		dc.b   0
aUnexpectedInterrupt:dc.b 'Unexpected Interrupt'
		dc.b $10
aFbusError:	dc.b 'FBus Error'
		dc.b   0
aAddressError:	dc.b 'Address Error'
		dc.b   0
aIllegalInstructionError:dc.b 'Illegal Instruction Error'
		dc.b   0
aDivideByZeroError:dc.b	'Divide by Zero Error'
		dc.b $10
aCheckException:dc.b '"Check Exception'
		dc.b   0
aOverflowException:dc.b	'Overflow Exception'
		dc.b $10
a0privilegeError:dc.b '0Privilege Error'
		dc.b   0
aTraceException:dc.b 'Trace Exception'
		dc.b   0
aLineAException:dc.b 'Line A Exception'
		dc.b $18
aLineFException:dc.b 'Line F Exception'
		dc.b $10
aVersion:	dc.b '*Version'
		dc.b   0
a6_5_9b1:	dc.b '6.5.9b1'
		dc.b   0
aBuild:		dc.b 'Build'
		dc.b   0
aJul25190120801:dc.b 'Jul 25 19:0 12:08:01'
		dc.b   0
		dc.b   1
; ---------------------------------------------------------------------------
		move.b	(a0),-(a5)
		ori.b	#$64,d1	; 'd'
		ori.b	#$20,d1	; ' '
		ori.b	#8,d1
		ori.b	#$A0,d1
		ori.b	#$26,d1	; '&'
		subq.b	#8,d1
		bra.w	loc_1077C+1
; ---------------------------------------------------------------------------
		eori.w	#$580,(a1)
		ori.b	#3,d1
		subq.b	#8,(a0)
		or.b	d0,d0
		btst	d0,d3
		cmpi.b	#$34,d0	; '4'
		negx.b	d0
		btst	d0,d0
		btst	d0,d2
		ori.b	#0,d1
		btst	d0,d2
		ori.b	#3,d2
		btst	d1,d3
		movep.w	$301(a6),d1
		btst	d0,d1
		andi.b	#3,d2
		btst	d1,d0
		btst	d0,d2
		btst	d1,(a4)
		cmp.l	-(a3),d5
; ---------------------------------------------------------------------------
		dc.b $2C ; ,
		dc.b $B3 ; ³
		dc.b $A2 ; ¢
		dc.b $C3 ; Ã
; ---------------------------------------------------------------------------
		and.b	-(a3),d6
		move.l	-(a3),-(a5)
; ---------------------------------------------------------------------------
		dc.b $A1 ; ¡
		dc.b $13
		dc.b $AC ; ¬
		dc.b $B2 ; ²
		dc.b $C1 ; Á
		dc.b $22 ; "
		dc.b $FF
		dc.b $FF
		dc.b $EC ; ì
		dc.b $EC ; ì
		dc.b $21 ; !
		dc.b $E0 ; à
		dc.b $F0 ; ð
		dc.b $12
		dc.b $10
		dc.b $10
		dc.b   0
		dc.b   3
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   8
		dc.b $13
		dc.b $48 ; H
		dc.b $14
		dc.b $24 ; $
		dc.b $14
		dc.b $44 ; D
		dc.b $14
		dc.b $78 ; x
		dc.b $12
		dc.b $CE ; Î
		dc.b  $F
		dc.b $2E ; .
		dc.b  $F
		dc.b $2E ; .
		dc.b $E8 ; è
		dc.b $D2 ; Ò
		dc.b $10
		dc.b   3
		dc.b $F3 ; ó
		dc.b $DE ; Þ
		dc.b $A1 ; ¡
		dc.b $1E
		dc.b $24 ; $
		dc.b   9
		dc.b   0
		dc.b   2
		dc.b $10
		dc.b   0
		dc.b  $B
		dc.b $C9 ; É
		dc.b $9B ; ›
		dc.b $A1 ; ¡
		dc.b $10
		dc.b   0
		dc.b $11
		dc.b   9
		dc.b $12
		dc.b $A0 ;  
		dc.b $15
		dc.b $60 ; `
		dc.b $16
		dc.b $30 ; 0
		dc.b $25 ; %
		dc.b $10
		dc.b $D0 ; Ð
		dc.b $10
		dc.b   0
		dc.b $27 ; '
		dc.b $88 ; ˆ
		dc.b $71 ; q
		dc.b   0
		dc.b $3B ; ;
		dc.b $1B
		dc.b $FF
		dc.b $FF
		dc.b $EC ; ì
		dc.b $F6 ; ö
		dc.b $FF
		dc.b $FF
		dc.b $EC ; ì
		dc.b $FA ; ú
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b   2
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b   8
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $14
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $1A
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $20
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $2C ; ,
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $32 ; 2
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $3C ; <
		dc.b  $E
		dc.b   2
		dc.b   0
		dc.b $65 ; e
		dc.b   0
		dc.b   4
		dc.b   5
		dc.b  $E
		dc.b   8
		dc.b   0
		dc.b $76 ; v
		dc.b   0
		dc.b   7
		dc.b   0
		dc.b $15
		dc.b $80 ; €
		dc.b $80 ; €
		dc.b $79 ; y
		dc.b $31 ; 1
		dc.b $10
		dc.b $F0 ; ð
		dc.b  $C
		dc.b   2
		dc.b $17
		dc.b   1
		dc.b   0
		dc.b $26 ; &
		dc.b $74 ; t
		dc.b $35 ; 5
		dc.b   0
		dc.b $17
		dc.b $80 ; €
		dc.b   0
		dc.b $26 ; &
		dc.b $67 ; g
		dc.b $1B
		dc.b  $B
		dc.b  $A
		dc.b $26 ; &
		dc.b $71 ; q
		dc.b $36 ; 6
		dc.b   0
		dc.b $1B
		dc.b $40 ; @
		dc.b $40 ; @
		dc.b $62 ; b
		dc.b $31 ; 1
		dc.b $12
		dc.b $1F
		dc.b   2
		dc.b   0
		dc.b $6E ; n
		dc.b   0
		dc.b $28 ; (
		dc.b   3
		dc.b $27 ; '
		dc.b   7
		dc.b   3
		dc.b $26 ; &
		dc.b $6B ; k
		dc.b $33 ; 3
		dc.b   0
		dc.b $27 ; '
		dc.b   7
		dc.b   4
		dc.b $26 ; &
		dc.b $6B ; k
		dc.b $34 ; 4
		dc.b   0
		dc.b $28 ; (
		dc.b $C0 ; À
		dc.b   0
		dc.b $5C ; \
		dc.b $61 ; a
		dc.b $30 ; 0
		dc.b   0
		dc.b $28 ; (
		dc.b $C0 ; À
		dc.b $80 ; €
; ---------------------------------------------------------------------------

loc_1077C:				; CODE XREF: ROM:00010678j
		addq.w	#6,-(a1)
		move.w	d0,d1
		move.l	d0,(a4)+
		and.w	(a4)+,d0
		bsr.s	unk_107B9
		ori.b	#0,$2563(a1)
; ---------------------------------------------------------------------------
		dc.b $10
		dc.b $44 ; D
; ---------------------------------------------------------------------------
		move.l	d3,-(a4)
		btst	d0,-(a5)
		bls.s	unk_107C5
		ori.b	#1,$2563(a1)
		move.w	d0,d1
		move.l	d4,$425(a4)
		bcs.s	unk_107D3
		ori.b	#$40,$2565(a1) ; '@'
		move.w	d0,d1
		move.l	a0,-(a4)
; ---------------------------------------------------------------------------
		dc.b   8
		dc.b $5C ; \
		dc.b $67 ; g
		dc.b   0
		dc.b $70 ; p
		dc.b $29 ; )
		dc.b $10
		dc.b $10
		dc.b $5C ; \
		dc.b $6C ; l
		dc.b $31 ; 1
		dc.b   0
		dc.b   7
unk_107B9:	dc.b $32 ; 2		; CODE XREF: ROM:00010784p
		dc.b   9
		dc.b   6
		dc.b  $A
		dc.b  $E
		dc.b $1E
		dc.b   0
		dc.b $20
		dc.b $11
		dc.b $21 ; !
		dc.b $13
		dc.b $24 ; $
unk_107C5:	dc.b   7		; CODE XREF: ROM:00010792j
		dc.b $25 ; %
		dc.b   0
		dc.b $26 ; &
		dc.b $14
		dc.b $2E ; .
		dc.b $8A ; Š
		dc.b $30 ; 0
		dc.b   7
		dc.b   0
		dc.b   5
		dc.b   0
		dc.b   2
		dc.b $30 ; 0
unk_107D3:	dc.b $19		; CODE XREF: ROM:000107A0j
		dc.b $B1 ; ±
		dc.b $10
		dc.b   0
		dc.b $11
		dc.b $53 ; S
		dc.b $12
		dc.b $A0 ;  
		dc.b $15
		dc.b $22 ; "
		dc.b $16
		dc.b $30 ; 0
		dc.b $25 ; %
		dc.b $33 ; 3
		dc.b $9B ; ›
		dc.b $27 ; '
		dc.b   0
		dc.b   1
		dc.b $26 ; &
		dc.b $A2 ; ¢
		dc.b $AA ; ª
		dc.b $91 ; ‘
		dc.b $C4 ; Ä
		dc.b $10
		dc.b $4F ; O
		dc.b $2F ; /
		dc.b   0
		dc.b   5
		dc.b   5
		dc.b $38 ; 8
		dc.b $36 ; 6
		dc.b $34 ; 4
		dc.b $32 ; 2
		dc.b $30 ; 0
		dc.b   2
		dc.b   5
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $44 ; D
		dc.b $21 ; !
		dc.b $C0 ; À
		dc.b $F0 ; ð
		dc.b $10
		dc.b   3
		dc.b   8
		dc.b   8
		dc.b   1
		dc.b   1
		dc.b   3
		dc.b $25 ; %
		dc.b $50 ; P
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   8
		dc.b $26 ; &
		dc.b $28 ; (
		dc.b $26 ; &
		dc.b $48 ; H
		dc.b $27 ; '
		dc.b $2A ; *
		dc.b $27 ; '
		dc.b $C4 ; Ä
		dc.b $28 ; (
		dc.b $BA ; º
		dc.b $E8 ; è
		dc.b $28 ; (
		dc.b $E8 ; è
		dc.b $D2 ; Ò
		dc.b $F3 ; ó
		dc.b $DE ; Þ
		dc.b   0
		dc.b $20
		dc.b $81 ; 
		dc.b  $A
		dc.b $1A
		dc.b   0
		dc.b   8
		dc.b $E0 ; à
		dc.b $14
		dc.b  $A
		dc.b $12
		dc.b $DD ; Ý
		dc.b $14
		dc.b $10
		dc.b $10
		dc.b $33 ; 3
		dc.b $10
		dc.b  $F
		dc.b   4
		dc.b  $A
		dc.b   2
		dc.b $DD ; Ý
		dc.b   4
		dc.b $10
		dc.b   0
		dc.b $33 ; 3
		dc.b   0
		dc.b   7
		dc.b $18
		dc.b $1E
		dc.b  $C
		dc.b   0
		dc.b  $E
		dc.b   3
		dc.b  $A
		dc.b $33 ; 3
		dc.b $C0 ; À
		dc.b $72 ; r
		dc.b $72 ; r
		dc.b $88 ; ˆ
		dc.b $76 ; v
		dc.b $2F ; /
		dc.b $46 ; F
		dc.b $E0 ; à
		dc.b $6E ; n
		dc.b $70 ; p
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   2
		dc.b $50 ; P
		dc.b $FF
		dc.b $52 ; R
		dc.b $FF
		dc.b $48 ; H
		dc.b   0
		dc.b $4A ; J
		dc.b $FF
		dc.b $44 ; D
		dc.b $C9 ; É
		dc.b $40 ; @
		dc.b   0
		dc.b $42 ; B
		dc.b $51 ; Q
		dc.b $62 ; b
		dc.b $23 ; #
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $4A ; J
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $56 ; V
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $6A ; j
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $80 ; €
		dc.b $10
		dc.b   0
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $8A ; Š
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $9E ; ž
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $A2 ; ¢
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $B8 ; ¸
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $BC ; ¼
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $D0 ; Ð
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $D4 ; Ô
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $EC ; ì
		dc.b $FF
		dc.b $FF
		dc.b $ED ; í
		dc.b $F6 ; ö
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b  $A
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $2A ; *
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $48 ; H
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $4E ; N
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $64 ; d
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $86 ; †
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $A8 ; ¨
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $C0 ; À
		dc.b $32 ; 2
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $EE ; î
		dc.b   0
		dc.b $F0 ; ð
		dc.b   1
		dc.b   2
		dc.b   5
		dc.b $FF
		dc.b   3
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   9
		dc.b $39 ; 9
		dc.b $BA ; º
		dc.b $39 ; 9
		dc.b $BA ; º
		dc.b $39 ; 9
		dc.b $DA ; Ú
		dc.b $3A ; :
		dc.b $1E
		dc.b $E8 ; è
		dc.b $D2 ; Ò
		dc.b  $F
		dc.b $2E ; .
		dc.b  $F
		dc.b $2E ; .
		dc.b  $F
		dc.b $2E ; .
		dc.b $F3 ; ó
		dc.b $DE ; Þ
		dc.b $22 ; "
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $F6 ; ö
		dc.b   0
		dc.b $F0 ; ð
		dc.b   1
		dc.b   2
		dc.b   5
		dc.b $FF
		dc.b   3
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   9
		dc.b $39 ; 9
		dc.b $BA ; º
		dc.b $39 ; 9
		dc.b $BA ; º
		dc.b $39 ; 9
		dc.b $DA ; Ú
		dc.b $3A ; :
		dc.b $1E
		dc.b $E8 ; è
		dc.b $D2 ; Ò
		dc.b  $F
		dc.b $2E ; .
		dc.b  $F
		dc.b $2E ; .
		dc.b  $F
		dc.b $2E ; .
		dc.b $F3 ; ó
		dc.b $DE ; Þ
		dc.b   0
		dc.b $76 ; v
		dc.b $34 ; 4
		dc.b $44 ; D
		dc.b $14
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   0
		dc.b $48 ; H
		dc.b $60 ; `
		dc.b $4A ; J
		dc.b $60 ; `
		dc.b $50 ; P
		dc.b $60 ; `
		dc.b $52 ; R
		dc.b $60 ; `
		dc.b $44 ; D
		dc.b $1C
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $44 ; D
		dc.b $14
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   0
		dc.b $48 ; H
		dc.b $60 ; `
		dc.b $4A ; J
		dc.b $60 ; `
		dc.b $50 ; P
		dc.b $60 ; `
		dc.b $52 ; R
		dc.b   1
		dc.b $44 ; D
		dc.b $1C
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $44 ; D
		dc.b $14
		dc.b $52 ; R
		dc.b $60 ; `
		dc.b $44 ; D
		dc.b $1C
		dc.b $44 ; D
		dc.b $14
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   0
		dc.b $48 ; H
		dc.b   1
		dc.b $4A ; J
		dc.b   3
		dc.b $50 ; P
		dc.b   3
		dc.b $52 ; R
		dc.b   1
		dc.b $44 ; D
		dc.b $4C ; L
		dc.b $46 ; F
		dc.b $10
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $44 ; D
		dc.b $14
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   0
		dc.b $48 ; H
		dc.b   3
		dc.b $4A ; J
		dc.b   1
		dc.b $50 ; P
		dc.b   1
		dc.b $52 ; R
		dc.b   3
		dc.b $44 ; D
		dc.b $4C ; L
		dc.b $46 ; F
		dc.b $10
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $44 ; D
		dc.b $14
		dc.b $48 ; H
		dc.b $FF
		dc.b $4A ; J
		dc.b $FF
		dc.b $4E ; N
		dc.b $FF
		dc.b $44 ; D
		dc.b $8C ; Œ
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $46 ; F
		dc.b $F0 ; ð
		dc.b $5E ; ^
		dc.b $85 ; …
		dc.b $44 ; D
		dc.b $14
		dc.b $5C ; \
		dc.b $FD ; ý
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $40 ; @
		dc.b   0
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b   8
		dc.b   0
		dc.b   4
		dc.b   0
		dc.b  $C
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $74 ; t
		dc.b $10
		dc.b $F0 ; ð
		dc.b  $E
		dc.b   8
		dc.b $4B ; K
		dc.b $1A
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b  $C
		dc.b   0
		dc.b $20
		dc.b   0
		dc.b  $C
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $68 ; h
		dc.b $53 ; S
		dc.b $42 ; B
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $12
		dc.b   0
		dc.b   3
		dc.b   0
		dc.b  $C
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $68 ; h
		dc.b $68 ; h
		dc.b $18
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $18
		dc.b   0
		dc.b $21 ; !
		dc.b   0
		dc.b  $C
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $68 ; h
		dc.b $50 ; P
		dc.b $F2 ; ò
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $1C
		dc.b   0
		dc.b $1F
		dc.b   0
		dc.b $14
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $40 ; @
		dc.b $57 ; W
		dc.b $D6 ; Ö
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $20
		dc.b   0
		dc.b $16
		dc.b   0
		dc.b $12
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $16
		dc.b $62 ; b
		dc.b $4C ; L
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $28 ; (
		dc.b   0
		dc.b $15
		dc.b   0
		dc.b $12
		dc.b $FF
		dc.b $FF
		dc.b $F7 ; ÷
		dc.b $16
		dc.b $62 ; b
		dc.b $4C ; L
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $30 ; 0
		dc.b   0
		dc.b   3
		dc.b   0
		dc.b  $A
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $FE ; þ
		dc.b $4C ; L
		dc.b $96 ; –
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $36 ; 6
		dc.b   0
		dc.b $1E
		dc.b   0
		dc.b  $A
		dc.b $FF
		dc.b $FF
		dc.b $EE ; î
		dc.b $FE ; þ
		dc.b $11
		dc.b $4F ; O
		dc.b $1E
		dc.b $18
		dc.b  $A
		dc.b $88 ; ˆ
		dc.b   7
		dc.b $F0 ; ð
		dc.b   1
		dc.b $14
		dc.b $87 ; ‡
		dc.b   3
		dc.b $FC ; ü
		dc.b   3
		dc.b $28 ; (
		dc.b $86 ; †
		dc.b   1
		dc.b $FE ; þ
		dc.b   7
		dc.b $50 ; P
		dc.b $1F
		dc.b $40 ; @
		dc.b   0
		dc.b $64 ; d
		dc.b   7
		dc.b $66 ; f
		dc.b   7
		dc.b $44 ; D
		dc.b $14
		dc.b $58 ; X
		dc.b $38 ; 8
		dc.b $5E ; ^
		dc.b $85 ; …
		dc.b $4C ; L
		dc.b   0
		dc.b $4E ; N
		dc.b   0
		dc.b $48 ; H
		dc.b $60 ; `
		dc.b $4A ; J
		dc.b $60 ; `
		dc.b $50 ; P
		dc.b $60 ; `
		dc.b $52 ; R
		dc.b $60 ; `
		dc.b $46 ; F
		dc.b $F0 ; ð
		dc.b $5C ; \
		dc.b $FD ; ý
		dc.b $42 ; B
		dc.b $41 ; A
		dc.b $61 ; a
		dc.b   1
		dc.b $7F ; 
		dc.b $20
		dc.b   1
		dc.b   1
		dc.b   1
		dc.b   3
		dc.b $3E ; >
		dc.b $98 ; ˜
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   8
aReGThi:	dc.b '>àEÞG¶tHI'
		dc.b  $C
		dc.b $E8 ; è
		dc.b $28 ; (
		dc.b $E8 ; è
		dc.b $D2 ; Ò
		dc.b $F3 ; ó
		dc.b $DE ; Þ
		dc.b   8
		dc.b $81 ; 
		dc.b $18
a0123456789abcdefag:dc.b '0123456789ABCDEF€G'
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $3C ; <
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $50 ; P
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $60 ; `
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $74 ; t
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $8C ; Œ
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $9A ; š
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $B2 ; ²
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $C4 ; Ä
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $DC ; Ü
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $EC ; ì
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $F4 ; ô
		dc.b $FF
		dc.b $FF
		dc.b $EF ; ï
		dc.b $FC ; ü
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b   6
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b  $E
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $1C
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $2C ; ,
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $34 ; 4
		dc.b   6
		dc.b $6F ; o
		dc.b $FF
		dc.b   0
		dc.b   5
		dc.b   5
		dc.b $91 ; ‘
		dc.b $6E ; n
		dc.b   6
		dc.b $7F ; 
		dc.b $FF
		dc.b   3
		dc.b   5
		dc.b $91 ; ‘
		dc.b $94 ; ”
		dc.b  $A
		dc.b $6F ; o
		dc.b $EF ; ï
		dc.b $63 ; c
		dc.b $23 ; #
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $12
		dc.b $6F ; o
		dc.b $EF ; ï
		dc.b  $F
		dc.b $24 ; $
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $62 ; b
		dc.b $6F ; o
		dc.b $EF ; ï
		dc.b $63 ; c
		dc.b   7
		dc.b $46 ; F
		dc.b $13
		dc.b $92 ; ’
		dc.b $1C
		dc.b  $E
		dc.b $43 ; C
		dc.b $EF ; ï
		dc.b  $F
		dc.b $23 ; #
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $12
		dc.b $43 ; C
		dc.b $EF ; ï
		dc.b $63 ; c
		dc.b $20
		dc.b   7
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $62 ; b
		dc.b $43 ; C
		dc.b $EF ; ï
		dc.b $63 ; c
		dc.b   4
		dc.b   0
		dc.b   5
		dc.b   3
		dc.b $92 ; ’
		dc.b $B2 ; ²
		dc.b $65 ; e
		dc.b $73 ; s
		dc.b $FF
		dc.b $10
		dc.b   1
		dc.b $43 ; C
		dc.b $10
		dc.b   5
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $7D ; }
		dc.b $63 ; c
		dc.b $FF
		dc.b $10
		dc.b   1
		dc.b $44 ; D
		dc.b $10
		dc.b   7
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b   9
		dc.b $73 ; s
		dc.b $FF
		dc.b   0
		dc.b   7
		dc.b   0
		dc.b $F0 ; ð
		dc.b   7
		dc.b   5
		dc.b   3
		dc.b $93 ; “
		dc.b $86 ; †
		dc.b $11
		dc.b $73 ; s
		dc.b $FF
		dc.b   0
		dc.b   4
		dc.b $93 ; “
		dc.b $32 ; 2
		dc.b   5
		dc.b  $F
		dc.b $FF
		dc.b   0
		dc.b   4
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b   9
		dc.b $1F
		dc.b $FF
		dc.b   0
		dc.b   4
		dc.b $92 ; ’
		dc.b $B2 ; ²
		dc.b $11
		dc.b $1F
		dc.b $FF
		dc.b   0
		dc.b   4
		dc.b $93 ; “
		dc.b $32 ; 2
		dc.b $21 ; !
		dc.b $1F
		dc.b $FF
		dc.b   0
		dc.b   5
		dc.b   4
		dc.b   3
		dc.b $90 ; 
		dc.b $72 ; r
		dc.b $41 ; A
		dc.b $1F
		dc.b $FF
		dc.b   0
		dc.b   5
		dc.b $42 ; B
		dc.b $10
		dc.b   5
		dc.b $90 ; 
		dc.b $72 ; r
		dc.b $61 ; a
		dc.b  $F
		dc.b $FF
		dc.b   0
		dc.b $F0 ; ð
		dc.b   5
		dc.b   2
		dc.b   5
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $FF
		dc.b  $F
		dc.b $EF ; ï
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $1D
		dc.b $87 ; ‡
		dc.b $EF ; ï
		dc.b $10
		dc.b   1
		dc.b $4B ; K
		dc.b $14
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $FF
		dc.b $87 ; ‡
		dc.b $EF ; ï
		dc.b   0
		dc.b   5
		dc.b $4B ; K
		dc.b $10
		dc.b   5
		dc.b $90 ; 
		dc.b $72 ; r
		dc.b $FF
		dc.b $AF ; ¯
		dc.b $EF ; ï
		dc.b   0
		dc.b   3
		dc.b   5
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b $63 ; c
		dc.b $20
		dc.b   1
		dc.b $4C ; L
		dc.b $10
		dc.b   3
		dc.b $90 ; 
		dc.b $72 ; r
		dc.b $FF
		dc.b $20
		dc.b   1
		dc.b $4C ; L
		dc.b $11
		dc.b $94 ; ”
		dc.b $54 ; T
		dc.b  $A
		dc.b $56 ; V
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $3C ; <
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $42 ; B
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $52 ; R
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $62 ; b
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $72 ; r
		dc.b $20
		dc.b $F0 ; ð
		dc.b  $C
		dc.b   2
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $82 ; ‚
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $90 ; 
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $9E ; ž
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $B0 ; °
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $B8 ; ¸
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $CC ; Ì
		dc.b $CB ; Ë
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $E2 ; â
		dc.b $FF
		dc.b $FF
		dc.b $F0 ; ð
		dc.b $F2 ; ò
		dc.b   8
		dc.b   1
		dc.b $FF
		dc.b $FF
		dc.b   8
		dc.b   2
		dc.b $80 ; €
		dc.b $FF
		dc.b $41 ; A
		dc.b   1
		dc.b $FF
		dc.b $FF
		dc.b   8
		dc.b   1
		dc.b $17
		dc.b   8
		dc.b   1
		dc.b $FF
		dc.b $7D ; }
		dc.b   8
		dc.b   2
		dc.b $80 ; €
		dc.b $FF
		dc.b $14
		dc.b   1
		dc.b $FF
		dc.b   0
		dc.b   1
		dc.b $56 ; V
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b  $E
		dc.b $13
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   4
		dc.b $7D ; }
		dc.b   2
		dc.b   5
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   6
		dc.b $15
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   3
		dc.b $7D ; }
		dc.b   3
		dc.b $2A ; *
		dc.b   0
		dc.b   4
		dc.b $4E ; N
		dc.b $B9 ; ¹
		dc.b $13
		dc.b $AC ; ¬
		dc.b $AC ; ¬
		dc.b   0
		dc.b $7D ; }
		dc.b   5
		dc.b $5F ; _
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b $11
		dc.b $AF ; ¯
		dc.b $1E
		dc.b $13
		dc.b   5
		dc.b $50 ; P
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $11
		dc.b $B4 ; ´
		dc.b $4A ; J
		dc.b $10
		dc.b   1
		dc.b   7
		dc.b $20
		dc.b   1
		dc.b $1E
		dc.b $13
		dc.b $AC ; ¬
		dc.b   8
		dc.b   0
		dc.b $7D ; }
		dc.b  $D
		dc.b $43 ; C
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   2
		dc.b $10
		dc.b   5
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   2
		dc.b $7D ; }
		dc.b  $F
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b   0
		dc.b   5
		dc.b   3
		dc.b $B0 ; °
		dc.b $EA ; ê
		dc.b   0
		dc.b $7D ; }
		dc.b $45 ; E
		dc.b   1
		dc.b   3
		dc.b  $F
		dc.b $DC ; Ü
		dc.b $13
		dc.b $B1 ; ±
		dc.b $B6 ; ¶
		dc.b $13
		dc.b $4D ; M
		dc.b $4D ; M
		dc.b $5F ; _
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b $11
		dc.b $B4 ; ´
		dc.b $FE ; þ
		dc.b $12
		dc.b $4D ; M
		dc.b $52 ; R
		dc.b   0
		dc.b   8
		dc.b $21 ; !
		dc.b $B1 ; ±
		dc.b $B6 ; ¶
		dc.b $13
		dc.b $4D ; M
		dc.b $52 ; R
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $15
		dc.b $B1 ; ±
		dc.b $B6 ; ¶
		dc.b   0
		dc.b $5A ; Z
		dc.b $5A ; Z
		dc.b   0
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   2
		dc.b $B1 ; ±
		dc.b $B6 ; ¶
		dc.b $6E ; n
		dc.b $41 ; A
		dc.b $10
		dc.b   1
		dc.b  $C
		dc.b   3
		dc.b   3
		dc.b $B2 ; ²
		dc.b $68 ; h
		dc.b   0
		dc.b $7D ; }
		dc.b $75 ; u
		dc.b $5F ; _
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b $10
		dc.b $F0 ; ð
		dc.b  $A
		dc.b   3
		dc.b $B4 ; ´
		dc.b $FE ; þ
		dc.b   0
		dc.b $7D ; }
		dc.b $75 ; u
		dc.b  $B
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $B3 ; ³
		dc.b $5E ; ^
		dc.b   0
		dc.b $7D ; }
		dc.b $62 ; b
		dc.b   0
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FE ; þ
		dc.b $B4 ; ´
		dc.b $5E ; ^
		dc.b   0
		dc.b $7D ; }
		dc.b $7B ; {
		dc.b $41 ; A
		dc.b $5F ; _
		dc.b $53 ; S
		dc.b $45 ; E
		dc.b $54 ; T
		dc.b $10
		dc.b   5
		dc.b $B3 ; ³
		dc.b $96 ; –
		dc.b   0
		dc.b $7D ; }
		dc.b $7D ; }
		dc.b $10
		dc.b   1
		dc.b   8
		dc.b $25 ; %
		dc.b $B4 ; ´
		dc.b   8
		dc.b   0
		dc.b $7D ; }
		dc.b $7D ; }
		dc.b $54 ; T
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $15
		dc.b $B3 ; ³
		dc.b $A8 ; ¨
		dc.b   0
		dc.b $7D ; }
		dc.b $FF
		dc.b $F8 ; ø
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   2
		dc.b $B4 ; ´
		dc.b $FE ; þ
		dc.b   1
		dc.b $56 ; V
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b  $E
		dc.b $13
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   4
		dc.b $7D ; }
		dc.b   2
		dc.b   5
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   6
		dc.b $13
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   3
		dc.b $7D ; }
		dc.b   3
		dc.b $2A ; *
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b  $C
		dc.b $13
		dc.b $AC ; ¬
		dc.b $AC ; ¬
		dc.b   0
		dc.b $7D ; }
		dc.b   5
		dc.b $5F ; _
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b $11
		dc.b $B0 ; °
		dc.b  $E
		dc.b $13
		dc.b   5
		dc.b $50 ; P
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $11
		dc.b $B4 ; ´
		dc.b $4A ; J
		dc.b $10
		dc.b   1
		dc.b   7
		dc.b $20
		dc.b   1
		dc.b $1E
		dc.b $13
		dc.b $AC ; ¬
		dc.b   8
		dc.b   0
		dc.b $7D ; }
		dc.b  $D
		dc.b $43 ; C
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   2
		dc.b $10
		dc.b   5
		dc.b $AA ; ª
		dc.b $DA ; Ú
		dc.b   2
		dc.b $7D ; }
		dc.b  $F
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   1
		dc.b   0
		dc.b   5
		dc.b   3
		dc.b $B0 ; °
		dc.b $EA ; ê
		dc.b   0
		dc.b $7D ; }
		dc.b $45 ; E
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   8
		dc.b   3
		dc.b   3
		dc.b $B4 ; ´
		dc.b $4A ; J
		dc.b $13
		dc.b $4D ; M
		dc.b $45 ; E
		dc.b $5F ; _
		dc.b $11
		dc.b  $F
		dc.b $DE ; Þ
		dc.b $14
		dc.b $B1 ; ±
		dc.b $38 ; 8
		dc.b $13
		dc.b $4D ; M
		dc.b $4D ; M
		dc.b $52 ; R
		dc.b   0
		dc.b   8
		dc.b $21 ; !
		dc.b $B1 ; ±
		dc.b $38 ; 8
		dc.b $13
		dc.b $4D ; M
		dc.b $52 ; R
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $10
		dc.b   5
		dc.b $B1 ; ±
		dc.b $38 ; 8
		dc.b   0
		dc.b $5A ; Z
		dc.b $5A ; Z
		dc.b   0
		dc.b   1
		dc.b   3
		dc.b   8
		dc.b   5
		dc.b   3
		dc.b $B1 ; ±
		dc.b $38 ; 8
		dc.b $13
		dc.b $4D ; M
		dc.b $5A ; Z
		dc.b $41 ; A
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $11
		dc.b $B1 ; ±
		dc.b $38 ; 8
		dc.b $10
		dc.b $F0 ; ð
		dc.b   6
		dc.b   2
		dc.b $6D ; m
		dc.b $5F ; _
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $B3 ; ³
		dc.b $96 ; –
		dc.b   0
		dc.b $7D ; }
		dc.b $63 ; c
		dc.b  $B
		dc.b $10
		dc.b   1
		dc.b  $C
		dc.b   5
		dc.b   3
		dc.b $B2 ; ²
		dc.b $E4 ; ä
		dc.b   0
		dc.b $7D ; }
		dc.b $FF
		dc.b   0
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $FF
		dc.b $11
		dc.b $B5 ; µ
		dc.b $54 ; T
		dc.b $1F
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b   2
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b  $C
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $16
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $20
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $2A ; *
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $34 ; 4
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $3E ; >
		dc.b   4
		dc.b $2D ; -
		dc.b $10
		dc.b $F0 ; ð
		dc.b   4
		dc.b   6
		dc.b $BE ; ¾
		dc.b $D0 ; Ð
		dc.b   4
		dc.b $B4 ; ´
		dc.b $BE ; ¾
		dc.b $D0 ; Ð
		dc.b   1
		dc.b   4
		dc.b $BC ; ¼
		dc.b $5C ; \
		dc.b   8
		dc.b   4
		dc.b $BE ; ¾
		dc.b $76 ; v
		dc.b  $B
		dc.b $1E
		dc.b $BC ; ¼
		dc.b $F4 ; ô
		dc.b $13
		dc.b   4
		dc.b $BD ; ½
		dc.b $C2 ; Â
		dc.b $14
		dc.b  $F
		dc.b $11
		dc.b $C0 ; À
		dc.b  $A
		dc.b $31 ; 1
		dc.b   4
		dc.b $B4 ; ´
		dc.b $10
		dc.b $F0 ; ð
		dc.b   4
		dc.b   5
		dc.b $BF ; ¿
		dc.b $2A ; *
		dc.b   1
		dc.b   4
		dc.b $BC ; ¼
		dc.b $AC ; ¬
		dc.b   8
		dc.b   4
		dc.b $BF ; ¿
		dc.b $82 ; ‚
		dc.b  $B
		dc.b   4
		dc.b $BD ; ½
		dc.b $3A ; :
		dc.b $13
		dc.b   4
		dc.b $BE ; ¾
		dc.b $20
		dc.b $14
		dc.b  $F
		dc.b $11
		dc.b $C0 ; À
		dc.b  $A
		dc.b   1
		dc.b $24 ; $
		dc.b $22 ; "
		dc.b $56 ; V
		dc.b $10
		dc.b $F0 ; ð
		dc.b   4
		dc.b   7
		dc.b $E4 ; ä
		dc.b $9E ; ž
		dc.b $30 ; 0
		dc.b $6E ; n
		dc.b $D4 ; Ô
		dc.b $3E ; >
		dc.b $3F ; ?
		dc.b $10
		dc.b $E4 ; ä
		dc.b $6E ; n
		dc.b $70 ; p
		dc.b   6
		dc.b $D5 ; Õ
		dc.b $FA ; ú
		dc.b $80 ; €
		dc.b $20
		dc.b $D6 ; Ö
		dc.b $24 ; $
		dc.b $B0 ; °
		dc.b $75 ; u
		dc.b $D6 ; Ö
		dc.b $4A ; J
		dc.b $C0 ; À
		dc.b $6C ; l
		dc.b $E0 ; à
		dc.b $7C ; |
		dc.b $C1 ; Á
		dc.b $63 ; c
		dc.b $10
		dc.b   3
		dc.b $D6 ; Ö
		dc.b $B8 ; ¸
		dc.b $C2 ; Â
		dc.b   2
		dc.b   3
		dc.b $D7 ; ×
		dc.b $74 ; t
		dc.b $E0 ; à
		dc.b   1
		dc.b $12
		dc.b $D9 ; Ù
		dc.b $C6 ; Æ
		dc.b $E1 ; á
		dc.b $E0 ; à
		dc.b $10
		dc.b   3
		dc.b $DA ; Ú
		dc.b $38 ; 8
		dc.b $E2 ; â
		dc.b   2
		dc.b   3
		dc.b $DA ; Ú
		dc.b $90 ; 
		dc.b $E3 ; ã
		dc.b $12
		dc.b $10
		dc.b $F0 ; ð
		dc.b   4
		dc.b   3
		dc.b $DC ; Ü
		dc.b $BE ; ¾
		dc.b $41 ; A
		dc.b $79 ; y
		dc.b $E4 ; ä
		dc.b $C0 ; À
		dc.b $50 ; P
		dc.b $B9 ; ¹
		dc.b $E3 ; ã
		dc.b $FC ; ü
		dc.b $51 ; Q
		dc.b $4F ; O
		dc.b $10
		dc.b $F0 ; ð
		dc.b   2
		dc.b   9
		dc.b $E3 ; ã
		dc.b $FC ; ü
		dc.b $E5 ; å
		dc.b $7E ; ~
		dc.b $E6 ; æ
		dc.b $50 ; P
		dc.b $E4 ; ä
		dc.b $F2 ; ò
		dc.b $E6 ; æ
		dc.b $76 ; v
		dc.b $EA ; ê
		dc.b   4
		dc.b $E9 ; é
		dc.b $5C ; \
		dc.b $EA ; ê
		dc.b $4A ; J
		dc.b $EC ; ì
		dc.b $56 ; V
		dc.b   0
		dc.b $30 ; 0
		dc.b $81 ; 
		dc.b $28 ; (
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $48 ; H
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $54 ; T
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $6A ; j
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $74 ; t
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $82 ; ‚
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $9C ; œ
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $B2 ; ²
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $C2 ; Â
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $D6 ; Ö
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $E6 ; æ
		dc.b $FF
		dc.b $FF
		dc.b $F1 ; ñ
		dc.b $F6 ; ö
		dc.b $FF
		dc.b $FF
		dc.b $F2 ; ò
		dc.b   8
		dc.b $25 ; %
		dc.b   2
		dc.b   1
		dc.b   1
		dc.b   1
		dc.b   1
		dc.b   1
		dc.b   2
		dc.b   1
		dc.b   1
		dc.b   2
		dc.b $18
		dc.b $FF
		dc.b $FF
		dc.b $F2 ; ò
		dc.b $1A
		dc.b $FF
		dc.b $FF
		dc.b $F2 ; ò
		dc.b $22 ; "
		dc.b $FF
		dc.b $FF
		dc.b $F2 ; ò
		dc.b $2A ; *
		dc.b $FF
		dc.b $FF
		dc.b $F2 ; ò
		dc.b $30 ; 0
		dc.b $10
		dc.b   0
		dc.b $83 ; ƒ
		dc.b $19
		dc.b $37 ; 7
		dc.b   0
		dc.b   2
		dc.b   9
		dc.b $6C ; l
		dc.b $80 ; €
		dc.b $C9 ; É
		dc.b   2
		dc.b   2
		dc.b   2
		dc.b   3
		dc.b   0
		dc.b   2
		dc.b $10
		dc.b   5
		dc.b $1C
		dc.b $69 ; i
		dc.b   0
		dc.b   4
		dc.b $11
		dc.b $80 ; €
		dc.b $D5 ; Õ
		dc.b   0
		dc.b   2
		dc.b $10
		dc.b $80 ; €
		dc.b $A5 ; ¥
		dc.b   0
		dc.b   2
		dc.b   4
		dc.b   4
		dc.b   2
		dc.b   2
		dc.b   4
		dc.b   2
		dc.b   2
		dc.b  $E
		dc.b   2
		dc.b $80 ; €
		dc.b $F4 ; ô
		dc.b   0
		dc.b   2
		dc.b   6
		dc.b $81 ; 
		dc.b $12
		dc.b   0
		dc.b   2
		dc.b  $B
		dc.b  $A
		dc.b   2
		dc.b   2
		dc.b   2
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   0
		dc.b   1
		dc.b   1
		dc.b $14
aMpwd:		dc.b 'mpwd'
; end of 'ROM'


		END
