From 8e4a0e0aabc9c35cc6b9bc9506e629dabf291031 Mon Sep 17 00:00:00 2001 From: Linus Nielsen Feltzing Date: Sun, 10 Nov 2002 18:24:40 +0000 Subject: [PATCH] An attempt to support older recorder models git-svn-id: svn://svn.rockbox.org/rockbox/trunk@2817 a1c6a512-1295-4272-9138-f99709370657 --- firmware/mpeg.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/firmware/mpeg.c b/firmware/mpeg.c index d830b0aac5..4a7d37e8f8 100644 --- a/firmware/mpeg.c +++ b/firmware/mpeg.c @@ -33,6 +33,7 @@ #include "thread.h" #include "usb.h" #include "file.h" +#include "hwcompat.h" #endif extern void bitswap(unsigned char *data, int length); @@ -649,10 +650,18 @@ static void dma_tick(void) TCNT2 = 0; for(i = 0;i < 30;i++) { - PADR |= 0x800; + if(read_hw_mask() & PR_ACTIVE_HIGH) + PADR |= 0x800; + else + PADR &= ~0x800; + while(PBDR & 0x8000) {}; mp3buf[mp3buf_write] = *(unsigned char *)0x4000000; - PADR &= ~0x800; + + if(read_hw_mask() & PR_ACTIVE_HIGH) + PADR &= ~0x800; + else + PADR |= 0x800; mp3buf_write++; if(mp3buf_write >= mp3buflen)