News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Help with segmentation

Started by fafastrungen, August 10, 2006, 09:31:06 AM

Previous topic - Next topic

fafastrungen

I made a mistake, I put my question in the wrong forum.
I don't want to program under DOS, I want to program the microprocessor directly, what I want is something like programing a 16F84 pic, no OS behind.
I just want to throw instrucction to the micro. I have a diskette that I use to boot the Pc and when Pc boots it loads the boot sector of my diskette. In the diskette there is no calls to OS, just the code I want to test, so, microprocessor direct programing.

asmignorant

Yes, you made a mistake and yes, you can address more than 1 MB in Pentium Pro processor.
You have 3 modes of operation: protected mode; real-address mode and system management mode.
Of course with 32 btis you can acces to 4 GB of memory (2^32 - 1), but this you already know.
You must map all the segments to the same linear adddres.

Read the intel's documents.

Boucly

fafastrungen, if you are still there, I think MASM32 has opcodes for processor in the .hlp file under heading Bare Hex Opcodes And Mnemonics. As for the intel manual, try this page.

I presumed that opcodes are the 0010110, the computer language. Am I right? If I am wrong  :red, I didn't post this reply.

Boucly

fafastrungen

Thanks Boucly and asmignorant for your help.

Dinosaur

Been away for a week and missed the latest posts.

I have been through the "Dinosaur" argument many times on other forums.
When you go looking it is amazing how many industrial machines operate on DOS.
Sadly many intelligent people still think that computers only sit on desktops.

fafastrungen, if it feels good, DO IT

fafastrungen

Quote from: Dinosaur on August 19, 2006, 01:32:36 AM
Been away for a week and missed the latest posts.

I have been through the "Dinosaur" argument many times on other forums.
When you go looking it is amazing how many industrial machines operate on DOS.
Sadly many intelligent people still think that computers only sit on desktops.

fafastrungen, if it feels good, DO IT

Don't worry dude, I throw away all the opinions that are not related with my tech question.

sinsi

Sorry dudes, my comments should have been [irony][/irony].

Win32 makes things a bit easier (e.g. MakeMeAWindow) but doesn't make
up for *knowing* how a computer works, like programming via INT 10/13/16 and INT 21 eh?

Writing your own OS is (as I see it) ultimately fruitless, since you will be mimicking MSDOS/PCDOS/etc
to run programs, or have to write special programs for YourOS(TM).

But the importance of knowing how to write to a screen or HDD, whether direct access or BIOS, is
worth a lot. Given the everyday BIOS, there is no reason that you can't write a "killer app"
that boots from a floppy (well, in theory :bg).

I do have a 486 with DOS (6.22, not 5) with Windows 3.11, because using VB4 is...um...fun heh heh, but
using ASM is interesting...so close to the ROM BIOS and video BIOS.

If you can master the BIOS of a new computer, you can master the computer.
I reckon that is the target of any true ASM programmer.

As far as dinosaurs go, I am proud to be one (self-perceived) but, hey, it makes diagnostics easier.
So apologies to Dinosaur (I didn't realize there was a user with that name).

Going from finding "EDASM" on a Z80 Microbee and learning assembly language to Win32 ASM with
ML version 8 has been so much fun, and all for my own benefit - no paid jobs etc. - but knowing
what the BIOS does and where it crashes has made me The Computer Guru...and who am I to complain?

Know thy computer.


Light travels faster than sound, that's why some people seem bright until you hear them.

fafastrungen

sinsi, you're free to say whatever you want and I accept it, but you have to understand that free opinions can cause differents reactions.
I accept all that people says, but in this case your answer was not related with my question.

sinsi

Quotebut in this case your answer was not related with my question.
Sorry, I was responding to
Quotewhat I want is try to understand what happens when I press a key in the system or what happens when I want to read a file
and
QuoteI'm just trying to understand the things at very low level

You can't get much lower than INT 10/13/16 because the billions of combinations of hardware in computers make it
impractical to use I/O to talk to that hardware - the BIOS takes care of it for you.
Light travels faster than sound, that's why some people seem bright until you hear them.

fafastrungen

QuoteYou can't get much lower than INT 10/13/16 because the billions of combinations of hardware in computers make it
impractical to use I/O to talk to that hardware - the BIOS takes care of it for you.

I agree 50% becouse the BIOS also has the hardware combination's problem.
There must be a kind of common rules that everybody must follow, becouse for the BIOS it is also imposible cover all the hardware in the market. For example, when the bios access to the video card, the video card must have a set of common functions to run basically, the BIOS can't cover all types of video cards, it's impossible to it too.
So, this is the level I want to reach, not deep into every device in the market, this is impossible (at least for me), I just want to know these common features of devices and program simple things.

ninjarider

from what i've read. it sounds like you want to be able to make drivers or understand them atleast. it is possible to write software that controls a device in the windows enviroment. if you have ever heard of a vxd file. it is a segment of a driver that controls a device. If you want to do it in a windows enviroment you would have to get a ddk (believe it stands for device development kit) for your os version. Microsoft has discontinued everything before 98se and windows me do to there virtual java machine