added memory info
Several additions / bug fixes