• AVR Freaks

How to determine free space on USB thumb drive....

Author
gadgetwob
New Member
  • Total Posts : 6
  • Reward points : 0
  • Joined: 2011/03/11 11:50:04
  • Location: 0
  • Status: offline
2011/04/11 03:01:20 (permalink)
0

How to determine free space on USB thumb drive....

Hi Folks,
              I have been programming in assembler for a good few years, but C is still fairly new to me.  I am working on a project based on Microchip's Thumb Drive Data Logger Demo.  I have probably missed something really obvious, (apologies in advance if that is the case) but I can't see a way to determine the remaining free space on the thumb drive.  This project needs to delete the oldest files on the drive in order to maintain a certain amount of free space, so it doesn't become full during logging.  Anyone got any ideas?  Your help would be greatly appreciated.

Thanks

Rob
#1

2 Replies Related Threads

    chinzei
    Super Member
    • Total Posts : 2250
    • Reward points : 0
    • Joined: 2003/11/07 12:39:02
    • Location: Tokyo, Japan
    • Status: offline
    Re:How to determine free space on USB thumb drive.... 2011/04/11 04:54:19 (permalink)
    0
    This one.

    C:\Microchip Solutions v2010-10-19\Microchip\MDD File System\FSIO.c

    /*********************************************************************************
      Function:
        void FSGetDiskProperties(FS_DISK_PROPERTIES* properties)
      Summary:
        Allows user to get the disk properties (size of disk, free space, etc)

    For the details of usage, read the comments after these lines on the source code.

    I have probably missed something really obvious

    The help file (MDDFS Library Help.chm) doesn't refer to this function. Just on the source code.
    So, it isn't so obvious.

    Tsuneo
    #2
    gadgetwob
    New Member
    • Total Posts : 6
    • Reward points : 0
    • Joined: 2011/03/11 11:50:04
    • Location: 0
    • Status: offline
    Re:How to determine free space on USB thumb drive.... 2011/04/11 09:54:30 (permalink)
    0
    That's great!  Exactly what I wanted!  Thanks for your help, I was beginning to wonder what on earth I would do.....

    Rob
    #3
    Jump to:
    © 2019 APG vNext Commercial Version 4.5