Skip to content
Branch: master
Go to file

Latest commit


Failed to load latest commit information.
Latest commit message
Commit time

GRC Bit Converter

GRC Bit Converter ( is a python script for parsing and printing data produced by GNU-Radio Companion's Clock Recovery MM and Binary Slicer blocks. This script takes a file with bits represented as bytes (a 0 represented as 0x00 and a 1 represented as 0x01) and combines them into their intended byte representation. Once combined the script provides several capabilities for packetizing, inverting, shifting, identify Correlated Access Encoded packets, and searching the data.


  • Python BitArray - Version 0.8
    • Ubuntu may try to install a really old version of BitArray. Don't be fooled, it will not work.

    -f <file>:       Input file (required)"
    -p <size>:       Size of the packet (defaults to 250)"
    -s <string>:     Search for a string. This will also supress packet printing."
    -i:              Invert the bits of the byte. This may be necessary if high"
                     actually represents a 0 instead of a 1 and visa versa."
    -c:              Data is coded. Therefore look for 2's and 3's as packet markers."
    -b <number>:     Bypass this number of BITS. NOTE: only used for non-coded parsing."


The following is an example of parsing captured data as outlined in Converting Radio Signals to Data Packets.

cutaway> python ~/InG-Storage/Research/Dev/grc_bit_converter/ -c -p 18 -f blog_demod_1e6_905.99e6_gfsk_76721_lfp_hackrf_coded.dat
Starting Packet Parsing.

New Packet: 0
Size: 17
Occurances: 1
xV4H��� U��;


New Packet: 1
Size: 17
Occurances: 1
xV4H��� V!��▒


New Packet: 2
Size: 17
Occurances: 1
xV4H��� W)��



  • modualize for use in other scripts
  • search for user provided preamble
  • search for user provided SyncWords
  • handle dynamic length bytes for packet printing
  • document code better
  • remove dependancy on bitarray 0.8, if possible


Python script to convert bit bytes output by GNU Radio Companion's Binary Slicer into actual bytes.



No releases published


You can’t perform that action at this time.