added ram locations to header, initialize stack in app template