update data transfer function