simple buffer read/write implemented