No space for eeprom or f-ram

I'm working on a project using the ATSamD11A which has 16KB of programming space. No matter what library I use or try just to see if it is enough space to write to external storage. it goes overflow. I have the MB85RC F-Ram i2c chip. Not sure what to do to free up space on the library or coding to make it work. This is the library I have found. https://github.com/sosandroid/FRAM_MB85RC_I2C Can someone in the community who knows how to do this can help me please?

Joseph

Probably the CPP --
comment out the functionalities that you won't use - if you can stick to reading/writing Words then you can get rid of, I presume, the OneBit stuff and other things like that.

How much memory is your code using without the eeprom/fram code?

Unused functions in the library should be automatically eliminated by the compiler.

While "in theory", an ARM chip with 16K of program memory is "more powerful" than an AVR with 16K of program memory, this mostly falls apart because most of the ARM libraries are written "assuming" that there will be a lot more than 16k present in the chip. Add "significant" amounts of code to support USB (~6k), a big chunk for a bootloader (4k), and "really huge" amounts to support floating point (the gnu floating point code for CM0 is one of those libraries that is "completely un-optimized for CM0" Sigh), and there's not a lot you can do with a SAMD11 unless you are REALLY CAREFUL. (whereas a 16k AVR used to be a "really big" AVR, with various libraries optimized to run on chips with 4k or 8k.)

The same applies to other vendors' "small memory" ARM chips :frowning:
I have some of those original Luminary Micro CM3 chips (the first released Cortex Microcontrller) with only 8k. It seemed like a good idea at the time, but I dunno what they're good for.

You can look at using picolib instead of newlib-nano, and qfplib instead of the gnu floating point, and the 1k UF2 booloader than someone wrote, and ... end up spending most of your time fighting the memory limits instead of working on the actual application or product that you were aiming for. I've spent a good part of my career fight memory limits. It can be fun. It can even be lucrative. But it's not for everyone.

1 Like

I haven’t even add that code yet. Just the eeprom or f-ram code to see If I can write something. I just have a simple thermistor temperature code that takes about 2k maybe less I haven’t tried yet. And I just found out that with the D11 processor there is 4k taking up by the bootloader itself. which only leaving me 12k left. the eeprom or F-ram code goes way over that.

Joseph

Hey West, I would have no clue how to do something like this. I'm not even skilled enough to trying something like this.

Joseph

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.