added function get_memory_data()