TRANSFERING AND USING PROM FILES 3-MAY-90 KERMIT USE Procedure for transfering PROM code from QUICKPRO files on the IBM PC to .DAT files on the VAX: Have the PROM files on floppy disk A on the PC, the example file is called file.dat. Under MSDOS from drive c: type cd\kermit, the procedure is simulated as follows: note: means type carriage return, ^] means type right bracket key while pressing the control key. PC PROMPT TYPE IN: COMMENT ----------- -------- ------- Kermit> kermit start PC kermit program KERMIT-MS> c sets vt100 mode on PC wake up the file server CS100t > connect xx.x.xx.x connect and log in as usual, and move to desired default (normal log in procedure ) directory on the VAX. $ kermit Start Kermit on the VAX kermit-32> Set File Type Binary tell it to expect binary files kermit-32> server server message will follow ^] c return from VT100 mode kermit-MS> Send a:file.dat Transfers file.dat to the current directory on VMS as file.dat.program will indicate progress of file transfer.Repeat as needed,MSDOS wildcards will work. kermit-MS> finish when you are through sending files c return to VT100 mode kermit-32> exit exit from Kermit on VAX $ again in VMS, use as you will $ lo logout eventually ^] c exit VT100 mode on PC kermit-ms> Quit exit from Kermit on PC kermit> back to MSDOS The file file.dat is now stored as a binary file on the VAX. MAKING SENSE OF A DUMPED PROM FILE in VMS VMS stores the binary files in blocks of 510 bytes, but displays a dumped binary file in blocks of 512 bytes. VMS adds a two byte header to the 510 bytes of data, therefore the address display provided by the VMS dump/byte is offset by 2 x # of block in file. An example of the format is shown below. Note that this block header disappears when a binary file is transferred back to a PC using Kermit; It is simply the way VMS stores and dumps binary files. Also, the sequence of bytes in the dump/byte display is right to left, so when looking at a block the addresses proceed from 00 at the upper right corner of the display to 1FF at the lower left corner of the display. This is the opposite from the way the QPRO prom burning program displays data on the PC Dump of file MSUTRGROOT:[000000.PROG_DEV.COMINT.DEV_DATA]CBPCAD1.DAT;1 on 2-MAY-1990 18:25:17.11 File ID (27992,59932,0) End of file block 5 / Allocated 8 Virtual block number 1 (00000001), 512 (0200) bytes ** ** these two bytes are added 03 03 03 03 03 03 03 03 03 03 03 03 03 00 01 FE ................ 000000 02 02 02 02 02 02 02 02 02 03 03 03 03 03 03 03 ................ 000010 07 07 07 07 07 02 02 02 02 02 02 02 02 02 02 02 ................ 000020 . by VMS, for the rest of . this block the PROM address . of the data is equal to the . block address minus 2.For . the example,the block . address = 0001D5 therefore . ** example prom address = 01D3 33 33 33 33 33 33 33 33 33 33 X1 33 33 32 32 32 2223333333333333 0001D0 00 00 00 00 00 00 00 00 00 00 00 00 00 33 33 33 333............. 0001E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 0001F0 Dump of file MSUTRGROOT:[000000.PROG_DEV.COMINT.DEV_DATA]CBPCAD1.DAT;1 on 2-MAY-1990 18:25:17.11 File ID (27992,59932,0) End of file block 5 / Allocated 8 Virtual block number 2 (00000002), 512 (0200) bytes ** ** 2 more bytes added by VMS, 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 FE ................ 000000 00 00 00 00 00 00 2E 2C 2A 28 26 24 22 20 00 00 .. "$&(*,....... 000010 . now prom address equals . (block address - 4) + 200. 00 00 00 00 00 X2 00 00 00 00 00 00 00 00 00 00 ................ 0001F0 ** example this byte is at block address 0001FA in the second block so add 200 hex for first block, making it byte number 0003FA in file, subtract 2 bytes for each block , 3FA - 4 = 3F6 = PROM ADDRESS The general formula is PROM ADDRESS = ((VIRTUAL BLOCK NUMBER - 1 ) x 200H ) + BLOCK ADDRESS - ( 2 x VIRTUAL BLOCK NUMBER ) For the first example ,X1, Virtual block number = 1, block address =0001D5 PROM ADDRESS = ( ( 1 - 1 ) x 200H ) + 0001D5H - ( 2 x 1 ) = 01D3H 0 + 1D5H - 2 = 01D3H For the second example,X2, Virtual block number = 2, block address =0001FA PROM ADDRESS = ( ( 2 - 1 ) x 200H ) + 0001FAH - ( 2 x 2 ) = 01D3H 200H + 01FAH - 4 = 03F6H