Apple I Programming
Here are a few simple tips and programs for those interested in programming the Apple I:
<br /> Echo = $FFEF</p> <p> LDA value_to_print<br /> JSR Echo<br />
The above snippet relies on the Echo subroutine in the Apple I's ROM. All you need to do is load an ASCII value into the accumulator, then call that subroutine.
<br /> KbdRdy = $D011<br /> Kbd = $D010 </p> <p>GetChar:<br /> LDA KbdRdy ; Key ready?<br /> BPL GetChar ; Loop until ready.<br /> LDA Kbd ; Load character.<br /> RTS ; Exit.<br />
This subroutine loops until a key is pressed, then loads its ASCII value into the accumulator. It is not dependant upon the Apple I's ROM. KbdRdy and Kbd are in the 6821.