summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/debug_menu.c6
-rw-r--r--apps/iap.c12
2 files changed, 14 insertions, 4 deletions
diff --git a/apps/debug_menu.c b/apps/debug_menu.c
index c0a476dc10..94076bf64d 100644
--- a/apps/debug_menu.c
+++ b/apps/debug_menu.c
@@ -122,6 +122,10 @@
#include "usb_core.h"
#endif
+#if defined(IPOD_ACCESSORY_PROTOCOL)
+#include "iap.h"
+#endif
+
/*---------------------------------------------------*/
/* SPECIAL DEBUG STUFF */
/*---------------------------------------------------*/
@@ -1182,7 +1186,7 @@ bool dbg_ports(void)
#endif
#if defined(IPOD_ACCESSORY_PROTOCOL)
-extern unsigned char serbuf[];
+ const unsigned char *serbuf = iap_get_serbuf();
lcd_putsf(0, line++, "IAP PACKET: %02x %02x %02x %02x %02x %02x %02x %02x",
serbuf[0], serbuf[1], serbuf[2], serbuf[3], serbuf[4], serbuf[5],
serbuf[6], serbuf[7]);
diff --git a/apps/iap.c b/apps/iap.c
index 4d2ec625cd..f53717e625 100644
--- a/apps/iap.c
+++ b/apps/iap.c
@@ -52,7 +52,7 @@ static unsigned long iap_remotebtn = 0;
static int iap_repeatbtn = 0;
static bool iap_btnrepeat = false, iap_btnshuffle = false;
-unsigned char serbuf[RX_BUFLEN];
+static unsigned char serbuf[RX_BUFLEN];
static int serbuf_i = 0;
static unsigned char response[TX_BUFLEN];
@@ -837,13 +837,13 @@ void iap_handlepkt(void)
/* tuner frequency from scan */
case 0x13:
{
- rmt_tuner_freq();
+ rmt_tuner_freq(serbuf);
break;
}
/* RDS station name 0x21 1E 00 + ASCII text*/
case 0x21:
{
- rmt_tuner_rds_data();
+ rmt_tuner_rds_data(serbuf);
break;
}
}
@@ -868,3 +868,9 @@ int remote_control_rx(void)
return btn;
}
+
+const unsigned char *iap_get_serbuf(void)
+{
+ return serbuf;
+}
+