problems launching dabmod with hack rf

513 views
Skip to first unread message

peter allridge

unread,
Sep 30, 2017, 3:43:11 PM9/30/17
to mmbtools
HI people I cant seem to get the hack rf one working on a rpi3 all I seem to get is this error and me and a few others cant figure out what we are doing wrong?? any help would be great please?

pi@raspberrypi:~/dab/ODR-DabMod $ odr-dabmod -C modulator.ini
ODR-DabMod version v1.0.1, compiled at Sep 30 2017, 19:55:52      RC: Waiting for connection on port 2121
Compiled with features: zeromq output_soapysdr
Input
      Starting up version v1.0.1
  Type: tcp
  Source: localhost:9200
Output
 SoapySDR
  Device:
  master_clock_rate: 32768000
  Sampling rate: 2.048 MHz
      OutputSoapy:Creating the device with:
      SoapySDR master clock rate set to 0 kHz
      OutputSoapySDR:Actual TX rate: 0 ksps.
      OutputSoapySDR:Actual frequency: 0 kHz.
      OutputSoapySDR:Actual tx gain: 0
Input TCP:
  Receiving from localhost:9200
      Setting up timestamp decoder with 0 offset
No resampler
      OutputSoapy: dropping one frame with invalid FCT
      OutputSoapy: dropping one frame with invalid FCT
ERROR Unexpected stream error NOT_SUPPORTED
WARN  SoapySDR worker terminated

Process time:
                    DabModulator:     220657 us (98.90 %)
                     OutputSoapy:       2455 us (1.10 %)
                           total:     223112 us (100.00 %)
Process time:
                   PrbsGenerator:       1652 us (1.03 %)
                       FicSource:         19 us (0.01 %)
                   PrbsGenerator:        104 us (0.06 %)
                     ConvEncoder:        201 us (0.13 %)
               PuncturingEncoder:        217 us (0.14 %)
                SubchannelSource:         19 us (0.01 %)
                   PrbsGenerator:        205 us (0.13 %)
                     ConvEncoder:        701 us (0.44 %)
               PuncturingEncoder:        947 us (0.59 %)
                 TimeInterleaver:       1541 us (0.96 %)
                SubchannelSource:         22 us (0.01 %)
                   PrbsGenerator:        187 us (0.12 %)
                     ConvEncoder:        719 us (0.45 %)
               PuncturingEncoder:        740 us (0.46 %)
                 TimeInterleaver:       1475 us (0.92 %)
                FrameMultiplexer:        147 us (0.09 %)
                BlockPartitioner:         84 us (0.05 %)
                QpskSymbolMapper:       2083 us (1.30 %)
            FrequencyInterleaver:       2530 us (1.58 %)
                  PhaseReference:         68 us (0.04 %)
           DifferentialModulator:       4666 us (2.90 %)
                      NullSymbol:         86 us (0.05 %)
                  PhaseReference:         41 us (0.03 %)
  TII(comb:16, pattern:3, variant:new):         28 us (0.02 %)
               SignalMultiplexer:       1501 us (0.93 %)
                   OfdmGenerator:      14880 us (9.26 %)
                     GainControl:       5669 us (3.53 %)
           GuardIntervalInserter:       2783 us (1.73 %)
                       FIRFilter:     114732 us (71.43 %)
                    OutputMemory:       2584 us (1.61 %)
                           total:     160631 us (100.00 %)
ERROR OutputSoapy: worker thread died
ERROR Exception caught: Fault in OutputSoapy
ERROR Modulator failure.
      4 DAB frames encoded
      0.096 seconds encoded
      Terminating
      RC: Leaving
pi@raspberrypi:~/dab/ODR-DabMod $

as you can see I get this same error no matter what we do?

thanks pete

Rashid Mustapha

unread,
Sep 30, 2017, 4:15:01 PM9/30/17
to crc-mm...@googlegroups.com
Sorry to have to be the bearer of bad news. Although this isn't your problem (which looks like soapy is trying to talk to something other than HackRF) I believe it won't be possible for that configuration to work. At the native sampling rate, the filters in HackRF will no suppress close-in images at +/- 2.048 MHz, so you'll never get the C/N to where a receiver will work. 

Take a look at the manual on Github where I explain why oversampling is necessary with HackRF. The Pi is not capable of the resampling needed. Sorry. :(

Best regards,

Rash.


--
You received this message because you are subscribed to the Google Groups "mmbtools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to crc-mmbtools+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


peter allridge

unread,
Sep 30, 2017, 4:24:19 PM9/30/17
to mmbtools
thanks you rash I do have an amd pc here i do want to use that so will get onto that instead..

On Saturday, 30 September 2017 21:15:01 UTC+1, Rash wrote:
Sorry to have to be the bearer of bad news. Although this isn't your problem (which looks like soapy is trying to talk to something other than HackRF) I believe it won't be possible for that configuration to work. At the native sampling rate, the filters in HackRF will no suppress close-in images at +/- 2.048 MHz, so you'll never get the C/N to where a receiver will work. 

Take a look at the manual on Github where I explain why oversampling is necessary with HackRF. The Pi is not capable of the resampling needed. Sorry. :(

Best regards,

Rash.

On 30 Sep 2017 20:43, "peter allridge" <pall...@gmail.com> wrote:
HI people I cant seem to get the hack rf one working on a rpi3 all I seem to get is this error and me and a few others cant figure out what we are doing wrong?? any help would be great please?

p...@raspberrypi:~/dab/ODR-DabMod $ odr-dabmod -C modulator.ini

as you can see I get this same error no matter what we do?

thanks pete

--
You received this message because you are subscribed to the Google Groups "mmbtools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to crc-mmbtools...@googlegroups.com.

peter allridge

unread,
Sep 30, 2017, 4:49:54 PM9/30/17
to mmbtools
one more question is this why it will not communicate with the hack? i would of thought i could of done that at least i just need a workin testbed nothing else so i can get use to the software etc etc.

pete



Rashid Mustapha

unread,
Sep 30, 2017, 5:19:53 PM9/30/17
to crc-mm...@googlegroups.com
Hi Pete,

No, I don't think soapysdr knows that it is talking to a HackRF, so you'll need to check your config and maybe check the HackRF firmware is the right version for soapy.

R.



On 30 Sep 2017 21:49, "peter allridge" <pall...@gmail.com> wrote:
one more question is this why it will not communicate with the hack? i would of thought i could of done that at least i just need a workin testbed nothing else so i can get use to the software etc etc.

pete



mike....@gmail.com

unread,
Oct 1, 2017, 2:33:06 PM10/1/17
to mmbtools
Hi Pete - Section 5.2.2 of the MMB-TOOLS PDF file gives the clue as to how to use a HackRF One using a FIFO file method of transfer and the compiling rule you have to add prior to installing ODR-DabMod. I am not using Soapy and my tests have shown that the modulator is indeed very resource hungry and even a dual-core processor cannot drive the HackRF faster than 4096ksps. I have upgraded to a quad core processor  PC and this can go upto 8192ksps into the HackRF giving a better output spectrum. I am using a second dual core PC to produce the MUX data sent via ZMQ link. Another tip, make sure that the network link has a consistent speed between MUX and MOD.
Mike Davison

On Saturday, September 30, 2017 at 8:43:11 PM UTC+1, peter allridge wrote:
HI people I cant seem to get the hack rf one working on a rpi3 all I seem to get is this error and me and a few others cant figure out what we are doing wrong?? any help would be great please?

p...@raspberrypi:~/dab/ODR-DabMod $ odr-dabmod -C modulator.ini

peter allridge

unread,
Oct 1, 2017, 5:26:57 PM10/1/17
to mmbtools
Hi Mike thanks for the reply i don't know why soapy wont communicate with the hack but im goin to get it working first before i move over to a pc for further tests and so on i will try the file method later see if i get any further i just need it to communicate for now then upgrade the hardware from a pi to this pc i have its quad core so should be fine for what i need.. nice 1 for the info every little helps out as i go along, and yes im a newbie to Linux so don't shoot me yet haha

Thanks pete


On Sunday, 1 October 2017 19:33:06 UTC+1, mike....@gmail.com wrote:

mike....@gmail.com

unread,
Oct 2, 2017, 4:25:39 AM10/2/17
to mmbtools
Hi Pete - I'm no Linux expert either. My complaint with the Linux scene is that I liken it to having the first rung of the learning ladder missing as everyone in the project thinks that you're immediately conversant with the terminology and their usage and meanings. You just have to bite the bullet and try and interpret things as you get more familiar with them.
Mike D.

Matthias Brändli

unread,
Oct 3, 2017, 8:58:39 AM10/3/17
to crc-mm...@googlegroups.com
Hi Mike,

I don't believe your complaint is in any way more directed towards ODR
than any other project which happens to be based on Linux, and I
understand it can be frustrating at times.

I'm afraid that we have to assume users have found the first step of the
linux ladder by themselves, just as we assume people bring some
knowledge about DAB in general, because we don't have time to prepare
these ladder steps.

So yes, "bite the bullet", get a good book/tutorial about Linux, and I
hope you'll see it as an investment that can also pay off in a different
situation!

mpb

PS:
Pete, regarding the SoapySDR issues: you can first check using
"SoapySDRUtil --check" if the HackRF driver is available, and then
"SoapySDRUtil --make" to verify it Soapy can setup and access your
HackRF. Try ODR-DabMod only once both these checks work!
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com
> <mailto:crc-mmbtools...@googlegroups.com>.

peter allridge

unread,
Oct 3, 2017, 2:50:07 PM10/3/17
to mmbtools
Hi Matthias i have gotten the hack to work the fifo way but i cant seem to receive anything as yet im not sure why it's probably something ive set wrong but im on the right tracks now im sure. The fifo file seems to be accepting data now and the hack isn't disconnecting anymore all seems to run fine just cant pick ant stations up..

As for Soapysdr i could not get the drivers installed at all for it so i started again and have gotten this far no errors but no audio as yet just a signal with what looks to be quite clean shoulders..

Thanks Pete

mike....@gmail.com

unread,
Oct 3, 2017, 4:30:16 PM10/3/17
to mmbtools
Yes it was a general comment and not directed at the ODR project. I think the PDF is, in general, very good. I followed it quite closely to produce from audio files, the 2 programme ETI file which was read by Dablin very well. I then expanded it to 4 programmes successfully and then to drive the HackRF successfully. I have dabbled with Linux since Suse 5.something that was free on a magazine eventually successfully using it on 2m 1200baud AX25 into a Baycom modem. I had downloaded the CRC CD some years ago but did not find it as straightforward to follow as the subsequent work you and others have done for which we should all be grateful. I hope that my success with the HackRF One and processor requirements is not a blind alley and adds something to the project.
Mike D.

peter allridge

unread,
Oct 3, 2017, 5:44:18 PM10/3/17
to mmbtools
Hi all got it working but only when i come away from the hack with a sdr dongle i start to pick it up obviously this is a config issue but i tried the settings that is suppose to give the best results and it made it worse where i could hardly pick it up so turned off digital gain and that is a lot better? pass i don't know a dab signal at all so any help please?

Thanks Pete

Matthias Brändli

unread,
Oct 4, 2017, 4:24:55 AM10/4/17
to crc-mm...@googlegroups.com
Hi Peter,

I have trouble understanding you. Please make shorter sentences.

When you describe an issue, it is very important that you tell us what
your setup is like. From your email I don't understand what settings you
tried. Be as explicit as possible.

Cheers
mpb
> > <mailto:crc-mmbtools...@googlegroups.com>.
> > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com
> <mailto:crc-mmbtools...@googlegroups.com>.

Matthias Brändli

unread,
Oct 4, 2017, 4:31:55 AM10/4/17
to crc-mm...@googlegroups.com
Hi Mike,

glad the guide was helpful! Maybe it would be useful to add a chapter
describing the processing demands. It is obvious to me that the
multiplexer uses less resources than an audio encoder or the modulator,
but that's not obvious for someone who just started using the tools.
That could be part of the introduction.

1200 baud AX.25, haven't heard that in a while :-) My grandfather was
using the Packet Radio network a lot in its heyday! I did once exchange
a few messages with a fellow ham in northern germany.

73 DE HB9EGM

mpb
> > an email to crc-mmbtools...@googlegroups.com <javascript:>
> > <mailto:crc-mmbtools...@googlegroups.com <javascript:>>.
> > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com
> <mailto:crc-mmbtools...@googlegroups.com>.

peter allridge

unread,
Oct 4, 2017, 6:29:09 AM10/4/17
to mmbtools
Sorry im terrible the stations ive setup run fine but the audio skips about randomly and it gets worse when I try apply any digital gain so I have turned it off for now as I don't understand why it makes it worse at the settings it says will be best which is 2.4 digital gain at a sample rate of 4096000 gainmode=2 firfilter=1 and format=s8

hackrf_transfer -t /tmp/ofdm.fifo -f 206352000 -x 47 \ -a 1 -s 4096000 -b 1750000

im just changing settings and getting nowhere atm

Pete
>         > <mailto:crc-mmbtools+unsub...@googlegroups.com>.
>         > For more options, visit https://groups.google.com/d/optout
>         <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com

peter allridge

unread,
Oct 4, 2017, 7:33:32 AM10/4/17
to mmbtools
Sorry guys its fixed I changed to another usb port and all is now perfect for a test signal which is what I need from the hack only :)

Thanks guys much appreciated.

Pete


On Wednesday, 4 October 2017 11:29:09 UTC+1, peter allridge wrote:

mike....@gmail.com

unread,
Oct 4, 2017, 7:08:51 PM10/4/17
to mmbtools
Hi Matthias - if I were to have one item that puzzles me about ODR-PadEnc and ODR-AudioEnc, the former has a default of 58bytes pad length but the latter has no default and it must be specified otherwise no DLS text appears. Why have a default in one case but not in the other?
Mike G1SBN.
>     > <mailto:crc-mmbtools+unsub...@googlegroups.com <javascript:>>.
>     > For more options, visit https://groups.google.com/d/optout
>     <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com

Matthias Brändli

unread,
Oct 5, 2017, 7:58:34 AM10/5/17
to crc-mm...@googlegroups.com
Hi Mike,

Yes, maybe a bit unfortunate, and I don't think it wasn't explicitly
designed to be like this.

The option -p in ODR-AudioEnc not only sets the PAD length, but also
enables insertion. That's why it's default is implicitly 0. The -P
option has a default.

If I change the default for -p to 58, I need to have another way to say
"enable PAD". A new option breaks backward compatibility. Removing the
default for -P breaks backward compatibility. Having "Specify either -p
or -P to enable PAD insertion" could work, but would be awkward to
explain. (Imagine the question from the user: "If both options have a
non-empty default, why do I have to set one of them to enable PAD?")

To clarify this, I've very slightly changed the description of -p in the
usage screen.

mpb

On 05/10/17 01:08, mike....@gmail.com wrote:
> Hi Matthias - if I were to have one item that puzzles me about
> ODR-PadEnc and ODR-AudioEnc, the former has a default of 58bytes pad
> length but the latter has no default and it must be specified otherwise
> no DLS text appears. Why have a default in one case but not in the other?
> Mike G1SBN.
>
> On Wednesday, October 4, 2017 at 9:31:55 AM UTC+1, Matthias Brändli wrote:
>
> Hi Mike,
>
> glad the guide was helpful! Maybe it would be useful to add a chapter
> describing the processing demands. It is obvious to me that the
> multiplexer uses less resources than an audio encoder or the modulator,
> but that's not obvious for someone who just started using the tools.
> That could be part of the introduction.
>
> 1200 baud AX.25, haven't heard that in a while :-) My grandfather was
> using the Packet Radio network a lot in its heyday! I did once exchange
> a few messages with a fellow ham in northern germany.
>
> 73 DE HB9EGM
>
> mpb
>
> >     > <mailto:crc-mmbtools...@googlegroups.com
> <javascript:> <javascript:>>.
> >     > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>
> >     <https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>>.
> >
> > --
> > You received this message because you are subscribed to the Google
> > Groups "mmbtools" group.
> > To unsubscribe from this group and stop receiving emails from it,
> send
> > an email to crc-mmbtools...@googlegroups.com <javascript:>
> > <mailto:crc-mmbtools...@googlegroups.com <javascript:>>.
> > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com
> <mailto:crc-mmbtools...@googlegroups.com>.

mike....@gmail.com

unread,
Oct 5, 2017, 8:33:08 AM10/5/17
to mmbtools
I've posed the same point in my own thread about resources but your explanation here is understandable and as you say, needing only a trimming of the usage explanation.Case closed.
MD.
>     >     > <mailto:crc-mmbtools+unsub...@googlegroups.com
>     <javascript:> <javascript:>>.
>     >     > For more options, visit https://groups.google.com/d/optout
>     <https://groups.google.com/d/optout>
>     >     <https://groups.google.com/d/optout
>     <https://groups.google.com/d/optout>>.
>     >
>     > --
>     > You received this message because you are subscribed to the Google
>     > Groups "mmbtools" group.
>     > To unsubscribe from this group and stop receiving emails from it,
>     send
>     > an email to crc-mmbtools...@googlegroups.com <javascript:>
>     > <mailto:crc-mmbtools+unsub...@googlegroups.com <javascript:>>.
>     > For more options, visit https://groups.google.com/d/optout
>     <https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "mmbtools" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to crc-mmbtools...@googlegroups.com

mike....@gmail.com

unread,
Mar 12, 2019, 11:33:41 AM3/12/19
to mmbtools
I don't seem to be able to find the correct syntax to enable the bandwidth filter of the HackRF One through Soapy. I've just been checking the spectrum on the Rigol and it's horrible. Using my original script but setting the filter too high proves the point.
MD


Rashid Mustapha

unread,
Mar 12, 2019, 6:28:37 PM3/12/19
to crc-mm...@googlegroups.com
Hi Mike.

I can well imagine that the registers for the on-chip monolithic filters is not passed through. You obviously need to call the lowest passband (1.7 MHz) and use a stackload of oversampling to push the images way into the stop-band.

Don't be surprised if this doesn't get supported as HackRF really is an afterthought for developers. It isn't a viable radio in any real world use case scenario. 

Realistically, any serious operator would really want (need?) at least their phase reference symbol to be aligned with other multiplexes to aid tuning, and that implies a PPS at least. If the PPS is there, it isn't too far away from a GPSDO.

Moving to that would also likely cure your sampling rate mismatches in one hit.

R.







On Tue, 12 Mar 2019, 15:33 , <mike....@gmail.com> wrote:
I don't seem to be able to find the correct syntax to enable the bandwidth filter of the HackRF One through Soapy. I've just been checking the spectrum on the Rigol and it's horrible. Using my original script but setting the filter too high proves the point.
MD


--
You received this message because you are subscribed to the Google Groups "mmbtools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to crc-mmbtools...@googlegroups.com.

Rashid Mustapha

unread,
Mar 12, 2019, 6:50:24 PM3/12/19
to crc-mm...@googlegroups.com
Quick and dirty is to patch libhackrf to call that filter as default and recompile. ;)
Reply all
Reply to author
Forward
0 new messages