From: Bruce J. Weimer, MD
Subject: Play Wav Files
Date: 
Message-ID: <v77vbb12jelk31@corp.supernews.com>
I build and program robots as a hobby.  I'm currently developing "emotions"
for a robot I one day plan to build.  I'm programming an HP Pentium PC under
Windows XP using Xanalys LispWorks Personal Edition (the free download
version).  And the program already does some interesting things, but now I'd
like to give it a "voice."  Specifically, I'd like to have a Lisp function
play a WAV file - something simple like:

(PlayWave 'filename.wav)

The problem is that since I'm a Lisp newbie I don't have the faintest idea
how to do this - would anyone be able to offer some specific code?  I'd be
very grateful for any assistance.

Thank you.

Bruce.
From: Edi Weitz
Subject: Re: Play Wav Files
Date: 
Message-ID: <874r639b0g.fsf@bird.agharta.de>
"Bruce J. Weimer, MD" <······@mminternet.com> writes:

> I build and program robots as a hobby.  I'm currently developing
> "emotions" for a robot I one day plan to build.  I'm programming an
> HP Pentium PC under Windows XP using Xanalys LispWorks Personal
> Edition (the free download version).  And the program already does
> some interesting things, but now I'd like to give it a "voice."
> Specifically, I'd like to have a Lisp function play a WAV file -
> something simple like:
> 
> (PlayWave 'filename.wav)
> 
> The problem is that since I'm a Lisp newbie I don't have the
> faintest idea how to do this - would anyone be able to offer some
> specific code?  I'd be very grateful for any assistance.

I think about the easiest way would be to call the Win32 API function
PlaySound. See Jeff Caldwell's intro about using the Win32 API from
LispWorks at

  <http://cl-cookbook.sourceforge.net/win32.html>

Edi.