VESA BIOS Extensions & Bitmap Font - Amateur OS Dev (x86 asm)
Adding a 2nd stage bootloader, a couple Vesa Bios Extensions functions to query and choose a graphics mode - in this case 1920x1080 32bpp, a custom 8x16 bitmap font, and changing to print text and a 'cursor' using this new font
Source code as of the end of this video:
https://git.sr.ht/~queso_fuego/amateur_os_video_sources/tree/master/item/31_VBE_custom_font
Playlist for this series:
https://www.youtube.com/playlist?list=PLT7NbkyNWaqajsw8Xh7SP9KJwjfpP8TNX
Notes:
- Hopefully this video is a little easier to follow than some earlier ones. I'll try to continue more with the 'copying and explaining' format for future videos as it takes less recording time (if you can believe it) and code is already 'mostly' debugged.
Going back through the series so far showed that anyone trying to type and follow along probably had a really hard time, I was not keeping in mind that some people would want to do that and use these videos as a tutorial of sorts.
I'll try to be better for those folks for the future. I'll also try to put the overall OS source in a git repo as of the end of each video, so you can download or view the code covered on a step by step basis.
Next video(s) should be:
Viewer's choice!
...or maybe graphics primitives, fixing up the text/bin editor, making a font editor, memory manager, or something else
Wikipedia page on VBE:
https://en.wikipedia.org/wiki/VESA_BIOS_Extensions
VBE Core Functions Standard 3.0:
http://www.petesqbsite.com/sections/tutorials/tuts/vbe3.pdf
VESA tutorial OS Dev Wiki page (good assembly example at bottom of page):
https://wiki.osdev.org/User:Omarrx024/VESA_Tutorial
Outline:
0:00 - Show VBE & font example
2:32 - VBE 3.0 docs, functions 4F00h/4F01h/4F02h, working test code
20:24 - Start changing the actual OS for VBE, create 2nd stage bootloader
31:03 - Add VBE test code to 2nd stage bootloader
50:12 - Write VBE mode info block to memory & change clear_screen for VBE
56:05 - Show 8x16 bitmap font
1:02:04 - Add font to filetable & bootsector
1:07:56 - Change some clear_screen, print_char, print_string calls
1:13:21 - Change print_string for bitmap font
1:36:34 - Change remaining print_string calls
1:38:24 - Print OS boot message
1:39:38 - Change print_char for bitmap font
1:44:12 - Change remaining print_char calls
1:47:14 - Change move_cursor for bitmap font
1:52:49 - Fix print_char
1:54:29 - Remove extraneous move_cursor calls
1:57:39 - Fix backspace in kernel
2:02:12 - Fix rename/delete/save/load file in file_ops
2:04:40 - Remove extra move_cursor calls from rename/delete file and calculator
2:07:16 - Fix string printing in editor
2:16:29 - Closing thoughts & Outro
Updates for this series and other things will be on twitter @Queso_Fuego, if I remember (not likely). I'll probably use the YT channel community tab for video/channel updates if channel metrics are met. If people prefer, I can look into a mailing list for updates, or tweet out stuff anyway
----------------------------------------------------------------------------------------------------------------------------------------
Git repos:
https://git.sr.ht/~queso_fuego/quesos
https://github.com/queso-fuego/amateuros
Software used:
VMware Workstation Player - https://www.vmware.com/products/workstation-player/workstation-player-evaluation.html
openBSD - https://www.openbsd.org/
qemu - https://www.qemu.org/
vim - https://www.vim.org/ (neovim is better)
fasm - https://flatassembler.net/
fasm docs - https://flatassembler.net/docs.php?article=manual
davinci resolve - https://www.blackmagicdesign.com/products/davinciresolve/
OBS Studio - https://obsproject.com/
Contact:
email - fuegoqueso@gmail.com
twitter - @Queso_Fuego
Thoughts/Notes/Suggestions/Other - Drop a message in the video comments, by twitter, or by email
Credits:
Music from https://incompetech.com:
"Your Call" Kevin MacLeod (incompetech.com)
Licensed under Creative Commons: By Attribution 4.0 License
http://creativecommons.org/licenses/by/4.0/
The blue title tags:
#osdev #vbe #assembly