basic read function added