Hello
how can i get the size of the memory without using GRUB?
my os 32bit pmode.
thanx
memory size
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:memory size
there should be plenty of methods described in the FAQ, including asking the BIOS, etc.
Re:memory size
Use GRUB!abuashraf wrote: Hello
how can i get the size of the memory without using GRUB?
my os 32bit pmode.
thanx
I don't need because I use grub, but if you really want to do that, you can use BIOS calls (execute them in Real Mode and then save the amount of memory in a structure you can access later) or probe memory directly (PMode)...
It's explained in the FAQ:
http://www.mega-tokyo.com/osfaq/How%20do%20I%20determine%20the%20amount%20of%20RAM%3F
JJ
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re:memory size
afaik in PMode, you have two alternatives:
- Direct probing
- V8086 (or any other form of realmode emulation)
Direct probing can be hazardous and v8086 mode is annoying to program (or even nonexistant if you're up to 64 bits).
So basically you're sortof expected to do it by GRUB or by some ProprietaryBootLoader, but it can be done in PMode. Not that anybody here seems to like it.
<insert faq link here>
- Direct probing
- V8086 (or any other form of realmode emulation)
Direct probing can be hazardous and v8086 mode is annoying to program (or even nonexistant if you're up to 64 bits).
So basically you're sortof expected to do it by GRUB or by some ProprietaryBootLoader, but it can be done in PMode. Not that anybody here seems to like it.
<insert faq link here>