OSDev.org
https://forum.osdev.org/

BOOTCFG - Startup Configuration Tricks and OS Loader for DOS
https://forum.osdev.org/viewtopic.php?f=2&t=32121
Page 3 of 3

Author:  ~ [ Fri Aug 11, 2017 2:35 pm ]
Post subject:  Re: BOOTCFG - Startup Configuration Tricks and OS Loader for

Native Sound Blaster and Thinkpad 390X

I have currently added the sbtest0 command to my kernel to start learning to program the classic Sound Blaster.

I did a test at port 0x220 (one of the ports where the Sound Blaster DSP could be found) and obtained the Sound Blaster version byte value (2, 4...), and timeouts with LOOP runouts for an efficient detection without locking up.

With this code I have found that the Thinkpad 390X has a native Sound Blaster capable sound card, so I'm done with this excellent machine, which will allow me to do more tests for a kernel that I wish to have standard VGA, SuperVGA, sound, network with simple native drivers at the very least for a decent OS code base.

Had not it been the case (if ESSOLO.COM had implemented emulation somehow), I wouldn't be celebrating, and I would have focused my efforts to learn something else for the time being.


Information Resources.

I used the ESSOLO.COM driver for the ESS-Solo1 sound card driver for DOS for the Thinkpad 390X, but I only use it for initializing the card... after that my kernel does the rest of the hardware manipulation.

I used DMAW.C to keep learning how to program the Sound Blaster and send simple WAV data to it:
http://devel.archefire.org/forum/viewtopic.php?f=221&t=2305&p=4300#p4300

DMAWSDOC.C generated DMAW.HTM, which teaches how to program the Sound Blaster at the most basic level:
http://devel.archefire.org/downfile.php?path=/SourceDoc/DMAW/&filename=DMAW.HTM



You can inspect the kernel source code for the new Sound Blaster driver functions for more fun. Currently basically there is just the OPCODE__wait_DSP_DATA_AVAIL and OPCODE__ResetDSP functions, and the sbtest0 command.

Just remember that you could need to set up the basic Sound Blaster from DOS first, specially for non-creative clones.

Attachments:
File comment: DOS COM file implementing the same SoundBlaster test code than the [b]sbtest0[/b] command.
sbtest0.zip [4.93 KiB]
Downloaded 43 times

Page 3 of 3 All times are UTC - 6 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/