Skip to content
Snippets Groups Projects
Commit af0c25ad authored by Max Horn's avatar Max Horn
Browse files

Refactor the send code

Previously, sending worked by decoding a string which encoded
a binary or tristate codeword. Trying to send a bit pattern directly
(encoded as an integer) involved turning it into a string first.

This is a waste of memory and CPU cycles. So we do it the other way
around now: The central send() function accepts an integer containing
the bit pattern to be sent. The other send() function which takes
a 0-1-string, as well as sendTriState(), now call this new central
send() function. Incidentally, this reduces code duplication and enables
further refactoring.
parent 90d00c1c
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment