Going into protected mode fails

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
User avatar
siavoshkc
Member
Member
Posts: 40
Joined: Wed Feb 19, 2014 11:10 am

Re: Going into protected mode fails

Post by siavoshkc »

0K I found the cause.

I assembled in with BIOS call and without it and saved Bochs state at the end. Then compared the vga state files in WinMerge. The only difference was that when the code was displaying the 'P' the Cursor Location High an Low Registers were zero. Which was irrelevant. But made me wonder where I really expected to see the 'P' on the screen? Well where the cursor was obviously but I was writing at the start of display buffer. So I realized the 'P' was there the whole time I was not sharp enough to see it. 'Bochs' in cyan was changed to 'Pochs' in cyan. Did you notice I started this post with '0' not the 'O'?

Well I wrote this much to hide my shame. But the reason I saw the 'P' when I had called int 10h is that it cleared the screen before printing the 'P'. That I don't know why yet as all the registers were the same and the cursor wasn't because for some reason screen was reset somehow.
Check out my FSB Data Integrity Tester at http://fsbdit.sourceforge.net/.

Siavosh
Octocontrabass
Member
Member
Posts: 5563
Joined: Mon Mar 25, 2013 7:01 pm

Re: Going into protected mode fails

Post by Octocontrabass »

siavoshkc wrote:That I don't know why yet as all the registers were the same and the cursor wasn't because for some reason screen was reset somehow.
INT 0x10 AH=0x00 resets the VGA registers.
Post Reply