module documentation
Token stream decoder
Function | decode |
Decodes a byte stream into a list of Token objects and its minimum supported OS version |
Function | invalid |
Undocumented |
def decode(bytestream:
bytes
, *, tokens: Tokens
= None) -> tuple[ list[ Token], OsVersion]
:
(source)
¶
Decodes a byte stream into a list of Token
objects and its minimum supported OS version
- Each token is represented using one of three different representations formats, dictated by mode:
- display: Represents the tokens with Unicode characters matching the calculator's display
- accessible: Represents the tokens with ASCII-only equivalents, often requiring multi-character glyphs
- ti_ascii: Represents the tokens with their internal font indices (returns a bytes object)
Parameters | |
bytestream:bytes | The token bytes to decode |
tokens:Tokens | The Tokens object to use for decoding (defaults to the TI-84+CE tokens) |
Returns | |
tuple[ | A tuple of a list of Token objects and a minimum OsVersion |