diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/fecmodem.cc | 6 | ||||
-rw-r--r-- | src/fecmodem.h | 4 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/fecmodem.cc b/src/fecmodem.cc index 85221dc..a75c27b 100644 --- a/src/fecmodem.cc +++ b/src/fecmodem.cc @@ -58,6 +58,12 @@ uint8_t FECModem::hamming2416(uint8_t *byte1, uint8_t *byte2, uint8_t parity) return 0; } +void FECModem::enable() +{ + this->Modem::enable(); + hammingState = FIRST_BYTE; +} + uint8_t FECModem::buffer_available() { // XXX this reset implementation is _completely_ broken diff --git a/src/fecmodem.h b/src/fecmodem.h index 087aae4..1d8931b 100644 --- a/src/fecmodem.h +++ b/src/fecmodem.h @@ -37,7 +37,9 @@ class FECModem : public Modem { uint8_t correct128(uint8_t *byte, uint8_t parity); uint8_t hamming2416(uint8_t *byte1, uint8_t *byte2, uint8_t parity); public: - FECModem() : Modem() { hammingState = FIRST_BYTE; }; + FECModem() : Modem() {}; + + void enable(void); /** * Checks if there are unprocessed bytes in the receive buffer. |