home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
database
/
dbadvan.zip
/
DUMP.PRG
< prev
next >
Wrap
Text File
|
1987-02-14
|
1KB
|
39 lines
SET talk OFF
*sample data byte to start 29970
*sample data byte to end 30000
* find the memory range
INPUT "What byte to start?" TO byte
INPUT "What byte to stop? " TO lastbyte
DO WHILE byte <= lastbyte
*print the current address
? str(byte,6)
* print the next 10 bytes in decimal
STORE 1 TO counter
DO WHILE counter < 11
?? peek(byte)
STORE byte +1 TO byte
STORE counter +1 TO counter
ENDDO WHILE counter < 11
**backup and print the same 10 bytes in ascii
STORE byte - 10 TO byte
STORE 1 TO counter
DO WHILE counter < 11
*** if it is a printing character, print it ***
*** else print a "."
IF peek(byte) > 27 .AND peek(byte) <127
?? chr(peek(byte))
ELSE
?? "."
ENDIF peek(byte) > 27 .AND peek(byte) <127
STORE byte +1 TO byte
STORE counter +1 TO counter
ENDDO WHILE counter < 11
ENDDO WHILE byte <= lastbyte
*cleanup
RELEASE byte, lastbyte, counter
SET talk ON
***************************************************************
***************************************************************
***************************************************************
***************************************************************