Dr_Acula
Experienced Member
A quick couple of questions for any resident CP/M experts: I'm using the CP/M bdos calls to read and write sequential files. For reading a file it is fairly easy as you put the file name in the FCB, set the temp DMA to the default DMA location of 80H, then call the openfile function, then the readseq function then the closefile function.
For writes however, I've found you need to two more things. First, call the erasefile function (in case the file already exists), and then call the createfile function. Then open the file, write a record and close it.
Is this the correct way to go about doing things?
And do I need to terminate all files with a ^Z?
Help would be very much appreciated.
For writes however, I've found you need to two more things. First, call the erasefile function (in case the file already exists), and then call the createfile function. Then open the file, write a record and close it.
Is this the correct way to go about doing things?
And do I need to terminate all files with a ^Z?
Help would be very much appreciated.