If you're writing your own OS, look for the VBE documentation (google!)