Before you run the program, you need a 30x4 matrix stored in the variable UFLG. The first column should contain 0 through 10 and 81 through 99. This is an index for the user flags. The rest of the matrix can be 0s when you start.
How It Works
When you run UFLG it'll display a flag number followed by a ":" and then a note up to 18 characters long that you've supplied about that flag's purpose. Here's a Free42 screen capture to give you an idea:
- The up and down arrows scroll through the list of flags.
- Key 1 toggles the set/clear state of the current flag. If a square appears before the flag number, it means the flag is currently set.
- Key 6 opens the alpha register so you can add or change the note for the current flag. To fit on a single line (and in the 30x4 UFLG matrix) your note cannot be longer than 18 characters. It is possible that if you add 5 more columns to your UFLG matrix you'll be able to use both lines of the alpha register, but I've not tested that yet.
- Exit key ends the program and returns both the stack and the alpha register back to the state it was in before you ran UFLG.
- Shift key 1 clears all user flags.
- Shift key 6 clears your note for the current flag.
Here's the program!
Code: Select all
00 { 317-Byte Prgm }
01▸LBL "UFLG"
02 LSTO "UFX"
03 R↓
04 LSTO "UFY"
05 R↓
06 LSTO "UFZ"
07 R↓
08 LSTO "UFT"
09 R↓
10 LASTX
11 LSTO "UFL"
12 1
13 8
14 NEWMAT
15 LSTO "UFA"
16 INDEX "UFA"
17 XEQ a
18 INDEX "UFLG"
19 RCL "UFX"
20▸LBL 00
21 REAL?
22 [FIND]
23▸LBL 01
24 CLMENU
25 10
26 RCLEL
27 "CF"
28 FC? IND ST X
29 "SF"
30 KEY 1 GTO 11
31 "NOTE"
32 KEY 6 GTO 16
33 KEY 7 GTO 17
34 KEY 8 GTO 18
35 KEY 9 GTO 19
36 MENU
37 " "
38 FS? IND ST X
39 "•"
40 X<Y?
41 ├"0"
42 AIP
43 ├":"
44 J+
45 XEQ A
46 AVIEW
47 STOP
48 GTO 00
49▸LBL 11
50 FS? 64
51 GTO 12
52 RCLEL
53 FC?C IND ST X
54 SF IND ST X
55 GTO 01
56▸LBL 12
57 0.01
58▸LBL 13
59 CF IND ST X
60 ISG ST X
61 GTO 13
62 81.099
63▸LBL 14
64 CF IND ST X
65 ISG ST X
66 GTO 14
67 GTO 01
68▸LBL 16
69 CLA
70 FS? 64
71 GTO 15
72 J+
73 XEQ A
74 AON
75 STOP
76 AOFF
77▸LBL 15
78 J+
79 XEQ a
80 GTO 01
81▸LBL 17
82 I-
83 FS? 76
84 XEQ 20
85 GTO 01
86▸LBL 18
87 I+
88 FS? 76
89 XEQ 20
90 GTO 01
91▸LBL 20
92 RCLIJ
93 R↓
94 1
95 STOIJ
96 RTN
97▸LBL a
98 ASTO ST X
99 STOEL
100 ASHF
101 J+
102 FC? 76
103 GTO a
104 I-
105 XEQ 20
106 RTN
107▸LBL A
108 RCLEL
109 STR?
110 ARCL ST X
111 J+
112 FC? 76
113 GTO A
114 I-
115 XEQ 20
116 RTN
117▸LBL 19
118 INDEX "UFA"
119 XEQ A
120 RCL "UFL"
121 STO ST L
122 RCL "UFT"
123 RCL "UFZ"
124 RCL "UFY"
125 RCL "UFX"
126 END