在以SD卡为图像存储器件的图像协处理器中,基带芯片和SD卡控制器在速度上的差异经常会导致数据传输错误。为解决此问题,设计了一种可适应多种时序情况的DMA控制器。该DMA控制器的状态机,一方面对基带芯片和SD卡控制器的操作请求进行仲裁,在响应基带芯片请求的同时,适当推迟SD卡控制器的请求;另一方面对DMA读写的数据进行计数,并以此判断SD卡的一次多块读或多块写操作是否完成;最后对基带芯片和SD卡控制器的速度做出判断,必要时暂停速度较快一方的操作。实际工作表明,该DMA控制器能够在基带芯片和SD卡控制器之间正确传输数据并使读写SD卡的速度达到210 kB/s。Abstract: In the image coprocessor which used SD card as memory,there is a speed difference between baseband and SD card controller. The difference will result some errors in data transmission. To solve the problem,the DMA controller adapted for several timing cases was designed. On the one hand,after arbitrating operation requests from baseband and SD card controller,the DMA controller responded to a request of baseband and delayded another. On the other hand,by counting the number of data in a DMA operation,the controller determined whether a read or write operation of multiple block should done or not. In the end,the DMA controller estimated the speed of baseband and SD card controller and broke the operations of the faster one. In practice,the DMA controller transfers data correctly between baseband and SD card controller and enhances the speed of read or write operation of SD card to 210kB/s.
猜您喜欢
评论