-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdundee-20.txt
1396 lines (915 loc) · 46.2 KB
/
dundee-20.txt
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
%
% % d u n d e e c o l l e g e
%%%%% %
% ** %%% o f t e c h n o l o g y
| * % %
\ *_/ %
\__ % Computer Centre
Introduction to using the
DECSYSTEM-20
Programming Information PI16
Introduction To Using The DECSYSTEM-20
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C O N T E N T S
~~~~~~~~~~~~~~~
Section Page
~~~~~~~ ~~~~
1. INTRODUCTION 1
2. GETTING ACQUAINTED 2
2.1 Identifying Yourself 2
2.2 Leaving The System 2
2.3 Using Two Easy Commands 3
3. STORING YOUR PROGRAM IN THE COMPUTER 4
3.1 Using EDIT 4
3.2 Correcting Typing Errors 5
4. RUNNING YOUR PROGRAM 6
4.1 Executing Your Program 6
4.2 Checking Your Program 6
4.3 Stopping Your Program 6
5. CHANGING YOUR PROGRAM 7
5.1 Starting EDIT 7
5.2 Printing a Line 7
5.3 Inserting a Line 7
5.4 Deleting a Line 7
5.5 Replacing a Line 8
5.6 Changing a Line Without Completely Retyping It 8
5.7 Saving the File 8
6. WORKING WITH FILES 9
6.1 Listing the Names Of Your Files 9
6.2 Deleting a File 9
6.3 Restoring a File 9
6.4 Listing Your Program on Your Terminal 10
6.5 Listing Your Program on the Line Printer 10
6.6 Copying a File 10
7. LETTING TOPS-20 DO SOME OF THE WORK 11
7.1 Getting information about Command Names 11
7.2 Getting information about Command Arguments 11
7.3 Letting TOPS-20 type part of a command 11
7.4 Correcting TOPS-20 Commands 12
7.5 Abbreviating Commands 12
7.6 Getting information about TOPS-20 Programs or 13
Facilities
8. RUNNING A SYSTEM PROGRAM 14
9. USING BASIC 15
9.1 Starting BASIC 15
9.2 Entering Your Program 15
9.3 Saving Your Program 15
9.4 Running Your Program 15
9.5 Changing Your Program 16
9.6 Replacing Your Program 16
9.7 Listing Your Program 16
9.8 Running An Existing Program 16
9.9 Leaving BASIC and logging out 16
10. SUMMARY OF TOPS-20 COMMANDS 17
10.1 System Access Commands 17
10.2 File System Commands 17
10.3 Device Handling Commands 18
10.4 Program Control Commands 19
10.5 Information Commands 20
10.6 Terminal Commands 20
10.7 BATCH Commands 21
10.8 CTRL Commands 21
11. REFERENCES 22
PI16/4 DEO/KLB January 1983
Retyped M.MacArthur June 1993
- 1 -
1. INTRODUCTION
~~~~~~~~~~~~~~~~~~~~
This brief guide introduces you to both the DECSYSTEM-20 and the basic
commands of the TOPS-20 Command Language, as used from an on-line terminal.
Each section describes the minimum number of steps needed to accomplish
common tasks. For fuller information the appropriate DECSYSTEM-20 manuals
should be consulted. As you use this guide you should try each procedure
described at a computer terminal - the easiest and surest way of learning
about TOPS-20 is to use it.
The following conventions have been used in this guide
Convention Meaning
~~~~~~~~~~ ~~~~~~~
<RET> means press the carriage RETURN
(CR) key on your terminal.
$ means press the ESCape (or ALTMODE) key on your
terminal( not to be confused with the $ key).
_ (underlining) in examples, indicates what you
should type if you want to try the examples.
CTRL/x means press the CTRL key and, at the same time,
type the letter after the slash (e.g. CTRL/C
means press the CTRL key and type C). The
charachter represented by CTRL/x is called a
control charachter
TAB means press the TAB key on your terminal. If
your terminal does not have a TAB key, a
CTRL/I may be typed instead.
Acknowledgement is due to Digital Equipment Co. for co-operation in
permitting the reproduction of the material which forms the basis of this
booklet.
- 2 -
2. GETTING ACQUAINTED
~~~~~~~~~~~~~~~~~~~~~~~~~~
2.1 Identifying Yourself
~~~~~~~~~~~~~~~~~~~~
In order to begin using the system, do the following:
i) Ask someone to show you how to turn on the computer terminal.
ii) After you turn on the terminal, press the key labelled CTRL
and, at the same time, type the letter C.
iii) After you see the @, which is the system prompt, type LOGIN
and press the key labelled ESC. After the system prints
(USER), type your user name and press the ESC key. After
the system prints (PASSWORD), type your password and press
the ESC key. After the system prints (ACCOUNT), type your
account number and press the key labelled RETURN.
In Dundee College of Technology, you should give the room
number of the romm in which you are working as the account
code. If the room number contains a point, it should be hyphen-
ated, e.g. 4322-1 shouldbe used as the account code in
room 4322.1. When logging in from an external location over
a telephone line, the account TELE should be used
This procedure is called logging-in. Below is an example of how
you would identify yourself if your user name were DES-B2, your
password FREDDY, and if you were working in room 3506.
_CTRL/C_
MR2172 Dundee Coll of Tech. TOPS-20 Monitor 5(4747)
There are 30+5 jobs and the load average is 0.76
@_LOGIN$_ (USER) _DES-B2$_ (PASSWORD) _$_ (ACCOUNT) _3506_<RET>
Job 17 on TTY20 8-Nov-82 13:00:40
@
Note that your password is not echoed (printed) at your terminal, for
security reasons. It is in your own interest not to reveal your pass-
word to other users, and you should not interfere with directories and
files other than those you are authorised to use.
2.2 Leaving the System
~~~~~~~~~~~~~~~~~~
When you are finished using the system, do the following:
After you see the @, type LOGOUT, and press the key labelled
RETURN. The system then prints a sign-off message.
This procedure is called logging-out. Below is an example of how you
would leave the system.
@_LOGOUT_<RET>
Killed Job 17, User DES-B2, Account 3506, TTY 20,
at 8-Nov-82 13.10.55 Used 0:0:9 in 0:10:15
- 3 -
2.3 Using Two Easy Commands
~~~~~~~~~~~~~~~~~~~~~~~
To find out who else is using the system, after you see the @, type
the command SYSTAT and press the key labelled RETURN.
@_SYSTAT_
Mon 8-Nov-82 13:01:30 Up 3:46:54
15+7 Jobs Load Av 2.54 2.42 2.03
System shutdown scheduled for 9-Nov-82 09:30:00
Job Line Program User
8 26 EXEC EES-B3
9 41 EDIT PHT-STAFF
10 6 FORTRA MCS-D1
.
.
.
@
To get today's date and time, after you see the @, type the command
DAYTIME and press the RETURN key.
@_DAYTIME_
Monday, November 8, 1982 13:02:16
@
Now that you know hoe to get on and off the system and also how to
type several commands, your next task is to get your program into
the computer so that you can run it. Turn to Section 3 - STORING
YOUR PROGRAM IN THE COMPUTER and continue.
If you have a BASIC language program, turn to Section 9 - USING BASIC.
- 4 -
3. STORING YOUR PROGRAM IN THE COMPUTER
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If your program is written in the BASIC language, you do not have to read
this section. Turn to Section 9 - USING BASIC to find out how to get your
BASIC program into the computer and run it.
First you must get your program into a file in your area of disk storage,
because the DECSYSTEM-20 keeps all programs in files. Choose a name for
your file; in general it is better if this name is not more than six
characters long. If the program you are going to put in the file is a
FORTRAN program, add .FOR to the end of the name; if it is a COBOL program
add .CBL to the end; if it is an ALGOL program, add .ALG to the end. These
three-letter combinations (.FOR, .CBL, and .ALG) are called file types. If
you name your FORTRAN program TEST, the file name and file type appear
together as TEST.FOR.
3.1 Using EDIT
~~~~~~~~~~
After you have a name for your file, do the following:
i) After you see the @, type CREATE and press the ESC key.
ii) After you see (FILE), type the file name and file type you have
chosen for your file, and press the RETURN key.
iii) After you see 00100, type the first line of your program and
press the RETURN key.
iv) After you see the next line number (i.e. 00200), type the second
line of your program and press the RETURN key.
v) Continue typing your program; wait for the line number, type
the next line of your program, and then press the RETURN key.
vi) Type the last line of your program, but press the ESC key instead
of the RETURN key.
vii) After you see the *, type E (for End) and press the RETURN key.
e.g. @_CREATE$_ (FILE) _TEST.FOR_<RET>
Input: TEST.FOR.1
00100 _ WRITE (5,1010)_<RET>
00200 _1010 FORMAT(` THIS IS A TEST.')_<RET>
00300 _ END$_
*_E_<RET>
[TEST.FOR.1]
@
The name used for the FORTRAN program in this example was TEST.
Note that typing E in response to the EDIT prompt * returns you
to MONITOR level with the @ prompt.
- 5 -
3.2 Correecting Typing Errors
~~~~~~~~~~~~~~~~~~~~~~~~~
You can type a CTRL/U on a line to tell the system to ignore what you
have typed so far because you want to start the line over again. In
addition to correcting a line by typing it over, you can correct one
or more charachters on the line with the DELETE key. The way you
correct a typing error with the DELETE key depends on when you notice
it:
- If you notice that you have just mistyped a charachter, press the
DELETE key. The last charachter you typed will be erased. Now
type the correct charachters and continue typing the line:
00400 _REEE\AD (X);_
^ You pressed the DELETE key here
|___________________ to erase the second E. Note
that TOPS-20 prints the deleted
charachter followed by a \ when
you press the DELETE key.
- If you mistyped a charachter, but did not notice it until you
typed more charachters on the same line, press the DELETE key as
many times as it takes to erase the line back through the mistyped
charachter. Now type the correct charachter and the rest of the
line.
After deleting charachters, you can have the current line
reprinted, in a tidier form for checking, by typing CTRL/R; you
may then continue to type the rest of the line.
CTRL/R -*
00600 _WRITE (`[C] THE SQUAROOT OF_F\O\ \T\O\O\_EROOT OF `);_
^-----------:
00600 WRITE (`[C] THE SQUAREROOT OF `); |
|
You pressed the DELETE key six times
to erase the word OF, a space, and
the letters OOT. Note that TOPS-20
prints the six deleted charachters,
each followed by a backslash (\).
- If you mistyped a charachter but did not notice it until you
pressed the RETURN key at the end of the line, turn to Section 5-
CHANGING YOUR PROGRAM and learn how to replace a line in your
file.
Now that you have entered your program into a file, you must inform
TOPS-20 that you want it translated, loaded, and started. Turn to
Section 4 - RUNNING YOUR PROGRAM to learn the necessary steps for
this task.
- 6 -
4. RUNNING YOUR PROGRAM
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4.1 Executing Your Program
~~~~~~~~~~~~~~~~~~~~~~
To translate, load, and start your program, do the following:
i) After the @,type EXECUTE and press the ESC key.
ii) After the guide word (FROM), type the file name and file type,
and press the RETURN key.
@_EXECUTE$_ (FROM) _SQRT.ALG_<RET> The file type .ALG tells the
ALGOL: SQRT system to translate your program
using the ALGOL compiler.
LINK: Loading
[LNKXCT SQRT Execution] Execution begins.
TYPE THE VALUE OF X: _34.562_<RET> Obtain the square root of 34.562
THE SQUAREROOT OF 34.562 IS 5.879 The answer is 5.879
End of Execution
@ The program execution is finished
when the system prints the @.
4.2 Checking Your Program
~~~~~~~~~~~~~~~~~~~~~
If you want to check on the progress of your program while it is
running, type T while pressing the CTRL key. This is called typing a
CTRL/T; it will not interfere with the running of your program in any
way.
@_EXECUTE$_ (FROM) _SQRT.ALG_<RET>
ALGOL: SQRT
_<CTRL/T>_ALGOL Running at 410644 Used 0:00:20.3 in 0:09:54 Load 0.64
LINK: Loading
[LNKXCT SQRT Execution]
.
.
.
@
4.3 Stopping Your Program
~~~~~~~~~~~~~~~~~~~~~
There may be times when you want to stop your program while it is still
running. To do so, type C twice while pressing the CTRL key. You
will then see an @, which means you can type any TOPS-20 command.
@_EXECUTE$_ (FROM) _SQRT.ALG_<RET> The user executes the program.
ALGOL: SQRT
200 IMPROPER DECLARATION The user finds an error, so he types
_<CTRL/C><CTRL/C>_ two CTRL/C's to stop the process.
^C
@
You have now learned how to enter and run your program. Sometimes, how-
ever, your program may not contain an error and thus return incorrect
results, or, more often, simply not execute. In such cases, you must
modify it; turn to Section 5 - CHANGING YOUR PROGRAM.
- 7 -
5. CHANGING YOUR PROGRAM
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5.1 Starting EDIT
~~~~~~~~~~~~~
To use EDIT to change your program, after you see an @, type EDit, and
press the ESC key. After the computer prints (FILE), type the file
name and file type of the file you want to change.Press the RETURN key.
@_EDIT_ (FILE) ADDTWO.FOR
Edit: ADDTWO.FOR.1
*
Note: If you type the name of a file which does not exist, the system
prints:
%File not found, Creating New file
Input: ADDTWO.FOR.1
00100
allowing you to create a new file. If you mistyped the file name
or file type, press the ESC key and type EQ (for End and Quit),
then press the RETURN key. The system will print @.
Now type another EDIT command and give the correct file name.
5.2 Printing a Line
~~~~~~~~~~~~~~~
To print a line of your file, type P and the number of the line you
want printed. Press the RETURN key.
*_P200_<RET>
00200 WRITE (5,1910)
*
5.3 Inserting a Line
~~~~~~~~~~~~~~~~
To insert a new line in your file, type I and the line number you
want your new line to have. Press the RETURN key. After you see the
line number, type the new line and press the RETURN key again.
*_I450_<RET>
00450 _ 1820 FORMAT (2F)_<RET>
*
5.4 Deleting a Line
~~~~~~~~~~~~~~~
To delete a line in your file, type D and the number of the line you
want deleted. Press the RETURN key. EDIT replies with the number
of lines deleted.
*_D500_<RET>
1 Lines (00500/1) deleted - line 500 on page 1 of the file deleted.
*
- 8 -
5.5 Replacing a Line
~~~~~~~~~~~~~~~~
To delete a line in your file and insert a new line in its place, type
R and the number of the line you want to replace. Press the RETURN
key. After you see the line number, type the new line and press the
RETURN key again. EDIT prints a message telling you how many lines
you deleted.
*_R200_<RET>
00200 _WRITE (5,1820)_<RET>
1 Lines (00200/1) deleted
*
5.6 Changing a Line Without Completely Retyping It
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To replace an existing group of charachters on a line with a new group
of characters, type S (for Substitute) and the existing group of
charachters, then press the ESC key (EDIT prints a $ every time you
pres the ESC key). Type the new charachters, then press the ESC key
again. Type the number of the line that contains the existing group of
charachters, and then press the RETURN key.
For example, the existing contents of line 800 are:
00800 1030 FIRMAT (`ADDING `,F,' TO `,F,' GIVES `,F)
To correct this line, FIRMAT should be FORMAT. The command
SFIRMAT$FORMAT$800 replaces all occurences of FIRMAT with FORMAT
on line 800.
*_SFIRMAT$FORMAT$800_<RET>
00800 1030 FORMAT (`ADDING `,F,' TO `,F,' GIVES `,F)
*
5.7 Saving The File
~~~~~~~~~~~~~~~
To finish using EDIT and save the edited file, type E and press the
RETURN key.
*_E_<RET>
[ADDTWO.FOR.2]
@
You have now learned the process of entering, executing, editing and
saving a program. By this time, you should have several files in
your area of the disk. The next task you will learn is how to list
the names of all your files. Turn to Section 6 - WORKING WITH FILES.
- 9 -
6. WORKING WITH FILES
~~~~~~~~~~~~~~~~~~~~~~~~~~
6.1 Listing the Names of Your Files
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To obtain a list of the names of your files, do the following:
After you see an @, type DIRECTORY and press the RETURN key.
The names of your files, along with other information about them, will
be printed on your terminal. The following example shows a typical
response from TOPS-20 when you type DIRECTORY.
@_DIRECTORY_<RET>
PS:<DES-B2>
ADDTWO.FOR.2
.QOR.1
.REL.2
SQRT.ALG.1
.REL.1
Total of 5 files
@
The disk structure (PS: in the above example) on which your directory
resides precedes the directory name. The number after the file type
is a generation number supplied by TOPS-20. These numbers indicate
how many times you have changed each file.
6.2 Deleting a File
~~~~~~~~~~~~~~~
To remove a file that you no longer want, do the following:
After you see an @, type DELETE, press the ESC key, and type
the name of the file you want to mark as deleted. Press the
RETURN key. The system responds by printing the name of the
file it has delted.
@_DELETE$_ (FILES) _ADDTWO.QOR_<RET>
ADDTWO.QOR.1 [OK]
@
If you want to mark more than one file for deletion, separate each file
specification with a comma. When a file is marked for deletion, it is
not immediately removed from the system.
6.3 Restoring a File
~~~~~~~~~~~~~~~~
If you delete a file by mistake, you can retrieve it by typing
UNDELETE, pressing the ESC key, and typing the name of the file. Then
press the RETURN key. The system responds by printing the name of the
file it restored.
@_UNDELETE$_ (FILES) _ADDTWO.QOR_<RET>
ADDTWO.QOR.1 [OK]
@
The command should be given as soon as you notice that you deleted
the file by mistake. Otherwise, the file may not be restorable. In
addition, you cannot restore the file once you log off the system.
- 10 -
6.4 Listing Your Program on Your Terminal
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you want a copy of your program listed on your terminal, do the
following:
After you see an @, type TYPE, press the ESC key, and type
the name and file type of the file containing your program.
Press the RETURN key.
@_TYPE$_ (FILE) _ADDTWO.FOR_<RET>
If, for any reason, you want to stop the listing of your file,
press the CTRl key and, at the same time, type the letter O,
(i.e. type a CTRL/O). To resume printing, type another CTRL/O.
6.5 Listing Your Program on The Line Printer
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you want to get a copy of your program listed on the line printer
in the Computer Centre, do the following:
After you see an @, type PRINT, press the ESC key, and type
the name and file type of the file containing your program.
Press the RETURN key.
@_PRINT$_ (FILES) _SQRT.ALG_<RET>
[Job SQRT Queued, Request-ID 963, Limit 52]
@
6.6 Copying a File
~~~~~~~~~~~~~~
If you want to copy one of your files and store it as another file in
your area, do the following:
i) After you see an @, type COPY and press the ESC key.
ii) After the system prints (FROM), type the complete name of
the file you want to copy and press the ESC key.
iii) After the system prints the generation number and (TO), type
the name you want the new file to have and press the RETURN
key.
@_COPY$_ (FROM) _ADDTWO.QOR$_.1 (TO) _ADDTWO.BAK_<RET>
ADDTWO.QOR.1 => ADDTWO.BAK.1 [OK]
@
You now have the basic information you need in order to enter your
program, to edit it, and to run it. You also know how to list the
names of your files, to delete any files you no longer want to keep,
and to obtain copies of your files. The next section tells you
how to make TOPS-20 do still more work for you. Turn to Section 7 -
LETTING TOPS-20 DO SOME OF THE WORK.
- 11 -
7. LETTING TOPS-20 DO SOME OF THE WORK
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7.1 Getting Information About Command Names
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To get a list of all the TOPS-20 commands, type a ? after you see an @.
e.g. @_?_
To get a partial list of TOPS-20 commands, type one or more letters
and a ?.
e.g. @_A?_ - list all commands beginning with letter A.
7.2 Getting Information About Command Arguments
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To find out the arguments TOPS-20 expects you to type after you type
a particular command name, do the following:
i) After you see an @, type the command name and a space. Then
type a ?.
ii) After TOPS-20 types the arguments it expects and retypes the
command name on the next line, type the argument you want to
use. Press the RETURN key at the end of the argument.
e.g.
@_INFORMATION$_ (ABOUT) _?_ one of the following:
ADDRESS-BREAK ALERTS ARCHIVE-STATUS
ARPANET AVAILABLE BATCH-REQUESTS
COMMAND-LEVEL DECNET DEFAULTS
DIRECTORY DISK-USAGE DOWNTIME
ERROR-MESSAGE FILE-STATUS FORK-STATUS
JOB-STATUS LOGICAL-NAMES MAIL
MEMORY-USAGE MONITOR-STATISTICS MOUNT-REQUESTS
OUTPUT-REQUESTS PLOT-REQUESTS PRINT-REQUESTS
PROGRAM-STATUS PSI-STATUS RETRIEVAL-REQUESTS
SPOOLED-OUTPUT-ACTION STRUCTURE SUBSYSTEM-STATISTICS
SYSTEM-STATUS TAPE-PARAMETERS TERMINAL-MODE
VERSION VOLUMES
@INFORMATION (ABOUT) _DISK-USAGE$_ (OF DIRECTORY)<RET>
118 pages assigned, 110 in use, 8 deleted
300 Working pages, 200 Permanent pages allowed
39634 Pages free on PS:, 112773 pages used
7.3 Letting TOPS-20 Type Part of a Command
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you want TOPS-20 to help you type a command, press the ESC key
after typing any part of the command. If it is able to help you,
TOPS-20 will type as much of the command as it can and then wait for
you to type in more. If TOPS-20 is not able to help you, it will ring
the terminal's bell and wait for you to type in more of the command.
This method of typing is called RECOGNITION INPUT.
e.g. @_TY$_PE (FILE) _A$_DDTWO._F$_OR.2<RET>
When you press the ESC key after typing TY, TOPS-20 responds with the
rest of the command name and the guide word (FILE) indicating that it
wants you to give a name of a file as an argument. After typing the
first charachter of the name, press the ESC key again. TOPS-20 com-
pletes the name for you and stops when it tries to complete the file
type.
- 12 -
Because you have more than one file with the name ADDTWO, TOPS-20
cannot choose a file type. Type only the first letter of the file
type and press the ESC key. TOPS-20 then completes the file type
and generation number. Press the RETURN key to get the file printed
on your terminal.
7.4 Correcting TOPS-20 Commands
~~~~~~~~~~~~~~~~~~~~~~~~~~~
When you use recognition input, you will notice that a TOPS-20 command
consists of a command name, guide words, and arguments. In
the command:
@TYPE (FILE) ADDTWO.FOR
the command name is TYPE, the guide word is (FILE), and the argument
is ADDTWO.FOR. When you do not use recognition input, a TOPS-20
command will consist only of a command name and arguments.
Commands are divided into fields. Each command name or argument you
type begins a field, and the next keyword argument you type begins
the next field. The fields, separated by vertical lines, of several
commands are shown below.
@LOGIN (USER) | DES-B2 (PASSWORD) | password (ACCOUNT) | 3506
@TYPE (FILE) | ADDTWO.FOR
@COPY (FROM) | FRED.FOR (TO) | FRED2.FOR
There are three methods of correcting typing errors in TOPS-20 commands
1. Pressing the DELETE key erases the previous charachter.
2. Typing a CTRL/W erases back to the start of the current field.
3. Typing a CTRL/U erases the entire current line.
7.5 Abbreviating Commands
~~~~~~~~~~~~~~~~~~~~~
When you have become very familiar with the use of the common TOPS-20
commands, you may wish only to type abbreviated versions, without
invoking recognition input every time. Only sufficient letters at the
start of each keyword need to be typed to permit the system to
recognise it uniquely.
e.g. @_INFO$_RMATION (ABOUT) _DISK$_-USAGE<RET> - recognition input
@_INFORMATION DISK-USAGE_<RET> - full input
@_INFO DIS_<RET> ) - abbreviated
@_I DIS_<RET> ) input
are all acceptable to the system;
@_I DI_<RET>
is not acceptable because DI is insufficient to define the
second keyword - it could mean DIRECTORY or DISK-USAGE.
- 13 -
7.6 Getting Information About TOPS-20 Programs or Facilities
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you want to get a list of programs or facilities that have infor-
mation on how to use them, type HELP, a space, and a ?.
@_HELP ?_
If you want to get information about a certain program or facility,
type HELP, a space, and the name of the program or facility. Press
the RETURN key.
Now that you have learned some of the helpful features of TOPS-20,
in addition to learning how to run your program, you may want to
learn how to run a system program. Turn to Section 8 - RUNNING A
SYSTEM PROGRAM.
- 14 -
8. RUNNING A SYSTEM PROGRAM
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The TOPS-20 system includes a variety of general-purpose system programs,
provided by the manufacturer, that help you get your work done. The
method of using such programs is generally similar. It is illustrated
here by an example of using the FILCOM program to compare two files and
tell you the differences between them. Let us assume that two files have
been created previously in your directory and that their names are
FIRST.FIL and SECOND.FIL. The following steps would then be followed:
i) Start the system program by typing its name and pressing the RETURN
key. Most system programs respond by printing an * prompt on your
terminal.
@_FILCOM_<RET>
*
ii) After the *, type the place where you want the program to output the
results, followed by an equals sign, then tye the name of the input
file(s). If there is more than one input file, separate the file names
with commas:
*_TTY:=FIRST.FIL,SECOND.FIL_<RET>
iii) After the program finishes all the tasks you have for it, stop it by
typing a single CTRL/C.
*_ <----- CTRL/C
@
In the above example, the system will print out at your terminal (i.e. TTY:)
a list of all the differences found between the two files FIRST.FIL and
SECOND.FIL.
- 15 -
9. USING BASIC
~~~~~~~~~~~~~~~~~~~
If you want to run a BASIC program, you can enter it directly into BASIC; you
should not use EDIT.
9.1 Starting BASIC
~~~~~~~~~~~~~~
After you see the @, type BASIC and press the RETURN key.
@_BASIC_<RET>
READY
9.2 Entering Your Program
~~~~~~~~~~~~~~~~~~~~~
If you want to enter a new BASIC program, do the following:
i) After you see READY, type NEW and press the RETURN key.
ii) After you see the NEW FILE NAME--, type a name up to 6 char-
acters long for your program and press the RETURN key.
iii) After you see READY, begin typing your program. Start each
new line with a line number, type the contents of the line and
press the RETURN key at the end of each line. To erase a
charachter on the current line, press the DELETE key.
_NEW_<RET>
NEW FILE NAME--_SQUARE_<RET>
READY
9.3 Saving Your Program
~~~~~~~~~~~~~~~~~~~
Once you have finished entering your program type SAVE and press the
RETURN key. When BASIC is finished saving your program, it prints
the word READY.
_SAVE_<RET>
READY
In the above example the program would be saved as a file in your
directory on disk with the filename SQUARE.BAS.1
9.4 Running Your Program
~~~~~~~~~~~~~~~~~~~~
To run your program, type RUN and press the RETURN key.
_RUN_<RET>
SQUARE 13:08 9-NOV-82
TYPE A NUMBER.
?_34.5_<RET>
THE SQUAREROOT OF 34.5 is 5.87367
TIME: 0.14 SECS.
READY
- 16 -
9.5 Changing Your Program
~~~~~~~~~~~~~~~~~~~~~
To change your program, type the number of the line you want to
change. Then type the new contents of that line and press the RETURN
key.
_400 INPUT X_<RET>
_500 Y = SQR(X)_<RET>
9.6 Replacing Your Program
~~~~~~~~~~~~~~~~~~~~~~
After you have finished changing your file, type REPLACE and press the
RETURN key. The REPLACE command works only for programs that you have
already saved.
_REPLACE_<RET>
READY
9.7 Listing Your Program
~~~~~~~~~~~~~~~~~~~~
To list the entire program, type LIST and press the RETURN key.
_LIST_<RET>
To list a single line of your program, type LIST followed by the line
number and press the RETURN key.
9.8 Running An Existing Program