<<Cheats >>

Home Page

Projects...
PC Controller Box
Joystick Switch Box
c128D Refurb

Programs...
Byte Simulator
Cheat 'O Matic
GEOS

Collections...
3D Models
Book Collection

Information...
My BASIC Notes
Web Links

eMail Me

Note: You must add uk to the end of the address, it's to help prevent spam.

My BASIC Notes

Basic2 Commands
Disk Drives
ASCII and CHR$ Codes
PEEK's and POKE's
RAM Memory Map
ROM Memory Map
Screen Display
Sprite

USR()
Abbreviation: U <SHIFT+S>

TYPE: Floating-Point Function
FORMAT: USR (<numeric>)

Action: The USR function jumps to a User callable machine language SubRoutine which has its starting address pointed to by the contents of memory locations 785-786. The starting address is established before calling the USR function by using POKE statements to set up locations 785-786. Unless POKE statements are used, locations 785-786 will give you an ?ILLEGAL QUANTITY error message.

The value of the <numeric> argument is stored in the floating-point accumulator starting at location 97, for access by the Assembler code, and the result of the USR function is the value which ends up there when the subroutine returns to BASIC.

EXAMPLES of USR Function:

10 B=T*SIN(Y)
20 C=USR(B/2)
30 D=USR(B/3)


Commodore Cheetah made by Allen Monks, started in the year 2000.