test_server: Add utils to detect continuous 0 from audio data
Add one handy function to detect continous 0 from chameleon. This
function will also save problem samples to .wav file. It can detect for
a very long time by chameleon stream server.
This CL also fixed the lint errors.
Example usage:
>>> ConnectCrosToLineIn()
>>> p.StartCapturingAudio(6)
(do someting on DUT to play
audio to headphone)
>>> DetectAudioValue0()
BUG=None
TEST=Test audio_AudioBasicHDMI and audio_AudioBasicHeadphone.
Test if we can detect the value by HDMI and audiojack interfaces.
Change-Id: I5b20e0cb039c083c823e6f4bb3b6d78e03c88ed5
Reviewed-on: https://chromium-review.googlesource.com/424256
Commit-Ready: Hsu Wei-Cheng <mojahsu@chromium.org>
Tested-by: Hsu Wei-Cheng <mojahsu@chromium.org>
Reviewed-by: Cheng-Yi Chiang <cychiang@chromium.org>
10 files changed