There's no provision to see the read and write buffers in the MSC firmware.
but how they are going to transfer the data too and from memory to host and host to memory. is it not possible. i need to find it. suggest me any procedure.
thanks for your reply
The data transfer does take place through the DMA channel where the data from the host is directly sent to the DMA buffers over the UIB socket but there is no buffer pointer to these buffer and they are handled according to the CBW command which is the first packet that is sent from the host.
The CBW is a 31-Byte packet in which the direction (read or write), transfer length, start address in the SD card and the number of blocks of data that needs to be written to the SD card are specified.
Based on the direction and the transfer length, SD card is initialized.
If the direction is a read operation, the specified length of data is picked from the start address specified and filled into the DMA buffers. But there's no buffer pointer to these buffers as all of this is taken care by the MSC class driver. The buffers are then directly committed to the host and a CSW packet is sent which tells that the data has been received by the host.
In the same way. write transactions also take place:
- Send 31-Byte CBW
- Send the specified length of data and wait for its completion
- Send CSW to check if the data was received
The usage of MSC driver doesn't give room to perform any vendor specific operations as everything is controlled by that driver.
And that's the reason why there's no provision to find the read and write in msc_example.