From mailserv@gaia.ucs.orst.edu Sun May 22 16:40:40 1994
Precedence: Bulk
Date: Sun May 22 14:35:13 PDT 1994
From: gus-sdk-request@gaia.ucs.orst.edu (GUS Programmer's Server)
Reply-To: gus-sdk@gaia.ucs.orst.edu (GUS Programmer's Digest)
Subject: GUS Programmer's Digest V11 #13

GUS Programmer's Digest     Sun, 22 May 94 14:35 PST     Volume 11: Issue  13 

Today's Topics:
                       confusing behavior, SDK

Standard Info:
	- Meta-info about the GUS can be found at the end of the Digest.
	- Before you ask a question, please READ THE FAQ.

----------------------------------------------------------------------

Date: Sun, 22 May 94 02:20:35 EDT
From: gchung@eden.rutgers.edu (Greg Chung)
Subject: confusing behavior, SDK

I'm using the good 'ole SDK2.1, yes I'm back to hacking my GUS.

I've found a curious oddity:

I set up a mod playing routine by using UltraTimer1Handler (for mod
timing), UltraTimer2Handler (for nifty volume bars, etc), and
UltraWaveHandler (the sample-finished handler, for ramps).

I then start the playback (UltraStartTimer(1)) and sit in a while
loop:
while (MOD.Playing) { ... }

In the { ... } I have found that if I put in a kbhit(), everything is
fine until I quit the program.  At that point a dos "mem" will cause a
crash.  However, if I use "(void) getch()" instead, all is well.  

Obviously something's wrong here.  I've tried turning off almost
everything, leaving just the timer1 going and calling an empty
function, yet the kbhit is still what causes the crash.

I'm not going to say that kbhit is the culprit, but whatever it's
doing is making some problem come to the surface... but I have no idea
what.

Other info: I'm setting up everything as should be with the correct
open/reset functions.  The kbhit function works fine before I define
the interrupt handlers (in the file selection window).

If anyone out there has some insight, please reply.  Many thanks.

------------------------------

End of GUS Programmer's Digest V11 #13
**************************************

To post to tomorrow's digest:                    <gus-sdk@mail.orst.edu>
To (un)subscribe or get help:            <gus-sdk-request@mail.orst.edu>
To contact a human (last resort):          <gus-sdk-owner@mail.orst.edu>

FTP Sites              Archive                       Directories
---------              -------                       -----------
Main N.American Site:  archive.orst.edu              pub/packages/gravis
                       wuarchive.wustl.edu           systems/ibmpc/ultrasound
Main Asian Site:       nctuccca.edu.tw               PC/ultrasound
European Callers ONLY: theoris.rz.uni-konstanz.de    pub/sound/gus
Submissions:           archive.epas.utoronto.ca      pub/pc/ultrasound/submit
Newly Validated Files: archive.epas.utoronto.ca      pub/pc/ultrasound
Mirrors:               garbo.uwasa.fi                mirror/ultrasound
 
MailServer For Archive Access: Email to <mail-server@nike.rz.uni-konstanz.de>

Hints:
      - Get the FAQ from the FTP sites or the request server.
      - Mail to <gus-sdk-request@mail.orst.edu> for info about other GUS
	related mailing lists (general use, musician's, etc.).


