FRIHOSTFORUMSSEARCHFAQTOSBLOGSCOMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Creating a new Operating System





Shirish
Friends I am working on building a fully functional Operating System from Scratch. Anyone who is interested can contact me or post in the forum

I am presently using Nasm as Assembler for bootloader
and C/C++ for Kernel Coding

It will be protected mode OS with a New GUI in high Resolution working on SVGA

Development has started and the source code will be published soon
of the modules i write or complete

Viewers can provide more optimized routines or ask any questions for their projects
v3nd0r
hmm, i can help you, some beta test, or start coding i know c/c++ and asm of course. So let me know if you whant me to help developing it.
Shirish
Foremost thing required for booting a computer is a BootLoader

So we re gonna begin working on a bootLoader

In fact Bootloader is the first thing which starts on your pc when you power it.

Bios loads Bootloader from a specific address 0x0:07C0 from the device set up in Bios

Moreover the system works in 16 bit mode

rest later
In next tutorial , we'll discuss Botloader generation.

Till that time , you can download Bochs or any emulator for your operating system like Microsft Virtual PC or Bochs as said earlier

It will help you a lot in OS Dev.

It will save you from frequent shutdowns.
izcool
Good luck with it, I hope it works out for you guys.

I would like to recommend a very useful tool to you guys for beta testing and all. It is called VMware Workstation, details can be found at http://www.vmware.com/products/desktop/ws_features.html . I've used it a few times on my own, it's really good.

That should be a little bit easier than plugging in an entirely different computer, wiping the hard drive, yadda, yadda, yadda.

Basically, you run the program, and it acts as a regular computer, but it uses a virtual hard drive to store the OS on. It uses your own disk space, but it doesn't add a partition or anything.

- Mike.
pawelek
I would like to test it.
How long are you working on it ??? I think that its hard work to do.
Good luck

Can you advice me, what book is good for beginners in C/C++ ??
Nirotu
Very impressive idea guys. Good Luck and please keep us all informed on your progress. And you probably don't know the answer to this yet, but what main features are you shooting for? and what current OS will it be similar too. Good Luck! Smile
nntien
Exciting topic! I just listen to all of you!
lockwolf
I really am up for new operating systems. Throw me a pm when you get around to the beta and Ill see what I can do!

I also want to know, is it going to distrubuted under the GPL or is it going to be commercial?
THE11thROCK™
Awesome job! Shirish it is really a nice project. I hope you'd be successful with it. Very Happy
simplyw00x
This looks like a very exciting project. Is there anything in this that will make it different to/better than current OSs? Here are a few suggestions:
- Encourage users not to use Admin-level accounts day-to-day
- Allow access to all levels of customisation
- DBFS and such, as detailled here

If you want help, I know some C/C++, can beta-test, and have a great deal of spare time for the next few weeks.
leodv
I been planning to work on an OS by myself as i wish to learn the concept of the multitasking OS. I have read up on some ASM and knows Java, i will need some time to learn C++ tho.
roguewrath
I am intersted in well in helping out. If you have a cvs repository or place with files I can see if I can contribute anything to the project.
Shirish
I will be uploading the code in the forum only

But the other files will be on my new site on frihost.net
as soon as i launch it

Ya this new os will be totally customizable
It would have a futuristic interface

it would treat all the files and data as objects
People would be able to link to other easily

and work could be done easily using speech or command line or desktop interface using Natural languages (English preffered)


Any more suggestions ?

I will post tye of interface i'm looking for soon

Basically it will be able to handle hardware very well
since i'm intrested in making it to be able to control miniature robots or bigger ones when it develops more.

People would be able to use it as a standalone OS for running their customised applications

By this ppl would have Customised Application OS ready to run


Presently any intrested coders can put up their version of bootloaders on the forum

you can also make suggestions for it about the features wanted

or any display interface like that in SUSE Linux

i like it very much

even mandrake is cool
Texas Al
What is going to be different between your OS and the dozens that are available out there (and I'm not just talking about Linux, Unix, and BSD variants, the dozens of other OS).

One of two possibilities exist. Either you are an experienced systems programmer or you aren't.

If you aren't an experienced programmer, you'll learn a lot, but it will take you forever just to make the OS work, let alone make it better. Still it's a worthwhile thing to take a stab at... if you get stuck, study some of the other open source OS's and see how they did it.

If you are an experienced programmer, you're wasting your talent! Join an existing OS project and add the features you'd like to see. If they don't accept your changes, fork your project, but at least you won't be starting from nothing! If you're interested in writing kernel stuff at least you'll have the higher level functionality of the existing OS you can put on top of it and immediately have something that is useful. If you're interested in writing something higher level, like a window manager or a file system, you can use it with the existing kernel.



I know I sound like one of those cranky people who are saying "It's impossible, it will never work!"

That's not my intention. Operating systems have been written before, so it's possible... I'm just saying that when you see the sheer amount of work this takes, you'll give up, and the work you've done up to that point will just be a bunch of unfinished code on your hard drive. On the other hand, if you take something that exists and make it better, you do have a chance of finishing that.

In any case, good luck! I'm not trying to discourage you, just to encourage you to start something you'll be capable of finishing.
n0obie4life
Geez, my only question is that will it be free and open sourced?
Shirish
Friends!
It will be opensource and freely available

We together will build a powerful Os

for that i need your constant support and suggestions

Thanks Texas

But I want to create my own

As You can put your name on it rather than join a new group
where u don't have a say on everything like its name and interface etc.
lockwolf
A nice feature that would help with hardware support would be if you can find a way so it uses the same drivers that are used in a win32 enviorment, just a thought.

Also, if by some miracle, you are able to pull this off, I will take up programing and create an operating system!
Shirish
lockwolf

the compatibility of drivers depends on the type of environment you are providing

that means the executable files which are provided by the OS

also the filesystem is very important

working on your idea, i suggest that

though i will provide several exe formats in my OS

bu i don't want to use win32 filesystem at present.

though i sufggest that you can emulate or provide a virtual environ for driver to work in you OS projects.
roguewrath
What kind of hardware were you planning to have in these robots? I assuming something like arm processors. I not sure exactly how one is suppose to make a bootloader without knowing the kind how many registers one will work with etc.
Kelcey
pawelek wrote:
I would like to test it.
How long are you working on it ??? I think that its hard work to do.
Good luck

Can you advice me, what book is good for beginners in C/C++ ??


I suggest you learn C first. C isn't as "friendly" as C++ is. But you get a deeper understanding of what C++ is doing if you know how C works. I recommend deitel and deitel books. They authored the book for my C++ class... pretty good.
frozenhead
Interesting... I have a knowledge in C and C++ but not really in an expert level..

In a small way I can help and be a "tester" of the OS if soon be opensourced..


Best Luck to all of you guys!.. You have my support! Keep us posted for the developments! Wink

________________
n0obie4life
Oh yeah, make sure I can play STEAM on it Very Happy.
Shirish
Friends

Building an OS not only requires carefull planning but a defined implementation and standards

So better come out with your new ideas for this new OS

Any techniques -> designing,programming ,almost anything is appreciated.
nasirmansoor
Wow what an amazing project
Guys go on with it .. ur plans r really cool !!

I can really help with ASM and some C++
I think we should all giv in wutever we can for this opensource and free OS .. and best of All we can have an OS with everything we want and in our way
htmlmaster
I am interested in making an Operating System too. Please show it to me when you finish, and, how do you make this GUI in C++? I can't even figure out the bloodshed dev C++ complier's Windows program. Would you be kind enough to give me some advice?
nntien
I used to download and try MenuetOS. I think it's programmed by assembly. Should try one time!
Shirish
I will be posting the source code of A BOOTLOADER soon

It would enable you to boot to system

it will display a picture

and other control and commands
to be executed
Neus
thats a rather cool project... ill make sure to keep an eye on this thread so i can see wahts the latest... goodluck guys Smile
Shirish
Code:

;-----------------------------------------------------------------------------------------------------------------------
;FAT12 BootSector Code for ZION Operating System
;Author: Shirish Goyal <shirishzone@gmail.com>
;Date: August 21,2005
;-----------------------------------------------------------------------------------------------------------------------
;Initializes the system
;Finds a file Loader.bin in FAT12 Floppy and loads it in RAM at 0x0500:0000
;Execute the Loader from RAM
;-----------------------------------------------------------------------------------------------------------------------

[BITS 16]

BOOTSEG         equ 0x07C0
STACKSEG        equ 0x9000
STACKLIMIT      equ 0xFFFF
LOADERSEG       equ 0x0050
ROOTOFFSET      equ 0x0200

;-------------------------------------------------
;set the Print Character Constants
;-------------------------------------------------
CR      equ 0x0D
LF      equ 0x0A
;-------------------------------------------------

[ORG 0x0000]

;----------------------------------------------------------------------------------------------------------------------
;FAT12 Boot Parameter Block
;----------------------------------------------------------------------------------------------------------------------
        jmp start                                           
        OEMName                 db "ZION  OS"                       
        BytesPerSector          dw 0x0200               ;Bytes Per Sector = 512 bytes
        SectorsPerCluster       db 0x01
        ReservedSectors         dw 0x0001               ;Reserved Sectors at Start of Floppy including bootsector
        TotalFATs               db 0x02
        MaxRootDirEntries       dw 0x00E0
        TotalSectorsSmall       dw 0x0B40
        MediaDescriptor         db 0xF0
        SectorsPerFAT           dw 0x0009
        SectorsPerTrack         dw 0x0012
        TotalHeads              dw 0x0002
        HiddenSectors           dd 0x00000000
        TotalSectorsLarge       dd 0x00000000
        PhysicalDrive           db 0x00
        Flags                   db 0x00
        Signature               db 0x29
        VolumeId                dd 0xFFFFFFFF
        VolumeLabel             db "ZION   BOOT"
        FATSystemType           db "FAT12   "
;----------------------------------------------------------------------------------------------------------------------
start:
        cli                                             ;disable interrupts before setting segment registers
       
        mov ax,BOOTSEG
        mov ds,ax
        mov es,ax                                       ;setup all Segment registers to start of Bootsector
        mov fs,ax                                       ;at location 0x7C00:0000       
        mov gs,ax
       
        mov ax,STACKSEG
        mov ss,ax                                       ;setup stack at 0x9000:0000
        mov sp,STACKLIMIT                               ;SP points to 0x9000:FFFF i.e. End of Free RAM
       
        sti                                             ;enable interrupts                     
 
    ;------------------------------------------------------------------------------------------------------------------
        mov si,msgLoading                               ;show welcome message
        call PrintMessage

Code:
------------------------------------------------------------------------------------------------------------------
    ;Load Root Directory Region after BootSector at 0x7C00:0200                 0x200=512 bytes
    ;Steps Required:
    ;1. Calculate Number of Sectors used by Root Dir Region and store in CX
    ;2. Find the location of Root Dir Region in FAT12 Structure and store in AX
    ;3. Read Root Dir Region and store to RAM at 0x7C00:0200
    ;------------------------------------------------------------------------------------------------------------------
    LoadRootDir:
            ;Step 1: Calculating No. of Sectors used by RootDir Region
            ;Sectors used = (Size of Entry in bytes * No. of Entries)/Bytes per sector
            xor cx,cx                                   ;initialize CX and DX
            xor dx,dx                                   
            mov ax,0x0020                               ;Each Root Dir Entry is 32 bytes(0x0020) in size
            mul word [MaxRootDirEntries]                ;find size of Root Dir Region
            div word [BytesPerSector]                   ;find no. of sectors used by Root Dir Region
            xchg ax,cx                                  ;store value in CX and initalize AX for next operation
           
            ;Step2: Finding the location of Root Dir Region in FAT12 Structure
            ;Location = Reserved Sectors + FAT Region Sectors
            mov al,byte [TotalFATs ]                   
            mul word [SectorsPerFAT]                    ;find no. of sectors used by FATs
            add ax,word [ReservedSectors]               ;store Location of Root Dir Region in AX
           
            mov word [DataAreaStart],ax
            add word [DataAreaStart],cx                 ;find location of Data Region for loading Loader later and save it
           
            ;Step3. Read Root Dir Region and store to RAM at 0x7C00:0200
            ;use ReadSectors routine using CX for Sector count , AX for Sector location and BX for location in RAM
            mov bx,ROOTOFFSET
            call ReadSectors
   
    FindLoader:
            ;check the root directory for root entry for loader
            mov cx,word [MaxRootDirEntries]             ;initialize loop counter
            mov di,ROOTOFFSET                           ;goto first root entry
        .FindLoop:
            push cx
            mov cx,0x000B                               ;Loader file has a 11 Character name
            mov si,LOADERNAME                           ;save loader name to SI
            push di
            rep cmpsb                                   ;compare SI with DI at byte level
            pop di
            je LoadFATRegion                            ;if loader found then load FAT to find its cluster chain
           
            pop cx
            ;continue till loader found or all entries searched
            add di,0x0020                               ;mov to next entry of 32 bytes
            loop .FindLoop                              ;decrement CX and continue till CX = 0
           
        .Absent:
            jmp LoaderFail

Code:
;------------------------------------------------------------------------------------------------------------------
    ;Load FAT Region for reading the Cluster chain of Loader
    ;Stores FAT Region with Sector Count CX, starting from location AX in FAT Strcture at location ES:BX in RAM
    ;Steps Required:
    ;1. Find Number of Sectors used by FAT Region
    ;2. Find location of FAT Region in FAT Structure
    ;3. Set Location of FAT in RAM
    ;------------------------------------------------------------------------------------------------------------------
    LoadFATRegion:
            ;save first cluster of Loader to conserve RAM space
            ;by overwriting Root Region in RAM by FAT Region at 0x07C0:0200
            mov dx,word [di+0x001A]                     ;Cluster is stored at offset 26 in Root Entry
            mov word [Cluster],dx                       ;Save First Cluster of Loader
           
            ;Step1: Find Number of Sectors used by FAT Region
            ;Sector Count=TotalFATs * SectorsPerFAT
            xor ax,ax                                   ;initialize AX
            mov al,byte [TotalFATs]
            mul word [SectorsPerFAT]
            mov cx,ax                                   ;Sector Count stored in CX
           
            ;Step1: Find location of FAT Region in FAT Structure
            ;Location=ReservedSectors+TotalFATSectors
            mov ax,word [ReservedSectors]               ;Location in AX ///////////////////////////////////////
           
            ;Step3. Set Location of FAT in RAM
            mov bx,ROOTOFFSET
            call ReadSectors
    ;------------------------------------------------------------------------------------------------------------------
    ;------------------------------------------------------------------------------------------------------------------
    LoadLoaderImage:
            ;Set location for Loader in RAM
            mov ax,LOADERSEG                            ;load Loader at 0x0050:0000 i.e. start of Free RAM
            mov es,ax
            mov bx,0x0000                               ;set IP for Loader Code
            push bx
       
        .LoaderLoop:
            ;Read sectors of Data Region corresponding to Cluster of Loader
            ;AX:starting location, CX:Sector Count, BX:Offset of Segment used in RAM
            mov ax,word [Cluster]                       
            pop bx                                      ;BX stores location to write in RAM
            call FAT2LBA                                ;AX stores location of Sector to be Read
            xor cx,cx
            mov cl,byte [SectorsPerCluster]             ;CX stores no. of sectors to read
            call ReadSectors
            push bx
           
            ;Find out next Cluster in Chain
            ;Each Cluster of 12 bits and hence Location of next cluster is at 3/2 of Cluster
            ;Location= Cluster+(Cluster>>1)
            mov ax,word [Cluster]
            mov cx,ax
            mov dx,ax                                   ;used for shifting
            shr dx,0x0001
            add cx,dx                                   ;CX stores location of cluster
           
            mov bx,ROOTOFFSET                           ;Location of FAT Region in RAM at 0x07C0:0000
            add bx,cx                                   ;BX stores location of next cluster in RAM
            mov dx,word [BX]                            ;DX stores next cluster value
           
            ;Each Cluster is of 12 bits
            ;For finding correct value of the next cluster from the pseudo cluster value, steps required:
            ;For Odd Cluster, take upper 12 bits of pseudo cluster value by right shifting
            ;For Even Cluster, take lowest 12 bits of pseudo cluster value by logical AND
            test ax,0x0001                              ;check if cluster odd or even
            jnz .OddCluster
           
        .EvenCluster:
            and dx,0000111111111111b
            jmp .ClusterLoop
        .OddCluster:
            shr dx,0x0004
        .ClusterLoop:
            mov word [Cluster],dx                       ;store new cluster
            cmp dx, 0x0FF0                              ;check if EOF
            jb .LoaderLoop
           
        .Complete:
            push word LOADERSEG                         ;save Segment and offset values to stack to enable jump by retf
            push word 0x0000
            retf                                        ;load Loader's SEG:OFFSET value from stack and execute code

Code:
;------------------------------------------------------------------------------------------------------------------
    LoaderFail:
        mov si,msgLoaderFail
        call PrintMessage
        jmp Fail
    Fail:
        mov si,msgReboot                                ;show message for reboot
        call PrintMessage
       
        mov ah,0x00                                     ;call BIOS Keyboard Service
        int 0x16                                        ;Wait for Keyboard input
       
        int 0x19                                        ;Reboot System

;----------------------------------------------------------------------------------------------------------------------
;FAT to LBA Routine
;Converts FAT Cluster no. in AX to corresponding Sector No. and store in AX
;LBA Sector= (FAT Cluster-2)*SectorsPerCluster+DataRegionLocation        ;First 2 clusters are reserved for FAT12
;----------------------------------------------------------------------------------------------------------------------
FAT2LBA:
        sub ax,0x0002
        xor cx,cx
        mov cl,byte [SectorsPerCluster]                 ;convert byte to word before multiplying
        mul cx
        add ax,word [DataAreaStart]
        ret
;----------------------------------------------------------------------------------------------------------------------
;LBA to CHS Addressing Routine
;Converts Linear Sector No. in AX to CHS(Cylinder ,Head,Sector) Scheme
;Sector= (LBA Sector(AX) mod SectorsPerTrack)+1              ;Sectors start from 1
;Head = (LBA Sector/SectorsPerTrack)mod TotalHeads
;Cylinder= (LSector/SectorsPerTrack)/TotalHeads
;DIV Operation: Quotient:AX  Remainder:DX
;----------------------------------------------------------------------------------------------------------------------
LBA2CHS:
        xor dx,dx                                       ;set DX=0 for storing Remainder for DIV Operation
        div word [SectorsPerTrack]
        inc dl
        mov byte [Sector],dl                            ;find Sector in CHS
       
        xor dx,dx                                       ;set DX to 0 again
        div word [TotalHeads]
        mov byte [Head],dl                              ;find Head in CHS
        mov byte [Cylinder],al                          ;find Cylinder in CHS
        ret
leodv
May I know which compiler to use for this code? TASM? NASM?
Asylum
What features do you plan on implementing and what type of o/s will it most likely be?
Shirish
I already answered those questions earlier

Well you can give your own suggestions

The code for bootloader is specially for NASM as it is open source too

I am using only open source tools to build my OS.
Donutey
do you have a website to show progress on your OS?
if you don't you should, it would allow much better feedback than in this forum thread, and more people could see your work.

Keep up the good work.
Shirish
Actually I am working on that part only due to which the project got delayed

I am creating a wiki on my OS

Thanks for interest in the OS

Keep in touch
kv
Just a question of curiosity. Why would one write his own os when lots of os are lying around, and many of them are opensource (like linux, freebsd, etc)?
Cryptz
will this be a Windows rip off Rolling Eyes
leodv
Quote:
will this be a Windows rip off Rolling Eyes


No one would like to create a software which is a direct ripoff of another software. I do not suppose the creator of this OS would like to copy windows too much, may only include functions that may prove useful.
Shirish
I am not using any pre-available designs in my OS like that of Windows

Though I am starting off with Windows Filesystem fat32 which i will change later on

I hope someone will post pictures of new interface designs here for my help

Did anyone checked out the code I posted
Actually it was incomplete
Its two functions are left for posting though I have created them.
Donutey
keep up the good work... really ambitious
Kd527
Wow, good luck! That's a huge project to build your own OS! Will it be able to run on Apple hardware? Also, will it be able to run other OS applications natively (like OS/2 could)? This could be interesting to watch... I still don't know if I would trust anything not UNIX based, but we'll see I guess...

BTW will it be open source?
Cryptz
Good Luck with it Very Happy
leodv
I suppose we could start off with creating CLI rather GUI first? Because we could test out any problem with the kernel and stuffs before dealing with the GUI.
Shirish
What kind of features are u looking for CLI

Main point of starting with GUI is because I want to start up on SVGA high resolution
and i am still stuck on that.

If someone can help out svga in assembly, plz do

Bye
leodv
We could use an display architecture like linux, client & server architecture.
Although linux only use client server for GUI, i was thinking of using client server for CLI too, this would eliminate the need for "telnet" and such. Unless you planning on developing a desktop OS. I suppose the CLI OS kernel could start from functions like booting into 32bit, whereas the bootloader only boots to 16bit, some sort of 2 tier booting. Following up could be functions to disk access, memory management, and task management, forgive me if you plan only to work on real time OS. If it's RTOS, then i suppose function like accessing the clock and text editor would be a great start.
Donutey
for a gui a really simple interface would be awesome (and easier to program) such as the win 95 bar, but without all the crashing Rolling Eyes
gamo
Texas Al wrote:
What is going to be different between your OS and the dozens that are available out there (and I'm not just talking about Linux, Unix, and BSD variants, the dozens of other OS).

One of two possibilities exist. Either you are an experienced systems programmer or you aren't.

If you aren't an experienced programmer, you'll learn a lot, but it will take you forever just to make the OS work, let alone make it better. Still it's a worthwhile thing to take a stab at... if you get stuck, study some of the other open source OS's and see how they did it.

If you are an experienced programmer, you're wasting your talent! Join an existing OS project and add the features you'd like to see. If they don't accept your changes, fork your project, but at least you won't be starting from nothing! If you're interested in writing kernel stuff at least you'll have the higher level functionality of the existing OS you can put on top of it and immediately have something that is useful. If you're interested in writing something higher level, like a window manager or a file system, you can use it with the existing kernel.



I know I sound like one of those cranky people who are saying "It's impossible, it will never work!"

That's not my intention. Operating systems have been written before, so it's possible... I'm just saying that when you see the sheer amount of work this takes, you'll give up, and the work you've done up to that point will just be a bunch of unfinished code on your hard drive. On the other hand, if you take something that exists and make it better, you do have a chance of finishing that.

In any case, good luck! I'm not trying to discourage you, just to encourage you to start something you'll be capable of finishing.



Is there a way to download and install linux, and have the operating system list
at startup appear in a certain order?

I want the list of OS's to look like this:

Microsoft Windows XP Pro
Microsoft Windows Recorvery Consell
Linux

I dont really need to chage the name of the OS's, but I do need to be able to easily uninstall it, not damage the computer, and have the list in this exact order.

If this requires editing a VERY important system file, then i'll just keep using knoppix.

Also, can you set Linux to install to a directory on my computer, instead of a HD partion? I *really* want to keep all my file and NOT reformat.

If anyone needs more info, I'll be watching the post.
mark
Thats so awesome. I would like to create one too. I would look forward for the 'release' of your Operating System.
leodv
gamo, you could install a boot loader, the common ones used for multi os booting system are grub and lilo..it would need 2 go some configurations to work tho. Unless u install an distro that includes the bootloader, maybe it would help you to setup through it's setup scripts or system.
cowboyx
This is a realy great idea and I would like to say it would all kinds of kool if you could make it better than windows! LOL
cowboyx
umm wouldnt it be hard to make drivers without getting a lawsuit
nntien
Learn more from this forum!
Thank you!
leodv
Does making your own driver for hadwarre will get you a lawsuit? I hope not, i suppose since it's free and meant for learning purposes and non-comercialize, it would b fine.
leodv
I did try to do some screen drawing with bios interrupt. I will post them as soon as I get home from work. Smile
Rhysige
Hmm Very interesting idea Smile I suppose all those free OS's came from somewhere so goodluck and I will keep watching development, I think if I get your idea right you will allow it to be cutomised which is something I do alot with windows.. but it usually requires editing stuff you shouldnt actually play with and using third party software.
leodv
Hmm, i wondered where my source code for vga drawing went to. Will post again when i find it.
Shirish
friends

finding svga help for initial startup is really a terrible problem

I tried a lot but drawing in svga like windoews or linux do is a lot dfficult

I f anyone has any comments do tell me

well i will try to load svga mode after loading total os if everything fails


Do provide links here of help available

also provide any other fetures u want at this stage

do give ur own source cxode if u have

it will b a great help
waiteck
Shirish wrote:
friends i am posting this bcz i m running short of points

please excuse me

friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit
friends

keep posting

sorry for the delay of one month due to loss of internet connection

i have created several files



if any one of u know how to play with svga code inn asm

please write down the method here so that all can benefit


Admins should look into this lol.. Spamming for points..
Donutey
idk... this is one of the more productive threads in the forums... unlike all the "tell us your hardware specs" etc. ones...
Shirish
Friends.
I am posting the code for second stage bootloader here

This loader loads a file loader.exe from the floppy and then loads kernel .exe from floppy

Besides it puts system in protected mode and initialization of svga is still to be done


Code:

;-----------------------------------------------------------------------------------------------------------------------
;FAT12 BootSector Code for ZION Operating System
;Author: Shirish Goyal <shirishzone@gmail.com>
;Date: August 21,2005
;-----------------------------------------------------------------------------------------------------------------------
;Initialize VESA Mode
;Initializes Protected Mode [32 bit]
;Finds a file Kernel.exe in FAT12 Floppy and loads it in RAM at :0000
;Execute the Kernel from RAM
;-----------------------------------------------------------------------------------------------------------------------

[BITS 16]

BOOTSEG         equ 0x07C0
STACKSEG        equ 0x9000
STACKLIMIT      equ 0xFFFF
LOADERSEG       equ 0x0050
ROOTOFFSET      equ 0x0200
IMAGESEG    equ 0x6400

[ORG 0x0000]
        jmp start

start:
        cli
       
        mov ax,LOADERSEG
        mov ds,ax
        mov es,ax
        mov fs,ax
        mov gs,ax
       
        mov ax,STACKSEG
        mov ss,ax
        mov sp,STACKLIMIT
       
        sti
        call ClearScreen
       
        mov si,msgSuccess
        call PrintMessage
       


Code:
;------------------------------------------------------------------------------------------------------------------
        mov si,msgLoading                               ;show welcome message
        call PrintMessage
       
    ;------------------------------------------------------------------------------------------------------------------
    ;Load Root Directory Region after BootSector at 0x7C00:0200                 0x200=512 bytes
    ;Steps Required:
    ;1. Calculate Number of Sectors used by Root Dir Region and store in CX
    ;2. Find the location of Root Dir Region in FAT12 Structure and store in AX
    ;3. Read Root Dir Region and store to RAM at 0x7C00:0200

Code:
;------------------------------------------------------------------------------------------------------------------
    LoadRootDir:
            ;Step 1: Calculating No. of Sectors used by RootDir Region
            ;Sectors used = (Size of Entry in bytes * No. of Entries)/Bytes per sector
            xor cx,cx                                   ;initialize CX and DX
            xor dx,dx                                   
            mov ax,0x0020                               ;Each Root Dir Entry is 32 bytes(0x0020) in size
            mul word [MaxRootDirEntries]                ;find size of Root Dir Region
            div word [BytesPerSector]                   ;find no. of sectors used by Root Dir Region
            xchg ax,cx                                  ;store value in CX and initalize AX for next operation
           
            ;Step2: Finding the location of Root Dir Region in FAT12 Structure
            ;Location = Reserved Sectors + FAT Region Sectors
            mov al,byte [TotalFATs ]                   
            mul word [SectorsPerFAT]                    ;find no. of sectors used by FATs
            add ax,word [ReservedSectors]               ;store Location of Root Dir Region in AX
           
            mov word [DataAreaStart],ax
            add word [DataAreaStart],cx                 ;find location of Data Region for loading Loader later and save it
           
            ;Step3. Read Root Dir Region and store to RAM at 0x7C00:0200
            ;use ReadSectors routine using CX for Sector count , AX for Sector location and BX for location in RAM
            mov bx,ROOTOFFSET
            call ReadSectors

Code:
FindKernel:
            ;check the root directory for root entry for loader
            mov cx,word [MaxRootDirEntries]             ;initialize loop counter
            mov di,ROOTOFFSET                           ;goto first root entry
        .FindLoop:
            push cx
            mov cx,0x000B                               ;Loader file has a 11 Character name
            mov si,KERNELNAME                           ;save loader name to SI
            push di
            rep cmpsb                                   ;compare SI with DI at byte level
            pop di
            je LoadFATRegion                            ;if loader found then load FAT to find its cluster chain
           
            pop cx
            ;continue till loader found or all entries searched
            add di,0x0020                               ;mov to next entry of 32 bytes
            loop .FindLoop                              ;decrement CX and continue till CX = 0
           
        .Absent:
            jmp KernelLoadFail
    ;

Code:
------------------------------------------------------------------------------------------------------------------
    ;Load FAT Region for reading the Cluster chain of Loader
    ;Stores FAT Region with Sector Count CX, starting from location AX in FAT Strcture at location ES:BX in RAM
    ;Steps Required:
    ;1. Find Number of Sectors used by FAT Region
    ;2. Find location of FAT Region in FAT Structure
    ;3. Set Location of FAT in RAM
    ;------------------------------------------------------------------------------------------------------------------
    LoadFATRegion:
            ;save first cluster of Loader to conserve RAM space
            ;by overwriting Root Region in RAM by FAT Region at 0x07C0:0200
            mov dx,word [di+0x001A]                     ;Cluster is stored at offset 26 in Root Entry
            mov word [Cluster],dx                       ;Save First Cluster of Loader
           
            ;Step1: Find Number of Sectors used by FAT Region
            ;Sector Count=TotalFATs * SectorsPerFAT
            xor ax,ax                                   ;initialize AX
            mov al,byte [TotalFATs]
            mul word [SectorsPerFAT]
            mov cx,ax                                   ;Sector Count stored in CX
           
            ;Step1: Find location of FAT Region in FAT Structure
            ;Location=ReservedSectors+TotalFATSectors
            mov ax,word [ReservedSectors]               ;Location in AX
           
            ;Step3. Set Location of FAT in RAM
            mov bx,ROOTOFFSET
            call ReadSectors

Code:
;------------------------------------------------------------------------------------------------------------------
    LoadKernelImage:
            ;Set location for Loader in RAM
            mov ax,IMAGESEG                             ;load Loader at 0x0050:0000 i.e. start of Free RAM
            mov es,ax
            mov bx,0x0000                               ;set IP for Loader Code
            push bx
       
        .LoaderLoop:
            ;Read sectors of Data Region corresponding to Cluster of Loader
            ;AX:starting location, CX:Sector Count, BX:Offset of Segment used in RAM
            mov ax,word [Cluster]                       
            pop bx                                      ;BX stores location to write in RAM
            call FAT2LBA                                ;AX stores location of Sector to be Read
            xor cx,cx
            mov cl,byte [SectorsPerCluster]             ;CX stores no. of sectors to read
            call ReadSectors
           
            cmp bx, 1024             ; Segment override (64kb)
            jne .SegmentOk
            mov ax, es                ; next segment ( add 64)
            add ax, 64
            mov es, ax
            mov bx, 0
           
       

Code:
.SegmentOk:
            ;Find out next Cluster in Chain
            ;Each Cluster of 12 bits and hence Location of next cluster is at 3/2 of Cluster
            ;Location= Cluster+(Cluster>>1)
            push bx
            mov ax,word [Cluster]
            mov cx,ax
            mov dx,ax                                   ;used for shifting
            shr dx,0x0001
            add cx,dx                                   ;CX stores location of cluster
           
            mov bx,ROOTOFFSET                           ;Location of FAT Region in RAM at 0x07C0:0000
            add bx,cx                                   ;BX stores location of next cluster in RAM
            mov dx,word [BX]                            ;DX stores next cluster value
           
            ;Each Cluster is of 12 bits
            ;For finding correct value of the next cluster from the pseudo cluster value, steps required:
            ;For Odd Cluster, take upper 12 bits of pseudo cluster value by right shifting
            ;For Even Cluster, take lowest 12 bits of pseudo cluster value by logical AND
            test ax,0x0001                              ;check if cluster odd or even
            jnz .OddCluster
leodv
Nice, i think i will try and port these codes to my zaurus, which is left in the dust
justinrs32
Sounds awesome. I know some stuff in C. If you have any questions let me know.

I, myself, made an OS. Only it was made with 100% ASM. It was basically like MenuetOS, which is a free OS made with ASM, except it had various improvments. It was just something to call my own, that I had fun making.

Good luck, hollar if you need anything.
bananaphone
PM me when you get a BETA and ill test it out!

Sounds really cool - good luck guys!
lockwolf
Either I havent been paying attention or just not visiting this section but its been a while since I looked at this topic and I cant wait for release of this! Keep up the good work!
garvalf4
Shirish, it's interesting what you're doing, but since you're on Frihost, why don't you start a website for presenting your project ? With full explanaitions, screenshots and such.

I'm fascinated by operative systems (except for ms windows), and I enjoyed to see the ultra compact menuetos. Why don't you collaborate to one of them ? (menuetos, syllable, haiku and such)

There is a good list there ;
http://en.wikipedia.org/wiki/List_of_operating_systems
seanooi
I could help you test it out when it's ready for beta testing. Just drop me a message in my PM inbox Laughing
Arnie
Same. I'll be testing it on old hardware like 286, 386, 486, P1, P2 and P3.
leodv
Nice listing of old PCs, i too have a few pentium 1s and 2s, 386 486..i just do not know what to be done to them. Maybe i will try to create beowulf. Shirish, be sure to post your website url soon. Very Happy Damn, i hate to work, else i would have started on my own OS.
Arnie
You can put light Linux distros on them or other free OSes.
leodv
Haha, i did get linux on them, but i can't find a purpose for them. Until i do, they are left there in the dust.
mike4652
First off I wish you well in your endeviors. Laughing
Good luck.
Lately I have been using XANDROS, and I must admit that it is ok
But it still dosen't match XP, as much as I regret to admit it.
I hope that someone will give us hope. I don't like the way that BG has gained control of the PC world, but other OS's just don't measure up.
The user innerface must be a real hard task.
I like XANDROS but it still is slower and less friendly than XP.
Good Luck and I will be watching your progress.
No help for lack of knowledge, but very hopeful for something better to be offered to the PC world Laughing
Rhysige
Its true, you have alot of people willing to Beta test but not enough capable of making this.
Donutey
Shirish-
you might have better luck if you looked around or posted in developer forums. Frihost people are mostly knowledgeble in things like HTML, CSS, Java etc... (web languages) Good Luck. Mr. Green
clogfan
Hi. This is a hell of a challenging project.

But I miss some things :
- I see a small list of proposed features, but I don't see the big picture. What platforms is it meant for (what cpu's, embedded,...), who will use this OS (general users, graphical designers, developers,...),... A common mistake with projects is not to determine the scope. You start writing a bootloader, without really knowing the next steps.
- This seems like a solo project : you write your code on your machine, without using a repository (like cvs). This makes it impossible to join forces and collaborate. Moreover, you ask everyone to send code for a bootloader : so basically you stimulate individual efforts instead of working together. I strongly advice using some good collaborative infrastructure, like sourceforge (www.sf.net).
- A technical design of the system would be interesting. How do you see the system, of which parts does it consist, how do these parts communicate to each other, what type of multithreading will be used,...
- I don't see anything about security, although this should be a key issue.
- ...

If you really want to make this a successful project, you'd better first think about it, and only start programming when you have a clear vision.

Good luck !
picsite
very cool....keep us updated on whats happening....i would like to see where this thing goes...btw how do u get time to work on it, this is like a 24/7 committment?
leodv
I suppose Shirish are interested in making the OS for educational purpose, i would say it will not match closely to any of the leading OS in the market now, but it will be a great learning experience. Shirish need our support in exchange of his motivation in the development of the OS. =) I'm willing to help, so tell me if you need me on the crew.
KHO
l've got an old 12gb win98 sittin in the other room gathering dust, if you have drivers to make the speakers work so that 5gigs of music l put on it forever ago doensn't go to waste, then l would be happy to beta test it for ya
Shirish
i'll try my best to run that on my pc

you can use it too when made, free
Shirish
Friends

You can send me different libraries in C
which will form the core library of OS

the more libraries you send more better support it will provide to varied applications

take care to send libraries which are compatible with gnu C
kv
I really don't believe in writing a new os when there are plenty of them -- really good ones like linux with source code available -- around. But I appreciate the enthusiasm of you people trying to put effort into something like this. I have been seeing this thread going on for a while with absolutely no progress. Statements like "we need to get a solid design first" "we should think of security" in the posts won't help. Here is a suggestion.

One of you (sirish should be the one i guess) should create a cvs repository somewhere and grant access to people who will work on this. A document sould be created. It need not be an elaborate doc but might define just scope, environment, overview, target, etc and may consist of details of other documents to come regarding design (high level, low level, etc). Then documents can be created for each of them as and when required and uploaded to cvs.
Once this process is started, people keep updating the document and after a while it will become more clear as to how things can proceed.

It will be better if a standard format is defined for the documents uploaded. This way, all the documents by different people will be consistent.

Good luck guys!
Shirish
I appreciate the views of ky

Even though cvs is a good point

but i don;t like them personally for the slow access rate they provide

I will start my own website instead where the ppl will be able to post their matter about the OS

Thanks for your views .
Shirish
Hello Friends

So the OS Work is going on its full scale.

I will be presenting the initial version by end of this month

So keep watching this group.

Also there is interesting news for all of you

that i am finally launching my Frihost site

www.digitalmind.frihost.net

Please check that out by end of this week i.e 21 Jan 2006

By then Cheers to all and Wish u a nice day
Shirish
Here is code for gdt.cpp
Code:

#include <kernel/GDT.h>

void GlobalDescriptorTable::DefineDescriptor(int num,unsigned long base,unsigned long limit,segmentTypeBit segmentType,descriptorTypeBit descriptorType,privilegeBit privilegeLevel,presentBit present,unsigned char granularity)
{
   GlobalDescriptor *gd = (GlobalDescriptor *) GDT_BASE + num;
        gd->SegmentLimitLow=(limit & 0xFFFF);
   gd->SegmentBaseLow=(base & 0xFFFF);
   gd->SegmentBaseMid=((base>>16) & 0xFF);
   gd->SegmentType=segmentType;
   gd->DescriptorType=descriptorType;
   gd->PrivilegeLevel=privilegeLevel;
   gd->Present=present;
   gd->SegmentLimitHigh=((limit>>16)& 0xFF);
   gd->Granularity=granularity;
   gd->SegmentBaseHigh=((base>>24) & 0xFF);
}

void GlobalDescriptorTable::CreateTable()
{
   /*DefineDescriptor(
                int num,
          unsigned long base,
            unsigned long limit,
           segmentTypeBit segmentType,
            descriptorTypeBit descriptorType,
             privilegeBit privilegeLevel,
              presentBit present,
                unsigned char granularity)
    */
   
    //NULL Descriptor
    DefineDescriptor(0,0,0,RES_1,SYSTEM,RING0,ABSENT,0);
    //CODE Descriptor
    DefineDescriptor(1,0,0x000FFF,RES_3,CODE_DATA,RING0,PRESENT,0x000C);
    //DATA Descriptor
    DefineDescriptor(2,0,0x000FFF,LDT,CODE_DATA,RING0,PRESENT,0x000C);
    
    for(int index=3;index<256;index++)
    {
        DefineDescriptor(index,0,0x000000,RES_1,SYSTEM,RING0,ABSENT,0x000C);
    }
}

void GlobalDescriptorTable::LoadGDTR()
{
    GDTRegister GDTR;
    GDTR.Limit=(unsigned short int)GDT_LIMIT;
    GDTR.BaseLow=(unsigned short int)GDT_BASE_LOW;
    GDTR.BaseHigh=(unsigned short int)GDT_BASE_HIGH;

    asm("lgdt (%0)": :"p" (&GDTR));
}

void GlobalDescriptorTable::Initialize()
{
    CreateTable();
    LoadGDTR();
   
    asm("mov $0x0010,%ax");
    asm("mov %ax,%ds");
    asm("mov %ax,%ss");
    asm("mov %ax,%es");
    asm("mov %ax,%gs");
    asm("mov %ax,%fs");
   
}


Code for gdt.h
Code:
typedef enum present_tag
{
    ABSENT=0x00,
    PRESENT=0x01
}presentBit;

typedef enum descriptor_privilege_tag
{
    RING0=0x00,
    RING1=0x01,
    RING2=0x02,
    RING3=0x03
}privilegeBit;

typedef enum descriptor_type_tag
{
    SYSTEM=0x00,
    CODE_DATA=0x01
}descriptorTypeBit;

typedef enum segmentTypeBit
{
    RES_1=0x00, TSS_16A=0x01, LDT=0x02, TSS_16B=0x03,
     CALL_GATE_16=0x04, TASK_GATE=0x05, INT_GATE_16=0x06,
     TRAP_GATE_16=0x07, RES_2=0x08, TSS_32A=0x09,
     RES_3=0x0A, TSS_32B=0x0B, CALL_GATE_32=0x0C, RES_4=0x0D,
     INT_GATE_32=0x0E, TRAP_GATE_32=0x0F
};

/********************************* Descriptor **********************************
BASE:   
        It defines thee location of Segment in the 4GB Linear Address Space.
        Three fragments are concatenated to form a single 32bit value.
LIMIT:
        It defines the size of Segment.
        Two fragments on concatenation give a 20bit value.
GRANULARITY:
        It defines the units with which LIMIT is interpreted.
        0: Units of 1byte        LIMIT:1Mb
        1: Units of 4Kb          LIMIT:4GB
TYPE:
        It defines various types of Descriptors.
DESCRIPTOR PRIVILEGE LEVEL:
        It defines the protection level.
SEGMENT-PRESENT:
        It defines if the segment can be used for addressing.
        0:Not valid
        1:Valid
ACCESSED:
        It defines if the segment has been accessed.
        0:Not accessed
        1:Accessed
*******************************************************************************/
typedef struct GlobalDescriptor
{
    unsigned short int SegmentLimitLow;
    unsigned short int SegmentBaseLow;
    unsigned char SegmentBaseMid;
    segmentTypeBit SegmentType:4;
    descriptorTypeBit DescriptorType:1;
    privilegeBit PrivilegeLevel:2;
    presentBit Present:1;
    unsigned char SegmentLimitHigh:4;
    unsigned char Granularity:4;
    unsigned char SegmentBaseHigh;
};

typedef struct GDTRegister
{
    unsigned short int Limit;
    unsigned short int BaseLow;
    unsigned short int BaseHigh;
};

class GlobalDescriptorTable
{
private:
    void LoadGDTR();
    void CreateTable();
    void DefineDescriptor(int num,unsigned long base,
                            unsigned long limit,
                            segmentTypeBit segmentType,
                            descriptorTypeBit descriptorType,
                            privilegeBit privilegeLevel,
                            presentBit present,
                            unsigned char granularity);
public:
    void Initialize();
   
};
garvalf4
will an iso of your operating system be available on your website ? I've just visited it, but there are some missing php files everywhere.
With an iso file, we'll be able to test it wih qemu for example.
Then you can post your projet at :
http://free.oszoo.org/index-2.html
bboy_nycb
Very good initiative !
i hope you will succeed in writing a new OS.
It must be very interesting and very exciting writing C code that works.
I can only use Perl and it will takes me some time to learn C .
Shirish
ya friends
it is great to find your kernel working

though i have the basic version which can start from grub

it can display logo in text

and then shows the info passed by grub

i am now working on memeory management

hope to include vesa facility soon

lets's see
munkey_boy
im a begginer at photoshop and real basic 2005
Shirish
Hey friends

I completed maximum of the part within last week

You can design logos for it if you re a designer

I have named it "Shunya"- it means zero in English

Well i will post the binary soon as soon as i complete the Interrupts part.

Then i will continue with keyboard.
Arnie
Got a hardware req list?
Talk2Tom11
I would love to help with this. I will do all the beta testing that you need. Is there a link to this OS so i can see the progress?
root
I haven't read all of the posts, but I saw some people asking on how to learn programming. I suggest you do not start with C or C++ if you are completely new to programming. Rather, start with something easier to learn like Visual Basic or Python. That way, the concepts you learn in the easier language will transfer over to C or C++, as they are pretty much the same, the syntax will be completely different though.
d722002
Something to try:
Multi-Platform Application Compatibility-
So we can use our Windows, Mac, or Linux apps on one OS!!

Edit:
Made a logo for ya!
[img]http://www.phantomware.frih.net/images/shunya_bw.bmp[/img]
Shirish
Friend

D77000 posted a picture

Well thanks for the attempt

but It didn't meet the requirements of a high profile designer

Send only good entries in future.

Also the initial version can be askd for at your email

I will mail you one.
mano1979
If you guys need a god logo, i would love to make you one. What sort are you looking for?

A bit more colorfull than the last post i hope?
mano1979
I can do quite some DTP and am a photographer, and quite good with photoshop. So just let me know.....

So when will the system be ready for use?
manumiglani
Shirish wrote:
Friends I am working on building a fully functional Operating System from Scratch. Anyone who is interested can contact me or post in the forum

I am presently using Nasm as Assembler for bootloader
and C/C++ for Kernel Coding

It will be protected mode OS with a New GUI in high Resolution working on SVGA

Development has started and the source code will be published soon
of the modules i write or complete

Viewers can provide more optimized routines or ask any questions for their projects


where r u from in India ? may be we can meet. can't we ?
Shirish
Hey Friends

I am from India
I study in Guru Nanak Dev university,Amritsar, Punjab
doing B.Tech Computer Sci.

I love Image Processing, Robotics, Operating Systems and any Core Computer Studies.
Shirish
All those proficient in DTp and Photoshop

They can try some cool wallpapers if they want to see them in my OS

They must be innovative and contain a "Zero" that is O

So use your imagination and you may win 50 Fri$ each whose entry is used in OS

Please help in the task
Shirish
If you can create good website in php with good features like uploading html files which would be dispalayed as enteriesds on pages and which on clicking display those html files

I can give you 100 fri$ for that .Grphics work would be done by me.

You can just do the coding work . Although I have accomplished the work bu t i don't have time to do rest of the work myself.

S o if you can help just contact me on email given above.
Arnie
Arnie wrote:
Got a hardware req list?
(of your OS, so I know what sort of machine to reserve for it.)
cowboyx
I would very much like to do bete testing. . . please contact me!
Shirish
Friends in the following postings , I will be listing the different requirements and features of Shunya OS

Prerequisites

Hardware Requirements

‘Shunya’ is based on x86 Intel Platform and requires minimum of hardware to operate. Actually in that terms, it can be said that most of the requirements have become standards in Industry today and it would be difficult to find a PC which doesn’t satisfy the environment. As the OS has not been tested on AMD based PC’s , hence nothing can be said about it. Well it can be extended easily for AMD too as it based on Object Oriented Concept and uses Machine level instruction to bare minimum for maximum compatibility. The list below provides the minimum hardware requirements for execution of OS.

Intel 80386,80486,Pentium based PC
(Other Systems which based on Intel Architecture and x86 Instruction Set may be supported too).

Color VGA Monitor
Shunya utilizes color text mode for initial startup. In future versions , VESA Interface may be provided.

A Standard 101 key AT Keyboard and Controller
Shunya controls the A20 Address Line through Keyboard Serial Controller. Though code can be changed based on System Manufacturer Documentation.

Minimum 1 MB RAM
Shunya can support maximum of 4GB RAM through Protected Mode by enabling A20 Address Line. Though minimum 1MB RAM is required for bare operation even for Real Mode.

A Standard 1.44 MB Floppy Drive
A Floppy Drive is required to boot the System using Kernel binary which is in form of Floppy Image created using PartCopy utility.

--

Development Tools & Environment

DJGPP Compiler

DJGPP, an acronym for DJ's GNU Programming Platform developed by DJ Delorie, is a complete 32-bit C/C++ development system for Intel 80386 (and higher) PCs running DOS. DJGPP is Free C++ Compiler including ports of many GNU development utilities. The ported GNU packages are, free and, the library and utilities developed specifically for DJGPP, are distributed under the GNU license. DJGPP supports platforms having a huge installed base, and it is highly popular among MS-DOS/MS-Windows users.

Nasm Assembler

NASM is an open source x86 assembler designed for portability and modularity. It supports a range of object file formats including Linux a.out and ELF, COFF, Microsoft 16-bit OBJ and Win32.

Ld Linker
Ld combines a number of object and archive files, relocates their data and ties up symbol references. Ld accepts Linker Command Language files written in a superset of AT&T's Link Editor Command Language syntax, to provide explicit and total control over the linking process.
Different formats may be linked together to produce any available kind of object file. Aside from its flexibility, the GNU linker is more helpful than other linkers in providing diagnostic information. Many linkers abandon execution immediately upon encountering an error; whenever possible, Ld continues executing, allowing you to identify other errors (or, in some cases, to get an output file in spite of the error).

Bochs Emulator

Bochs is a highly portable open source Cross Platform IA-32 Emulator written in C++, which runs on most popular platforms. It includes emulation of the Intel x86 CPU, common I/O devices, and custom BIOS. Currently, Bochs can be compiled to emulate a 386, 486 or Pentium CPU. Bochs is capable of running most Operating Systems inside the emulation including Linux, Windows® 95, DOS, and recently Windows® NT 4. Bochs was written by Kevin Lawton .The 'typical' use of Bochs is to provide complete x86 PC emulation, including the x86 processor, hardware devices, and memory. This allows you to run OS's and software within the emulator on your workstation, much as if you have a machine inside of a machine

SciTE Editor

SciTE is a SCIntilla based Text Editor. Originally built to demonstrate Scintilla, it has grown to be a generally useful editor with facilities for building and running programs.
SciTE is currently available for Intel Win32 and Linux compatible operating systems with GTK+.

PartCopy

PartCopy is a free utility which creates image of Floppy or Hard-Disk which can be used for Distribution purposes or testing on Emulator. Though there are other utilities which support same feature like Raw-Write provided free under GNU License. A utility for creating Boot-Disks was also designed during the project which can be used only for 1.44 MB Floppy Disks.

--

Setting Up the Development Environment

Shunya OS was developed using DJGPP , LD Linker and Nasm Assembler. DJGPP needs to be installed in the home directory say C:\djgpp. It has number of directories with compiler and linker in Directory <binutils>.

To work in global environment, the environment variable has to be set up in the System variables in Windows XP. Also the path to bin directory must be set in PATH variable.

Then the compiler can be called by ‘gpp’ from anywhere on the command line. Another variant of ‘djgpp’ i.e. ‘gxx’ is generally used for Windows to compile C++ programs. In case of C files , ‘gcc’ can be used.

Linker available in ‘bin ‘ directory can be called directly by ‘ld’ command.

Bochs emulator used for testing the compiled kernel binaries must be installed in root directory. It requires a bochsrc.bxrc script file which list the configuration of the x86 system we want to emulate.

A Bochs script is written with a floppy interface and ‘lgpl-elpin’ VGA-Bios which supports enhanced color modes.

SciTe Editor is used for writing all types of codes .It provides very efficient indentation and text editing features.

Partcopy is a general utility which is in the root directory

--

Boot Process

Boot Sequence

When power is applied to the computer , it triggers RESET pin on processor, which causes processor to read from memory location 0xFFFFFFF0 and executes code from that point. This address is mapped to Read-Only Memory (ROM) containing BIOS. The BIOS must poll the hardware and set up an environment capable of booting the operating system. BIOS functionality can be broken into three areas: Power On Self Test (POST), Setup and Boot.

The main function of the POST is to test and initialize the various hardware components detected by the BIOS. As part of the POST routine, hardware devices also register themselves with the BIOS as associated with or "hooked" into certain interrupt values. For instance, by convention on the Intel platform, all hard drives register with the 13h interrupt. This allows programs to invoke this software interrupt to communicate with disk drives, utilizing device driver code within the BIOS.

Many modern operating systems supply their own 32-bit device drivers once fully running, but these operating systems do make use of BIOS routines to initially load the operating system from disk.

Once POST operations are complete, the BIOS offers the user the option of entering "Setup" mode. The user may change the configuration of the BIOS, including the boot sequence here.

The last action of the BIOS is to execute the 19h interrupt, which loads the first sector of the first boot device. Since this is the location of the boot loader, execution of the 19h interrupt transfers control to the boot loader. The hard drive and other devices, such as CD-ROM drives, can register as bootable and be put on a list of bootable devices, which is prioritized by the user during the "Setup" mode.

Once the BIOS loads the first sector of the boot device into RAM, the boot loader begins execution .In the case of a hard drive, this first sector is referred to as the Master Boot Record (MBR) which contains the partition table describing the partitions defined on the hard drive. It also contains a program, the boot loader, which will load the first sector of the partition marked as active into RAM and execute it. The size of the MBR is limited to one sector on disk or 512 bytes, since it is located within the first sector of the drive at cylinder 0, head 0, sector 1. This size limitation greatly limits its functionality. Typically boot loaders have been highly integrated with the operating system that they support. This integration cuts down on the operations a boot loader must perform, making a 512 byte boot loader feasible. When more functionality is required, a multi-stage boot loader must be used.

--

Dealing with GRUB

A multi-stage boot loader provides more function and flexibility by working around the 512 byte size limitation. Rather than consisting of a single program which loads the operating system directly, multi-stage boot loaders divide their functionality into a number of smaller programs that each successively load one another. This architecture allows a fairly primitive boot loader, located in the MBR, to load and execute the next stage of the boot loader, a larger and more sophisticated boot loader.
Subsequent stages can be located elsewhere on the hard drive and thus are not subject to the single sector size limit. This chaining of boot loaders allows the boot loader functionality to become arbitrarily complex.

LILO and GRUB are two well-known multi-stage boot loaders capable of booting a number of operating systems including Linux, Windows and FreeBSD. Both first "bootstrap" themselves into operation, then present the user with a number of OS boot options.

While boot loaders can exist as standalone software, as GRUB demonstrates, they are most often tailored to and integrated into a specific operating system. This has led to a situation where each operating system requires a customized boot loader. One movement to define a clear-cut API between the boot loader and operating system is the Multiboot Specification, developed and maintained by the Free Software Foundation .

The Multiboot standard defines three main aspects of the interaction between the boot loader and the operating system:
1. The format of the operating system image, as perceived by the boot loader,
2. The state of the system when the boot loader starts executing the operating system, and
3. The format of the information passed by the boot loader to the operating system

The Multiboot specification describes the header that must be included in the operating system image, the values that must be in certain registers (not all registers are specified), and the format of the information passed to the OS. Currently the only programs that fully support the specification are GRUB, the Mach kernel and the Fiasco operating system, while others such as Linux are somewhat Multiboot compliant.
The advantages of such a specification are several. It allows the developers of new operating systems to make use of existing boot loaders without having to write one themselves. Having such a clearly defined interface also adds a level of modularity and transparency to the boot process.

GRUB, acronym for Grand Unified Bootloader, can be used to load Shunya OS. GRUB is divided into two stages which load the kernel while initializing several system related tasks for the kernel. For building a Multiboot compliant kernel using GRUB , a Multiboot Header containing useful information must be loaded with 8K of Kernel File and aligned on dword (4-byte ) boundary. The pointer to Header structure containing values for various fields can be passed to kernel through EBX . A Stack of 8k is defined in a loader (Loader.asm) which stores values of EAX and EBX for passing to main() function in kernel.cpp.

;GRUB Multiboot Macros
multiboot:
MULTIBOOT_PAGE_ALIGN equ 1<<0
MULTIBOOT_MEMORY_INFO equ 1<<1
MULTIBOOT_AOUT_KLUDGE equ 1<<16
MULTIBOOT_HEADER_MAGIC equ 0x1BADB002
MULTIBOOT_HEADER_FLAGS equ MULTIBOOT_PAGE_ALIGN |MULTIBOOT_MEMORY_INFO |
MULTIBOOT_AOUT_KLUDGE
MULTIBOOT_CHECKSUM equ -(MULTIBOOT_HEADER_MAGIC+ MULTIBOOT_HEADER_FLAGS)

;GRUB Multiboot header
ALIGN 4
multibootHeader:
dd MULTIBOOT_HEADER_MAGIC
dd MULTIBOOT_HEADER_FLAGS
dd MULTIBOOT_CHECKSUM

; AOUT kludge
; Following values are filled by Linker
dd multibootHeader
dd startup
dd dataEnd
dd bssEnd
dd startup
...
push ebx ; points to Multiboot Header
call _main ; jumps to C Kernel
...

--

General Bootloader Design

Though Shunya uses GRUB for boot loading as it can handle variety of kernel formats and satisfies multiboot compliant specification, but during development of Shunya, a general Bootloader was created which consisted of three parts.
boot.asm, loader.asm and Akernel.asm.

boot.bin initialized form 0x7C00 and loaded a FAT16 Structure Loader from Floppy by using Root Directories and finding out file named ‘Loader.bin’ by loading FAT Region for reading the Cluster chain of Loader. Then it loaded the Loader image in RAM from floppy and executed it. A bootsector must be 512 bytes in size and contains 0xAA55 as Boot Signature for last 2 bytes.

Loader.bin on execution enabled the A20 Address line and loaded the Akernel.bin file form floppy by the same procedure followed for loader.bin. Finally , it sets up Global Descriptor Table and Interrupt Descriptor Table, and initializes the 32 bit Protected mode. It then jumps to AKernel.bin for execution.

AKernel.bin forms the interface between Assembly code and C Kernel . it calls the main() function in C Kernel from where the OS initializes. Although it was not necessary to design the Akernel file but it helped in multiboot compliancy.

During the whole Design of Bootloader, interactive messages are displayed . It not only helps in attracting user’s attention but also aided in debugging the initial assembly code which was difficult to trace at runtime using Bochs Emulator.

--

Real and Protected Mode

The Intel Architecture supports following operating modes and a quasi-operating mode.

Real-address mode.
This operating mode provides the programming environment of the Intel 8086 processor, with a few extensions (such as the ability to switch to protected or system management mode).

Protected mode.
This is the native operating mode of the processor. In this mode all instructions and architectural features are available, providing the highest performance and capability. This is the recommended mode for all new applications and operating systems.

Virtual-8086 mode.
In protected mode, the processor supports a quasi-operating mode known as virtual-8086 mode. This mode allows the processor to execute 8086 software in a protected, multitasking environment.

--

Real Mode

Following a hardware reset (either through a power-up or the assertion of the RESET# pin) the processor is placed in real-address mode and begins executing software initialization code from physical address 0xFFFFFFF0. Software initialization code must first set up the necessary data structures for handling basic system functions, such as a real-mode IDT for handling interrupts and exceptions. If the processor is to remain in real-address mode, software must then load additional operating-system or executive code modules and data structures to allow reliable execution of application programs in real-address mode.

In real-address mode, the only system data structure that must be loaded into memory is the IDT. By default, the address of the base of the IDT is physical address 0H. This address can be changed by using the LIDT instruction to change the base address value in the IDTR. Software initialization code needs to load interrupt and exception handler pointers into the IDT before interrupts can be enabled. The actual interrupt and exception handler code can be contained either in EPROM or RAM;
however, the code must be located within the 1-MByte addressable range of the processor in real-address mode. If the handler code is to be stored in RAM, it must be loaded along with the IDT.

--

Protected Mode

The processor is placed in real-address mode following a hardware reset. At this point in the initialization process, some basic data structures and code modules must be loaded into physical memory to support further initialization of the processor. Before the processor can be switched to protected mode, the software initialization code must load a minimum number of protected mode data structures and code modules into memory to support reliable operation of the processor in protected mode. These data structures include the following:
• A protected-mode IDT.
• A GDT.
• A TSS.
• (Optional.) An LDT.
• If paging is to be used, at least one page directory and one page table.
• A code segment that contains the code to be executed when the processor switches to protected mode.
• One or more code modules that contain the necessary interrupt and exception handlers.

Software initialization code must also initialize the following system registers before the processor can be switched to protected mode:
• The GDTR.
• (Optional.) The IDTR. This register can also be initialized immediately after switching to protected mode, prior to enabling interrupts.
• Control registers CR1 through CR4.

Protected mode is entered by executing a MOV CR0 instruction that sets the PE flag in the CR0 register. (In the same instruction, the PG flag in register CR0 can be set to enable paging.).

--

C Library Support

Working on Kernel development is a tedious task as there is no C Library available. In other words , file headers cannot be included directly for performing simplest of functions. Either a new C Library has to be designed from base or a custom library like that provided by GNU can be ported for existing system.
The C library implements the standard C functions (i.e., the things declared in <stdlib.h>, <stdio.h> and other) and provides them in binary form suitable for linking with user-space applications.
In addition to standard C functions (as defined in the ISO standard), a C library might (and usually does) implement further functionality, which might or might not be defined by some standard. The standard C library says nothing about networking, for example. For Unix-alike systems, the POSIX standard defines what is expected from a C library; other systems might differ fundamentally.
Shunya has its own simple set of functions defined for C Library which include String Manipulation , Comparing using strcpy(), strlen() and Memory handling using memset(), memcpy() .
Some of the assembly level code like that dealing with I/O interface such as outb(), inb() have been inlined in GNU C++
All these files are directly compiled and linked statically with kernel in form of libstdc.a., which can be called by any module anywhere by just including the required header in <lib> directory.
At present stage, Shunya has a bare minimum library functions which are required to just handle the most important tasks. In future versions, it is planned to include support for dynamic link libraries.
Due to incompatibilities in DJGPP and Linker Ld , sometimes the library format and kernel format don’t match and Objcopy can be used for inter conversion into other formats.
Objdump can be used to produce the dump of the different sections of libraries and kernel to find out inconsistencies posed by unresolved symbols.

--

Future of Shunya

Shunya at present stage cannot be considered an OS as it cannot be used as Development Environment and neither it supports any FileSystem. But it is under continuous development and in future , it will definitely provide a working environment with Graphic User Interface with a completely new FileSystem.

Development Tools & Environment

At present Shunya supports no Development tools and provides no environment for that purpose. Though other OS Developers can extend the code using their own code which can be compiled along with the kernel. In near future, a new assembler and ported GCC Compiler will be provided for development.
Arnie
Lolz that's enough info. You could make a website of that Wink
yomasta3
Wow thats amazing!!

I was wondering, is it going to be like a different version of linux or just a brand new OS? Also, do you have a website for it?

Thanks,
yomasta3
Shirish
He friends,

Its amazing that all my postings have been nulled and my points removed because one of the moderators thinks that i have copied the matter from other source.

Well that's never been my intention and all my matter is original.

Also, i have never been involved in such tasks and am a valuable contributer to group.

So moderators must look out for the junk postings rather than useful ones by peole like us.

What kind of stand do u have on this matter.

In one of the previous posts , domeone told me to use a website to post the matter,, but i used the group to cater to many people.


Thanks
heady233
Shirish wrote:
Friends I am working on building a fully functional Operating System from Scratch. Anyone who is interested can contact me or post in the forum

I am presently using Nasm as Assembler for bootloader
and C/C++ for Kernel Coding

It will be protected mode OS with a New GUI in high Resolution working on SVGA

Development has started and the source code will be published soon
of the modules i write or complete

Viewers can provide more optimized routines or ask any questions for their projects

When it's in beta I will try it out for you.
Arnie
My stand is posting such huge amounts of text on a forum isn't a good idea, as I already expressed in my suggestion above.
kv
Creating operating system is not a trivial job. I wish you all the success. At the same time, why don't you create a forum for this os you are developing? All the interested people can join the forum and discuss. You could have subtopics for kernel, bootloader, etc. You can host the forum in your frihost account itself.

My 2 cents.
Shirish
ya i am working on that

I am building my website. it would be a tutorial managemnt system in php

but i am facing the management issues in code

it is difficult to handle the graphics and dynamic code.

i will try my best to come up with design soon.
Shirish
Hey friends

The time has come for which we all were waiting.

Finally the site is up for display

you can access at

www.digitalmind.frihost.net

It will show the Operating system section under the heading Shunya OS in Advanced Section


Please register on the site
Shirish
Graphic User Interface

Design plan of Shunya for Graphic User Interface includes employing VESA 3.0 interface with latest Graphics Cards for optimized speed in Graphics manipulation and display. It will be based on concept of X11 servers which don’t clash with Operating System operations and provide a consistent interface for different Graphics toolkit. Considering the growing popularity of Desktop based OS , Shunya GUI will be interactive and compliant to Human –Interface Guidelines.
Master-
This little OS seems to be able to be something.

Im willing to be a beta tester when its time!
redice
You may post something like the system structure, which CPU(x86/mips/ppc/ARM) it suport, why this new one but linux/BSD or M$? Is it higher speed, easy to use, easy to program, support more driver?

I am study linux for a very long time, my work is all about linux. Now, linux is wild used as desktop system for end users, or embedded OS running in mobile、mini control, router, VOIP devices etc, or high performance server (www, database, mail or waht ever you like) ...

Why not build a linux based system from stratch.
Shirish
Well for all those questions

you can find answer on my website
www.digitalmind.frihost.net

in advanced sections in Shunya OS

i have already told about the structure and CPU itr supports there
and earlier too

also anyone who have queries and want to learn to build their own new OS can register on my website and do mail me when u register there

I will start the process of tutorials only when a subststntial visitors want the OS tutorials
brad31337
Hey,

Very cool thing you are working on here. Unfortunately my programming skills aren't anywhere near this advanced. However I would be able to work on the GUI part of it. Using my photoshop skills etc. Which also makes me think. The OS should be EASILY skinnable. I may be able to help with this. and of course i would love to BETA test...

Thanks
Brad
Shirish
Hey Brad

Don't worry if you don't have those killing Programming skills

Just start out and you will catch the train one day

You can start creating logos and wallpapers for Shunya OS

Just checkout my site as listed above to know about the logo pic on Shunya Section in my website

It contains a logo picture on the main page of Shunya section

U can use that to develop your own creative logos and wallpprs fore it.
Shirish
well branden the wallpaper you hust sent me the link was a good try

But i didn't just wanted you to copy the logo from my site and then apply filters and blend with a cool game flare sorta thing

Just go out of your imagination and just mess with the logo completely to create stunning 3d wallpapers

you can just make your own logos and also mess with my logo

I n case you want to use that just put its small version down in right

rest everything should be your own and 3d effects a must.

like those cool windows andf linux wallpapwers.

Thanks again Branden for your efforts .

Others must also come out with their own cool designs.
brad31337
The name is Brad But I'll re-create ur logo in some 3D Software and see wat happens...
Arnie
I will not be able to beta-test since I do not have VESA 3.0 video cards. If you could create VESA 1.2 or 2.0 alternatives, that would be useful. If you look at the system requirements, it would be senseless to require VESA 3.0 because computers from the Pentium age and older are perfectly able to run the OS, except that their VGAs are VESA 1.2. This is a problem that I often encounter when testing new OSes and it would be a pity if your OS would have it too.
lukeropro
What are VESA video cards? I have never heard of them..I don't think I have them too...Anyway, try to make it compatible with a wide range of specs including the so-called noob ones so that everyone can use it. I hope to be your beta-tester!
Arnie
(Nearly?) every video card conforms to the VESA standards. The newer the card, the newer standard it supports. VESA 3.0 is the newest.
Shirish
well inever said it will support vesa 3.0 interface

Infact i personally have vesa 2.x card

Even then i think vesa 3.0 will be downward compatible with previous versions.


so don't worry at all

More grave problems deal with that of compatibilty windows and linux

and hardware support for maximum devices
Arnie
Ok, I'm glad to hear that. But note that VESA 2.0 is not backwards compatible with 1.2. Of course VESA 2.0 cards can be used for VESA 1.2 operating systems, but VESA 1.2 cards cannot be used for VESA 2.0 operating systems. That's a problem I often encounter when I want to test some operating system, for example SkyOS.
undoweb
Whell good luck with your OS but:
Only you and your friends will use it, and maybe some testers, and i hope it will be a independen OS and note a linux copy!
Shirish
It is not a copy of any OS

Well video is a thing which is not required at present stage

We are moving into memory management jobs right now

then we will take up task management

and scheduling


I forgot to tell you that I have start a community based
on Shunya Operating System on ORKUT

You can join the Community if you have orkut account.
fiendskull9
hmm,

clean code Smile

Im in a BUNCH of projects right now but id be happy to help

i know Python, twisted.py, some pascal, some c, and im big on graphic design (mainly interface and web layouts)

i emailed you about this

-clay
Shirish
well you are definitely a great artist

I invite almost anyone with a good hand at graphics for designing
wallpapers
icons
window styles
cool side addons

anything which u want to see in this OS.

All of yo u will find ur name in contributors list.
Shirish
Here is the code for GDT.h

Code:

#ifndef GDT_H
#define GDT_H

typedef enum present_tag
{
    ABSENT=0x00,
    PRESENT=0x01
}presentBit;

typedef enum descriptor_privilege_tag
{
    RING0=0x00,
    RING1=0x01,
    RING2=0x02,
    RING3=0x03
}privilegeBit;

typedef enum descriptor_type_tag
{
    SYSTEM=0x00,
    CODE_DATA=0x01
}descriptorTypeBit;

typedef enum segmentTypeBit
{
    RES_1=0x00,
    TSS_16A=0x01,
    LDT=0x02,
    TSS_16B=0x03,
    CALL_GATE_16=0x04,
    TASK_GATE=0x05,
    INT_GATE_16=0x06,
    TRAP_GATE_16=0x07,
    RES_2=0x08,
    TSS_32A=0x09,
    RES_3=0x0A,
    TSS_32B=0x0B,
    CALL_GATE_32=0x0C,
    RES_4=0x0D,
    INT_GATE_32=0x0E,
    TRAP_GATE_32=0x0F
};

/********************************* Descriptor **********************************
BASE:   
        It defines thee location of Segment in the 4GB Linear Address Space.
        Three fragments are concatenated to form a single 32bit value.
LIMIT: 
        It defines the size of Segment.
        Two fragments on concatenation give a 20bit value.
GRANULARITY:
        It defines the units with which LIMIT is interpreted.
        0: Units of 1byte        LIMIT:1Mb
        1: Units of 4Kb          LIMIT:4GB
TYPE:
        It defines various types of Descriptors.
DESCRIPTOR PRIVILEGE LEVEL:
        It defines the protection level.
SEGMENT-PRESENT:
        It defines if the segment can be used for addressing.
        0:Not valid
        1:Valid
ACCESSED:
        It defines if the segment has been accessed.
        0:Not accessed
        1:Accessed
*******************************************************************************/
typedef struct GlobalDescriptor
{
    unsigned short int SegmentLimitLow;
    unsigned short int SegmentBaseLow;
    unsigned char SegmentBaseMid;
    segmentTypeBit SegmentType:4;
    descriptorTypeBit DescriptorType:1;
    privilegeBit PrivilegeLevel:2;
    presentBit Present:1;
    unsigned char SegmentLimitHigh:4;
    unsigned char Granularity:4;
    unsigned char SegmentBaseHigh;
};

typedef struct GDTRegister
{
    unsigned short int Limit;
    unsigned int Base;
};

extern void _gdt_flush();
//struct GDTRegister GDTR;
   
class GlobalDescriptorTable
{
    private:
        void LoadGDTR();
        void CreateTable();
        void DefineDescriptor(int num,unsigned long base,
                            unsigned long limit,
                            segmentTypeBit segmentType,
                            descriptorTypeBit descriptorType,
                            privilegeBit privilegeLevel,
                            presentBit present,
                            unsigned char granularity);
    public:
        void Initialize();
   
};

#endif
copilot
I would be interested in your OS. Send me a PM when it is available.
henrygl
nice job, i'll beta test
novisdesign
You guys should check out YouOS. It's a whole OS built in ajax that you use online. Maybe it can give you guys some ideas. Good Luck!

PS. We may be able to do some design work
Shirish
web applications are hottest trends.

Ppl are moving to AJAX applications after seeing the progress of ORKUT and other such stuff.

Surely they wud wanna give a try to the YouOS you suggested,
but ours is not a web based OS but it
surely will provide a Browser to do such tasks

Actually i wanted to develop a small OS which could be easily extended or embedded in handheld devices
then it can be utilised using a browser for any type of task.
nealio1000
Shirish said: Friends I am working on building a fully functional Operating System from Scratch. Anyone who is interested can contact me or post in the forum

I am presently using Nasm as Assembler for bootloader
and C/C++ for Kernel Coding

It will be protected mode OS with a New GUI in high Resolution working on SVGA

Development has started and the source code will be published soon
of the modules i write or complete

Viewers can provide more optimized routines or ask any questions for their projects

i say: interesting... Smile
rayx
Why not using LFS (Linux From the Scratch) ?
Shirish
Hey friends

we are not into designing anothier Linux

had that been the issue , we wud have better optimized the available LINUX.

We wanna build something new and out of pure experience

We don't want any kinda copyrights in this case ....


So plz don't insist on such things again...
lookahead
very interesting project.I hope something good comes out soon out of this project.
tamilchild
Creating operating system is very difficult one. In single person view it is difficult than company level.

Laughing
Shirish
Well friend I know that..

but Linus Torvalds was single too.

but it was just when he found friends like u , that Linux , a dream came true.
TheGeek
I wish you the best of luck, this seems like a very interesting idea and I cant wait to see it progress. I have bookmarked your website in anticipation of updates in the future.

As for my suggestions, these are thing i would like to see eventually, not that i expect to happen soon as i know its in its very early stages:

1. Easy to install, this is the reason many people avoid Linux

2. Keep the file system clean, this is one of the many down falls of windows is that the way its file system structure is, it has a habit of putting files all over the place.

3. Try to use an existing file system, or atleast have the ability to use existing file systems. This is one thing i know that you want to make your own to stay unique, but there are times when you want to be able to work with other file systems and cant, such as in older versions of linux before it was able to do much with NTFS, and it still limited with it.

4. Make it as "lite" as possible. Its a good idea to keep it so that it doesn't use up a lot of the users system so that there is more memory and processing power reserved for the programs its running. I like how your going with it so far only requiring 1MB of RAM to run, its probably the litest OS i have ever seen at this rate.

5. Allow for multiple types of GUIs to be loaded, like linux. Thats one of the things i feel that linux has going for it is that the actual OS is not GUI based (even though i know you said you wanted to make it so) but rather is CLI and the GUI is a seperate process from the actual OS.

6. Its good that your making it run on the x86 platform, as it is the mosty common one used today, however, you should also consider making versions that run on the 286, 386, and 486 platforms since some of those platforms meet the rest of the hardware requirements.

I'll also be willing to beta test for older x86 platform compatibility as i have several PI and PII laptops and desktops that are right now basically useless.
budazz
what kind of OS is this open source?
Shirish
Actually we're striving to build a Desktop Operating System which supports Browser facility

So that it can be used directly at Cyber cafes and exploit the recent trends of web operating systems too in near future...

for rest of details just check for previous posts..
TomS
Can anyone please tell me how I can add c++ code???
Like you said: "Here's the code for header.h" or "anything.cpp"
How can I make it work?

BTW: Would like to be a beta-tester, too. (If not even programmer).
Shirish
Hey

You need to set up all the tools for the development first..

I am setting up my website at the moment..

When all the tutorials on that issue will be up , i will post the link to do that..

Ya you can add your cpp files..but they must use only the standard library attatched or the library you develop from base..

no dlls or static libraries at the moment...

no virtual functions supported yet...
jon9314
WOW i got to give it to you. building a os from scratch boggles my mind. when it is in its beta stages i would love to test it.
Shirish
I want some real good thinkers and innovators who can think out of the box and find something achievable and new in OS technologies..

Anything in terms of interface design, scheduling or file system design is appreciated..
virus_in_town
Shirish BHai ...Best Of Luck FOr Ur Project.... i m excited to see and use Indian Operating System thanx a lot... good work ... Smile
angel_of_death
i thought it wudnt be all that hard. now i've changed my mind. still, glad to see its an indian.
make sure the thing is open sourced. i wudnt mind testing it either Smile
Shirish
Don'rt hesitate to put further your problems or what you want on the website

Like what kind of problems or any special sections on website you ever want...
Arnie
How's the project progressing?
Shirish
hey was just out for a while ..
going on for internship in Digital Signal Processing
but will keep you updated with latest of my developments soon.
Also put up my website .. but due to my inactivity at forums , it was deleted.
if any of you know of a free web host or can provide me space to put up my website .. please help me ..
simplyw00x
Quote:
but Linus Torvalds was single too.

He didn't make linux. He make the kernel of GNU/linux. None of the programs on linux were written by him, only the very core of the OS.
evilryu530
hey thats a cool ass idea, u might be the next big thign...
carlospro7
This is a really interesting topic. I tried looking for a name through the posts, but there are many of them that I must have missed it, but if you don't mind me asking, what do you plan on calling this OS? I'm interested in helping out. I know how to work with c/c++, but i'm still familiarizing myself with programming in general. Anyway, this is really cool, good luck, and I hope to hear more of this.
Shirish
I have named this OS as Shunya .. you are always welcome my friend.
loosu
Building your own OS , has many advantages .

U control everything . good or bad .

U control its purpose .

U get to learn the functionality of the hardware in depth .

U could customize it .

But the matter is that u have to stick on to it .

Anyway , Good luck pal .

WIll help if i can .
Shirish
Ya you have rightly said that..
One thing which keeps intimidating me all around is to control everything..
and that is what Shunya OS is providing me in field of computers..

Looso , I really like you whoever you are because ideas seems to be so converging to mine ..

Shirish
kansloos
Scripting ur own OS is a big thing I wish u guys a lot of luck.
PM me if u need some1 to test ur shit.

btw I would be nice if ur bootloader would also boot linux and windows systems.


Are u going to script ur own Filesystem as well?
Shirish
hi ppl
you can check my new site after i lost my previous site contents from frihost..

www.shunya.ej.am

Please do register for getting pdated on the development.

Also i will be posting some starters articles in a day or two..
so keep checking ..

Shirish
Shunya Developer Lead.
wingzfan99
I was working on my own OS for quite some time previously, got it to the point where i had it fully networked and running applications, but it became too time consuming and too difficult, so I gave up. I hope the same doesn't happen here!
Arnie
You already got networking up? It may be useful if you publish your OS on the web, I'd like to see it.
Shirish
Ya It would be a good idea posting about the design you made for your OS
May be we can help you out and learn during the process eve n more
starfish2007
well i do not know tohelp programming wise but i could help to give ideas i ben have alot of ideas for anew oprating sistem
xbcd
good luck. But hardware support is where you might hit a roadblock. I am willing to test. BTW i use Linux so if your os is similar which i guess it might be similar to then i can help in the idea's and point you to place that it has been partially implemented with source code so you can do a full implementation.
cvkien
wow, i like computer so much but i still don't know how to write my own OS. but now i'm learning myself... hope oneday can become like you all did.
why6487
Shirish wrote:
Ya It would be a good idea posting about the design you made for your OS
May be we can help you out and learn during the process eve n more


I can help you! I'm also working on a OS. 61% done.
I know some C++ and I may develop a language for it!
Example (language dev):
Code:

///////////////////////EXAMPLE//OF//THE//LANGUAGE//TO//THIS//OS///////////////////////
s_begin();
{
            /////////// Oh// no!// 16//bit!
            16bit = ex ax print Example
            richOS = ex ax media Example
            quit
}
/////////////////////END///////////////////////////////

I'm calling it Shiytmea.
brucedes
Hey, I just want to ask, if it already hasn't, will this OS be platform independent or will it only run or x86?

Oh, and when will you port Firefox over? Razz
munkey_boy
Is this project still active? And does anyone know of any ways to contact Shirish as http://www.shunya.ej.am/ seems to be down. I have advanced alot since I last posted in this topic in alot of ways. I have become better at graphics and also advanced to Java.
why6487
brucedes wrote:
Hey, I just want to ask, if it already hasn't, will this OS be platform independent or will it only run or x86?

Oh, and when will you port Firefox over? Razz

Razz

Why? Instead here's a mini-Firefox in Shytema, enjoy:
Code:

void Main()
{
               //moni-//fox
               drawmenu " "File>Open>Exit", "Help>About", "Address>Go to" "
               web_get "http://andrewsteinborn.frih.net/mini-fox/"
               goto-
                       str url("input: url")
                       web_get(url)
                exit-
                      exit
                open-
                        print "Not made yet!"
                about-
                        print "By andrew, 2007"
}

               
Arno v. Lumig
why6487, you do understand that writing these small pieces of code that have no meaning at all is not considered OS development, right? Instead learn ASM and C(++) and write memory management stuff, boot loaders, hardware interface thingies etc. Imagining some weird functions like web_get etc won't help you anything. First get a working socket implementation (a working socket implementation. Not something like make_connection or whatever you would call it)
DarkAkira
Interesting

My company is also creating an Operating System.

It originally started as development of a real ALTIMIT OS, but I left that project, took all source with me, and am now having my company design a new OS from scratch. It will have a GUI unlike any others, will run on x86, x64, and PPC architectures. It will also be BIOS and EFI compatible. We have already finished the bootloader, and are currently working on the GUI.

OS is being written in C/C++, and will be using an OpenGL based GUI to allow for infinite amounts of eye candy without compromising performance. GUI will be Fully 3d Compatible (GPU acceleration). Kernel is based off of Darwin (Open-Source Kernel). The reason for this base is I feel there is no need to "re-invent the wheel" when there are tools available that can be easily converted to work for your personal needs. Kernel from scratch could take years by itself.

I will post screenshots when I can, but I will make a new thread for that. I wont rule yours.

Good Luck with your project!
why6487
Arno v. Lumig wrote:
why6487, you do understand that writing these small pieces of code that have no meaning at all is not considered OS development, right? Instead learn ASM and C(++) and write memory management stuff, boot loaders, hardware interface thingies etc. Imagining some weird functions like web_get etc won't help you anything. First get a working socket implementation (a working socket implementation. Not something like make_connection or whatever you would call it)


I am workin' on that. Good luck then.
brucedes
Arno v. Lumig wrote:
why6487, you do understand that writing these small pieces of code that have no meaning at all is not considered OS development, right? Instead learn ASM and C(++) and write memory management stuff, boot loaders, hardware interface thingies etc. Imagining some weird functions like web_get etc won't help you anything. First get a working socket implementation (a working socket implementation. Not something like make_connection or whatever you would call it)



Heh, calling it "Memory Management stuff" and "Hardware interface thingies" somewhat takes the intelligent edge off, doesn't it? Wink

That also reminds me of this:

Quote:
Him: "I can download games like Quake and play them during lunch, you know."
Me: "We're only allowed 10 megs in our accounts, and the system administrators would notice you downloading a large file."
Him: "Nah, I could hack it so he couldn't."
Me: "Ah, so you are into hacking. By the way do you know any programming languages?"
Him: "Yeah, of course."
Me: "Which ones?"
Him: "I can't tell you or else you'll use them."
Me: "Just by mentioning C++ or Pascal or whatever will not instantly make me a genius with those languages."
Him: "Oh sorry, I didn't understand you. Yeah, I know C++ and Pascal."
Me: "What compiler do you use?"
Him: "Well, Qbasic is my favorite."
Me: "Nobody over the age of eight uses QBasic for serious purposes."
Him: "But they made windows with QBasic."
Arno v. Lumig
brucedes wrote:
Arno v. Lumig wrote:
why6487, you do understand that writing these small pieces of code that have no meaning at all is not considered OS development, right? Instead learn ASM and C(++) and write memory management stuff, boot loaders, hardware interface thingies etc. Imagining some weird functions like web_get etc won't help you anything. First get a working socket implementation (a working socket implementation. Not something like make_connection or whatever you would call it)



Heh, calling it "Memory Management stuff" and "Hardware interface thingies" somewhat takes the intelligent edge off, doesn't it? Wink


Okay then.. The biiiiig baaaad Global Descriptor Table... I've been into OS development for a while, but never got past keyboard input and writing to the VGA buffer... The main problem was lack of patience, I guess...

But that's besides the point. The point I was trying to make was that you can't make an OS by using a lot of imaginary functions and just hope the computer will understand it.

Quote:

That also reminds me of this:

Quote:
Him: "I can download games like Quake and play them during lunch, you know."
Me: "We're only allowed 10 megs in our accounts, and the system administrators would notice you downloading a large file."
Him: "Nah, I could hack it so he couldn't."
Me: "Ah, so you are into hacking. By the way do you know any programming languages?"
Him: "Yeah, of course."
Me: "Which ones?"
Him: "I can't tell you or else you'll use them."
Me: "Just by mentioning C++ or Pascal or whatever will not instantly make me a genius with those languages."
Him: "Oh sorry, I didn't understand you. Yeah, I know C++ and Pascal."
Me: "What compiler do you use?"
Him: "Well, Qbasic is my favorite."
Me: "Nobody over the age of eight uses QBasic for serious purposes."
Him: "But they made windows with QBasic."


Hey! I started programming when I was 11, in QBasic! I was pretty damn serious with it! Wink

In our school it's just too easy to get past the proxy by the way (the proxy that checks the traffic anyway), the ICT admins put a wireless router behind it, so you can just take a random USB WLAN dongle, put it in the PC, and connect to that router (You'll have to do some WEP/WPA (not sure which one) cracking though).
Arno v. Lumig
brucedes wrote:
Arno v. Lumig wrote:
why6487, you do understand that writing these small pieces of code that have no meaning at all is not considered OS development, right? Instead learn ASM and C(++) and write memory management stuff, boot loaders, hardware interface thingies etc. Imagining some weird functions like web_get etc won't help you anything. First get a working socket implementation (a working socket implementation. Not something like make_connection or whatever you would call it)



Heh, calling it "Memory Management stuff" and "Hardware interface thingies" somewhat takes the intelligent edge off, doesn't it? Wink


Okay then.. The biiiiig baaaad Global Descriptor Table... I've been into OS development for a while, but never got past keyboard input and writing to the VGA buffer... The main problem was lack of patience, I guess...

But that's besides the point. The point I was trying to make was that you can't make an OS by using a lot of imaginary functions and just hope the computer will understand it.

Quote:

That also reminds me of this:

Quote:
Him: "I can download games like Quake and play them during lunch, you know."
Me: "We're only allowed 10 megs in our accounts, and the system administrators would notice you downloading a large file."
Him: "Nah, I could hack it so he couldn't."
Me: "Ah, so you are into hacking. By the way do you know any programming languages?"
Him: "Yeah, of course."
Me: "Which ones?"
Him: "I can't tell you or else you'll use them."
Me: "Just by mentioning C++ or Pascal or whatever will not instantly make me a genius with those languages."
Him: "Oh sorry, I didn't understand you. Yeah, I know C++ and Pascal."
Me: "What compiler do you use?"
Him: "Well, Qbasic is my favorite."
Me: "Nobody over the age of eight uses QBasic for serious purposes."
Him: "But they made windows with QBasic."


Hey! I started programming when I was 11, in QBasic! I was pretty damn serious with it! Wink

In our school it's just too easy to get past the proxy by the way (the proxy that checks the traffic anyway), the ICT admins put a wireless router behind it, so you can just take a random USB WLAN dongle, put it in the PC, and connect to that router (You'll have to do some WEP/WPA (not sure which one) cracking though).
expert77
i would love to test it just pm me if u need beta tester
eliniko
I would love to help in the project.

I'm familiar with C,C++,Java,C#.
VI scripting.

I currently using Linux as well BSD operating system.
aningbo
so when's the OS be ready to use and try out??? how many more years????? will it be ready to use for users?
Trigonomicationalistic
I want to start making my own, how you say, OS for a computer but I dont know where to begin or even how to start it with coding... I am however accepting help Very Happy if you dont mind... Embarassed

(signature from izcool all rights reserved for him)
_________________
(\ /)
(O.o)
(> <)

This is Bunny. Copy Bunny into your signature to help him on his way to world domination.
Related topics
What is your operating system?
New O/S from Microsoft
FreeBSD-also a good operating system
blackhawk [microsfot new server operating system but...
Windows XP the best?
What operating system do you use?
I Need distributed Operating System
Which Linux distribution is the best?
sticking "Creating a new Operating System"
how to create an operating system?
The Singularity Operating System
BlueFeather Operating System
COnstructing an OS from nothing...
wich is best operating system for gaming ?
Reply to topic    Frihost Forum Index -> Computers -> Operating Systems

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.