Hello,
Sorry for the stupid question, but I can't figure it out how to switch from protected mode to real mode and then get back to protected mode and continue running. Is there any easy way to do it? I need to do this in order to be able to switch to VGA 0x13 mode.
Thanks,
Paul Herman
Switching from protected mode to real mode and back
Re: Switching from protected mode to real mode and back
While getting the processor from pmode to real mode and back to pmode is as easy as flipping a bit in CR0. However before doing so you need to clean up and setup all the surrounding environments like paging, IRQs, etc. As Brendan said on this thread, you need to "stop the world" to call real mode BIOS, which usually end up a mess.
It's probably easier to deal with the VGA directly.
Check this out VGA_Hardware.
It's probably easier to deal with the VGA directly.
Check this out VGA_Hardware.
Re: Switching from protected mode to real mode and back
If a trainstation is where trains stop, what is a workstation ?
- 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: Switching from protected mode to real mode and back
Bluemoon +1, mostly because of the following:
You definitely don't. I recommend that you check out the link posted as well as the FAQ entry on changing video modes and then decide if you really need it or if you are just misinformed.I need to do this in order to be able to switch to VGA 0x13 mode.