Hi,
FlashBurn wrote:Big question is then, how can I find out if the used card is vga compatible or not?
That's easy - it's not 100% VGA compatible at the hardware level (even though it might have "VGA compatible" BIOS functions)....
In general, what you're doing isn't a good idea anyway - reading the current cursor position from VGA I/O ports is slow because reading (and writing) to any I/O ports is slow. A better idea would be to keep a copy in RAM, such that when you set the cursor position (and I/O ports) you set the values in RAM at the same time, and when you read the cursor position you only need to read the values from RAM - saving yourself slow I/O port reads and making your code less dependant on VGA compatibility.
An even better idea is to use BIOS functions during boot to turn the hardware cursor off, and then simulate your own cursor in software (if/when necessary). This is a little more work, but means your code can use the video card like a pure frame buffer without any I/O port accesses.
FlashBurn wrote:And where do I get information how to program such cards? Please do not tell me that there are not any information available. I thought that all newer cards are compatible.
Most modern video cards are slightly VGA compatible, ranging from BIOS functions only to most VGA I/O ports behaving the same. In general it's impossible to be 100% VGA compatible while providing more than a standard VGA card did. For example, for a 100% VGA compatible video card writing certain "undefined" values to the card's I/O ports should not cause the card to operate in higher resolutions or higher colour depths (but this is required in some way for SVGA).
AFAIK laptops are a little worse when it comes to "VGA compatibility", because often the LCD screen can only handle one screen resolution directly (and all other screen resolutions are a "pretend" subset of this). This isn't all that uncommon - for example, the standard 320 * 200 * 256 colour video mode actually has a resolution of 320 * 400 (as far as the monitor is concerned) and the video card pretends it's a 320 * 200 video mode by sending each scan line twice.
Anyway, unless you can work around the problem (e.g. as suggested above), then you'll need to write a video driver (or part of a video driver) to suit the specific video card. If it's an onboard Intel graphics chip you might be lucky. If it's not you're out of luck if VBE isn't an option.
Cheers,
Brendan