The Due and freemem

The "MemoryFree.h" libery show me 4294966668 of memory?

How show the memory on the Due?

Thanks.

Good question. The library was probably written before the Due was created.

Just another brick in the pile of 'normal' Arduino things that don't work on the Due.

Is the library author contactable? Send them a free Due in the mail and they might be able to solve it.

Hi
I did not remember where I get this piece of code:

#include <Streaming.h>
#include <malloc.h>

extern char _end;
extern "C" char *sbrk(int i);

void freeRam()
{
  char *ramstart = (char *) 0x20070000;
  char *ramend = (char *) 0x20088000;
  char *heapend = sbrk(0);
  register char * stack_ptr asm( "sp" );
  struct mallinfo mi = mallinfo();
  Serial << "Ram used (bytes): " << endl
    << "  dynamic: " << mi.uordblks << endl
    << "  static:  " << &_end - ramstart << endl
    << "  stack:   " << ramend - stack_ptr << endl; 
  Serial << "Estimation free Ram: " << stack_ptr - heapend + mi.fordblks << endl;
}

Works great on Due

He thanks.

this works good!

Thanks, works for me too,

Streaming.h >> Streaming | Arduiniana