Remote-processing CAMBASIC Manuel d'utilisateur Page 73

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 208
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 72
Commands - 40
DPEEK and DPOKE
Memory Function and Statement
SYNTAX: n = DPEE K(address)
n = DPEE K (address, segment)
DPOKE address, data
DPOKE address, data, segm ent
PURPOSE: DPEEK returns a 16– bit value from memor y.
DPOKE writes a 16– bit value to memory.
REMARK S: A 16– bit word is form ed with the lower 8 bits as the value located at memory addr ess “address
and the upper 8 bits as the value located at memory location “ address + 1.
The first syntax applies to the first 64K of memory (segment 0). For addresses above segment 0, use
the second syntax. Not all cards support segmented mem ory.
DPEEK is an extension of PEEK and executes twice as fast as two PEEK functions. DP OKE is an
extension of POKE and executes twice as fast as two pokes.
RELATED: DPOKE, PEEK, FPEEK, PEEK$, POKE, FPOKE, POKE$
EXAMPLE: The following routine POKEs or writes two numbers into memory. The DPEEK statement allows
both to be retrieved and printed ( 256 x 3 + 45 = 813). You could also say DPOKE 2000, 813.
10 POKE &A000,45 : POKE &A001,3
20 PRINT DPEEK(&A000)
RUN
813
10 A=DPEEK(1000,2)
This retrieves data from address 1000 at segment 2.
ERROR: < Data negative> for address and segment
< Data > 65,535> for address
< Data out of range> if segment > 15
Vue de la page 72
1 2 ... 68 69 70 71 72 73 74 75 76 77 78 ... 207 208

Commentaires sur ces manuels

Pas de commentaire