![]() |
Midnight Sun Firmware
|
Public Member Functions | |
| __init__ (self, **kwargs) | |
| pack (self) | |
| datagram_type_id (self) | |
| node_ids (self) | |
| data (self) | |
| datagram_type_id (self, value) | |
| node_ids (self, nodes) | |
| data (self, value) | |
Protected Member Functions | |
| _unpack (cls, datagram_bytearray, arbitration_id) | |
| _unpack_nodeids (self, raw_nodes) | |
| _pack_nodeids (self, raw_nodes) | |
Static Protected Member Functions | |
| _check_kwargs (**kwargs) | |
| _convert_from_bytearray (in_bytearray, size) | |
| _convert_to_bytearray (in_value, size) | |
Protected Attributes | |
| _datagram_type_id | |
| _node_ids | |
| _data | |
Custom CAN-datagram class
| __init__ | ( | self, | |
| ** | kwargs | ||
| ) |
Initialize datagram class
|
staticprotected |
This function checks that all args passed in are correct
|
staticprotected |
Helper function to get little endian value from byte array
|
staticprotected |
Helper function to get a little endian byte array from a value
|
protected |
This function takes in an ordered list and outputs a bytearray of node ids
|
protected |
This function returns an instance fo the class by unpacking a bytearray
|
protected |
This function takes in the raw bytearray of node ids and returns an ordered list
| data | ( | self | ) |
This function describe the datagram node ids
| data | ( | self, | |
| value | |||
| ) |
This function sets the datagram data
| datagram_type_id | ( | self | ) |
This function describes the datagram id
| datagram_type_id | ( | self, | |
| value | |||
| ) |
This function sets the datagram type
| node_ids | ( | self | ) |
This function assigns the datagram id
| node_ids | ( | self, | |
| nodes | |||
| ) |
This function sets the datagram node ids
| pack | ( | self | ) |
This function packs a new bytearray based on set data