@@ -17,16 +17,16 @@ let sdcard = embedded_sdmmc::SdCard::new(sdmmc_spi, delay);
1717println! (" Card size is {} bytes" , sdcard . num_bytes ()? );
1818// Now let's look for volumes (also known as partitions) on our block device.
1919// To do this we need a Volume Manager. It will take ownership of the block device.
20- let mut volume_mgr = embedded_sdmmc :: VolumeManager :: new (sdcard , time_source );
20+ let volume_mgr = embedded_sdmmc :: VolumeManager :: new (sdcard , time_source );
2121// Try and access Volume 0 (i.e. the first partition).
2222// The volume object holds information about the filesystem on that volume.
23- let mut volume0 = volume_mgr . open_volume (embedded_sdmmc :: VolumeIdx (0 ))? ;
23+ let volume0 = volume_mgr . open_volume (embedded_sdmmc :: VolumeIdx (0 ))? ;
2424println! (" Volume 0: {:?}" , volume0 );
2525// Open the root directory (mutably borrows from the volume).
26- let mut root_dir = volume0 . open_root_dir ()? ;
26+ let root_dir = volume0 . open_root_dir ()? ;
2727// Open a file called "MY_FILE.TXT" in the root directory
2828// This mutably borrows the directory.
29- let mut my_file = root_dir . open_file_in_dir (" MY_FILE.TXT" , embedded_sdmmc :: Mode :: ReadOnly )? ;
29+ let my_file = root_dir . open_file_in_dir (" MY_FILE.TXT" , embedded_sdmmc :: Mode :: ReadOnly )? ;
3030// Print the contents of the file, assuming it's in ISO-8859-1 encoding
3131while ! my_file . is_eof () {
3232 let mut buffer = [0u8 ; 32 ];
@@ -43,7 +43,7 @@ By default the `VolumeManager` will initialize with a maximum number of `4` open
4343
4444``` rust
4545// Create a volume manager with a maximum of 6 open directories, 12 open files, and 4 volumes (or partitions)
46- let mut cont : VolumeManager <_ , _ , 6 , 12 , 4 > = VolumeManager :: new_with_limits (block , time_source );
46+ let cont : VolumeManager <_ , _ , 6 , 12 , 4 > = VolumeManager :: new_with_limits (block , time_source );
4747```
4848
4949## Supported features
0 commit comments