merged -r5966:6112 on trondeau/ofdm_mod. Allows for generic constellations (supports...
[debian/gnuradio] / gnuradio-core / src / python / gnuradio / gruimpl / crc.py
index ad8ce887937feb7820cf370a1eeefb303e42c2a8..d31aca0ea7c26ec6327379633872da7ac34d301c 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright 2005 Free Software Foundation, Inc.
+# Copyright 2005,2007 Free Software Foundation, Inc.
 # 
 # This file is part of GNU Radio
 # 
@@ -25,7 +25,7 @@ import struct
 
 def gen_and_append_crc32(s):
     crc = gr.crc32(s)
-    return s + struct.pack(">I", hexint(crc))
+    return s + struct.pack(">I", hexint(crc) & 0xFFFFFFFF)
 
 def check_crc32(s):
     if len(s) < 4: