home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
RBBS in a Box Volume 1 #3.1
/
RBBSIABOX31.cdr
/
phon
/
peek.c
< prev
next >
Wrap
Text File
|
1987-04-30
|
640b
|
44 lines
#include <dos.h>
unsigned peek(off,seg)
unsigned seg,
off;
{
unsigned int far *adr;
FP_SEG(adr)=seg;
FP_OFF(adr)=off;
return(*adr);
}
unsigned peekb(off,seg)
unsigned seg,
off;
{
unsigned char far *adr;
FP_SEG(adr)=seg;
FP_OFF(adr)=off;
return(*adr);
}
poke(off,seg,val)
unsigned seg,
off;
unsigned int val;
{
unsigned int far *adr;
FP_SEG(adr) = seg;
FP_OFF(adr) = off;
*adr = val;
}
pokeb(off,seg,val)
unsigned seg,
off;
unsigned char val;
{
unsigned char far *adr;
FP_SEG(adr) = seg;
FP_OFF(adr) = off;
*adr = val;
}