| 73 | } |
| 74 | |
| 75 | static int encode_data_gcr(uint8_t data) |
| 76 | { |
| 77 | switch (data & 0x0f) |
| 78 | { |
| 79 | #define GCR_ENTRY(gcr, data) \ |
| 80 | case data: \ |
| 81 | return gcr; |
| 82 | #include "data_gcr.h" |
| 83 | #undef GCR_ENTRY |
| 84 | } |
| 85 | return -1; |
| 86 | } |
| 87 | |
| 88 | static void write_byte(std::vector<bool>& bits, unsigned& cursor, uint8_t b) |
| 89 | { |