Part Number: TAA3040
Hi,
Is it possble to change the HPF setting in the DSP_CFG0 Register on the fly? If not, what state does the TAA3040 have to be in to change the setting?
Thanks.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Part Number: TAA3040
Hi,
Is it possble to change the HPF setting in the DSP_CFG0 Register on the fly? If not, what state does the TAA3040 have to be in to change the setting?
Thanks.
Hi Adam,
It is recommended to power down the ADC before changing this setting.
Best,
Garret
Thanks Garret. Can this just be clearing bits 5, 6, and 7 in PWR_CFG register, or does it need a 'real' power down?
So I can switch from HPF_SEL = 00 (the filter coefficients are at their default of all pass) to HPF_SEL = 01 and the chip responds as I would expect – the HPF is engaged. However, switching back to HPF_SEL = 00, which should go back to all pass doesn't work. The HFP remains engaged. I have checked that the register value reads back correctly.
What the code does is:
1) Power down the ADC using ADC_PDZ in the PWR_CFG register (I tried also powering down the PLL and the MIC BIAS but that doesn't seem to make a difference).
2) Wait approximately 40ms (again, I've tried longer!)
3) Change the DSP_CFG0 register bits as above.
4) I've tried another delay here – don't seem to do anything.
5) Power the ADC back up using the PWR_CFG register.
Any ideas?
Thanks,
Adam
Hi Adam,
How are you measuring the effect of the HPF? Can you send any filter response plots you may have taken that show this issue?
Best,
Garret
Just using a low frequency square wave. With the all pass it's square (!) but obviously the HPF 'droops' the top and bottom of the signal. Similarly, change the DC level of the input signal in all pass and the output DC level changes – change DC level in HPF and the output doesn't change.
Hi Adam,
Thank you for your observation. I will investigate this next week. Let me know if you find anything else.
Best,
Garret
Hi Adam,
I have discovered the reason for your observation. When you set HPF_SEL = 00, the HPF becomes a custom programmable first-order IIR filter with coefficient values in P4_R72 to P4_R83. All-pass is simply the default for this configuration. The coefficient values will change with the HPF_SEL value.
Since you switched to HPF_SEL = 01, the coefficient values are set to that of the corresponding HPF (12Hz @ 48kHz FSYNC).
Switching back to HPF_SEL = 00 does not reset the coefficients back to an all-pass filter - the coefficients remain from the previous state. However, this allows you to write to the coefficient registers to set your own HPF. In order to reset to the all-pass filter, you must manually write the default values to the coefficient registers after switching to HPF_SEL = 00:
w 9c 00 00
w 9c 6b 00
w 9c 00 04
w 9c 48 7f ff ff ff 00 00 00 00 00 00 00 00
The default all-pass filter coefficients are otherwise only set when the device is reset, which is why you saw it working initially.
Best,
Garret