|
uC chip interface arduino
0.9.0
A interface for async and neuromrphic IC testing
|
Packet class to be used as a base class for all packets acting as an interface. More...

Public Member Functions | |
| def | __init__ (self) |
| def | check_and_log (self) |
| check_and_log logs the packet if the header is in the logging lists More... | |
| def | from_bytearray (cls, byte_array) |
| method to construct a packet from a bytearray depending on the header the correct packet type is returned More... | |
| def | header (self) |
| getter method for the header attribute More... | |
| def | set_exec_time (self, time) |
| setter method for the execution time attribute More... | |
| def | set_header (self, header) |
| setter method for the header attribute More... | |
| def | time (self) |
| getter method for the time attribute More... | |
| def | to_bytearray (self) |
| placeholder for converting the package to a bytearray More... | |
Packet class to be used as a base class for all packets acting as an interface.
it contains the static method from_bytearray to construct a packet from a bytearray and chooses the correct packet type depending on the header
| def __init__ | ( | self | ) |
Reimplemented in ConfigPacket, DataI2CPacket, ErrorPacket, PinPacket, and Data32bitPacket.
| def check_and_log | ( | self | ) |
| def from_bytearray | ( | cls, | |
| byte_array | |||
| ) |
method to construct a packet from a bytearray depending on the header the correct packet type is returned
| byte_array | (bytearray) the bytearray to construct the packet from |
Reimplemented in Data32bitPacket, DataI2CPacket, PinPacket, ConfigPacket, and ErrorPacket.
| def header | ( | self | ) |
| def set_exec_time | ( | self, | |
| time | |||
| ) |
| def set_header | ( | self, | |
| header | |||
| ) |
setter method for the header attribute
| header | (byte/uint_8) the header of the packet |
Reimplemented in Data32bitPacket, DataI2CPacket, PinPacket, ConfigPacket, and ErrorPacket.
| def time | ( | self | ) |
| def to_bytearray | ( | self | ) |
placeholder for converting the package to a bytearray
Reimplemented in Data32bitPacket, DataI2CPacket, PinPacket, ConfigPacket, and ErrorPacket.