←back to thread

166 points floren | 1 comments | | HN request time: 0.214s | source
Show context
unwind ◴[] No.45125967[source]
Very interesting! Seems like a Bluetooth-connected display is kind of rare.

This part:

The one thing I’m left scratching my head over is the length field. If I have 0x20 bytes of image data to send over, I actually need to put 0x10 into that field.

Made me think the protocol simply assumes at least 2 bytes will always be used, so it transmits the length using the unit of 16-bit "words" instead of bytes. That would not be unheard of, and is kind of smart even.

replies(2): >>45128492 #>>45162222 #
1. yencabulator ◴[] No.45162222[source]
It's kinda weird since the payload seems to be (repeat:u8 + rgb565:u16)*, so always multiples of three bytes, not two.

Given how this is sort of software is usually written, my guess would be they originally didn't have the RLE encoding and were just sending (rgb565:u16)*. That'd explain it.