📄 board_at.equ
字号:
;-============================================================
; @(#)BOARD_at.EQU 6.2 11/18/94
; Becomes BOARDSET.INC after mct copies it
; File: BOARD_AT.EQU (originally board.EQU ) [for 8086]
; Created: Nov 1, 1990
; 11/18/94 J. Jefferies modified for 386EX eval board
;
;
;-============================================================
;
; XRAYMON Board Support
; for
;
; Polled I/O
;
;
; This file patched by menu program as boardset.inc
; Specific values will be set where $str$ found
;
;-============================================================
; Board setup include file for monitor
; CPU family designators
%SET (CPU80386,20h)
%SET (CPU80486,40h)
%SET (CPUPENTIUM,80h)
%SET (CPUI386EX,100h)
%SET (CPUNS486,200h)
; I/O baud rates
%SET (IO115200,8)
%SET (IO57600,7)
%SET (IO38400,6)
%SET (IO19200,1)
%SET (IO9600,2)
%SET (IO4800,3)
%SET (IO2400,4)
%SET (IO1200,5)
;
; Parity styles for I/O init
%SET (PAR_NONE,0)
%SET (PAR_ODD,1)
%SET (PAR_EVEN,2)
%SET (PAR_SPACE,3)
%SET (PAR_MARK,4)
;
;* Output format
%SET (POLLED,1) ; Polled I/O (with or without INTRPT)
%SET (PROBEIO,4) ; special for pROBE I/O using VBR+44h lookup
%SET (INITIO,8) ; 0=no init, else init (for boot start or int)
%SET (HWIO,16) ; hardware I/O
%SET (AUXMON,32) ; auxillary monitor started us
%SET (INTRPT,128) ; interrupt I/O (with or without POLLED)
%SET (WITHFPU,256) ; FPU present
; Normal configs are as follows:
; - HWIO:
; - W/AUXMON: [POLLED]+AUXMON
; - NO MON: [POLLED]+INITIO
;*-------------------------------------------------------------------------
; The next equates are set to describe the board and I/O in use
;*-------------------------------------------------------------------------
; The following are set by MCT using menupat to patch this file
%SET (CONIO,$CONIO$) ; set to combination of I/O flags
%SET (TARGET,$TARGT$) ; cpu used by board - for init stuff
%SET (ABVECT,$AVECT$) ; abort vector if any (for button abort)
%SET (BAUD,$BAUDR$) ; set if IOINIT enabled
%SET (IOBASE,$IOBAS$) ; base address of device I/O
%SET (IOOFF,$IOOFF$) ; offset as 1, 2, or 4
%SET (TIMECONST,$TCONS$) ; time constant for baud rate
%SET (INTLEVEL,$ILEVL$) ; interupt level to run at (0 is default)
%SET (IOINTVECT,$IOINT$) ; I/O interrupt vector (or 0)
%SET (PARITY,$PARIT$) ; I/O parity for init (if needed)
%SET (DATAAD,$DATAAD$) ; is mo_wsp to be a part of the xdm itself? i.e. pc-at style
%SET (PC_PORT,$PC_PORT$) ; Which COM port to use
%SET (FPU_EXCP,$FPU_EXCP$) ;how do we handle co-processor FPU exceptions
%SET (VIRT_MEM,$VIRT_MEM$) ;Do we use target Virtual memory or physical memory
%SET (NUM_8259, $NUM_8259$) ; the number of 8259's to be initialized
%SET (DEBUG_COM, $DEBUG_COM$) ; 0= no debug chars output, 1= AP to com1, 2 = AP to com2
%SET (GRAPHICS,$GRAPHICS$) ; 1=set graphics mode on startup
%IF(%GRAPHICS EQ 1) THEN (
; Metawindows Device Modes
$include(mwmodes.inc)
) FI
%SET (METAWINDOWS_MODE,$MW_MODE$) ; Maps to appropriate graphics mode
;
;Ethernet Initialization
%SET (RARPS,$RARPS$)
%SET (IP0,$IP0$)
%SET (IP1,$IP1$)
%SET (IP2,$IP2$)
%SET (IP3,$IP3$)
%SET (ETH0,$ETH0$)
%SET (ETH1,$ETH1$)
%SET (ETH2,$ETH2$)
%SET (ETH3,$ETH3$)
%SET (ETH4,$ETH4$)
%SET (ETH5,$ETH5$)
%SET (UDP_PORT,$UDP_PORT$)
%SET (ETH_IOADDR,$ETH_BASE_ADD$)
%SET (ETH_IRQ,$ETH_IRQ$)
%SET (ETH_CABLETYPE,$ETH_CABLE$)
%DEFINE (BASEAD) ($BASEAD$)
;----------------------------------------------------------------------
; EXAMPLE: the following are the settings as used during development
; the double quote replaced the "per_cent_sign" as the preprocesser gets confused
; if it sees the percent sign even after a ";".
;"SET (CONIO,"POLLED+"HWIO+"INTRPT+"INITIO) ; set to combination of I/O flags
;"SET (TARGET,"CPU80386) ; cpu used by board - for init stuff
;"SET (ABVECT,0) ; abort vector if any (for button abort)
;"SET (BAUD,"IO9600) ; set if IOINIT enabled
;"SET (IOBASE,03F8H) ; base address of device I/O
;"SET (IOOFF,1) ; offset as 1, 2, or 4
;"SET (TIMECONST,0) ; time constant for baud rate
;"SET (INTLEVEL,1) ; interupt level to run at (0 is default)
;"SET (IOINTVECT,20H) ; I/O interrupt vector (or 0)
;"SET (PARITY,"PAR_NONE) ; I/O parity for init (if needed)
;"SET (PC_PORT,1) ; Which COM port to use
;"SET (FPU_EXCP,0) ;how do we handle co-processor FPU exceptions
;"SET (VIRT_MEM,0) ;Do we use target Virtual memory or physical memory
; select which com port to use
; PC_PORT==1 for com port 1 PC_PORT==2 for com port 2
;----------------------------------------------------------------------
;Definitions for use of com1 ; what should be other defaults
%IF (%PC_PORT EQ 1) THEN (
%SET (INT_ENABLE, 0efH)
) ELSE (
%SET (INT_ENABLE, 0f7H)
) FI
; Definitions for general use of ports
%SET (RXDATA, 1) ;data ready on com port
%SET (TXEMPTY, 020H) ;xmit buffer empty bit
;%SET (DATA_REG, 0) ;TX/RX data registers
; I/O port offsets
%SET (MDM_CNTRL, 4) ;modem control reg
%SET (IO_INTRPT_REG,1) ;interrupt register
%IF ((%CONIO AND %AUXMON) ne 0) THEN (
MO_WSP_SIZE equ 0E00h ; XRAYMON workspace size (incl initial stack)
; Set the INIT_FLAGS
%IF ((%CONIO AND %WITHFPU) ne 0) THEN (
INIT_FLAG equ COINIVECT+COAUXMON+COFPU+COIBPROM ; flags for MON_INIT
) ELSE (
INIT_FLAG equ COINIVECT+COAUXMON+COIBPROM ; flags for MON_INIT
) FI
) ELSE (
MO_WSP_SIZE equ 1000h ; XRAYMON workspace size (incl initial stack)
;1000h =4K, worspace itself takes 0a8h=168 bytes
; Set the INIT_FLAGS
%IF ((%CONIO AND %WITHFPU) ne 0) THEN (
INIT_FLAG equ COINIVECT+COINTRPT+COFPU+COIBPROM ; flags for MON_INIT
) ELSE (
INIT_FLAG equ COINIVECT+COINTRPT+COIBPROM ; flags for MON_INIT
) FI
) FI ; end for IF(CONIO,AUXMON)
;**************For a ROM based system **************************************
; low memory
; MO_WSP ->|-----| Monitor work SPACE
; | | 168. (0x00a8) bytes of XDM's internal data;
; | | stack storage - 4K just for safety could be reduced;
; STACK_START ->| | Stack grows down from here;
; | | 64 bytes of dead space;
; IDT ->| | Interrupt Descriptor Table;
; | | A maximum of 256 entries of 8 bytes each. This shows up as
; | | 0x7ff as the IDTR limit (2048 bytes needed)
; high memory ------
;==========================================================================
%IF (%DATAAD EQ 0) THEN(
MO_WSP EQU $MO_WSP$ + 040h ;the address for the ram based Workspace
; add 40H to leave room for XDM core data such as w__, IVT,...
STACK_START EQU MO_WSP + MO_WSP_SIZE ;the stack starts at the end
INTERRUPT_DESC_TBL EQU STACK_START +64 ;the ram based IDT STARTS 4 bytes beyond STACK
IDT_SIZE EQU 0800H ;specified as 7ff (1024+1)
IDT_END EQU STACK_START + IDT_SIZE +64
TOTL_WRK_SP EQU IDT_END - MO_WSP +1; workspace size plus IDT et al.
)ELSE(
TOTL_WRK_SP EQU MO_WSP_SIZE + 64 ;the workspace size plus 64 byte buffer
)FI
;==========================================================================
%IF ((%CONIO AND %PROBEIO) ne 0) THEN (
BOARD_SAVE equ 1 ; # of longs to reserve in workspace
CON_SCHEME equ 3 ; 7-bit no control chars in transmissions
) ELSE (
BOARD_SAVE equ 0 ; # of longs to reserve in workspace
%IF (%PARITY NE 0) THEN (
CON_SCHEME equ 3 ; 7-bit no control chars in transmissions
) ELSE (
CON_SCHEME equ 0 ; 8-bit full control chars in transmissions
) FI
) FI
%IF ((%CONIO and (%POLLED+%INTRPT)) eq 0)
THEN (
OUT(MUST HAVE POLLED AND/OR INTRPT)
) FI
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -