Error using rx_voice.py

I am working on tx_voice.py and rx_voice.py and I am trying to embed a
fixed sequence in the payload part of my packet. However, when i try to
receive the data using rx_voice, i get an error saying

terminate called after throwing an instance of ‘std::runtime_error’
what(): msg length is not a multiple of d_itemsize
Aborted (core dumped)

I have added only one line in make_packet in packet_utils.py and it
looks like this:(just the important lines as i thought)

def make_packet(payload, samples_per_symbol, bits_per_symbol,
access_code=default_access_code, pad_for_usrp=True):

(packed_access_code, padded) = 

conv_1_0_string_to_packed_binary_string(access_code)
(packed_preamble, ignore) =
conv_1_0_string_to_packed_binary_string(preamble)
payload = packed_preamble + payload
payload_with_crc = gru.gen_and_append_crc32(payload)
pkt = ‘’.join((packed_access_code, make_header(L),
whiten(payload_with_crc), ‘\x55’))

if pad_for_usrp:
    pkt = pkt + (_npadding_bytes(len(pkt), samples_per_symbol, 

bits_per_symbol) * ‘\x55’)

return pkt

Can anyone please explain how to remove this error. I want to add fixed
sequence so that it helps in calculation of BER.

Thanks,
Pratik Hetamsaria

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs