From alsa-devel-owner@alsa.jcu.cz  Mon Jan 25 12:33:57 1999
Received: from entry.jcu.cz (IDENT:perex@entry.jcu.cz [160.217.1.111])
	by marvin.jcu.cz (8.9.1a/8.9.1) with SMTP id LAA19521;
	Mon, 25 Jan 1999 11:35:32 +0100
Date: Mon, 25 Jan 1999 11:35:32 +0100 (CET)
From: Jaroslav Kysela <perex@jcu.cz>
To: Sandor Gyetvai <gyetvai@pacbell.net>
cc: alsa-devel@alsa.jcu.cz
Subject: Re: ESS 1868
In-Reply-To: <36ABAF33.468488A4@pacbell.net>
Message-ID: <Pine.LNX.3.96.990125111748.31897D-100000@entry.jcu.cz>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Reply-To: alsa-devel@alsa.jcu.cz
Sender: alsa-devel-owner@alsa.jcu.cz
Precedence: list

On Sun, 24 Jan 1999, Sandor Gyetvai wrote:

> Hello,
> 
> I don't know how to get this card working right.  I tried the different
> Audiodrive drivers, but they don't seem to work.  I finally got it to
> work by using sb8 driver, but the midi is very slow.  Can you help.

No, I cannot help you. SB8 driver and MPU-401 Tx routines uses POLL MODE
for transmit MIDI bytes. Unfortunately there isn't possible do some
of loop which blocks the computer in kernel for a long time. MIDI Tx
routines are called from the interrupt handler, too. I don't know in this
time about good solution for this.

Future solutions:

1) Use timer with (3000 / Tx FIFO size) Hz and do polling in
   timer interrupt.
   - Unfortunately many soundcards doesn't have own timer (like SB etc..).
2) Use kernel thread with small priority for this job if possible.
   - Can someone help me with kernel thread code for 2.2 kernels? I tried
     make some code in alsa-driver/kernel/sthread.c source, but it is
     working only with 2.0 kernels. Code is locking with 2.2 kernels the
     machine.

Note: MPU401 code is prepared for thread use. You can only uncomment
      #define SND_MPU401_POLL in alsa-driver/include/mpu401.h.

Affected soundcards:

Each with MPU401 UART like Sound Blaster 8/16/AWE. Note that AWE have only
2-byte Tx FIFO, thus results with this card are very strange at this
time!!! I'm doing polling only at 100Hz on i386 (system timer). You can
expect with SB AWE only throughput about 200 bytes per socond!!! I think
that sequencer (resp. MIDI output) is totaly unuseable for these
soundcards.

* SoundBlaster 1.0/2.0/Pro
* ESS AudioDrive - Tx FIFO is about 8 bytes
* SonicVibes - 8 bytes
* CS423x - 12 bytes

Non-affected souncards:

* All GUS soundcards which uses GF1 MIDI (except GUS Extreme - ES1688).
* Ensoniq AudioPCI ES1370/ES1371

							Jaroslav

-----
Jaroslav Kysela <perex@jcu.cz>
Academic Computer Centre, University of South Bohemia
Branisovska 31, C. Budejovice, CZ-370 05 Czech Republic


