Set write permission for 'write without response' characteristics.
Fork of nRF51822 by
Diff: nordic/app_common/crc16.cpp
- Revision:
- 65:98215c4f3a25
- Parent:
- 0:eff01767de02
diff -r 5d5f5cbc7c79 -r 98215c4f3a25 nordic/app_common/crc16.cpp --- a/nordic/app_common/crc16.cpp Mon Sep 08 15:45:22 2014 +0000 +++ b/nordic/app_common/crc16.cpp Mon Sep 08 17:21:46 2014 +0100 @@ -20,12 +20,12 @@ for (i = 0; i < size; i++) { - crc = (unsigned char)(crc >> 8) | (crc << 8); + crc = (unsigned char)(crc >> 8) | (crc << 8); crc ^= p_data[i]; crc ^= (unsigned char)(crc & 0xff) >> 4; crc ^= (crc << 8) << 4; crc ^= ((crc & 0xff) << 4) << 1; } - + return crc; }