سؤال

I am trying to receive a multicast UDP packet. The packet has a timestamp and some other useless data as well as sensor readings. Is there a way to only receive the last part of the packet, which would be the last 16 bytes out of the total 110 byte message? This would effectively take only the sensor readings and ignore the rest of the UDP package.

هل كانت مفيدة؟

المحلول

If the data you want is at the beginning of the packet, yes, by providing a buffer only large enough to hold the data you want. Otherwise no.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top