;-----------------------------------------------------------------------------
; Mini 8085 BIOS Interface
; Mike Christle (c) 2014
;-----------------------------------------------------------------------------
;                        TERMS OF USE: MIT License
;-----------------------------------------------------------------------------
; Permission is hereby granted, free of charge, to any person obtaining a
; copy of this software and associated documentation files (the "Software"),
; to deal in the Software without restriction, including without limitation
; the rights to use, copy, modify, merge, publish, distribute, sublicense,
; and/or sell copies of the Software, and to permit persons to whom the
; Software is furnished to do so, subject to the following conditions:
; 
; The above copyright notice and this permission notice shall be included in
; all copies or substantial portions of the Software.
; 
; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
; IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
; FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
; THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
; LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
; FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
; DEALINGS IN THE SOFTWARE.
;-----------------------------------------------------------------------------

MCMD1           EQU  0      ;MUART CMD1 Register
MCMD2           EQU  1      ;MUART CMD2 Register
MCMD3           EQU  2      ;MUART CMD3 Register
MMODE           EQU  3      ;MUART Mode Register
MP1CTL          EQU  4      ;MUART Port 1 Control Register
MINTEN          EQU  5      ;MUART Interrupt Enable Register
MINTDS          EQU  6      ;MUART Interrupt Disable Register
MSERTR          EQU  7      ;MUART Serial Tx Rv Register
MPORT1          EQU  8      ;MUART Port 1 Register
MPORT2          EQU  9      ;MUART Port 2 Register
MTMR1           EQU 10      ;MUART Timer 1 Register
MTMR2           EQU 11      ;MUART Timer 2 Register
MTMR3           EQU 12      ;MUART Timer 3 Register
MTMR4           EQU 13      ;MUART Timer 4 Register
MTMR5           EQU 14      ;MUART Timer 5 Register
MSTAT           EQU 15      ;MUART Status Register

CHARLF          EQU 10      ;ASCII Line Feed
CHARCR          EQU 13      ;ASCII Carrage Return
CHARSP          EQU 32      ;ASCII Space

RX_INT_VECT     EQU 0E000H  ;UART Receive interrupt vector
TX_INT_VECT     EQU 0E002H  ;UART Transmmit interrupt vector
T2_INT_VECT     EQU 0E004H  ;Time 2 interrupt vector
T3_INT_VECT     EQU 0E006H  ;Time 3 interrupt vector
T4_INT_VECT     EQU 0E008H  ;Time 4 interrupt vector
T5_INT_VECT     EQU 0E00AH  ;Time 5 interrupt vector

BIOS_RESET      EQU  0
BIOS_GETC       EQU  3
BIOS_GETS       EQU  6
BIOS_PUTC       EQU  9
BIOS_PUTS       EQU 12
