[En-Nut-Discussion] Run-time or compile-time configurable devices?

Harald Kipp harald.kipp at egnite.de
Tue Jan 3 20:24:08 CET 2012

Hi Uwe,

On 03.01.2012 15:48, Uwe Bonnes wrote:

> At the moment to my knowledge, a call like
> NutRegisterDevice(&DEV_UART4, 0, 0);
> has no restrictions and and so all the dependancies of the used NUTDEVICE
> must be resolved at runtime. Is there a usage for that feature? If not, a
> lot of dependancies can be resolved at compiled time and will result in much
> smaller code.

I'm afraid I do not understand your question. Actually it works like this:


  NutRegisterDevice(&DEV_UART4, 0, 0);

will add a dependency at compile time and thus add the UART driver to
the final binary.

The app/simple sample doesn't include any driver and so the final binary
contains only those parts which are required by the kernel.

Well...that's how it should work. Unfortunately there are some parts in
the kernel, which are not really required, like nvmem. This should be
fixed, of course.



More information about the En-Nut-Discussion mailing list