Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Here is the problem. The bootloader is surpose to be on the first sector or something pointing 2 it. what you have written is -w 100 0 0 1 which is not the first sector. The first sector is address at -w 0 0 0 1. That might of been the proble which your booloader doesn't work
Here is the problem. The bootloader is surpose to be on the first sector or something pointing 2 it. what you have written is -w 100 0 0 1 which is not the first sector. The first sector is address at -w 0 0 0 1. That might of been the proble which your booloader doesn't work
w 100 0 0 1 is fine. Debug loads the program binary to offset 0x100 (typical of COM programs). w 100 0 0 1 tells debug to copy a sector from 0x100 (where the loaded file is) into disk 0 (floppy disk) sector 1 (bootsector).
Probably the bigger problem is that he has debug load os-test.asm as the "assembled" bootsector.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Another thing that cause this if you don't write it correctly which i found out can be a problem. I personly copy the cmd program and put it in the code directory. When you write the code to the disk you should have something like this:
You must have the cmd program inside the CodeDir or pointing to that which if don't do so my bootloaders or code won't be written to disk. Try that if it works problem solve if not, i don't know.
What the crap does having CMD.EXE in his directory have to do with that? He tried to write his unassembled source file to the bootsector, no more, no less.
Solar wrote:It keeps stunning me how friendly we - as a community - are towards people who start programming "their first OS" who don't even have a solid understanding of pointers, their compiler, or how a OS is structured.