Applesoft BASIC (Apple II) Commands: CALL (Calls an assembly language subroutine) CLEAR (Clears all variable values from memory) COLOR= (Sets the low-res graphics color) CONT (Attempt to continue a program interrupted by STOP, END, or CTRL-C) DATA DEF DEL (Deletes lines from the program. Works on the program stored in memory, NOT on the screen) DIM DRAW END (End current program; Not used directly from the command line) FLASH (Makes text which comes on-screen flash; See also INVERSE and NORMAL) FOR GET GOSUB GOTO GR (Puts computer in graphics mode; Opposite of TEXT) HCOLOR= (Sets the high-res graphics color) HGR (High-res graphics mode; Like GR, except GR is low-res) HGR2 (Another high-res graphics mode) HIMEM: (Sets highest memory position available for variables; See also LOMEM:) HLIN (Example: HLIN 10,20 AT 10) HOME (Clears screen and moves cursor to the upper-left corner) HPLOT HTAB x (Sets cursor's horizontal position to x) IF IN#x (Reads input from slot, where x is the slot number) INPUT INVERSE (Makes text which comes on-screen be in reverse video; See also FLASH and NORMAL) LET (Sets a variable; "LET" is superfluous) LIST (Lists program currently in memory) LOAD (Load a program from the cassette port; NOT from the disk drive) LOMEM: (Sets lowest memory position available for variables; See also HIMEM:) NEW (Clears program currently in memory) NEXT NORMAL (Sets text which comes on-screen back to normal; See also FLASH and INVERSE) NOTRACE (Stops tracing initiated by TRACE) ON ONERR (Specifies a function to use when an error occurs) PLOT (Example: PLOT 20,20) POKE (Directly inserts a value into a memory location) POP PR#x (Attempt to boot from slot number, where x is the slot number to try) PRINT READ RECALL REM (Remark; Do-nothing line) RESTORE RESUME (Resume program flow after an error) RETURN ROT= (Sets the rotation value for high-resolution shapes) RUN (Runs program in memory) SAVE (Saves the program to the cassette port; NOT to a disk drive) SCALE= (Sets the scaling value for high-resolution shapes) SHLOAD (Loads a high-res shape table off the cassette port) SPEED= (Sets text output speed, 255 being fastest, 0 being slowest) STOP (Stops program execution) STORE (Stores an array to the cassette port) TEXT (Puts computer in text mode; Opposite of GR) TRACE (Displays line number for each statement as it is executed for debugging; Use NOTRACE to negate) VLIN (Example: VLIN 10,20 AT 20) VTAB x (Sets cursor's vertical position to x) WAIT (Enter infinite loop) XDRAW Applesoft BASIC (Apple II) Functions: ABS (Absolute value of an expression) ASC (Returns ASCII value of the first character in the string) ATN (Arctangent) CHR$ (Character reference) COS (Cosine) EXP (Exponent) FRE (Returns free memory available) INT (Returns the largest integer less than or equal to the input value) LEFT$ (Returns some leftmost characters in a string) LEN (Returns the length of a string) LOG (Logarithm) MID$ (Returns characters in the middle of a string) PDL (Position of an analog device, like a joystick or paddle) PEEK (Returns contents of a memory byte) POS (Returns the horizontal position of the cursor) RIGHT$ (Returns some rightmost characters in a string) RND (Random number) SCRN (Returns the color of a low-res screen pixel) SGN (Returns -1, 0, or 1, depending on whether the input number was negative, zero, or positive, respectively) SIN (Sine) SPC (Print blank spaces) SQR (Square root) STR$ (Converts a numeric value to a string) TAB (Inserts cursor tabs) TAN (Tangent) USR (Jumps to memory location $0A) VAL (Converts first number found in string to a numeric value) Applesoft BASIC (Apple II) Reserved Words: AND AT NOT OR STEP (Used with FOR) THEN (Used with IF) TO (Used with FOR and HPLOT) To use graphics with the Apple II, you must first: 1. Set it to graphics mode, with either GR, HGR, or HGR2 2. Issue COLOR= or HCOLOR=