views:

274

answers:

4

I wish to learn more about the inner working of the computer, to enhance my knowledge about embedded system developement.

At work, I never get involved with the low-level details (such as, the GDT, the loader of the code from flash to RAM, etc) as all these are already written.

I'd rather not buy any other hardware currently. Is there an emulator, and a very simple OS, I can play with, in order to master with all those low level aspects of embedded programmimng? Is there a tutorial that can walk me through setting a very simple embedded environment (setting the memory segments, the GDT, getting to protected mode, and execute main())

+4  A: 

The ususal suspects for x86 emulators would be Bochs and QEMU.

You might also want to take a look at James Molloy's kernel development tutorial and the resources it links to.

Christoph
+1  A: 

For our Operating Systems course we're currently using a toy OS called POTATOES. It's pretty basic and AFAIK based on James Molloy's kernel tutorials. You might have a look at it here.

In addition I can recommend the Wiki and discussion board at OSdev.org.

Happy hacking! :)

Edit: Some good information about the x86 architecture can be found in volume 3 of Intel's IA-32 Architectures Software Developer's manuals. Volume 1 features the basic architecture and in volume 2 you'll find a complete reference of the x86 assembly instruction set.

AdrianoKF
+1  A: 

In embedded system development emulator has a very specific meaning; are you in fact talking about a "simulator"? But if you are developing on an x86, and instruction set simulator is unnecessary and limited when you can instead use a VM.

In fact if you wanted "a very simple embedded environment" you would not choose an x86. Bootstrapping and configuring these complex devices (and their associated chip-sets and memory) is non trivial.

If your platform is x86 then the simplest thing to do is to use a Virtual Machine running on a real x86. The most flexible and robust VM is available for free from VMWare, and another free one from Microsoft. Microsoft's Virtual PC however is optimised for running Windows, getting Linux to work on it can be troublesome, let alone some niche RTOS.

Clifford
I'm talking indeed about a full VM, such as virtualbox/Qemu/Bochs/VMware etc. I just thought there's something more geared for embedded systems.
Elazar Leibovich
And of course, x86 is complicated, that's why I want to learn all it's intriguing features (segments, paging protected mode, oh my...)
Elazar Leibovich
If you have a budget, perhaps real hardware may be more suitable - An industrial PC card for example, low end PC/104 form factor boards need not be expensive.
Clifford
+1  A: 

You might be better off using a real embedded machine. A development environment for an Arduino is hardy expensive, and there you get to work right down at the metal: http://www.sparkfun.com/commerce/product_info.php?products_id=9284

AVR is a reasonable start into that space, x86 isn't.

Andrew McGregor