PORTS Forum

Ports and Interfaces => General Discussion => Topic started by: henson on April 23, 2012, 11:28:05 am

Title: Editing long files
Post by: henson on April 23, 2012, 11:28:05 am
It would seem that adding a few bytes (such as with a text editor) in the middle of a long file would require rewriting the file from the edit to the end.
Or, is there a way to put a partial cluster/sector in the middle?  The "USB Mass Storage" text does not specifically mention this common procedure.

Thanks.  JCH
Title: Re: Editing long files
Post by: Jan Axelson on April 23, 2012, 01:07:45 pm
Clusters in a volume are a fixed size. No way to insert a partial cluster.

Jan
Title: Re: Editing long files
Post by: henson on April 23, 2012, 02:15:22 pm
So the answer is yes, the file from the edit insertion on must be rewritten.  Only the last cluster may be partially filled.

Very useful and well written book, by the way.  How about Bluetooth/ZigBee next? 

Title: Re: Editing long files
Post by: Jan Axelson on April 23, 2012, 02:19:13 pm
I'm glad you found USB Mass Storage useful, and I always welcome suggestions for things to write about. Zigbee and Bluetooth have been on my "short list" for a while.

Jan