Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

Free Disk Space?

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> AVR-DOS
View previous topic :: View next topic  
Author Message
rileyesi

Bascom Member



Joined: 19 Dec 2006
Posts: 398

blank.gif
PostPosted: Wed Mar 21, 2007 6:12 pm    Post subject: Free Disk Space? Reply with quote

Hi.

Is there a way in AVR-DOS to measure how much storage space is remianing on an SD card? I want to get a warning if I am nearing my disk storage capacity.

Thanks and Regards,

Pete
Back to top
View user's profile
oe9vfj

Moderator



Joined: 17 Jun 2004
Posts: 269
Location: Austria, Hard

austria.gif
PostPosted: Thu Mar 22, 2007 7:35 am    Post subject: Reply with quote

Yes, Use DISKFREE().
You get remaining disksize in KB.

_________________
regards Josef

DOS - File System for BASCOM-AVR on http://members.aon.at/voegel
Back to top
View user's profile Visit poster's website
rileyesi

Bascom Member



Joined: 19 Dec 2006
Posts: 398

blank.gif
PostPosted: Thu Mar 22, 2007 5:30 pm    Post subject: Reply with quote

Thank you, Josef. I missed that in the documentation.

Pete
Back to top
View user's profile
oe9vfj

Moderator



Joined: 17 Jun 2004
Posts: 269
Location: Austria, Hard

austria.gif
PostPosted: Sat Mar 24, 2007 8:33 am    Post subject: Reply with quote

You can find it in the Help-File or at http://avrhelp.mcselec.com/DISKFREE.html
_________________
regards Josef

DOS - File System for BASCOM-AVR on http://members.aon.at/voegel
Back to top
View user's profile Visit poster's website
rileyesi

Bascom Member



Joined: 19 Dec 2006
Posts: 398

blank.gif
PostPosted: Sat Mar 24, 2007 7:30 pm    Post subject: Reply with quote

Josef,

Please don't misunderstand me!

My comment was not a criticism of your wonderful AVR-DOS or the documentation, but a criticism of my failure to see this in the manual!

Regards,

Pete
Back to top
View user's profile
wilbo666

Bascom Member



Joined: 13 Jan 2006
Posts: 18
Location: QLD, Australia

australia.gif
PostPosted: Fri Aug 01, 2008 12:46 pm    Post subject: Reply with quote

oe9vfj wrote:
Yes, Use DISKFREE().
You get remaining disksize in KB.


The help says diskfree() returns in bytes...is the help wrong?

Syntax
lFreeSize = DISKFREE()

Remarks
lFreeSize
A Long Variable, which is assigned with the available Bytes on the Disk in Bytes

Cheers
Wilbo
Back to top
View user's profile MSN Messenger
oe9vfj

Moderator



Joined: 17 Jun 2004
Posts: 269
Location: Austria, Hard

austria.gif
PostPosted: Fri Feb 20, 2009 1:59 pm    Post subject: Reply with quote

DISKSIZE and DISKFREE return the space in KB (1024 Bytes) unit. I changed that with implementation of FAT32, because this skips over the 2GB border which is the maximum of a LONG Variable.
_________________
regards Josef

DOS - File System for BASCOM-AVR on http://members.aon.at/voegel
Back to top
View user's profile Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> AVR-DOS All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum