view pirelli/aec @ 392:35009c936a4a

compal/melody-extr: first attempt at actual melody extraction
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 01 Apr 2022 06:03:47 +0000
parents 0f9606d1f8b8
children
line wrap: on
line source

Reverse eng question: what does Pirelli's fw do with the AEC feature
of Calypso DSP?

Seeking an answer to this question, I sent an aur 12 command to Pirelli's fw
via fc-tmsh.  The response came back with 48 bytes of data, consistent
with our reference TCS211 code with L1_NEW_AEC enabled.  Here is the raw
response in non-loudspeaker-call state:

aur 12: 48 bytes
offset 00:  02 00 01 00 14 00 CC 0C  AD 59 00 40 32 00 00 10
offset 10:  00 10 00 00 04 00 00 00  9E FE 43 06 E5 16 34 36
offset 20:  E5 16 43 06 9E FE B4 FC  BA FE 0F 01 40 00 C7 FF

In an active loudspeaker call, two settings change:

aur 12: 48 bytes
offset 00:  02 00 01 00 14 00 CC 0C  FF 0F 00 40 32 00 00 10
offset 10:  00 10 00 00 04 00 60 00  9E FE 43 06 E5 16 34 36
offset 20:  E5 16 43 06 9E FE B4 FC  BA FE 0F 01 40 00 C7 FF

Due to a misdesign in ETM (apparently unchanged between reference TCS211 and
Pirelli's fw), the 48 bytes that come back are actually just 24 bytes of real
data (new AEC config is 12 16-bit words) followed by 24 bytes of garbage
padding.  Decoding the returned 12 words of new AEC config, we get:

aec_enable = 0x0002
continuous_filtering = 0x0001
granularity_attenuation = 0x0014
smoothing_coefficient = 0x0CCC
max_echo_suppression_level = 0x59AD (handheld mode) or 0x0FFF (loudspeaker)
vad_factor = 0x4000
absolute_threshold = 0x0032
factor_asd_filtering = 0x1000
factor_asd_muting = 0x1000
aec_visibility = 0
noise_suppression_enable = 0x0004
noise_suppression_level = 0 (handheld mode) or 0x0060 (loudspeaker)