4.104.114.84.95
Last change
on this file since 16a384cf was
16a384cf,
checked in by Joel Sherrill <joel.sherrill@…>, on 04/23/99 at 16:35:11
|
New BSP from Tony R. Ambardar <tonya@…> from the
University of British Columbia. The BSP is for:
Yes, this is the "entry model" of a series of boards from Technologic
Systems. Costs <$200 I believe. They have a WWW page at www.t-systems.com.
I am letting them know about the availability of this BSP too.
|
-
Property mode set to
100644
|
File size:
884 bytes
|
Line | |
---|
1 | ; Some nasm macros to turn on TS-1325 LEDs and wait for button presses. |
---|
2 | ; This should be '%include'ed in your nasm source file. |
---|
3 | ; |
---|
4 | ; Tony Ambardar |
---|
5 | |
---|
6 | P1LTC equ 0F862h |
---|
7 | P1PIN equ 0F860h |
---|
8 | |
---|
9 | %macro LED_OFF 0 |
---|
10 | mov dx, P1LTC |
---|
11 | in al, dx |
---|
12 | or al, 01000000b ; turn off red |
---|
13 | and al, 11011111b ; turn off green |
---|
14 | out dx, al |
---|
15 | %endmacro |
---|
16 | |
---|
17 | %macro LED_GRN 0 |
---|
18 | mov dx, P1LTC |
---|
19 | in al, dx |
---|
20 | or al, 01100000b ; turn off red, turn on green |
---|
21 | out dx, al |
---|
22 | %endmacro |
---|
23 | |
---|
24 | %macro LED_YEL 0 |
---|
25 | mov dx, P1LTC |
---|
26 | in al, dx |
---|
27 | or al, 00100000b ; turn on green |
---|
28 | and al, 10111111b ; turn on red |
---|
29 | out dx, al |
---|
30 | %endmacro |
---|
31 | |
---|
32 | %macro LED_RED 0 |
---|
33 | mov dx, P1LTC |
---|
34 | in al, dx |
---|
35 | and al, 10011111b ; turn on red, turn off green |
---|
36 | out dx, al |
---|
37 | %endmacro |
---|
38 | |
---|
39 | %macro PSW_WAIT 0 |
---|
40 | mov dx, P1PIN ; Get PSW state |
---|
41 | mov ecx, 80000h |
---|
42 | %%read in al, dx |
---|
43 | test al, 00000001b ; is PSW asserted? |
---|
44 | jnz %%read ; if not, we're done |
---|
45 | dec ecx |
---|
46 | jnz %%read |
---|
47 | %endmacro |
---|
48 | |
---|
Note: See
TracBrowser
for help on using the repository browser.