178/317
6 - STMicroelectronics Programming Tools
EXTERN padr ; port A data register
EXTERN paddr ; port A data direction register
EXTERN paor ; port A option register
EXTERN pbdr ; port B data register
EXTERN pbddr ; port B data direction register
EXTERN pbor ; port B option register
EXTERN pcdr ; port C data register
EXTERN pcddr ; port C data direction register
EXTERN pcor ; port C option register
;*************************************************************
; SPI registers
;*************************************************************
EXTERN spidr ; SPI data register
EXTERN spicr ; SPI control register
EXTERN spisr ; SPI status register
; bits names of spicr :
SPIE equ 7 ; serial peripheral interrupt enable
SPE equ 6 ; serial peripheral output enable
MSTR equ 4 ; master
CPOL equ 3 ; clock polarity
CPHA equ 2 ; clock phase
SPR1 equ 1 ; serial peripheral rate bit1
SPR0 equ 0 ; serial peripheral rate bit0
; bit names of spisr :
SPIF equ 7 ; serial peripheral data transfert flag
WCOL equ 6 ; write collision status bit
MODF equ 4 ; mode fault flag
(tobecontinued)
In addition to the external declarations, this file provides the EQU definitions of some con-
stants that allow you to name the bits within the bytes using mnemonics. This improves the
legibility of the source text.
6.4.3.4 The MAP72251.ASM file
This file contains only absolute segment declarations. These declarations tell the linker where
the ROM, the RAM and the stack are. Here is the text of the file:
ST7/
;*************************************************************
;* ST72251 memory mapping