
; Copyright 2004-2005 Christopher Evans
; email:   tekno1911@yahoo.com
; Website: http://nxdos.sourceforge.net/
;                                                                           ;
;       This program is copyrighted, but may be freely distributed          ;
;       under the terms of the Free Software Foundation's GNU General       ;
;       Public License v2 (or later.)  See the file COPYING for the         ;
;       legalities.  If you did not receive a copy of COPYING, you          ;
;       may request one from the Free Software Foundation, Inc.,            ;
;       59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.           ;
;       ABSOLUTELY NO WARRANTY -- use it at your own risk!                  ;
;                                                                           ;

code            segment byte public
                assume  cs:code, ds:code

bootstart       equ  7c00h

                org  0h

mbr             proc far

start:          cli
                xor  ax, ax
                mov  ss, ax
                mov  sp, bootstart
                mov  si, sp
                push ax
                pop  es
                push ax
                pop  ds
                sti
                ;

main:
                mov  si, offset bootstart+partition_1
                mov  bl, 4
ptscan:
                cmp  byte ptr [si], 80h
                je   bootit
                cmp  byte ptr [si], 0h
                jne  special
                add  si, 10h  ; next++
                dec  bl       ; prev--
                jnz  ptscan

rombasic:       int  18h

bootit:
                mov  dx, [si]
                mov  cx, [si+2]
                mov  bp, si

special:


exitptr:

partition_1     db 10h dup(0)
partition_2     db 10h dup(0)
partition_3     db 10h dup(0)
partition_4     db 10h dup(0)
; 
; bootable db
; beghead  db
; begsectr dw
; syscode  db 
; endhead  db
; endsectr dw
; startsec dd
; size     dd
;

CodeSize        EQU $-start   
padding         db (512-CodeSize-2) dup(0)
bootsignature   db 55h,0aah

mbr             endp

code            ends

ProgramEnd      EQU $-01h

		end	start
