Remote-processing BASIC 52 Manual de usuario Pagina 24

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 163
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 23
RPBASIC-52 PROGRAMMING GUIDE
2-5
BLOAD
Syntax: BLOAD to RAM segmen t, RAM address, fro m EP ROM segmen t, EPRO M add ress, length
Where: to RAM segment = 0 to 7, is the 64K block in RA M to write to
RAM a ddress = 0 to 65,535, is the address to write to
from EPROM segment = 0 to 7, is the 64K block in EPROM to read from
EPRO M address = 0 to 65,535, is the address in EPROM to read from
length = 0 to 65,535, is the number of bytes to move from EPROM to RAM
Function: Transfers a block of binary data from flash EPROM to RAM.
Mode: Command, RUN
Use: BLOAD 1,0,5,0,1000
Cards: RPC-320, RPC-330
DESCRIPTION
BLOAD transfers a block of binary information from EPRO M to RAM. BLOAD does not check to see if
there is enough R AM m emory to save to or if the EPR OM is large enough to perform the transfer. Data is
retrieved from RAM using PEEK type functions.
segment can be though of as the X0000H address of the RAM or EPROM. When a segment of 1 and an
address of 4300H are used, an address equivalent to 14300H is used to access the device. When a 128K
RAM or E PRO M is used, segment is 0 or 1. A 512K RAM or EPROM can have a segment of 0 to 7. A 32K
device only has segment 0.
NOTE: Avoid using RAM segment 0. This is where RPBASIC program and variables are used. When
segment 0 must be used, transfer data to above the MTOP address location.
Data transfer rate is about 23.5 ms/1000 bytes. During BLO AD time, ONT ICK and ONITR interrupts are
recognized but not serviced. If these commands must be serviced quicker, transfer data in smaller blocks.
BSAVE transfers data from RAM to flash EPROM.
RELATED
BSAVE, all PEEK commands
ERROR
BAD ARGUMENT When any parameter above is out of limits.
EXAMPLE
The following example POKEs data into segment 1 of data RAM. The data is then saved to EPROM
segment 6 and loaded back to a different location in RAM. The data is then verified. A 128K RAM and
512K flash E PRO M m ust be installed for this example to w ork.
10 RA=512
20 FOR N=0 TO 1000 STEP 2
30 POKE W1,N,N
40 NEXT
50 FOR N=2000 TO 3000 STEP 2
60 POKE W1,N,0
70 NEXT
80 BSAVE6,RA,1,0,1000
90 BLOAD1,2000,6,RA,1002
100 FOR N=0 TO 1000 STEP 2
110 B=PEEKW(1,N+2000)
120 IF B<>N THEN PRINT "Error address",N," data is",B
130 NEXT
Vista de pagina 23
1 2 ... 19 20 21 22 23 24 25 26 27 28 29 ... 162 163

Comentarios a estos manuales

Sin comentarios