Skip to content

2.5.0 IRAM usage core_esp8266_si2c.c #5707

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
freeck opened this issue Feb 1, 2019 · 4 comments
Closed

2.5.0 IRAM usage core_esp8266_si2c.c #5707

freeck opened this issue Feb 1, 2019 · 4 comments

Comments

@freeck
Copy link

freeck commented Feb 1, 2019

Hi there, I was rather surprised by the increase of iram-usage of my application when using release v2.5.0 for the first time. The map shows that the i2c-library is the greatest consumer of ram i.e. Aprox. 2500 bytes! As on the other hand the developers did their utmost to decrease iram-usage with aprox 700 bytes....
This increase is caused by the extension of the library with slave-functionality.
Wouldn't it be a good idea to have two versions of this library , with and without slave-functions. Or some kind of conditional compilation and/or linking two separate modules.

@freeck freeck changed the title 2.5.3 IRAM usage core_esp8266_si2c.c 2.5.0 IRAM usage core_esp8266_si2c.c Feb 2, 2019
@earlephilhower
Copy link
Collaborator

Could you give a specific example or sketch that shows a difference?

@freeck
Copy link
Author

freeck commented Feb 2, 2019

Mind you: I use Sloeber as IDE.
I just included "wire.h" in a basic blink.ino example, made one referende to the original library , and there you are. Next I deleted all the IRAMCACHE definitions in the headers of the i2c-functions. Result: 2500 IRAM extra.

@earlephilhower
Copy link
Collaborator

Check out #6326. It's untested, but reduced IRAM usage by >500 bytes in the TWI code. Any testing you'd be able to provide would be welcome!

@devyte
Copy link
Collaborator

devyte commented Oct 31, 2019

The referenced PRs are merged, IRAM has improved quite a bit. Closing this.

@devyte devyte closed this as completed Oct 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants