[En-Nut-Discussion] SRAM + Ethernut 1.3

Harald Kipp harald.kipp at egnite.de
Mon Nov 27 17:42:58 CET 2006


The initialization is done in
arch/avr/os/nutinit.c

For the ATmega128:

     MCUCR = _BV(SRE) | _BV(SRW10);

Thus, 1 wait state by default.

If you add

HWDEF += -DNUT_3WAITSTATES

to UserConf.mk in the build directory, the following
additionally applies (after rebuilding):

/* Configure two sectors, lower sector = 0x1100 - 0x7FFF,
  * Upper sector = 0x8000 - 0xFFFF and run 3 wait states for the
  * upper sector (NIC), 1 wait state for lower sector (XRAM).
  */
#ifdef NUT_3WAITSTATES
     XMCRA |= _BV(SRL2) | _BV(SRW00) | _BV(SRW11); /* SRW10 is set in MCUCR */
     XMCRB = 0;
#endif

Harald

At 17:12 27.11.2006 +0100, you wrote:
>Hi,
>when I use the ethernut 1.3, what timing from the atmega datasheet p.27-29 
>for the extern latch and the extern SRAM is the ethernut using by default?
>
>Thanks, Daniela




More information about the En-Nut-Discussion mailing list