On Monday 28 April 2008 23:12, rtstofer wrote:
> --- In Electronics_101@yahoogroups.com, "markwcol" <markwcol@...> wrote:
> > I would like to build a circuit to allow a PIC Microcontroller to talk
> > to a Soundblaster card to create a Digital Piano/Synth. I am thinking
> > of a couple of circuit ideas
> > 1.- A PIC Controller to scan a Piano Keyboard and send data to the
> > sound card and produce the sounds notes via its output jack. The PIC
> > controller could also select patches to change the sound using internal
> > sounds.
> > 2.- Initialise the sound card to receive Midi data via the Soundcard
> > MIDI Port and play sounds via the output jack. This would add new life
> > to my old drum machine.
> > 3.- Hardware Soundfont device. Have the PIC load Soundfont data to the
> > soundcard ready for Keyboard/MIDI Playback.
> > Wondering does anyone have any circuit information or ideas they could
> > share to get me started. I am ok with the PIC side of things, but need
> > to understand the PCI Bus interface and Soundblaster IO control.
> > Regards Mark
> This project isn't going to happen for a number of reasons: First, the
> PIC is certainly capable of controlling the on-off switch but has
> nowhere near the capability of driving a project like this.
Depends on just what you see it as doing. From my read of the above we're
talking musical events (key press and release, with perhaps some timing info
for velocity information), patch selection and such is just a bit more I/O
and not at all timing-critical, with the major part of the work being done
by the PC program and the DSP.
> Second, I don't think you are going to find ANY documentation on the Sound
> Blaster APIs. You MIGHT be able to deduce some things from the Linux
That's an interesting point, because the key there is what chip are they
using on the card. Last one I remember taking notice of used an Ensoniq
ES1371, the ones before that AD1816 or something like that, and perhaps
data on the chips is out there somewhere.
> Third, of all the bus interfaces you could choose, PCI might
> be the hardest. Why not try to find an old ISA board?
I'm not sure I see where the choice of bus interface even comes into the
project in the first place, perhaps I'm missing something here. FWIW, the
first sound card I got going under linux was an ISA, and the isapnp program
got a bit of a workout, along with pnpdump and some others not the least of
which was my text editor. That was much more of a PITA than dealing with PCI
stuff later on, particularly since I didn't have the smarter install code
looking to deal with it but instead had to do most of it manually because I
did it much later on.
> If you REALLY want to build a project like this, you can take two
> approaches: buy into Linux on a PC with the various opensource
> programs or consider a processor with DSP capabilities like the
> Blackfin. There is an audio codec project for the Blackfin here:
> The only remaining task is to write all of the code. The Blackfin
> BF537 Stamp runs uClinux so at least some of the Linux codebase will
> be usable. The codebase for the BF537 has some sound drivers for the
> AD1836 codec although the current silicon is AD1836A.
> There is a Blackfin Audio starter board but it sells for $750 hereas
> the Stamp board sells for about $212.50 at DigiKey.
> I was successful at building an MP3 player with an LPC2106 ARM7
> processor and a VLSI codec. But that was trivial compared to this
> Bottom line: if you can't find a project on Google that matches your
> requirement then it hasn't been built. If it hasn't been built, there
> is a reason...
If one considers the PIC (or whatever) that's external to the computer and
sending musical event data from keyboard and patch selection components out
to the PC (via MIDI or some other choice of interface, it doesn't have to be
directly to the sound card hardware) then that becomes a fairly trivial
application. They made some specific chips years ago designed to do nothing
but scanning keyboards, and it's just not that big of a deal. The program
that sits in the PC and accepts this information and decides how to deal with
it is the hard part. But if that input is coming in as MIDI then it gets a
whole lot easier.
I don't see a problem here, mostly, but I'm also getting pretty tired so
it's possible I'm missing something...
Member of the toughest, meanest, deadliest, most unrelenting -- and
ablest -- form of life in this section of space, a critter that can
be killed but can't be tamed. --Robert A. Heinlein, "The Puppet Masters"
Information is more dangerous than cannon to a society ruled by lies. --James