mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-12 02:45:33 +00:00
snow: add keypress noise suppression
This was implemented for Daisy a long time ago, but left out on Snow
due to some confusion.
GPIO remapping is already handled because PD1 and PD0 (which is used
for ENTERING_RW) are remapped together. So all we need here is the
board_keyboard_suppress_noise() function definition which gets
called from the keyboard scanning code whenever a change is detected.
BUG=none
TEST=Verified using a scope that CODEC_INT line is driven
when a key is pressed (15us pulse)
Signed-off-by: David Hendricks <dhendrix@chromium.org>
Change-Id: Ifd358eb89a9547c4f4b9536b8922c93d2c3b77a0
Reviewed-on: https://gerrit.chromium.org/gerrit/28989
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
@@ -144,6 +144,13 @@ void board_interrupt_host(int active)
|
||||
gpio_set_level(GPIO_EC_INT, !active);
|
||||
}
|
||||
|
||||
void board_keyboard_suppress_noise(void)
|
||||
{
|
||||
/* notify audio codec of keypress for noise suppression */
|
||||
gpio_set_level(GPIO_CODEC_INT, 0);
|
||||
gpio_set_level(GPIO_CODEC_INT, 1);
|
||||
}
|
||||
|
||||
enum {
|
||||
/* Time between requesting bus and deciding that we have it */
|
||||
BUS_SLEW_DELAY_US = 10,
|
||||
|
||||
Reference in New Issue
Block a user