mikec@reed.UUCP (Cooper) (03/31/84)
Does anyone know of a method of recovering files from tape when you get a "?LOAD ERROR"? I seem to recall some method of poking the contents of the cassette buffer into memory, but I'm not sure of the poke values. Michael Cooper ...!tektronix!reed!mikec
calway@ecsvax.UUCP (04/05/84)
The easiest way to recover from a ?LOAD ERROR is to use a machine language monitor. You can do it with PEEKs and POKES, but it is a pain. If you are lucky, the only thing wrong with the file will be the BASIC pointer info. (I am assuming you are loading BASIC or else something that starts at the bottom of memory as if it were BASIC.) The important pointers are (decimal) 43 and 44 start of BASIC 45 and 46 start of variables (and end of BASIC) 47 and 48 start of arrays 49 and 50 end of arrays PEEKing the first two addresses should give you the values 1 and 8, or 01 and 08in hex. Reverse their order and you have the hex address for the start of BASIC: 0801. That's OK. But chances are that the next three pairs give the same value, which means the computer thinks there is no program in memory. You need to set each of these three pairs to values representing the address of the byte just after the end of your program. The following line, entered in the command mode as a single statement, will locate the end of your program: FORX=2049TO40959:IFPEEK(X)<>0ORPEEK(X+1)<>0ORPEEK(X+2)<>0THENPRINTX+4:NEXT This will print a long stream of numbers and then stop. The last number will be the address you want. Divide it by 256 and poke the result (disregarding any remainder) into 46, 48 and 50. Then take the result and multiply it back times 256 and subtract that product from the original address. POKE this value into 45, 47 and 49. And in case this doesn't work, write down the address, so you won't have to find it again. Now, try to LIST the program. If it LISTS OK, then you probably are home free, although you may need to clean up minor garbage here and there. If the LIST goes wacko, then your line links are screwed up and you really do need a machine language monitor. HES makes a nice one on cartridge that is only about $30-something. Hope this helps. Good luck. James Calloway The News and Observer Box 191 Raleigh, N.C. 27602 {akgua,decvax}!mcnc!ecsvax!calway