implement write for DcapChannel