From: Benjamin Braatz Date: Tue, 30 Mar 2021 14:11:38 +0000 (+0200) Subject: Small docstring fix. X-Git-Url: http://git.graph-it.com/?a=commitdiff_plain;h=070e371490292a91925b23d001313ea14a1c4d15;p=graphit%2Fcontrolpi-modbus.git Small docstring fix. --- diff --git a/controlpi_plugins/modbus.py b/controlpi_plugins/modbus.py index ed8d867..2eab95b 100644 --- a/controlpi_plugins/modbus.py +++ b/controlpi_plugins/modbus.py @@ -16,7 +16,7 @@ def crc_slow(message: bytes) -> bytes: the given message and this CRC is returned as two bytes (low byte first). - (This is the slow version without precomputed table.) + (This is the "slow" version without precomputed table.) >>> crc_slow(bytes([0x08, 0x01, 0x00, 0x06, 0x00, 0x06])).hex() '5c90' @@ -68,6 +68,8 @@ def crc(message: bytes) -> bytes: the given message and this CRC is returned as two bytes (low byte first). + (This is the "fast" version with precomputed table.) + >>> crc(bytes([0x08, 0x01, 0x00, 0x06, 0x00, 0x06])).hex() '5c90' >>> crc(bytes([0x08, 0x01, 0x01, 0x17])).hex()