Fpeek and fpoke – Remote Processing CAMBASIC User Manual

Page 84

Advertising
background image

Comm ands - 51

FPEEK and FPOKE

Memory Function and Statement

SYNTAX:

a = FPEE K(address)
a = FPEE K(address,segment )

FPOKE address, data
FPOKE address, data, segm ent

PURPOSE:

FPE EK returns a floating point number previously stored in memor y.
FPO KE writes a floating point number to memor y.

REMARK S:

This functio n can be use d to write and retr ieve data stor ed in mem ory. This is ver y useful in data
logging and pr ocess data stor age and r etrieval.

The first syntax applies to the first 64K of memor y (segment 0). F or addresses above segment 0,
use the second syntax. Not all cards support segmented mem ory.

FPE EK and FP OKE are the fastest way to write and retr ieve data from mem ory.

RELATED:

DPEEK, DPOKE, PEEK, PEEK$, POKE, POKE$

EXAMPLE:

10 FPOKE &A000,1.25
20 A=FPEEK(&A000)

10 D=FPEEK(200,1)

ERROR:

< Data > 65,535> – address, data and segment
< Data negative> – for address
< Data out of range> – if segment > 15

Advertising