Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bitcraze/crazyflie-lib-python
/ compute_cksum
Function
compute_cksum
cflib/crtp/serialdriver.py:58–63 ·
view source on GitHub ↗
(list)
Source
from the content-addressed store, hash-verified
56
57
58
def
compute_cksum(list):
59
cksum0, cksum1 = 0, 0
60
for
i in range(len(list)):
61
cksum0 = (cksum0 + list[i]) & 0xff
62
cksum1 = (cksum1 + cksum0) & 0xff
63
return
bytearray([cksum0, cksum1])
64
65
66
class
SerialDriver(CRTPDriver):
Callers
2
run
Method · 0.85
run
Method · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected