robotastic / trunk-recorder

Records calls from a Trunked Radio System (P25 & SmartNet)
GNU General Public License v3.0
865 stars 194 forks source link

Why?? Unable to setup a System to record, exiting... #416

Closed mathisono closed 3 years ago

mathisono commented 3 years ago

Could someone shed some light on why im getting : (error) Unable to setup a System to record, exiting...

increasing the debug level doesn't show any thing...

./recorder --config=config_SF_metro_hackrf.json
linux; GNU C++ version 7.3.0; Boost_106501; UHD_003.010.003.000-0-unknown

[2020-10-21 00:37:12.773847] (info)   Using Config file: config_SF_metro_hackrf.json

[2020-10-21 00:37:12.774102] (info)   
-------------------------------------
     Trunk Recorder
-------------------------------------

[2020-10-21 00:37:12.774117] (info)   
-------------------------------------
SYSTEMS
-------------------------------------

[2020-10-21 00:37:12.774136] (info)   

System Number: 1
-------------------------------------

[2020-10-21 00:37:12.774147] (info)   Short Name: bpd.csv
[2020-10-21 00:37:12.774155] (info)   System Type: p25
[2020-10-21 00:37:12.774162] (info)   Control Channels: 
[2020-10-21 00:37:12.774176] (info)     7.742188e+02
[2020-10-21 00:37:12.774218] (error)   ! System Modulation Not Specified, could be fsk4 or qpsk, assuming qpsk
[2020-10-21 00:37:12.774227] (info)   Analog Recorder Maximum Deviation: 4000
[2020-10-21 00:37:12.774235] (info)   Filter Width: 1
[2020-10-21 00:37:12.774245] (info)   Squelch: -160
[2020-10-21 00:37:12.774254] (info)   API Key: 
[2020-10-21 00:37:12.774262] (info)   Broadcastify API Key: 
[2020-10-21 00:37:12.774270] (info)   Broadcastify Calls System ID: 0
[2020-10-21 00:37:12.774277] (info)   Upload Script: 
[2020-10-21 00:37:12.774284] (info)   Call Log: true
[2020-10-21 00:37:12.774293] (info)   Audio Archive: true
[2020-10-21 00:37:12.774301] (info)   Loading Talkgroups...
[2020-10-21 00:37:12.774361] (error)   Warning: skipped 1 of 12 talkgroup entries! Invalid format?
[2020-10-21 00:37:12.774372] (error)   The format is very particular. See https://github.com/robotastic/trunk-recorder for example input.
[2020-10-21 00:37:12.774386] (info)   Talkgroups File: bpd.csv
[2020-10-21 00:37:12.774394] (info)   Loading Unit Tags...
[2020-10-21 00:37:12.774402] (info)   Unit Tags File: 
[2020-10-21 00:37:12.774411] (info)   Record Unknown Talkgroups: true
[2020-10-21 00:37:12.774420] (info)   Decode MDC: false
[2020-10-21 00:37:12.774427] (info)   Decode FSync: false
[2020-10-21 00:37:12.774436] (info)   Decode Star: false
[2020-10-21 00:37:12.774444] (info)   Decode TPS: false
[2020-10-21 00:37:12.774453] (info)   Talkgroup Display Format: Id
[2020-10-21 00:37:12.774463] (info)   Hide Encrypted Talkgroups: false
[2020-10-21 00:37:12.774471] (info)   Hide Unknown Talkgroups: false
[2020-10-21 00:37:12.774479] (info)   Minimum Call Duration (in seconds): 0
[2020-10-21 00:37:12.774490] (info)   
[2020-10-21 00:37:12.774497] (info)   

-------------------------------------
SOURCES
-------------------------------------

[2020-10-21 00:37:12.774522] (info)   Driver: osmosdr
[2020-10-21 00:37:12.774531] (info)   Center: 7.721700e+06
[2020-10-21 00:37:12.774547] (info)   Rate: 6000000
[2020-10-21 00:37:12.774563] (info)   Error: 0
[2020-10-21 00:37:12.774572] (info)   PPM Error: 53
[2020-10-21 00:37:12.774584] (info)   Auto gain control: false
[2020-10-21 00:37:12.774593] (info)   Gain: 0
[2020-10-21 00:37:12.774602] (info)   IF Gain: 32
[2020-10-21 00:37:12.774614] (info)   BB Gain: 40
[2020-10-21 00:37:12.774625] (info)   LNA Gain: 0
[2020-10-21 00:37:12.774635] (info)   PGA Gain: 0
[2020-10-21 00:37:12.774643] (info)   TIA Gain: 0
[2020-10-21 00:37:12.774652] (info)   MIX Gain: 0
[2020-10-21 00:37:12.774661] (info)   VGA1 Gain: 0
[2020-10-21 00:37:12.774670] (info)   VGA2 Gain: 0
[2020-10-21 00:37:12.774679] (info)   Idle Silence: false
[2020-10-21 00:37:12.774687] (info)   Digital Recorders: 5
[2020-10-21 00:37:12.774697] (info)   Debug Recorder: false
[2020-10-21 00:37:12.774705] (info)   SigMF Recorders: 0
[2020-10-21 00:37:12.774712] (info)   Analog Recorders: 1
[2020-10-21 00:37:12.774724] (info)   Source Device: hackrf=4f4397
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.11
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy airspyhf soapy redpitaya freesrp 
Using HackRF One with firmware 2018.01.1 
[2020-10-21 00:37:12.785233] (info)   SOURCE TYPE OSMOSDR (osmosdr)
[2020-10-21 00:37:12.785259] (info)   Setting sample rate to: 6000000
[2020-10-21 00:37:12.786756] (info)   Actual sample rate: 6000000
[2020-10-21 00:37:12.786801] (info)   Tuning to 7.721700e+06
[2020-10-21 00:37:12.787323] (info)   Gain Stage: RF supported values: 0 14 
[2020-10-21 00:37:12.787363] (info)   Gain Stage: IF supported values: 0 8 16 24 32 40 
[2020-10-21 00:37:12.787411] (info)   Gain Stage: BB supported values: 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 
[2020-10-21 00:37:12.787424] (info)   Max Frequency: 1.067170e+07
[2020-10-21 00:37:12.787443] (info)   Min Frequency: 4.771700e+06
[2020-10-21 00:37:12.787668] (info)   IF Gain set to: 32
[2020-10-21 00:37:12.787896] (info)   BB Gain set to: 40
[2020-10-21 00:37:12.787934] (info)   Auto gain control is OFF
[2020-10-21 00:37:12.787951] (info)   Setting antenna to [TX/RX]
[2020-10-21 00:37:12.788356] (info)   PPM set to: 53
Decim: 125 Decim2:  2
[2020-10-21 00:37:12.788664] (info)      P25 Recorder two-stage decimator - Initial decimated rate: 48000 Second decimated rate: 24000 FA: 6250 FB: 12000 System Rate: 6000000
[2020-10-21 00:37:12.803315] (info)      P25 Recorder ARB - Initial Rate: 6000000 Resampled Rate: 24000 Initial Decimation: 125 System Rate: 24000 ARB Rate: 1
Project 25 IMBE Encoder/Decoder Fixed-Point implementation
Developed by Pavel Yazev E-mail: pyazev@gmail.com
Version 1.0 (c) Copyright 2009
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions; see the file ``LICENSE'' for details.
Decim: 125 Decim2:  2
[2020-10-21 00:37:12.807374] (info)      P25 Recorder two-stage decimator - Initial decimated rate: 48000 Second decimated rate: 24000 FA: 6250 FB: 12000 System Rate: 6000000
[2020-10-21 00:37:12.816616] (info)      P25 Recorder ARB - Initial Rate: 6000000 Resampled Rate: 24000 Initial Decimation: 125 System Rate: 24000 ARB Rate: 1
Decim: 125 Decim2:  2
[2020-10-21 00:37:12.821498] (info)      P25 Recorder two-stage decimator - Initial decimated rate: 48000 Second decimated rate: 24000 FA: 6250 FB: 12000 System Rate: 6000000
[2020-10-21 00:37:12.830357] (info)      P25 Recorder ARB - Initial Rate: 6000000 Resampled Rate: 24000 Initial Decimation: 125 System Rate: 24000 ARB Rate: 1
Decim: 125 Decim2:  2
[2020-10-21 00:37:12.834766] (info)      P25 Recorder two-stage decimator - Initial decimated rate: 48000 Second decimated rate: 24000 FA: 6250 FB: 12000 System Rate: 6000000
[2020-10-21 00:37:12.845147] (info)      P25 Recorder ARB - Initial Rate: 6000000 Resampled Rate: 24000 Initial Decimation: 125 System Rate: 24000 ARB Rate: 1
Decim: 125 Decim2:  2
[2020-10-21 00:37:12.850164] (info)      P25 Recorder two-stage decimator - Initial decimated rate: 48000 Second decimated rate: 24000 FA: 6250 FB: 12000 System Rate: 6000000
[2020-10-21 00:37:12.859552] (info)      P25 Recorder ARB - Initial Rate: 6000000 Resampled Rate: 24000 Initial Decimation: 125 System Rate: 24000 ARB Rate: 1
[2020-10-21 00:37:12.870449] (info)   Analog Recorder Taps - initial: 909 channel: 2273 ARB: 607 Total: 3789
[2020-10-21 00:37:12.871028] (info)   Creating decoder sink...

[2020-10-21 00:37:12.871329] (info)   Decoder sink created!

[2020-10-21 00:37:12.871542] (info)   
-------------------------------------

[2020-10-21 00:37:12.871556] (info)   

-------------------------------------
INSTANCE
-------------------------------------

[2020-10-21 00:37:12.871577] (info)   Capture Directory: /home/w6bb/trunk-recorder
[2020-10-21 00:37:12.871587] (info)   Upload Server: 
[2020-10-21 00:37:12.871595] (info)   Broadcastify Calls Server: 
[2020-10-21 00:37:12.871602] (info)   Status Server: 
[2020-10-21 00:37:12.871609] (info)   Instance Key: 
[2020-10-21 00:37:12.871620] (info)   Instance Id: 
[2020-10-21 00:37:12.871635] (info)   Broadcast Signals: false
[2020-10-21 00:37:12.871647] (info)   Default Mode: digital
[2020-10-21 00:37:12.871659] (info)   Call Timeout (seconds): 3
[2020-10-21 00:37:12.871669] (info)   Log to File: false
[2020-10-21 00:37:12.871677] (info)   Control channel warning rate: 10
[2020-10-21 00:37:12.871686] (info)   Control channel retune limit: 0
[2020-10-21 00:37:12.871698] (info)   Frequency format: 0
[2020-10-21 00:37:12.871709] (info)   Status as String: true
[2020-10-21 00:37:12.871721] (info)   Log Level: info
[2020-10-21 00:37:12.871739] (info)   [bpd.csv] Started with Control Channel: 7.742188e+02
[2020-10-21 00:37:12.871762] (error)   Unable to setup a System to record, exiting...

OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO

config file

{
    "ver": 2,
    "sources": [
        {
            "center": 772170000.0,
        "rate":  10000000.0,
            "ifGain": 32,
        "ppm": 53,
            "bbGain": 40,
            "digitalRecorders": 5,
            "driver": "osmosdr",
        "device": "hackrf=4f4397"

        }
    ],
    "systems": [{
    "LogLevel": "fatal",
    "shortName": "ebrcstest",
    "apiKey": "undefined"
    "frequencyFormat": "mhz",
        "control_channels": [774.21875],
        "type": "conventionalP25",
        "talkgroupsFile": "bpd.csv",
        "shortName": "bpd",
    "modulation": "qpsk"
    }]
"uploadServer": "https://api.openmhz.com"
}
jonk6 commented 3 years ago

One thing that jumps out at me is

[bpd.csv] Started with Control Channel: 7.742188e+02

Try changing your config file from

"control_channels": [774.21875],

to

"control_channels": [774218750],

like the rest of your frequency references.

mathisono commented 3 years ago

it was "control_channels": [77421875.0], looks like all of the example config files have the wrong values!?

Is this error ok? Or am I missing something else?

[2020-10-21 10:41:11.005829] (error)   [ebrcstest]   Control Channel Message Decode Rate: 1/sec, count:  3
jonk6 commented 3 years ago

looks like all of the example config files have the wrong values!? Which example config files are you looking at? All of the config file examples in the trunk-recorder/examples directory have frequencies written as Hz values. Or do you mean that the actual values used in the sample config files don't work for you?

Yes, the Control Channel Message Decode Rate: 1/sec, count: 3 message is a problem. The control channel specified in your may be incorrect or you may not be receiving it well enough to reliably decide it. Double check that you're specifying the correct frequency for the control channel . Your comment value of 77421875.0 is 77.421875 MHz but based on the other parameters in your config file I'm guessing you want 774.21875 MHz which is 774218750.0. Also you try adjusting your gains and antenna placement if you think you should be able to receive that system.

robotastic commented 3 years ago

@mathisono Checking back it see if you got things working and if you spotted some specific errors in the example folder.

mathisono commented 3 years ago

Antenna gain setting and signal reception isn't the problem here!!!!

I'm rather confused, all of the example config files don't work and something here is crashing my hack rf???

{
    "ver": 2,
     "sources": [
        {
            "center": 775000000,
            "rate":90000000,
            "ifGain": 40,
        "ppm": 52,
            "bbGain": 40,
            "digitalRecorders": 5,
            "analogRecorders": 0,
            "debugRecorders": 0,
            "driver": "osmosdr",
        "modulation": "qpsk",
            "device": "hackrf=4f4397"

        }
    ],
    "systems": [
    {
        "control_channels":[772132000, 772268000],
        "type": "p25",
        "talkgroupsFile": "EBRCS_TG.csv",
        "shortName": "ebrcstest",
    "apiKey": "*****"
    }
],
"uploadServer": "https://api.openmhz.com"
}

@mathisono Checking back it see if you got things working and if you spotted some specific errors in the example folder.

robotastic commented 3 years ago

The example code is just an example. you will have to customize it for your local system. Try running hackrf_info to make sure the HackRF is working.

In your config file, the rate is set at 90mhz, the HackRF maxes out at 20mhz. I think 8mhz is a standard config. I would give that a try. 8000000

bctrainers commented 3 years ago

The example code is just an example. you will have to customize it for your local system. Try running hackrf_info to make sure the HackRF is working.

In your config file, the rate is set at 90mhz, the HackRF maxes out at 20mhz. I think 8mhz is a standard config. I would give that a try. 8000000

On the HackRF, it will have severe drift unless he obtains a TXCO module for it. It'll result in no-decode issues.

The other portion is the bandwidth the HackRF uses against TR. Most systems do not need more than 10MHz (1000000), for the ones that do, 12.5MHz (12500000) of spectrum coverages does the job. For me, I'm just lazy and set it to 15000000 (15MHz). :)

robotastic commented 3 years ago

Closing - reopen if there are any updates