[comp.sys.ibm.pc] How do I BSAVE?

jkg@gitpyr.gatech.EDU (Jim Greenlee) (12/23/86)

Here's one for all you BASIC hackers out there. What is the format for
a BSAVE header? The IBM BASIC manual has some cryptic explanation that
I don't really care to dig through. What I've gleaned so far is that the 
BSAVE header consists of 7 bytes - 1 byte of ID, 2 words of address, 
and 1 word of length. My questions are:

1. Should anybody care what the ID byte is? The example in the BASIC manual
   has '0FDH' as the ID. Would this be safe for most applications?
2. I assume that the address words are segment and offset. Is this true?
3. Can I just do something cheesy in Turbo Pascal to convert an Intel-Hex
   file to binary (with the header inserted at the beginning), or is it 
   more complicated than that?

For anyone interested, our application is downloading Intel-Hex assembler
output to a Tecmar E+EEPROM programmer in an IBM PC. For reasons which are
rather complicated to explain, we want to download the files to a diskette
in ASCII format and convert them to BSAVE format (the only thing that the
EPROM programmer understands). Direct serial transmission is not possible.
Any assistance is appreciated - e-mail is fine.

                                               Jim Greenlee

-- 
The Shadow...!{akgua,allegra,amd,hplabs,ihnp4,seismo,ut-ngp}!gatech!gitpyr!jkg

Jryy, abj lbh'ir tbar naq qbar vg! Whfg unq gb xrrc svqqyvat jvgu vg hagvy lbh
oebxr vg, qvqa'g lbh?!