External SRAM for Mega2560

The Mega2560 will support external SRAM up to the limit of 16 bit address space (64K)

I have the hardware working and I have verified that it all works using AVR studio.

Now I need to change the link options to tell the Arduino build/link/load environment where all the new memory boundaries are.

for Example: Where the stack Starts, where allocated Variables are loaded. Where the heap starts. Upper Memory limit. Etc.

Where is this done when you 'verify' a sketch?

I can't find the makefile anywhere (Mac 0SX).

Any help appreciated.

Looks like the memory constants for the ATmega2560 are here:

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/avr/include/avr/iom2560.h

Control-Click on the Arduino app and select: Show Package Contents

Hello,

What address latch did you use? I'm interested in doing something similar, but to connect the Wiznet chip... which, can be (somewhat) doubled as a memory device... and still have 32k of address space to use.

The 74AHC373 (and 573) should work. The spec sheet warns against using slower versions.

I'm designing a board with 256k at present and have used that chip, so hopefully it will work :slight_smile:


Rob

Graynomad:
The 74AHC373 (and 573) should work. The spec sheet warns against using slower versions.

I'm designing a board with 256k at present and have used that chip, so hopefully it will work :slight_smile:


Rob

Hmmm, I was looking at the 575...

Can you post your findings around here? I'm really interested in getting the external memory bus on the 2560 to work with that Wiznet chip and if someone already tested the latch (which is where I have most doubts) then, it would be a good step forward.

By the way, I like you website. :wink:

575, I wasn't familiar with it so did a search. It didn't even rate a mention at alldatasheets, but I eventually did find a Chinese data sheet.

However...

a) at 24 pins it's 4 pins bigger than necessary
b) it's an octal D flip flop, the interface needs a transparent latch.

In the "old days" the classic chip for the muxed address/data arrangement was the 74373, in terms of the logic this hasn't changed, but the speeds have. Hence the data sheet specifying an HCT device.

Section 9.1.2 of the data sheet spells it out pretty well.

I've attached a pic of the appropriate part of my schematic, I do stress however that I haven't got this working, just designed it.

By the way, I like you website.

Thanks, it seems fairly popular and keeps me off the streets :slight_smile:


Rob

So far the hardware has been the easy part.

The definitions file is not really useful, need to find the makefile and tell it to load all the bits in the correct place.

Does anyone know where the correct makefile is for the Mega2560 within the Arduino environment? I am using a Mac OSX

I posted a PC makefile a while back and I think someone took it and converted to Mac but I can't find the thread.


Rob

makefile ... I can't find the thread.

http://arduino.cc/forum/index.php/topic,55278.0.html ?
(that's Rob's original makefile, I think. Not the Mac fixup.)

Yep that's it, thanks Westfw.

Maybe Maniacbug can send you his changed version.


Rob