Commodore 128 Programmer's Reference Manual page 98

Hide thumbs Also See for 128:
Table of Contents

Advertisement

88
COMMODORE 128
| (
TI and TI$ are variables that relate to the real time clock built into the Commodore
U
128. The system clock is updated every l/60th of a second. It starts at 0 when the
Commodore 128 is turned on, and is reset only by changing the value of TI$. The
\ j
variable TI gives the current value of the clock in l/6Oth of a second. TI$ is a string that
^
reads the value of the real time clock as a 24-hour clock. The first two characters of TI$
contain the hour, the third and fourth characters are minutes and the fifth and sixth
characters are seconds. This variable can be set to any value (so long as all characters
\ j
are numbers) and will be updated automatically as a 24-hour clock.
'—'
EXAMPLE:
j
TI$ = "101530"
Sets the clock to 10:15 and 30 seconds (AM).
u
The value of the clock is lost when the Commodore 128 is turned off. It starts at
) -.
zero when the Commodore 128 is turned on, and is reset to zero when the value of the
j (
clock exceeds 235959 (23 hours, 59 minutes and 59 seconds).
U"J
The variable DS reads the disk drive command channel and returns the current
status of the drive. To get this information in words, PRINT DS$. These status variables
j j
are used after a disk operation, like DLOAD or DSAVE, to find out why the error light
LJ
on the disk drive is blinking.
ER, EL and the ERR$ function are variables used in error trapping routines. They
) /
are usually only useful within a program. ER returns the last error number encountered
[J
since the program was RUN. EL is the line where the error occurred. ERR$ is a
function that allows the program to print one of the BASIC error messages. PRINT
ERR$(ER) prints out the proper error message.
t s
LJ
RESERVED SYSTEM SYMBOLS
}
The following characters are reserved sysiem symbols.
L
SYMBOL
USE(S)
^
+
Plus sign
Arithmetic addition; string concatenation; relative pixel
cursor/sprite movement; declare decimal number in ma-
; {
chine language monitor
o
Minus sign
Arithmetic subtraction; negative number; unary minus;
relative pixel cursor/ sprite movement
*
Asterisk
Arithmetic multiplication
)
/
Slash
Arithmetic division
O
t
Up arrow
Arithmetic exponentiation
Blank space
Separate keywords and variable names
\ \
Equal sign
Value assignment; relationship testing
J
<
Less than
Relationship testing
U
>
Greater than
Relationship testing
,
Comma
Format output in variable lists; command/statement func-
\ I
tion parameters
[J

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents