4985 |
kaklik |
1 |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> |
|
|
2 |
<html> |
|
|
3 |
<head> |
|
|
4 |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
|
|
5 |
<title> words/words.asm </title> |
|
|
6 |
<meta name="keywords" content="amforth programming language Forth ATmega ATMEL"> |
|
|
7 |
<meta name="description" content="amforth - laguage Forth for ATMEL ATmega"> |
|
|
8 |
<!-- AUTOINCLUDE START "Page/Head.en.ihtml" DO NOT REMOVE --> |
|
|
9 |
<link rel="StyleSheet" href="../../../../Web/CSS/MLAB.css" type="text/css" title="MLAB Basic Style"> |
|
|
10 |
<link rel="StyleSheet" href="../../../../Web/CSS/MLAB_Print.css" type="text/css" media="print"> |
|
|
11 |
<link rel="shortcut icon" type="image/x-icon" href="../../../../Web/PIC/MLAB.ico"> |
|
|
12 |
<script type="text/javascript" src="../../../../Web/JS/MLAB_Menu.js"></script> |
|
|
13 |
<!-- AUTOINCLUDE END --> |
|
|
14 |
</head> |
|
|
15 |
|
|
|
16 |
<body lang="en"> |
|
|
17 |
|
|
|
18 |
<!-- AUTOINCLUDE START "Page/Header.en.ihtml" DO NOT REMOVE --> |
|
|
19 |
<!-- ============== HEADER ============== --> |
|
|
20 |
<div class="Header"> |
|
|
21 |
<script type="text/javascript"> |
|
|
22 |
<!-- |
|
|
23 |
SetRelativePath("../../../../"); |
|
|
24 |
DrawHeader(); |
|
|
25 |
// --> |
|
|
26 |
</script> |
|
|
27 |
<noscript> |
|
|
28 |
<p><b> JavaScript is required for including of the header </b></p> |
|
|
29 |
</noscript> |
|
|
30 |
</div> |
|
|
31 |
<!-- AUTOINCLUDE END --> |
|
|
32 |
|
|
|
33 |
<!-- AUTOINCLUDE START "Page/Menu.en.ihtml" DO NOT REMOVE --> |
|
|
34 |
<!-- ============== MENU ============== --> |
|
|
35 |
<div class="Menu"> |
|
|
36 |
<script type="text/javascript"> |
|
|
37 |
<!-- |
|
|
38 |
SetRelativePath("../../../../"); |
|
|
39 |
DrawMenu(); |
|
|
40 |
// --> |
|
|
41 |
</script> |
|
|
42 |
<noscript> |
|
|
43 |
<p><b> JavaScript is required for including of the menu </b><p> |
|
|
44 |
</noscript> |
|
|
45 |
</div> |
|
|
46 |
<!-- AUTOINCLUDE END --> |
|
|
47 |
|
|
|
48 |
<!-- ============== TEXT ============== --> |
|
|
49 |
<div class="Text"> |
|
|
50 |
|
|
|
51 |
<h1> words/words.asm </h1> |
|
|
52 |
|
|
|
53 |
<p> |
|
|
54 |
<input type=button onClick="history.back()" value="Back"> |
|
|
55 |
<input type=button onClick="history.forward()" value="Forward"> |
|
|
56 |
<a href="../WordList.en.html">Jump to Vocabulary</a> |
|
|
57 |
</p> |
|
|
58 |
|
|
|
59 |
<pre> |
|
|
60 |
; ( -- ) Tools |
|
|
61 |
; R( -- ) |
|
|
62 |
; emits a list of all (visible) words in the dictionary |
|
|
63 |
VE_WORDS: |
|
|
64 |
.db $05, "words" |
|
|
65 |
.dw VE_HEAD |
|
|
66 |
.set VE_HEAD = VE_WORDS |
|
|
67 |
XT_WORDS: |
|
|
68 |
.dw DO_COLON |
|
|
69 |
PFA_WORDS: |
|
|
70 |
.dw XT_HEAD |
|
|
71 |
.dw XT_EFETCH |
|
|
72 |
PFA_WORDS1: |
|
|
73 |
.dw XT_DUP ; ( -- addr addr ) |
|
|
74 |
.dw XT_NOTEQUALZERO ; ( -- addr f ) |
|
|
75 |
.dw XT_DOCONDBRANCH ; ( -- addr ) is nfa = counted string |
|
|
76 |
.dw PFA_WORDS2 ; |
|
|
77 |
|
|
|
78 |
.dw XT_ICOUNT ; ( -- adr n ) |
|
|
79 |
.dw XT_DOLITERAL |
|
|
80 |
.dw $1F |
|
|
81 |
.dw XT_AND ; mask immediate bit |
|
|
82 |
.dw XT_OVER |
|
|
83 |
.dw XT_OVER |
|
|
84 |
.dw XT_ITYPE ; ( -- adr n ) |
|
|
85 |
|
|
|
86 |
.dw XT_2SLASH ; ( -- adr k ) |
|
|
87 |
.dw XT_1PLUS ; ( -- adr k+1 ) |
|
|
88 |
.dw XT_PLUS ; ( -- adrk+1 ) |
|
|
89 |
|
|
|
90 |
.dw XT_SPACE ; emit space |
|
|
91 |
.dw XT_IFETCH ; ( -- addr ) |
|
|
92 |
.dw XT_DOBRANCH ; ( -- addr ) |
|
|
93 |
.dw PFA_WORDS1 ; ( -- addr ) |
|
|
94 |
|
|
|
95 |
PFA_WORDS2: |
|
|
96 |
.dw XT_DROP ; ( addr -- ) |
|
|
97 |
.dw XT_EXIT |
|
|
98 |
|
|
|
99 |
</pre> |
|
|
100 |
|
|
|
101 |
<p> |
|
|
102 |
<input type=button onClick="history.back()" value="Back"> |
|
|
103 |
<input type=button onClick="history.forward()" value="Forward"> |
|
|
104 |
<a href="../WordList.en.html">Jump to Vocabulary</a> |
|
|
105 |
</p> |
|
|
106 |
|
|
|
107 |
</div> |
|
|
108 |
|
|
|
109 |
<!-- AUTOINCLUDE START "Page/Footer.en.ihtml" DO NOT REMOVE --> |
|
|
110 |
<!-- ============== FOOTER ============== --> |
|
|
111 |
<div class="Footer"> |
|
|
112 |
<script type="text/javascript"> |
|
|
113 |
<!-- |
|
|
114 |
SetRelativePath("../../../../"); |
|
|
115 |
DrawFooter(); |
|
|
116 |
// --> |
|
|
117 |
</script> |
|
|
118 |
<noscript> |
|
|
119 |
<p><b> JavaScript is required for including of the footer </b></p> |
|
|
120 |
</noscript> |
|
|
121 |
</div> |
|
|
122 |
<!-- AUTOINCLUDE END --> |
|
|
123 |
|
|
|
124 |
</body> |
|
|
125 |
</html> |