mirror of
https://github.com/elliotnunn/sys7.1-doc-wip.git
synced 2024-12-12 04:29:09 +00:00
181 lines
8.3 KiB
Plaintext
181 lines
8.3 KiB
Plaintext
;
|
|
; File: LAPvars2.a
|
|
;
|
|
; Contains: xxx put contents here (or delete the whole line) xxx
|
|
;
|
|
; Written by: xxx put name of writer here (or delete the whole line) xxx
|
|
;
|
|
; Copyright: © 1987-1991 by Apple Computer, Inc., all rights reserved.
|
|
;
|
|
; Change History (most recent first):
|
|
;
|
|
; <1> 10/14/91 JSM first checked in
|
|
; <1.2> 9/8/89 jhl Phase 2 AppleTalk with final mods and VM rolled in.
|
|
; <1.1> 8/11/89 jhl For F19 ROM: Pull Best Router Table vars pointer out of code and
|
|
; put into MPP Variables
|
|
; <1.0> 6/14/89 WTO Adding AppleTalk 2.0 for first time.
|
|
; <2.0d1> 9/6/88 KEL - AppleTalk 2.0. Removed most conditionals.
|
|
; <1.2> 1/19/88 SJF Activate/Deactivate ports
|
|
; <1.1> 1/7/88 SJF 51d2
|
|
; <1.0> 12/23/87 BBM Converted appletalk sources to new build process.
|
|
;
|
|
;
|
|
|
|
;EASE$$$ READ ONLY COPY of file “LAPvars2.a”
|
|
; 1.2 jhl 09/08/1989 Phase 2 AppleTalk with final mods and VM rolled in.
|
|
; 1.1 jhl 08/11/1989 For F19 ROM: Pull Best Router Table vars pointer out of
|
|
; code and put into MPP Variables
|
|
; 1.0 WTO 06/14/1989 Adding AppleTalk 2.0 for first time.
|
|
; END EASE MODIFICATION HISTORY
|
|
;-----------=-----------=-------------------------------=---------------------------------------
|
|
;
|
|
; 2.0d1 06 Sep 88 KEL - AppleTalk 2.0. Removed most conditionals.
|
|
;
|
|
;-----------=-----------=-------------------------------=---------------------------------------
|
|
;EASE$$$ READ ONLY COPY of file LAPvars.a
|
|
; 1.2 SJF 1/19/88 Activate/Deactivate ports
|
|
; 1.1 SJF 1/7/88 51d2
|
|
; 1.0 BBM 12/23/87 Converted appletalk sources to new build process.
|
|
; END EASE MODIFICATION HISTORY
|
|
;-----------=-----------=-------------------------------=---------------------------------------
|
|
;
|
|
; LAP variables
|
|
;
|
|
|
|
IF ATLK THEN
|
|
WDSPtr EQU OurVars.MPPVarsEnd ; (4) WDS pointer saved here on writes
|
|
ELSE
|
|
WDSPtr EQU MPPVarsEnd ; (4) WDS pointer saved here on writes
|
|
ENDIF
|
|
|
|
LAPWrtRtn EQU WDSPtr+4 ; (4) LAP write return address saved here
|
|
RandomSeed EQU LAPWrtRtn+4 ; (2) Seed for random number generator
|
|
DestNode EQU RandomSeed+2 ; (1) Destination node saved here on writes
|
|
fLAPAdrValid EQU DestNode+1 ; (1) If node address has been validated
|
|
fGoodCTS EQU fLAPAdrValid+1 ; (1) If a valid CTS is received
|
|
fAdrInUse EQU fGoodCTS+1 ; (1) If get something from ourselves
|
|
fSendENQ EQU fAdrInUse+1 ; (1) Flag to AbusWrite to send ENQ (not data)
|
|
VBLDeferCnt EQU fSendENQ+1 ; (1) Count for VBL deferring check
|
|
lbackOff EQU VBLDeferCnt+1 ; (1) Local backoff mask for one send
|
|
backoff EQU lbackOff+1 ; (1) Global backoff mask
|
|
collsnHistory EQU backoff+1 ; (1) Bit history of collisions last 8 sends
|
|
deferHistory EQU collsnHistory+1 ; (1) Bit history of defers last 8 sends
|
|
deferTries EQU deferHistory+1 ; (1) Local count of defers in one send
|
|
collsnTries EQU deferTries+1 ; (1) Local count of collisions in one send
|
|
BridgeTime EQU collsnTries+1 ; (1) Timestamp since last router packet
|
|
|
|
FirstVWord EQU BridgeTime+2 ; Next word boundary is here (EVEN!)
|
|
VAbortWait EQU FirstVWord ; (2) Constant for sending abort bits (3.2B)
|
|
VRTimeout EQU VAbortWait+2 ; (2) Constant for receive-byte timeouts
|
|
VSTimeout EQU VRTimeout+2 ; (2) Constant for send-byte timeout
|
|
VDataTO EQU VSTimeout+2 ; (2) CTS-to-data timeout
|
|
VGetXXX EQU VDataTO+2 ; (2) Get a frame within 200 usecs
|
|
VXmitOn EQU VGetXXX+2 ; (2) Xmitter on to send flags
|
|
VRTStoCTS EQU VXmitOn+2 ; (2) Delay from RTS-in to CTS-out
|
|
VWait100 EQU VRTStoCTS+2 ; (2) Delay to wait 100 usecs
|
|
VFrameWait EQU VWait100+2 ; (2) Delay after incoming frame (49)
|
|
VSyncWait EQU VFrameWait+2 ; (2) Delay after sync pulse (49)
|
|
VWordsEnd EQU VSyncWait+2 ; End of timing values
|
|
|
|
SaveA45 EQU VWordsEnd ; (8) A4 and A5 saved here on interrupt
|
|
SaveDskRtn EQU SaveA45+8 ; (4) DskRtnAdr saved here for PollProc
|
|
SavePS EQU SaveDskRtn+4 ; (4) PollStack saved here for disk driver
|
|
SaveBIn EQU SavePS+4 ; (4) .BIN DCE saved here (for close)
|
|
SaveBOut EQU SaveBIn+4 ; (4) .BOUT DCE saved here (for close)
|
|
SaveVects EQU SaveBOut+4 ; (12) SCC interrupt vectors saved here
|
|
SaveRegs EQU SaveVects+12 ; (20) Registers saved here across PollProc
|
|
|
|
;
|
|
; Variables for Lisa/Mac hardware differences
|
|
;
|
|
VAVBufA EQU SaveRegs+20 ; Pointer to VIA or a $FF word
|
|
|
|
STLth EQU 6 ; Size of STData area
|
|
VSTData EQU VAVBufA+4 ; Data string to SCC after send
|
|
VDisTxRTS EQU VSTData+1 ; This is the DisTxRTS byte
|
|
|
|
;
|
|
; Router variables
|
|
;
|
|
|
|
RTMPVars EQU VSTData+STLth ; -> variables for the router
|
|
JDDPRoute EQU RTMPVars+4 ; ptr to the router
|
|
OurDCE EQU JDDPRoute+4 ; ptr to this driver's DCE
|
|
OurPort EQU OurDCE+4 ; our port id (byte)
|
|
PortActive EQU OurPort+1 ; active flag (byte)
|
|
PrevCtlHook EQU PortActive+1 ; default Appletalk control hook chain
|
|
|
|
;
|
|
; *** Add new (AppleTalk 2.0 and greater) variables here ***
|
|
;
|
|
RouterAddr EQU PrevCtlHook+4 ; (4) 24-bit DDP addr of last router heard from
|
|
Config EQU RouterAddr+4 ; (4) holds driver configuration params
|
|
NetHint EQU Config+4 ; (2) current guess for net number
|
|
;
|
|
; *** These next two variables must be kept contiguous ***
|
|
;
|
|
CableLo EQU NetHint+2 ; (2) holds lower bound of cable range
|
|
; or zero if network not known
|
|
CableHi EQU CableLo+2 ; (2) holds upper bound of cable range
|
|
|
|
CRstart EQU CableHi+2 ; (2) cable range from ZIP NetInfoReply
|
|
CRend EQU CRstart+2 ; (2) cable range from ZIP NetInfoReply
|
|
MultiCast EQU CRend+2 ; (6) possible multicast address
|
|
ZoneValid EQU MultiCast+6 ; (1) true if zone is valid
|
|
LinkAdrLen EQU ZoneValid+1 ; (1) length of link's physical address in bytes
|
|
NodeTries EQU LinkAdrLen+1 ; (2) number of node ID's we've tried ENQ'ing for
|
|
ZoneHint EQU NodeTries+2 ; (34) zone name hint
|
|
UserATLK EQU ZoneHint+34 ; (4) ptr to user ATLK
|
|
ZIPlstner EQU UserATLK+4 ; (4) ptr to workstation ZIP listener
|
|
ZIPBufPtr EQU ZIPlstner+4 ; (4) ptr to ZIP data structures
|
|
ZInUseFlgs EQU ZIPBufPtr+4 ; (2) holds flags for use by ZIP
|
|
;
|
|
; NOTE: The next two variables MUST be kept together! They are init'd by .MPP Open routine
|
|
;
|
|
JTrap EQU ZInUseFlgs+2 ; (2) holds JMP Abs.L opcode (to TrapAddr below)
|
|
TrapAddr EQU JTrap+2 ; (4) holds the absolute addr of the ROM CmpString routine
|
|
|
|
BRTdata EQU TrapAddr+4 ; (6) best router last heard from
|
|
BRTkey EQU BRTdata+6 ; (2) best router's network number
|
|
VBLQEl2 EQU BRTkey+2 ; (14) VBL QEl for BRTkey aging
|
|
|
|
ZIPQElPtr EQU VBLQEl2+14 ; (4) ptr to active ZChangeZone ioQel
|
|
SMZQElPtr EQU ZIPQElPtr+4 ; (4) ptr to ioQel @ csCode for SetMyZone
|
|
|
|
xSysVersion EQU SMZQElPtr+4 ; (2) system file version returned by _SysEnvirons
|
|
BRTptr EQU xSysVersion+2 ; (4) Pointer to Best Router Table Data
|
|
|
|
BufList EQU BRTptr+4 ; (4) VM buffer list header
|
|
WrBuf EQU BufList+4 ; (4) ptr to VM write buffer
|
|
NdVM EQU WrBuf+4 ; (2) flag is true if VM running
|
|
ioR EQU NdVM+2 ; (2) temp ioResult storage
|
|
saveNBPRegs EQU ioR+2 ; (8) temp storage for vital NBP process regs
|
|
machineType EQU saveNBPRegs+8 ; (2) machine type word
|
|
ABVarsEnd EQU machineType+2 ; End of local variables
|
|
|
|
;
|
|
; *** If we are gathering statistics, the following variables are also needed
|
|
;
|
|
StatsStart EQU ABVarsEnd
|
|
IntCount EQU StatsStart ; receive interrupt count
|
|
RcvCount EQU IntCount+4 ; good data packets received
|
|
XmitCount EQU RcvCount+4 ; data packets transmitted
|
|
CRCCount EQU XmitCount+4 ; bad CRC (all packets)
|
|
OVRCount EQU CRCCount+4 ; receive overruns (all packets)
|
|
UNDCount EQU OVRCount+4 ; transmit underruns (all packets)
|
|
NoHandCnt EQU UNDCount+4 ; No protocol handler for packet
|
|
LenErrCnt EQU NoHandCnt+4 ; Packet length does not match header's
|
|
BadCount EQU LenErrCnt+4 ; Bad packets seen
|
|
CollsnCount EQU BadCount+4 ; Number of assumed collisions
|
|
DeferCount EQU CollsnCount+4 ; Number of times deferred to other packets
|
|
IdleTOCount EQU DeferCount+4 ; Timed out waiting for end of packet
|
|
BadDDP EQU IdleTOCount+4 ; Bad DDP packet
|
|
NoDtaCount EQU BadDDP+4 ; No packet seen after RTS in
|
|
RandomCTS EQU NoDtaCount+4 ; Unsolicted CTS
|
|
StatsEnd EQU RandomCTS+4 ; <StatsLgCnt must be a multiple of 4!!>
|
|
StatsLen EQU StatsEnd-StatsStart
|
|
StatsLgCnt EQU StatsLen/4
|
|
|
|
DataSize EQU StatsEnd ; Size of our data with stats
|
|
|