class documentation
Represents a JOG command.
Class Method | unpack |
Unpacks a bytes sequence into a tagJOGCmd object. |
Method | pack |
Packs the tagJOGCmd object into a bytes sequence. |
Class Variable | cmd |
Undocumented |
Class Variable | is |
Undocumented |
Unpacks a bytes sequence into a tagJOGCmd object.
Parameters | |
data:bytes | The bytes to unpack, expected to be 2 bytes (2 uint8s). |
Returns | |
tagJOGCmd | A tagJOGCmd object. |
Raises | |
struct.error | If the input bytes are not the expected size (2 bytes). |
ValueError | If the unpacked byte values do not correspond to valid enum members. |
Packs the tagJOGCmd object into a bytes sequence.
Packs the isJoint (JogMode value) and cmd (JogCmd value) into a byte string. Uses little-endian byte order.
Returns | |
bytes | A bytes object representing the packed data (2 bytes). |