MFS Limited by page size?

This forum is dedicated to feedback, discussions about ongoing or future developments, ideas and suggestions regarding the ChibiOS projects are welcome. This forum is NOT for support.
wizhippo
Posts: 18
Joined: Thu Oct 31, 2013 3:41 pm

MFS Limited by page size?

Postby wizhippo » Fri Jan 08, 2021 11:23 pm

I have the following

Code: Select all

const MFSConfig mfscfg1 = {
        .flashp           = (BaseFlash *) &EFLD1,
        .erased           = 0xFFFFFFFFU,
        .bank_size        = 1024U,
        .bank0_start      = 64U,
        .bank0_sectors    = 32U,
        .bank1_start      = (64U + 32U),
        .bank1_sectors    = 32U,
};


Maybe I misunderstand. To me this would mean on a 128k device that the bank would start at 64k and I should end up with 32k usable storage.

If I try to write more then 1024 bytes I get mem full error.

Are record sizes limited to a single sector?

wizhippo
Posts: 18
Joined: Thu Oct 31, 2013 3:41 pm

Re: MFS Limited by page size?

Postby wizhippo » Fri Jan 08, 2021 11:37 pm

I think I had it wrong

.bank_size = 1024U refers the size of a bank and not the size of a page on the chip. Sorry my confusion.

User avatar
Giovanni
Site Admin
Posts: 14444
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1074 times
Been thanked: 921 times
Contact:

Re: MFS Limited by page size?

Postby Giovanni » Sat Jan 09, 2021 8:11 am

Hi,

Yes correct, the bank size is not the physical sectors size.

Giovanni


Return to “Development and Feedback”

Who is online

Users browsing this forum: No registered users and 27 guests