Add error feedback to pcd()