MEMSTART =?  0x280;
MEMEND   =? 0x1000;
STACKLEN =?  0x100;

MEMORY
{
 zero : org = 0x0 , len = 0x100
 ram : org = MEMSTART, len=MEMEND-MEMSTART-STACKLEN
}

SECTIONS
{
  zpage (NOLOAD) : {*(zpage) *(zp1) *(zp2)} >zero
  text : { *(text) *(rodata) *(.ctors) *(.dtors) } >ram
  data : { *(data) } >ram
  bss (NOLOAD) : { *(bss) } >ram

  __BB = ADDR(bss);
  __BE = ADDR(bss) + SIZEOF(bss);
  __ZS = ADDR(zpage);
  __ZL = SIZEOF(zpage);

  ___heap = MAX(ADDR(data) + SIZEOF(data), ADDR(bss) + SIZEOF(bss)) + SIZEOF(zpage);
  ___heapend = MEMEND-STACKLEN;
  __ZC = ___heap - SIZEOF(zpage);

}

