flat assembler
Message board for the users of flat assembler.

Index > OS Construction > FDOS - DOS-like os in FASM

Author
Thread Post new topic Reply to topic
Victor Kindhart



Joined: 02 Feb 2015
Posts: 7
Victor Kindhart 17 Jun 2015, 17:48
My first 16-bit OS here - FDOS (aka FASM DOS). I am trying to create a Real Mode OS which will resemble MS-DOS tho it won't be compatible with it. GitHub repo is here: https://github.com/Vik2015/fdos

My question is, does anybody know how would I add a FAT12/16 support to my OS so I could load programs?[/url]


Last edited by Victor Kindhart on 17 Jun 2015, 21:46; edited 1 time in total
Post 17 Jun 2015, 17:48
View user's profile Send private message Reply with quote
Mike Gonta



Joined: 26 Dec 2010
Posts: 243
Mike Gonta 17 Jun 2015, 20:53
Victor Kindhart wrote:
My first 16-bit OS here - FDOS (aka FASM DOS). I am trying to create a Real Mode OS which will resemble
MS-DOS tho it won't be compatible with it. GitHub repo is here: https://github.com/Vik2015/fdos
Oops, you've got the period in the url.
Victor Kindhart wrote:
My question is, does anybody know how would I add a FAT12/16 handler to my OS so I could load programs?
Have you seen this.

A more livelier discussion of when DOS is not DOS is here.

PS. Have you seen MikeOS32

_________________
Mike Gonta
look and see - many look but few see

https://mikegonta.com
Post 17 Jun 2015, 20:53
View user's profile Send private message Visit poster's website Reply with quote
Victor Kindhart



Joined: 02 Feb 2015
Posts: 7
Victor Kindhart 17 Jun 2015, 21:58
Mike Gonta wrote:
Victor Kindhart wrote:
My first 16-bit OS here - FDOS (aka FASM DOS). I am trying to create a Real Mode OS which will resemble
MS-DOS tho it won't be compatible with it. GitHub repo is here: https://github.com/Vik2015/fdos
Oops, you've got the period in the url.
Victor Kindhart wrote:
My question is, does anybody know how would I add a FAT12/16 handler to my OS so I could load programs?
Have you seen this.

A more livelier discussion of when DOS is not DOS is here.

PS. Have you seen MikeOS32


Dot removed Smile
And I know what MikeOS is - it was the first tutorial on OS deving I found. Gonna read that other page now.

Btw, do you know how can I make a bootable floppy? AFAIK a typical floppy disk has at least one sector in the start of floppy, which contains a jump, label, etc. And it also contains a small amount of code only to display "This is not a bootable floppy...". I've tried to find some software which can help me create a bootable floppy - I could have a bootloader there with FAT 12/16 support which would find my kernel on the floppy and load it into memory (gonna change that to loading to high memory) and running it, but failed - the only thing I managed to find was A LOT of tutorials on how to create a repair/reserve floppy disk on linux :/. Actually I COULD write my own program tho I'd like to use a real soft, not some dirty hack Smile
Post 17 Jun 2015, 21:58
View user's profile Send private message Reply with quote
Mike Gonta



Joined: 26 Dec 2010
Posts: 243
Mike Gonta 17 Jun 2015, 22:19
Victor Kindhart wrote:
Mike Gonta wrote:
Have you seen MikeOS32
And I know what MikeOS is - it was the first tutorial on OS deving I found.
Then take a look at MikeOS32 and say goodbye to real mode code.
Victor Kindhart wrote:
Btw, do you know how can I make a bootable floppy?
Say goodbye to that too and make a bootable USB flash drive.

_________________
Mike Gonta
look and see - many look but few see

https://mikegonta.com
Post 17 Jun 2015, 22:19
View user's profile Send private message Visit poster's website Reply with quote
Victor Kindhart



Joined: 02 Feb 2015
Posts: 7
Victor Kindhart 17 Jun 2015, 22:52
Mike Gonta wrote:
Victor Kindhart wrote:
Mike Gonta wrote:
Have you seen MikeOS32
And I know what MikeOS is - it was the first tutorial on OS deving I found.
Then take a look at MikeOS32 and say goodbye to real mode code.
Victor Kindhart wrote:
Btw, do you know how can I make a bootable floppy?
Say goodbye to that too and make a bootable USB flash drive.


That is the point. I am trying to write it using 16-bit code Smile

And I suppose I can install FAT system in USB drive? It seems like the easiest one to handle.
Post 17 Jun 2015, 22:52
View user's profile Send private message Reply with quote
cod3b453



Joined: 25 Aug 2004
Posts: 618
cod3b453 10 Jul 2015, 20:47
You can create a bootable image in FASM; the only real requirement is that the signature be present at the end of the sector for the BIOS to start executing it. The jump is optional but a good way of forcing cs:ip to be expected values.
Code:
        format binary as 'img'

SECTOR_SIZE equ 512

org $7C00

start_of_sector:

        jmp 0:start

    start:

        ; code here

        times (SECTOR_SIZE - (end_of_sector - signature) - ($ - start_of_sector)) db 0

        signature dw 0xAA55

end_of_sector:     
This can be extended to include FAT tables and file system images, including the second stage bootloader/kernel etc. [You can also use the code for hard disk, usb and CD-with-floppy-emulation images.]
Post 10 Jul 2015, 20:47
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.