![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Expert Programmer
|
compiler error
this is all i have so far and i get errors for BITS... i tried surrounding them in []'s but that created an error also... im using MASM32. Am i not aloud to write 16 bit in masm32.
BITS 16 ORG 0x7c00 main: end main btw: this is a start for a boot loader
__________________
"When in Rome, Do as the Romans Do" "Beauty is in the eye of the BEER holder" "Save your breath your going to need it for your blow up doll later" SearchLores.org |
|
|
|
|
|
#2 |
|
Expert Programmer
|
I'm sorry that i cannot help, but there are a few bootloaders out there to choose from, such as LILO or GRUB. Maybe you could investigate into using one of those.
But if all you want to do for a project is make a bootloader, then forget what i said ![]()
__________________
Join us at #programmingforums @ irc.freenode.net! My software never has bugs. It just develops random features.
|
|
|
|
|
|
#3 | |
|
Expert Programmer
|
Quote:
__________________
"When in Rome, Do as the Romans Do" "Beauty is in the eye of the BEER holder" "Save your breath your going to need it for your blow up doll later" SearchLores.org |
|
|
|
|
|
|
#4 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
Being naturally curious, I might Google it, but being naturally curious, I wonder a few things:
1) Why would one choose to write something that's obsolete before one starts? 2) Why would one choose a tool deliberately designed to move past that obsolescence? 3) Why would one choose a tool, which, if it could regress, would fail to document the procedure for doing that? EDIT: Curiosity having gotten the best of me, I would suggest that you check out EXPR16/EXPR32, OPTION SEGMENT, .MODEL, and that portion of the documentation dealing with processors and memory models.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers Last edited by DaWei; Nov 21st, 2005 at 10:05 AM. |
|
|
|
|
|
#5 |
|
Expert Programmer
|
im making this boot loader for the learning... im hungry for knowledge!
i thought OPTION SEGMENT and .MODEL were used in 32 bit only?
__________________
"When in Rome, Do as the Romans Do" "Beauty is in the eye of the BEER holder" "Save your breath your going to need it for your blow up doll later" SearchLores.org |
|
|
|
|
|
#6 |
|
Programmer
Join Date: Jun 2005
Posts: 86
Rep Power: 4
![]() |
BITS is a NASM directive (not MASM
). What you want is USE16http://courses.ece.uiuc.edu/ece390/b...ml#HEADING3-42 |
|
|
|
|
|
#7 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
My MASM32 docs (just downloaded it) don't mention a USE16, like the MASM docs do. Better hope its there, anyway, or an equivalent amongst those other things.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#8 |
|
Expert Programmer
|
using [USE16] or USE 16 does not work
... and the rest of the entire code says " must be in segment block "
__________________
"When in Rome, Do as the Romans Do" "Beauty is in the eye of the BEER holder" "Save your breath your going to need it for your blow up doll later" SearchLores.org |
|
|
|
|
|
#9 |
|
Expert Programmer
|
USE16 ORG 0x7c00 main: mov ax,0x0000 mov ds,ax mov si,HellWorld call PutStr jmp $ PutStr: mov ah,0x0E mov bh,0x00 mov bl,0x07 .nextchar lodsb or al,al jz .return .return ret HelloWorld db "HelloWorld",0 dw 0xAA55
__________________
"When in Rome, Do as the Romans Do" "Beauty is in the eye of the BEER holder" "Save your breath your going to need it for your blow up doll later" SearchLores.org |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|