Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > alt.os.development > #8399

Re: OS startup goals and steps

From "James Harris" <james.harris.1@gmail.com>
Newsgroups alt.os.development
Subject Re: OS startup goals and steps
Date 2015-07-16 11:01 +0100
Organization A noiseless patient Spider
Message-ID <mo7vbm$kog$1@dont-email.me> (permalink)
References (1 earlier) <op.x1s1vregyfako5@localhost> <mo5rjo$t4g$1@dont-email.me> <op.x1ug7niuyfako5@localhost> <mo7kn3$kaq$1@dont-email.me> <op.x1ux2fybyfako5@localhost>

Show all headers | View raw


"Rod Pemberton" <boo@fasdfrewar.cdm> wrote in message 
news:op.x1ux2fybyfako5@localhost...
> On Thu, 16 Jul 2015 03:00:10 -0400, James Harris
> <james.harris.1@gmail.com> wrote:

...

> RP> Are you going to at least set a text mode?
>>
>> I don't know if that would help in any way. Notwithstanding what I 
>> said  above won't the screen already be in a text mode? And if the OS 
>> sets a  different mode without checking what the monitor can do isn't 
>> there a  chance that the new mode won't display on the monitor?
>
> So, the plan is to leave text/video mode in the default mode for 
> safety?
>
> Ok.

Well, insofar as I have any kind of plan wrt to the video, yes, I was 
thinking, for now, just to leave the video as the BIOS set it. I will 
need to spend a lot more time researching this before coming up with a 
real plan.

> So, how do you know the rows and columns of the text mode?
> Do you plan to call the BIOS to determine the text resolution?
> e.g. 40x25, 80x25, 80x50, 132x25.

Yes. At one point I didn't think it was possible to get both those 
pieces of info but from looking at the code I have, I use the following.

  int 0x10-0f to get no. of columns and other things
  int 0x10-1130(bh=0) to derive the number of rows

> I looked at this the opposite way around.  I figured that old early
> resolutions for CGA, EGA, and VGA would be universally supported and
> safe to use.

It's a bit of a minefield. I think you pointed out that modern machines 
might not even be compatible with VGA.

> For text, I figured 80x25 text mode, such as mode 2 or 3
> for VGA controllers would be universal.  Well, at least where the 
> machine
> *has* VGA and not CGA or EGA.  EGA and CGA support the modes also, but
> I'm not sure if the CRTC programming is the same for them.

There is a note of what was intended for Linux and startup video 
handling at

  http://lwn.net/2001/0628/a/bios.php3

> My OS doesn't use the BIOS.

Not at all?

> So, I implemented 80x25 text for VGA by directly programming
> CRTC.  I figured the same for 320x200 in 256 colors, but never got to
> around to that.  After using VESA modes and some higher resolution 
> modes
> in DOS, I really wouldn't mind using them in my OS.

OK.

> However, I'll probably
> let the BIOS do the mode setting work, if I ever get around to it. 
> I'm
> not sure how that will go over with my code ...

Ditto.

James

Back to alt.os.development | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-14 10:35 +0100
  Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-15 04:00 -0400
    Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-15 22:29 -0400
      Re: OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-16 08:00 +0100
        Re: OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-16 11:01 +0100
          Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-17 05:40 -0400
            Re: OS startup goals and steps "wolfgang kern" <nowhere@never.at> - 2015-07-17 17:58 +0200
        Re: OS startup goals and steps "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-16 03:24 -0700
  Re: OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-16 10:32 +0100
    Re: OS startup goals and steps "wolfgang kern" <nowhere@never.at> - 2015-07-16 16:04 +0200
      Re: OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-17 06:44 +0100
        Re: OS startup goals and steps "wolfgang kern" <nowhere@never.at> - 2015-07-17 17:50 +0200
    Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-17 06:10 -0400
      Re: OS startup goals and steps "James Harris" <james.harris.1@gmail.com> - 2015-07-17 18:07 +0100
        Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-18 03:35 -0400
  Re: OS startup goals and steps "wolfgang kern" <nowhere@never.at> - 2015-07-16 14:42 +0200
    Re: OS startup goals and steps "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-17 05:48 -0400
      Re: OS startup goals and steps "wolfgang kern" <nowhere@never.at> - 2015-07-17 17:29 +0200

csiph-web