!lm10
!rm76
Apple Machine Language -- A Review

Many of you have asked me, "What book will help me, an absolute beginner, learn 6502 machine language?  I don't know what these other books are talking about!"

If these are your words, then the book "Apple Machine Language", by Don and Kurt Inman, is for you.  It is published by Reston Publishing Company, in both hardback ($17.95) and paperback ($12.95).  The book has 296 pages, is set in clear, easy-to-read type, and has lots of good diagrams and illustrations.

The authors assume that you are at least familiar with Applesoft Basic.  Chapter 1 gives a brief review of Applesoft, with special emphasis on the PEEK, POKE, and CALL statements.  (These are the statements you will be using to communicate between Basic and machine language programs.)  The authors also assume that you have your own Apple, and that you will not just READ the book.  They expect you to follow along every example with your own Apple, so you can EXPERIENCE the material.  You will not only learn a lot faster, but it will stick with you and you will UNDERSTAND what is going on.

Chapter 2 takes you across the bridge from Basic to machine language, very gently.  You develop, with the authors, a little Applesoft program which helps you enter and test machine language programs.

Chapter 3 finally introduces the ideas of binary numbers, hexadecimal, the A-register in the 6502, and a few instruction codes.  You will learn how to load a value into the A-register, modify that value, and store the result back into memory.

There are exercises at the end of each chapter which review the material covered.  Don't let that worry you, though...they also printed the answers!

Chapter 4 starts to get interesting and useful.  You learn how to use machine language to put some simple color graphics on the Apple screen.  You can plot individual points, draw rectangles, and color them in.  All the while, you are learning more machine instructions, more registers, more about memory addressing, and so forth.

Chapter 5 introduces you to writing text on the screen.  You learn how to call some of the monitor subroutines for text output, how to print characters at particular screen locations, and how to write messages of your choice.  Some new instructions are covered, and you learn some new address modes.  In particular, you learn all about relative branching.

Chapter 6 is one of my favorites.  I have always enjoyed twiddling Apple's little built-in speaker, and this chapter shows you how.  You build and play with a tone generator program, even to the point of tuning it up to make a simulated piano keyboard.
!np
Chapter 7 takes you deeper into sound and graphics, helping you code a routine to display the notes as you play them from the keyboard.  By the time you finish this chapter you will understand how to use 28 of the 6502's 56 instructions, and 8 of its 13 addressing modes.  You will also have used 9 of the subroutines found inside the Apple Monitor ROM.

Chapter 8 takes you inside Apple's Monitor...just a little.  Until now, you have been using the Applesoft program developed in chapter 2 to enter and test all your machine language programs.  In chapter 8 you learn how to do it from the monitor.  You will also learn how to do addition and subtraction.

Chapter 9 show you how to add numbers too big to fit in one byte.  Since one byte will only hold numbers between 0 and 255, or between -128 and +127, you can see that most numbers ARE too big to fit in one byte.  You will also learn all about the way negative numbers are handled in the 6502.

Chapter 10 delves deeper into the Apple Monitor, and explores 6502 decimal mode arithmetic.

Chapter 11 is only for those fortunate readers who have Integer BASIC in their Apples.  It doesn't matter whether Integer BASIC is on the Apple Monitor board, on a firmware card in ROM, or in a 16K RAM card...just so you have it.  Why?  Because there is another program in there you might not even be aware of: the Apple Mini-Assembler.  If you are lucky enough to have it, chapter 11 will tell you how to use it.  If not, skipover this chapter and use your S-C ASSEMBLER II instead!  On second thought, don't skip chapter 11 entirely.  It is here that indirect addressing is covered, and you need to know this material.

Chapter 12, "Putting It All Together", puts it all together.  The programming experience you work through is a multiplication subroutine.

There are four appendices which summarize the information about the Apple hardware found throughout the book.  Several of the charts in Appendix-A list page number references.  (Early editions of the book had blank columns where the page numbers were supposed to be, but that has been corrected.)  And finally, there is a regular alphabetic index.

By the time you finish this book, you have a solid foundation for learning to use an assembler like the S-C ASSEMBLER II.  I would like to think that my assembler is easy enough to learn that books like this one would not be needed, but there are a lot of concepts that are completely foreign to new computer owners.

I want to do all I can to help every one of you become proficient in assembly language, so I am making "Apple Machine Language" available to you at a discount.  You can buy the $12.95 paperback edition from me for $11.65 (plus 58 cents tax if you are in Texas).  Include a dollar for shipping, so I don't go broke.
