Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F102606284
packet.c
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, Feb 22, 11:12
Size
274 B
Mime Type
text/x-c
Expires
Mon, Feb 24, 11:12 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
24370065
Attached To
R6616 sbcp-uc
packet.c
View Options
#include <sbcp-uc/packet.h>
uint8_t
sbcp_compute_packet_cs
(
volatile
unsigned
int
*
buffer
){
uint16_t
psize
=
buffer
[
SBCP_PAYLOAD_SIZE_POS
]
&
0xff
;
uint16_t
i
;
uint8_t
cs
=
0
;
for
(
i
=
1
;
i
<
SBCP_HEADER_SIZE
+
psize
-
1
;
++
i
){
cs
+=
buffer
[
i
];
}
return
cs
;
}
Event Timeline
Log In to Comment