Rockbox mail archive
Subject: RE: DMA Operation???
From: Nielsen Linus (ext) (Linus.Nielsen_at_elema.siemens.se)
> 1. The main mpeg_thread function (in mpeg.c) gets a NEED_DATA
> event, and reads in the next chunk of MP3 from the file on
> disc to the buffer located at mp3buf+mp3buf_write (top level
> of current data). This happens every time
> the 'large' 1.5meg buffer reaches its low water mark. This is
> when you see the red light on the player come on because
> of disc access.
> 2. The data is at the same time being DMA'ed from the large
> buffer straight to the buffer in the MAS chip???
The MAS has a serial connection to the SH1. Period. We don't know anything
about how the DSP code in the MAS is implemented.
> or is there an intermediate buffer in 'rockbox' code from which the
> MAS picks up the stream?
> im a bit confused here - how does the data get from the large
> buffer to the MAS chip?
Via the serial connection (port 0). The DMA writes to the UART register.
> im also not comletely clear about the significience of
> 0x5FFFEC3 as the DMA destination address - you say that
> is where we write the address from where the DMA reads
> the data to be sent to the MAS. Doesnt it get
> the data from mp3buf + mp3buf_read and write it to
> 0x5FFFEC3? i assumed that the SAR3 is the source address
> for DMA3 and the DAR3 is where it dumps the data???
My mistake. The destination is set to be the UART send register for serial
> I take your point about having to frame align my 'beep', you are quite
> correct - bit of a challenge that :) i guess we are looking at doing a
> little DMA to finish the current frame before the 'beep' dma,
> followed by
> the remaining real MP3 frames, including dealing with track boundaries
Yup. Quite a tricky task.
Page was last modified "Jan 10 2012" The Rockbox Crew