The first two links below are for Scott Guthery's book - This covers the PC implementation of tiny-c. A
great deal of this book is helpful to understanding the original CP/M
implementation of tiny-c. The first file is large (10 Mb). You need
Adobe Acrobat Reader to view these files.
Learning C with tiny-c Appendices
Interpreter and sample programs (PC) - tiny-c-pc.zip
Interpreter and sample programs (CP/M) - tiny-c.zip
tiny-c sample programs - hello.tc - guessnum.tc - pf.tc - pieces.tc - mary.tc - morse.tc - meteor.tc - tree.tc - xmas.tc - tobee.tc
Documentation on the
above tiny-c programs - Note: All sample tiny-c programs have been
tested using the tiny-c/PC interpreter. Many of them started using the
CP/M tiny-c interpreter. The documentation shows how the PC versions are
run and what they do. Changes would be needed to get them to go in the
CP/M environment. meteor.tc, for example, uses ANSI escape sequences to
position the cursor and to do color. morse.tc, xmas.tc and mary.tc won't
work in CP/M as they rely on PC hardware for the beep function.
An interesting exercise is to convert tiny-c programs into C programs
which may then be compiled and thus made much faster. We've done that
with tobee.tc. Click Toby to see how this looks.
|