Alex Buell wrote:
> Hello folks,
>
> I'd like your thoughts on my first serious x86 assembly project; which
> lists all the modes available on a VESA compliant graphic adapter;
> runs on MSDOS. You can also change modes as well.
>
> I originally wrote this utility as I needed more screen estate to be
> able to view more of my code on the display. I'm now using a 132x50
> display. Utter bliss!
>
> I have made both the executables and sources freely available;
> http://www.munted.org.uk/programming/vmode.zip
>
> Feedback is welcome. Also bug re****ts ;o)
Neat! I puzzled for a while over all the "+ OFFSET"s. The reason you
need that cruft is that you haven't set ds (properly)! Unlike a .com
file, an "MZ" .exe - 16-bit - *does* have "real segments", and the
loader sets ds and es to your "PSP segment", not your "data" segment!
You've set 'em to cs, which is apparently 100h bytes from your data
segment. I suspect you're "lucky" this works. At the beginning of
vmode.asm, instead of "mov ax, cs", try "mov ax, data". I think you'll
find this works without all the "+ OFFSET" cruft. Or maybe there's a
reason you're doing it this way?
I haven't tried this... pretty sure it won't work in dosemu. I'll reboot
to dos and give it a shot... sometime soon...
Best,
Frank


|