This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Video mode code / eCos demo


Nick Garnett <nickg@ecoscentric.com> writes:

> davidw@dedasys.com (David N. Welton) writes:

> > This one's a bit obscure, but I noticed it by comparing with the
> > grub code:

> >   /* Now trip to the graphics mode.  */
> >   if (set_vbe_mode (mode_number | (1 << 14)) != 0x004F)

> > That 1 << 14 (0x4000) lets you use the 'linear framebuffer mode',
> > which is pretty important if you want to avoid that other, awful
> > thing where you have to continually select the frame you want to
> > work in.

> > Once again, I'm not sure if this should just be mentioned in the
> > docs (or maybe even just the .cdl), or if it would be convenient
> > to add in a bit of code to actually set the bit.

> >         "If you wish to access the screen as a linear framebuffer,
> >         be sure to logical or the mode you select with 0x4000."

> I'll leave this to the more knowledgeable to repond to.

Thinking about it more, I think the docs or CDL are the right place to
make a note of it.  A patch with a couple of orw's is really simple,
but it does limit flexibility, and that's bad, I suppose.

This has some information:

http://www.delorie.com/djgpp/doc/ug/graphics/vbe20.html

(look for 0x4000)

> > BTW, I finally got my eCos demonstration hacked together:

> > The images I selected(*) ought to be refreshing to look at if it's
> > as hot where you are as it is here in Italy!

> Cool :-) I don't know what temperatures you have had in Italy, but
> we had the hottest day since records began here yesterday: 37C in
> places, though it never got above 35C here. Remember, this is a
> country where anything much beyond the mid 20s has the newspapers
> dusting off their "Phew, What a Scorcher!" headlines.

It's about that hot here, but we're used to it by now... I guess.

> > It's still a bit buggy, but it boots and runs on the three pc's I
> > have, and I like it as a demo, because with something like Linux, you
> > simply could not pack in the same number of images (even if this demo
> > only fills the disk halfway, adding more images is pretty easy).

> It didn't run at all on my standard test machine, Pentium3 800MHz
> with Matrox G400 AGP installed. However it ran fine on another
> machine, Athlon 1200MHz with Matrox G450 AGP. There shouldn't be any
> significant difference between these in terms of what you are doing,
> so I'm not sure why the first one failed.

Well there was a bug in the original demo that I fixed - on some
machines it didn't get beyond the first few images.  Right now it
should work perfectly if it's going to work at all.

Some cards may not support the VBE modes, or VBE sans linear
framebuffer (making it a pain to program).  Where I would be worried
is if grub's vbeprobe did report the 0x115 video mode I'm using, and
the demo still didn't work.

It would be nice to make this work everywhere, but I would have to
collect a lot of info about lots of cards... not worth it.

Anyway, thanks for checking it out!
-- 
David N. Welton
   Consulting: http://www.dedasys.com/
     Personal: http://www.dedasys.com/davidw/
Free Software: http://www.dedasys.com/freesoftware/
   Apache Tcl: http://tcl.apache.org/

-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]