ASoC: ts3a227e: Remap keys to match Android headset specification
ts3a227e datasheet says typical key resistance is key1 50 Ohm key2 135 Ohm key3 240 Ohm key4 470 Ohm The android headset specification expect buttons impedance: A (MEDIA) 0-70 Ohm D (VOICECOMMAND) 110-180 Ohm B (VOLUMEUP) 210-290 Ohm C (VOLUMEDOWN) 360-680 Ohm Thus key mapping should be key1 - MEDIA key2 - VOICECOMMAND key3 - VOLUMEUP key3 - VOLUMEDOWN Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com> Acked-by: Dylan Reid <dgreid@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
97bf6af1f9
commit
ddf9ea21f5
|
@ -221,9 +221,9 @@ int ts3a227e_enable_jack_detect(struct snd_soc_component *component,
|
|||
struct ts3a227e *ts3a227e = snd_soc_component_get_drvdata(component);
|
||||
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_MEDIA);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOLUMEUP);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOICECOMMAND);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOICECOMMAND);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEUP);
|
||||
snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOLUMEDOWN);
|
||||
|
||||
ts3a227e->jack = jack;
|
||||
ts3a227e_jack_report(ts3a227e);
|
||||
|
|
Loading…
Reference in New Issue