Aucbvax.4284 fa.unix-wizards utzoo!decvax!ucbvax!unix-wizards Tue Oct 6 16:28:27 1981 Re: TOPS-10 Interchange Backup Tapes >From sdcarl!rusty@Berkeley Tue Oct 6 16:17:08 1981 This was written by Julius Smith last summer to read a DUMP format tape written on Stanford's Sail system. It is a quick-and-dirty but worked. # include # define NIN 512*5 # define NOUT 512*5 char mt[] = "/dev/nrmt0"; main(argc, argv) char **argv; { char t[NOUT],c[NIN]; register char *pt, *pc; register int fid; register int i, j; if ((fid = open(mt, 0)) == -1) { perror(mt); exit(1); } while (read(fid, &c[0], NIN) > 0) { for(j = 0; j > (i+1)) & (0177 >> i); # ifdef DEBUG printf(" -> %o\n", *pt); # endif DEBUG *pt++ |= (*(pc++ -1) << 0177; & |="((*(pc-1)" } *(PT-1) (7-I))>> 1) & 07); } *pt = '\n'; printf("%s", t); } } ----------------------------------------------------------------- gopher://quux.org/ conversion by John Goerzen of http://communication.ucsd.edu/A-News/ This Usenet Oldnews Archive article may be copied and distributed freely, provided: 1. There is no money collected for the text(s) of the articles. 2. The following notice remains appended to each copy: The Usenet Oldnews Archive: Compilation Copyright (C) 1981, 1996 Bruce Jones, Henry Spencer, David Wiseman.