avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] [RFC] New eeprom.h


From: Dmitry K.
Subject: Re: [avr-libc-dev] [RFC] New eeprom.h
Date: Fri, 29 Feb 2008 15:23:24 +1000
User-agent: KMail/1.5

Hi all.

I like the rewrite. It looks good. My only concern is not
only code size. There is a second question: this functions
are not a normal C functions.  That is:

. No argument type control at compile time. For expamle,
the expressions like
    eeprom_write_block ("Apple", s, sizeof("Apple"));
    eeprom_write_dword (3.14159, 0);
do not type any warnings.

. It is impossible to get address of eeprom function
to inderect call.

. Avr-gcc can not to optimize the EEPROM reading, like it
can do this in case of SRAM.


Summarizes the Eric's "eeprom.h" and all ideas from above
(Wouter, Shaun, Rick) I have prepare two projects.

Project 1.
It is a very simple: use an inderect calls (not indirect
registers). It is eliminates big space expense and notes
above: eeprom functions are pure functions. It is needed
to add only 6 very short functions into Avr-libc. At this
moment this project is ready for test. I can to commite
at this week-end.

Project 2.
Use a set of high quality asm functions. This is not only
space effective, also it is fast. Now the set of funtions is
ready for test. Some efforts are needed to include into
Avr-libc: I am not happy to do this manualy.

In attach the "eeprom.h" of project 1.

Opinions?

Thanks,
Dmitry.

Attachment: eeprom.h
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]