forked from erinjense/LED-slave-MC9S08QG8
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathutil.sub
32 lines (28 loc) · 1.18 KB
/
util.sub
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
;*******************************************************************************
; EE465: Microcontroll Applications
; Montana State University, Bozeman
; by Aaron Jense
;
; Simple utility subroutines
;*******************************************************************************
#ListOff
#Uses qg8.inc
#ListOn
;*******************************************************************************
#ROM
;*******************************************************************************
DELAY proc
bsr:3 Debounce_50ms
; bra Debounce_50ms
;*******************************************************************************
#Cycles
Debounce_50ms proc
clrhx
#Cycles
Loop@@ aix #1
cphx #DELAY@@
bne Loop@@
#temp :cycles
rts
DELAY@@ equ 50*BUS_KHZ-:cycles-:ocycles/:temp
;*******************************************************************************