Showing posts with label Dr. Dobb's Journal. Show all posts
Showing posts with label Dr. Dobb's Journal. Show all posts
Monday, May 15, 2017
Building a 68000 Single Board Computer - Dr Dobb's Demos
I expanded a couple of the programs that I entered from Dr. Dobb's Toolbook of 68000 Programming to run on my TS2 computer under the TUTOR monitor. I added a main program that uses the output routines provided by TUTOR through its trap 14 interface to display output of the routine.
The first is the random number generator routine. The demo lists a series of 32-bit random numbers in decimal. Here is some of the initial output:
TUTOR 1.3 > GO 1058
PHYSICAL ADDRESS=00001058
16807
282475249
1622650073
984943658
1144108930
470211272
101027544
1457850878
1458777923
2007237709
823564440
1115438165
1784484492
74243042
114807987
1137522503
1441282327
16531729
823378840
143542612
The second demo is for the square root routine. It lists the integer square roots of the numbers from 0 to 100 000, displaying the number and its corresponding square root. Here is some of the initial output:
TUTOR 1.3 > GO 10B0
PHYSICAL ADDRESS=000010B0
0 0
1 1
2 1
3 1
4 2
5 2
6 2
7 2
8 2
9 3
10 3
11 3
12 3
13 3
14 3
15 3
16 4
17 4
18 4
19 4
20 4
And here is the final output as it reached 100 000:
99980 316
99981 316
99982 316
99983 316
99984 316
99985 316
99986 316
99987 316
99988 316
99989 316
99990 316
99991 316
99992 316
99993 316
99994 316
99995 316
99996 316
99997 316
99998 316
99999 316
100000 316
Labels:
68000,
Dr. Dobb's Journal,
Motorola ECB,
MotorolaTUTOR,
random,
square root
Thursday, May 11, 2017
Building a 68000 Single Board Computer - Dr. Dobb's Toolbook of 68000 Programming
As part of my 68000 retrocomputing work, I've been collecting some old books on 68000 programming. One book that I have been searching for some time is Dr. Dobb's Toolbook of 68000 Programming. I was recently able to acquire a copy.
It is a collection of articles on the 68000 that were originally published in Dr. Dobb's Journal. Most of them were added or updated for publication in the book. It is an interesting collection of articles, ranging from an introduction to the 68000 family to some Forth implementations and 68000 assemblers, and some small programs.
Gordon Brandly's Tiny Basic, which I have earlier run on the TS2 board, is included.
Some of the articles are quite relevant to my recent work on the TS2 board. There is one on the TUTOR monitor program and another and on bringing up a new 68K board by getting it to freerun.
Overall, it makes for an interesting read. I even know one of the authors -- someone who did some consulting work (not 68000 related) where I was once employed.
This particular copy came from the University of Hertfordshire in England and contains the original library markings and card.
While some of the articles have very large software listings (like a 68000 assembler written in Modula-2), four of the articles were relatively small self-contained programs: I entered the source code for them and put the code up on my github account.
I successfully assembled them with the VASM assembler and ran them on my TS2 board under the TUTOR monitor. They all seemed to work flawlessly (with the exception of one that is not a complete self-contained program).
It was quite straightforward to run them under TUTOR, I added a small main routine with a JSR followed by a TRAP #14 to return to TUTOR after execution. From TUTOR I could set register values to fill in the parameters and the look at the values returned.
Now I'm debating whether to type in 88 pages of Modula-2 source code for an assembler - I don't think I can find a suitable compiler.
Subscribe to:
Posts (Atom)


