problem getting into pmode
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:problem getting into pmode
i would be trying it without the floppy stuff ...
btw, are you sure you're in text mode ?
btw, are you sure you're in text mode ?
Re:problem getting into pmode
ahh.. i am in textmode nr 10h, becasue i wanted color..
the "normal" textmode is nr 03h (witch i could not get color in..)
but then again, why would i give the text a color attribute if it?s for mode 03h (witch i haven?t been able to get color in..)
i will check out where textmode nr 10h (and 03h) put it?s data..
Hmm.. but you have a good point there.. thank you so much!
i have been posting on many diffrent os-dev boards with this problem (osdev.org, osdever.net/forums etc.) but you are the only one that have given me nice answers (and quick!)..
thank you again..
/ Christoffer
the "normal" textmode is nr 03h (witch i could not get color in..)
but then again, why would i give the text a color attribute if it?s for mode 03h (witch i haven?t been able to get color in..)
i will check out where textmode nr 10h (and 03h) put it?s data..
Hmm.. but you have a good point there.. thank you so much!
i have been posting on many diffrent os-dev boards with this problem (osdev.org, osdever.net/forums etc.) but you are the only one that have given me nice answers (and quick!)..
thank you again..
/ Christoffer
Re:problem getting into pmode
hmm.. but wait Gregor Brunmar (also a swedish guy ;D) use the same graphic mode and the "same" pmode message (only a P) in his tutorial on
http://hem.passagen.se/gregge/index_lores.html
that i do.
(and by the way that floppy stuff doesn?t make any diffrent, and i added it only becasue my floppy light won?t go off on my real "testing" PC)
Wierd...
/ Christoffer
http://hem.passagen.se/gregge/index_lores.html
that i do.
(and by the way that floppy stuff doesn?t make any diffrent, and i added it only becasue my floppy light won?t go off on my real "testing" PC)
Wierd...
/ Christoffer
Re:problem getting into pmode
Hehe... here's your personal bucket of paranoia. Your floppy code does something (or the light wouldn't go off). So there's the potential to do something wrong.bubach wrote: (and by the way that floppy stuff doesn?t make any diffrent, and i added it only becasue my floppy light won?t go off on my real "testing" PC)
Advice from the battlefield: Don't assume that "X" can't be the reason for your problems. Prove it.
Every good solution is obvious once you've found it.
Re:problem getting into pmode
No, i seriously mean it WON`T go off! i waited for about 15 min.
And i have proof (or whatever the correct spelling is), i acually tested without that piece of code...
how come it feels like my english is getting worse and worse..? ;D
/ Christoffer
And i have proof (or whatever the correct spelling is), i acually tested without that piece of code...
how come it feels like my english is getting worse and worse..? ;D
/ Christoffer
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:problem getting into pmode
if i read the Ralf Brown Interrupt List correctly
so better stay with mode 03 for now ...
the mode 03 *has* colors (at least 16 of them) and is a Text mode while03h = T 80x25 8x8 640x200 16 4 B800 CGA,PCjr,Tandy
= T 80x25 8x14 640x350 16/64 8 B800 EGA
= T 80x25 8x16 640x400 16 8 B800 MCGA
= T 80x25 9x16 720x400 16 8 B800 VGA
the mode 10 is a *graphic* mode (16 colors aswell) and is available only for pixel-plotting through 0xA0000 (and you should play with the CRT registers to access one or the other bitplane ..)10h = G 80x25 8x14 640x350 4 2 A000 64k EGA
= G . . 640x350 16 . A000 256k EGA,VGA
so better stay with mode 03 for now ...
Re:problem getting into pmode
i know mode 03h has colors, but i don?t get them to work! not with BIOS teletype INT anyway..
i go after this:
as you can see 10h is *both* text and graphics..
all other text in my OS is also in 10h + that in Gregor Brunmar?s tutorial he?s doing the exact same that i am trying to do..
So i know that it work. I just made something wrong..
/ Christoffer
i go after this:
Code: Select all
INT 10h, Service 0h
Set Screen Mode
Input: AH = 0h
AL = Mode Number (see below)
Output: The video mode is changed.
Mode Number Text Res. Graphics Res. Description Adapters Max. Pages
---------------------------------------------------------------------------
0h 40x25 ------ B&W Text CGA+ 8
1h 80x25 ------ B&W Text MDPA+ 8
2h 40x25 ------ Color Text CGA+ 4 or 8
3h 80x25 ------ Color Text (MDPA?)/CGA+ 4 or 8
4h 40x25 320x200 4 colors CGA+ 1
5h 40x25 320x200 2 colors CGA+ 1
6h 80x25 640x200 2 colors CGA+ 1
7h 80x25 ------ B&W MDPA (CGA+?) 1
8h to Ch -- PCjr or other adapters; no longer used
Dh 40x25 320x200 16 colors EGA+ 8
Eh 80x25 640x200 16 colors EGA+ 4
Fh 80x25 640x350 2 colors EGA+ 2
10h 80x25 640x350 16 colors EGA+ 2
11h 80x25 640x480 2 colors VGA+ 1
12h 80x25 640x480 16 colors VGA+ 1
13h 40x25 320x200 256 colors VGA+ 1
all other text in my OS is also in 10h + that in Gregor Brunmar?s tutorial he?s doing the exact same that i am trying to do..
So i know that it work. I just made something wrong..
/ Christoffer
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:problem getting into pmode
yes, but usually, you're displaying text using the BIOS functions ... and those know how to render the fonts on the graphic array while your program do not... (not already at least).
Displaying a 'P' in such a mode is likely to look like
and the bios has a table that contains all those bits for each character...
Displaying a 'P' in such a mode is likely to look like
Code: Select all
mov [0xA0000+640*0],01111110b
mov [0xA0000+640*1],00110011b
mov [0xA0000+640*2],00110011b
mov [0xA0000+640*3],00110011b
mov [0xA0000+640*4],00111110b
mov [0xA0000+640*5],00110000b
mov [0xA0000+640*6],00110000b
mov [0xA0000+640*7],01111000b
Re:problem getting into pmode
maybe, but the example code i based it on has it working...
but i will try it on mode 03h instead..
/ Christoffer
but i will try it on mode 03h instead..
/ Christoffer
Re:problem getting into pmode
If you feel like that, you should prove it until you have proof that proves you are right (or wrong).bubach wrote: And i have proof (or whatever the correct spelling is)...
how come it feels like my english is getting worse and worse..? ;D
See? Your English was right on the mark there.
Every good solution is obvious once you've found it.
Re:problem getting into pmode
Hej, bubach!
Hur mar du? ?r det correct: Du ?r fran sverige?
Ha en bra dej.
Hej do!
A little bit of swedish, which I've had chance to learn. *gg*
Hur mar du? ?r det correct: Du ?r fran sverige?
Ha en bra dej.
Hej do!
A little bit of swedish, which I've had chance to learn. *gg*
Re:problem getting into pmode
;D nice!!
Correction of BI lazy?s message: (with dots..)
Hej, bubach!
Hur m?r du? ?r det korrekt: ?r du fr?n sverige?
Ha en bra dag. (dej means you)
Hej d?!
Where did your learn that? Really god. A new sentance that might come in handy:
L?s den j?vla manualen!
It means: RTFM (Read The F***ing Manual)
Pype.Clicker:
You was right i was wrong.. :-[
the code a based it on used mode 03h (i was *so* sure that it used 10h, but it was in another tut.)
So now i just try to find that code to switch video mode without clearing the screen (using bios int?s).
I read that bit 7 in AL must be 1, so that BIOS does not clear the screen, but how can AL be both 10000000b and 03h at the same time?? (didn?t work.. )
I know i have seen a sample of that, i just have to find it..
I changed all my text output to mode 03h just to see if the code worked and it did! I could see my Pmode message! But beacasue i can?t get colors to work in 03h i will just use 10h, and 03h in pmode until my kernel vga driver is ready..
So soon i will be off starting another thread about some other n00b stuff..
Thanks to all (read Pype.Clicker ) that helped me get this far..
Correction of BI lazy?s message: (with dots..)
Hej, bubach!
Hur m?r du? ?r det korrekt: ?r du fr?n sverige?
Ha en bra dag. (dej means you)
Hej d?!
Where did your learn that? Really god. A new sentance that might come in handy:
L?s den j?vla manualen!
It means: RTFM (Read The F***ing Manual)
Pype.Clicker:
You was right i was wrong.. :-[
the code a based it on used mode 03h (i was *so* sure that it used 10h, but it was in another tut.)
So now i just try to find that code to switch video mode without clearing the screen (using bios int?s).
I read that bit 7 in AL must be 1, so that BIOS does not clear the screen, but how can AL be both 10000000b and 03h at the same time?? (didn?t work.. )
I know i have seen a sample of that, i just have to find it..
I changed all my text output to mode 03h just to see if the code worked and it did! I could see my Pmode message! But beacasue i can?t get colors to work in 03h i will just use 10h, and 03h in pmode until my kernel vga driver is ready..
So soon i will be off starting another thread about some other n00b stuff..
Thanks to all (read Pype.Clicker ) that helped me get this far..