file size is not a multiple of item size

240 views
Skip to first unread message

Bernard Nicoll

unread,
Oct 13, 2023, 8:27:44 PM10/13/23
to gr-...@googlegroups.com
Hello, newbie here again,

I'm trying to use a 'FILE' as the input source (instead of hardware), but nothing seems to happen either with livemon or scanner, it just stays idle.

I created a 30secs I/Q sample file using a sample rate of 4000 Khz.

I am puzzled with this message:  file_source :warning: file size is not a multiple of item size

hermite@uBuntu:~$ grgsm_scanner --args=file=/media/sf_Downloads/grgsm_869_ddc.ddc,rate=4000 -d -v
Args= file=/media/sf_Downloads/grgsm_869_ddc.ddc,rate=4000
gr-osmosdr 0.2.0.0 (0.2.0) gnuradio 3.10.1.1
built-in source types: file fcd rtl rtl_tcp uhd hackrf bladerf rfspace airspy airspyhf soapy redpitaya freesrp
file_source :warning: file size is not a multiple of item size
WARNING: Overriding original sample rate of 4000 with 2e+06

Any clue?

Thank you.

Vasil Velichkov

unread,
Oct 15, 2023, 9:18:25 AM10/15/23
to Bernard Nicoll, gr-...@googlegroups.com
Hi Bernard,

On 14/10/2023 03.27, Bernard Nicoll wrote:
> I'm trying to use a 'FILE' as the input source (instead of hardware), but
> nothing seems to happen either with livemon or scanner, it just stays idle.

Neither grgsm_livemon nor grgsm_scanner are designed to work with files. Why do you want to use them with files? Use grgsm_decode if you want to work with files.

> I created a 30secs I/Q sample file using a sample rate of 4000 Khz.w
>
> I am puzzled with this message: file_source :warning: file size is not a
> multiple of item size

How did you capture this file? The file size must be exact multiple of 8 because each complex sample is 64 bit long - 32bit float for real and 32bit float for imaginary.

> hermite@uBuntu:~$ grgsm_scanner
> --args=file=/media/sf_Downloads/grgsm_869_ddc.ddc,rate=4000 -d -v
> Args= file=/media/sf_Downloads/grgsm_869_ddc.ddc,rate=4000

Here rate=4000 is not 4000 Khz but 4Khz

> WARNING: Overriding original sample rate of 4000 with 2e+06

See the above warning.

Regards,
Vasil

Bernard Nicoll

unread,
Oct 17, 2023, 8:16:12 AM10/17/23
to gr-gsm
Thanks for all that info.

I'm now following some of Rob VK8FOES demos on GRGSM. Very straightforward.

I finally got grgsm_capture to generate a file but grgsm_decode fails with the following:

$ grgsm_decode -m BCCH -t 0 -c capture.cfile -v -p -f 870.4M -s 1e6 --ppm 1

Traceback (most recent call last):

  File "/usr/local/bin/grgsm_decode", line 389, in <module>

    tb = gsm_decoder(timeslot=options.timeslot, subslot=options.subslot, chan_mode=options.chan_mode,

  File "/usr/local/bin/grgsm_decode", line 121, in __init__

    self.socket_pdu_server = pdu.socket_pdu("UDP_SERVER", "127.0.0.1", "4729", 10000) #added in order to avoid generating ICMP messages

AttributeError: module 'gnuradio.pdu' has no attribute 'socket_pdu'

~$

Running with;

GNU Version: 3.10.1.1-2.

OS: Ubuntu 22.04.3 LTS

Kernel: Linux 6.2.0-34-generic, Architecture: x86-64



Any clue?

Thanks.

Vasil Velichkov

unread,
Oct 18, 2023, 3:48:19 AM10/18/23
to Bernard Nicoll, gr-gsm
Hi Bernard,

On 17/10/2023 15.16, Bernard Nicoll wrote:
> $ grgsm_decode -m BCCH -t 0 -c capture.cfile -v -p -f 870.4M -s 1e6 --ppm 1
>
> File "/usr/local/bin/grgsm_decode", line 121, in __init__
>
> self.socket_pdu_server = pdu.socket_pdu("UDP_SERVER", "127.0.0.1",
> "4729", 10000) #added in order to avoid generating ICMP messages
>
> *AttributeError: module 'gnuradio.pdu' has no attribute 'socket_pdu'*

You need to update your gr-gsm to the latest maint-3.10 branch from bkerler fork. This problem has already been solved in https://github.com/bkerler/gr-gsm/commit/de1d6430

Regards,
Vasil
Reply all
Reply to author
Forward
0 new messages