CP/M User
Veteran Member
I've been trying a bit of Assembly which has been compiling the program as a COM file for use in CP/M. But I found it interesting to note that some COM files have a EOF Marker at the end, and just wanted to know if there was some significance behind this.
I was having problems with my Assembly file, running it multiple times and at random it would crash the whole system - the program & CP/M. I thought this might have been a fault with the program, though then I thought that perhaps CP/M is crashing cause the program wasn't closing properly or something. I did a memory dump of the file and discovered that past the end of my program there was useless garbadge which was unnecessarily, then I remembered that CP/M must save files in 128 byte chunks which was how the rubbish was getting in. So I put a &1A byte at the end of the program and zeroed up the rest so it would be clean and simply found the program only really crashed after doing a number of things in CP/M, though thought to myself that perhaps CTRL-C was a cure. But yeah I wasn't sure what EOF marker does I thought if it offically closes the file then it maybe an important element to have in my programs.
I was having problems with my Assembly file, running it multiple times and at random it would crash the whole system - the program & CP/M. I thought this might have been a fault with the program, though then I thought that perhaps CP/M is crashing cause the program wasn't closing properly or something. I did a memory dump of the file and discovered that past the end of my program there was useless garbadge which was unnecessarily, then I remembered that CP/M must save files in 128 byte chunks which was how the rubbish was getting in. So I put a &1A byte at the end of the program and zeroed up the rest so it would be clean and simply found the program only really crashed after doing a number of things in CP/M, though thought to myself that perhaps CTRL-C was a cure. But yeah I wasn't sure what EOF marker does I thought if it offically closes the file then it maybe an important element to have in my programs.