public DeviceClient(UdpClient client) { this.client = client; receiveStream = client.ReceiveStream().Publish().RefCount(); }