Using FRDM Board to output data and a clock for communications example.

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
askksa12543
Date:
Thu Apr 30 14:05:24 2015 +0000
Parent:
10:90cc064f7082
Commit message:
crc fixed

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Wed Apr 29 19:35:32 2015 +0000
+++ b/main.cpp	Thu Apr 30 14:05:24 2015 +0000
@@ -149,7 +149,7 @@
     temp = crc_bytes / j;
     temp ^= CRC;
     //decrement j
-    j--;
+    j /= 2;
     
     //crc loop - shift in each bit position and xor with CRC constant
     while(j>0)
@@ -161,7 +161,7 @@
         //xor with crc constant
         temp ^= CRC;
         //decrement j
-        j--;        
+        j /= 2;        
     }
     
     //mask out 4 msb bits and return just the 4 bit CRC remainder
--- a/mbed.bld	Wed Apr 29 19:35:32 2015 +0000
+++ b/mbed.bld	Thu Apr 30 14:05:24 2015 +0000
@@ -1,1 +1,1 @@
-http://mbed.org/users/mbed_official/code/mbed/builds/433970e64889
\ No newline at end of file
+http://mbed.org/users/mbed_official/code/mbed/builds/8ab26030e058
\ No newline at end of file