Remote-processing RPC-30 Manual de usuario Pagina 12

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 38
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 11
SAVING PROGRAMS CHAPTER 3
Page 10 RPC-30
Figure 3-1 Autorun jumper
INTRODUCTION
Program s are stored in EEPROM in socket U8. You
can store one program up to a maximum size of about
28K bytes. A general rule to determine program storage
requirements is one line requires 40 bytes. 28K bytes
would store over 700 lines of code. Your application
could be significantly more or less, depending upon the
number of comm ands/line, comments, and pr int
statements.
Despite the fact you may have a 128K or 512K RAM
installed, the maximum program size CAMBASIC can
run is about 28K (leaving room for variable storage).
Only one program can be stored on the EEPROM.
Program s cannot be chained.
An EEPROM is non-volatile (retaining data even when
power is disconnected), having an unlimited number of
read cycles and a limited number of write cycles (about
10,000). A prog ram is not run fr om EEPR OM. It is
transfer red to RAM and run from there. Prog ram s in
RAM are run and can be modified. They can be saved
to EEPROM for auto execution later.
The RPC-30 can be set to autorun on power up or reset
by installing a jumper (W3). When autorun is on, the
program in E EPR OM is loaded into RA M and begins to
execute immediately.
The RPC -30 has two EEPR OMs. One is used for
program stor age. This is the one under disc ussion in this
chapter. The other is a serial EEPRO M used to save
various C AMBASIC and user param eters and is
discussed in Chapter 13.
The EEP ROM is write-protected with a software lock,
so accidental writes on pow er-on or -off are almost
impossible. You cannot disable the lock except when
executing the SAVE command. T o save param eters,
you must use the serial EEPROM or RA M, which is
battery backed.
SAVING A PROGRAM
To save a program in EEPROM, the autorun jumper W3
must be installed. Also, you need a program to save.
For this example, assume you wanted to save the
following program:
10 FOR N = 0 TO 2
20 PRINT "Hello ";
30 NEXT
40 PRINT
If this progr am is not alr eady in, type it in now (or , if
you prefer, use your own program).
Type in the following command:
SAVE
CAM BASIC will compile the program , progr am the
EEPROM , and verify its contents.
Compile...Write...Verify
The time it takes to do all of this depends upon the
length and complexity of the progr am. Gener ally, it w ill
be from 1 to 20 seconds. The ready prom pt (> ) will
appear when the program has been successfully saved to
the EEPRO M. If the program does not write to the
EEPROM, an error message will appear:
Fail @ xxxx
Saving a program overw rites the pr evious one. Ther e is
no way to recover it since both occupy the same space.
AUTORUNNING
To autorun a program:
1. Make sure there is a program in EE PROM (from
above).
2. Make sure the autorun jumper W3 is installed.
If you push the reset button, the progr am should
autoexecute. If there are any errors, the program will
stop (assuming you have not trapped them with ON
Vista de pagina 11
1 2 ... 7 8 9 10 11 12 13 14 15 16 17 ... 37 38

Comentarios a estos manuales

Sin comentarios