Chaostreff-Potsdam / erika3004

19 stars 5 forks source link

"Binärika": byte level Erika mock #76

Open ArchibaldBienetre opened 4 years ago

ArchibaldBienetre commented 4 years ago

With the current AbstractErikaMock + subclasses, we had issues in the past that the mock interface and the real interface would drift apart.

As a mitigation, we added ugly meta code to the constructors... This does not feel right / not feel python-y.
Instead, there's one level of abstraction where we cannot drift apart, that's the actual bytes as understood by the Erika device.

The BinErika implementation should

ArchibaldBienetre commented 4 years ago

Implementation can happen in small steps

cyroxx commented 4 years ago

Parts of what you are trying to achieve here could be tackled by (re-)implementing the DDR-ASCII codec on top of the Python codecs framework: https://docs.python.org/3/library/codecs.html When we include support for (custom) ANSI escape sequences, we could "translate" all supported characters and control codes the Erika has. Other thoughts: