summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLorenzo Miori <memorys60@gmail.com>2013-11-21 13:15:08 +0100
committerAmaury Pouly <amaury.pouly@gmail.com>2013-11-21 14:26:24 +0100
commitadc503302c65df3cfd7c0f6f900458a27beb5a9c (patch)
treebe87db2762e566d8bdc3ccd6cc230803b5335c26
parent193753aa1f93ba28995a80048cbc46f1fc5cde05 (diff)
downloadrockbox-adc503302c65df3cfd7c0f6f900458a27beb5a9c.tar.gz
rockbox-adc503302c65df3cfd7c0f6f900458a27beb5a9c.zip
tea5767: properly power up the tuner during detect
Change-Id: I5ca5c3ae28db1427e2528cb1740a9199180b9b38 Reviewed-on: http://gerrit.rockbox.org/670 Reviewed-by: Amaury Pouly <amaury.pouly@gmail.com>
-rw-r--r--firmware/drivers/tuner/tea5767.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/firmware/drivers/tuner/tea5767.c b/firmware/drivers/tuner/tea5767.c
index 6efcee26e3..d0041f9ce1 100644
--- a/firmware/drivers/tuner/tea5767.c
+++ b/firmware/drivers/tuner/tea5767.c
@@ -167,6 +167,7 @@ void tea5767_init(void)
167 167
168 /* init chipid register with 0xFF in case fmradio_i2c_read fails silently */ 168 /* init chipid register with 0xFF in case fmradio_i2c_read fails silently */
169 buf[3] = 0xFF; 169 buf[3] = 0xFF;
170 tuner_power(true);
170 if (fmradio_i2c_read(I2C_ADR, buf, sizeof(buf)) < 0) { 171 if (fmradio_i2c_read(I2C_ADR, buf, sizeof(buf)) < 0) {
171 /* no i2c device detected */ 172 /* no i2c device detected */
172 tuner_present = false; 173 tuner_present = false;
@@ -175,6 +176,7 @@ void tea5767_init(void)
175 chipid = buf[3] & 0x0F; 176 chipid = buf[3] & 0x0F;
176 tuner_present = (chipid == 0); 177 tuner_present = (chipid == 0);
177 } 178 }
179 tuner_power(false);
178#endif 180#endif
179} 181}
180 182