175/317
6 - STMicroelectronics Programming Tools
DC.W
0
DC.W
0
DC.W
0
DC.W
0
; skip 7 vectors
DC.W
0
DC.W
0
DC.W
0
DC.W
0
DC.W
0
DC.W
0
DC.W
reset
; reset vector ($FFFE)
END
The main program calls the following subroutine that has been written in a separate file on pur-
pose, though it would be easier to write it in the main source file:
ST7/
;=============================================================
;=
timer 0.5 second
=
;=============================================================
; This subroutine generates a 500ms timing by looping.
PUBLIC Delay500
#include "Register.inc"
; definition of the constants
; ===========================
BYTES
; The following constants are defined as 1 byte values
watch
EQU $FF
DELAY1
EQU 10
DELAY2
EQU 100
DELAY3
EQU 140
; definition of the variables (in page 0)
; ==================================
segment 'ram0'
Time:
ds.b 3
; reserve memory space in RAM for
; a page zero variable named Time,
; that is 3 byte long.
segment 'rom'
WORDS
; Timing routine for 500ms
; =====================================
Содержание ST7 Series
Страница 1: ...ST7 8 BIT MCU FAMILY USER GUIDE JANUARY 1999 1 ...
Страница 238: ...238 317 8 C Language and the C Compiler 08 Burn bmp Then use the EPROMer programmer software as described in Chapter 7 ...
Страница 289: ...289 317 10 Second Application a Sailing Computer 10 befor Bs Rw Vw VMG AlphaR AlphaV Before the wind ...