I used to do a heavy amount of assembly programming. If you want to start from scratch, i suggest going there. Of course assembly is terse; remember that it is only half a step removed from machine code: one instruction line equals one machine code instruction (unless you write some macros). If you decide to go with assembly, get ralph brown's interrupt list .txt.
a ".com" is pure machine code. Dos prefizes it with a "program segment prefix" which holds (the pointers to) important data; like the emegency failure routine, command line arguments, up to 2 supplied files, current environment, etc etc etc. it is 100 bytes long (.RADIX 16). In any event, the CS:IP (code segment & instruction pointer) points to byte 0 of the file. There is no imposed header, like in ELF or .exe files. They are a bit more complex in the setup, but machine code is machine code; and all memory is laid out linearly -- otherwise there would be no such thing as a buffer overflow attack. I can't think of any online tutorials that would do better than printed resources; check out your local barnes and noble.
Creating your own OS is extreemly ... involved. Most likely it will not run stand alone for a few incarnations -- remember that even linux required minix in order to work when it was being created.
[never mind, thanks void main];
I am probably telling you what you already know, so i will just shut up now. happy hacking
-t.
[ November 15, 2002: Message edited by: beltorak0 ]