Implement query command and add memory map.