Method and apparatus for adaptive data chunk transfer
View Patent ↗A block memory device and method of transferring data to a block memory device are described. Various embodiments provide methods for transferring data to a block memory device by adaptive chunking. The data transfer method comprises receiving data in a data chunk. The data transfer method then determines that the data chunk is ready to be transferred to a block memory and transfers the data chunk to the block memory. The transfer occurs over duration, repeating the above steps until the transfer is complete. The data transfer method determines that the data chunk is ready to be transferred to the block memory based on at least in part on a duration of a previous transfer.
1. A method for transferring data to a block memory device by adaptive chunking, the method comprising:
receiving data for a data chunk;
determining that the data chunk is ready to be transferred to a block memory;
transferring the data chunk to the block memory, the transfer occurring over a duration; and
repeating the above method steps until the transfer is complete, wherein a size of the data chunk is based at least in part on a duration of a previous transfer,
wherein the size of the data chunk is equal to the amount of data able to be transferred to a buffer during the duration of the previous transfer.
2. The method of claim 1 , wherein determining that the data chunk is ready to be transferred to the block memory further comprises determining that a size of the data chunk is greater than or equal to a minimum data chunk size and less than or equal to a maximum data chunk size.
3. The method of claim 1 , wherein determining that the data chunk is ready to be transferred to the block memory further comprises determining that a size of the data chunk is at least a minimum update size of the block memory.
4. The method of claim 1 , wherein determining that the data chunk is ready to be transferred to the block memory comprises determining that a size of the data chunk conforms to one or more transfer conditions.
5. The method of claim 4 , wherein determining that a size of the data chunk conforms to one or more transfer conditions further comprises determining that a size of the data chunk conforms to a data storage chunk size of the block memory.
6. The method of claim 1 , wherein the block memory comprises memory blocks of a predetermined size and a fixed size.
7. The method of claim 1 , wherein the previous transfer consists of transferring a previous data chunk to the block memory.
8. The method of claim 1 , wherein the previous transfer consists of erasing at least one block of the block memory.
9. The method of claim 1 , wherein the previous transfer consists of erasing at least one block of the block memory and transferring a previous data chunk to the block memory.
10. The method of claim 1 , wherein receiving data for the data chunk comprises receiving a portion of a USB data frame for the data chunk.
11. The method of claim 10 , wherein receiving the portion of the USB data frame for the data chunk further comprises receiving the portion of the USB data frame for the data chunk, the portion of the USB data frame being part of a bulk-transfer.
12. The method of claim 10 , wherein receiving the portion of the USB data frame for the data chunk further comprises receiving the portion of the USB data frame for the data chunk, the portion of the USB data frame being part of an interrupt-driven transfer.
13. The method of claim 10 , wherein receiving the portion of the USB data frame for the data chunk further comprises receiving the portion of the USB data frame for the data chunk, the portion of the USB data frame being part of an isochronous transfer.