Hi Yassin, On Mon, 21 Dec 2015 18:16:35 -0800 (PST) Yassin Jaffer <[email protected]> wrote:
> You don't seem to provide the full gain scale for most of the inputs any > reason for that (Please check the user manual)? I got the scales from the user manuals. Did I make a mistake? Just checked again: >From A20 User Manual v1.4 20150510: DAC LNG: -1.5 dB to 0 dB; max raw value 1. DAC FMG: -4.5 dB to 6 dB; 1.5 dB/step; max raw value 7. DAC MICG: -4.5 dB to 6 dB; 1.5 dB/step; max raw value 7. MIC_PHONE_CAL: PREG1 0 dB..42 dB; same for PREG2; max raw value 7. ADC ADCG: -4.5 dB, -3 dB, ..., 6 dB; max raw value 7. unused: ADC LNPREG: 15:13 in 0x28: -12 dB to 9 dB, 3 dB/step; max raw value 7. >From A10 User Manual v1.5 20130820: ADC PREG*: 0 dB; 35 dB, 38 dB, 41 dB; max raw value 3. And from the patch: (DAC LNG) +static DECLARE_TLV_DB_SCALE(sun4i_codec_linein_loopback_gain_scale, + -150, + 150, + 0); (DAC FMG) +static DECLARE_TLV_DB_SCALE(sun4i_codec_fmin_loopback_gain_scale, + -450, + 150, + 0); (DAC MICG) +static DECLARE_TLV_DB_SCALE(sun4i_codec_micin_loopback_gain_scale, + -450, + 150, + 0); (A10 ADC PREG) +static DECLARE_TLV_DB_RANGE(sun4i_codec_micin_preamp_gain_scale_a10, + 0, 0, TLV_DB_SCALE_ITEM(0, 0, 0), + 1, 7, TLV_DB_SCALE_ITEM(3500, 300, 0)); (MIC_PHONE_CAL PREG) +static DECLARE_TLV_DB_RANGE(sun7i_codec_micin_preamp_gain_scale, + 0, 0, TLV_DB_SCALE_ITEM(0, 0, 0), + 1, 7, TLV_DB_SCALE_ITEM(2400, 300, 0) +); (ADC ADCG) +static DECLARE_TLV_DB_SCALE(sun4i_codec_adc_gain_scale, -450, 150, 0); I don't see the mistake :( Note that TLV_DB_SCALE wants the minimum and the step; maximum is implicit. > You are trying to add input capture support but your routing for > FMIN/Line-In does not include the ADC as a sink. True. Will add it in v9. > I would suggest if your patch cover playback only or add more descriptive > comments. It covers capturing in the sense that I successfully tested capturing with all the combinations as well as loopback playback. >And can you please keep the history of your revisions. Do you mean I should post the changelog of all prior versions that ever existed with each patch set? If so, will do. Regards, Danny -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
