[haiku] Re: haiku HDA (audio) driver - feedback

  • From: "Jérôme Duval" <korli@xxxxxxxxxxxxxxxx>
  • To: haiku@xxxxxxxxxxxxx
  • Date: Fri, 2 Jan 2009 16:55:18 +0100

Hi Cyan,

2008/12/28 FreeLists Mailing List Manager <ecartis@xxxxxxxxxxxxx>

> I did encounter a couple of problems. Firstly there seemed to be
> something wrong with the output level, possibly to do with the codec
> configuration? The output level seems to be roughly 40-60dB quieter
> than a line-level signal, even with the codec mixer gains cranked
> as far as they'll go. Decreasing the codec mixer levels decreased the
> signal output as expected, and the mute controls functioned normally.
> Increasing the output level from the media kit mixer (master fader)
> caused clipping, suggesting the signal attenuation is happening
> somewhere after conversion from float to PCM.


Dunno. Some codecs have VRef levels for inputs which are incorrectly set (ie
on ALC882, it seems to be the case for the Mic-In).


>
> I tested both the front outputs and the side outputs (which are
> driven by different circuitry on the codec chip -- no headphone amp)
> and both had the same low output level. The microphone-level inputs
> on a mixing desk were used to raise the signal to an audible level
> for the test.


I added some code to activate EAPD on pins which have this capability
(available in r28839)**. Maybe it would help in your case.


>
> The second issue was that recording didn't seem to work. I only
> tested briefly with R5's SoundRecorder (so it might be a format
> mismatch?), but although SoundRecorder started up okay, the VU meters
> remained fixed at the top (left meter) and somewhere in the middle
> (right meter), unrelated to an external signal via any jack socket
> or the mixer settings.


Yeah, SoundRecorder is only ok atm (R5 and Haiku) with 16 bits data. Support
for 24 bits (which the HDA format chosen) is still to be fixed and tested.
It's not that obvious to implement because Haiku doesn't encode media files.
I have problems with writing 24 bits WAVE files with correct paddings and
well played afterwards.
Recording in 16 bits data also doesn't work completely, and I don't
understand why yet.


> Regarding the sample rate (192kHz), would it be possible to
> reconfigure the driver to operate at a different rate, such as
> 44.1kHz?


This would be an unimplemented feature of the multiaudio media addon:
proposing sample rate and format listbox to be used on the next start or
live.


>
>
> Aside from providing the best possible quality (due to elimination
> of all resampling), it would open up the possibility of using the
> multi-channel features later -- which only function up to 96kHz.
> Considering there are 10 independent outputs and the media kit mixer
> already has the necessary routing, this would be very useful!
>
>
I don't see yet how the media mixer really helps here. It's all up to the
driver to expose a 6-channels stream or multiple stereo streams (for
outputs).

Thanks so far for your testing and feedback. It's definitely appreciated.

Bye,
Jérôme

Other related posts: