1

I'm setting up a new nodejs udp server, and want to send only one bit of data to another udp client.

But I find that the smallest size of Buffer is one Byte which contains 8 bits.

Is there any way to send only one bit of data in nodejs?

刘腾辉
  • 11
  • 2
  • 1
    The smallest _payload_ is, IIRC, zero bytes (with one byte being the next smallest). The smallest _transmission_ is... 28 bytes? (20 for IPv4 envelope, 8 for UDP envelope; add 28 more bytes if IPv6) And that is without the link layer... Unless you're Google, or making an MMO, you probably don't need to worry about it. – Amadan May 13 '19 at 03:38

0 Answers0