

                  how to call dfgnbla from a C program



	what's it for?

	this program will 

	1)  beep a user-specified number of times and then cycle 
	    silently until any key hit, or

	2)  cycle silently until any key hit

	it also returns the char value of the key hit

	it's called from a C or C++ program

;----------------------------------------------------------------------

	any restrictions on this program?

	ms-dos/windows/xp operating system
	386 cpu or better

;----------------------------------------------------------------------

	how do i call it from an C program?

	install the following code in your C program

//-------------------------------------------------------
//	declarations
//-------------------------------------------------------

extern unsigned char dfgnbla(unsigned int);

//-------------------------------------------------------
//	variables
//-------------------------------------------------------
extern unsigned int bla_beep;      /* nbr of beeps for dfgnbla */
unsigned char bla_key;             /* keystroke returned by dfgnbla */


//-------------------------------------------------------
//	code
//-------------------------------------------------------
   bla_beep = 10;               /*  nbr of beeps  */
   bla_key = dfgnbla(bla_beep); /*  bla_key now = char value of key hit  */



	see blac.c (included in this package) for a C program 
	that calls dfgnbla 

        note:  actual name of external module is _dfgnbla
        according to borland conventions you should ...
        *OMIT* underscore (use dfgnbla) in C program (see above).
        *INCLUDE* underscore (use _dfgnbla) in linker list

	install above code into caller program  
	compile caller program
	add _dfgnbla to your link.  _dfgnbla.obj included in package
	run linker
	run caller program


        to cycle silently like the ms-dos pause command but without
        the 'press any key to continue ...', write this ... 

        bla_beep = 0;          /*nbr of beeps */

        the rest of the code is the same as the above example or blac.c
;----------------------------------------------------------------------

	what happens when i call it?

	it beeps a user-specified number of times, then cycles 
	silently until you hit any key.  the beeps should be about 
	2 per second regardless of your cpu clock speed.  it returns
	the char value of the key you hit.

;----------------------------------------------------------------------

	any warnings about this program?

	THE BEEP IS NOT VERY LOUD.  you may not hear it if tv or radio
	is playing loudly.
;----------------------------------------------------------------------

	can i control the sound volume?

	no.  the chip does not allow it.
;----------------------------------------------------------------------
