baycom / tfrec

SDR tool for receiving wireless sensor data (TFA IT+ KlimaLogg Pro, LaCrosse, WeatherHub)
GNU General Public License v2.0
68 stars 19 forks source link

New DVB-T Sticks with Fitipower FC0012 tuner #20

Open AlexLoes opened 3 years ago

AlexLoes commented 3 years ago

Hello

I remaked an issue with new DVB-T Sticks with an RTL28xx. I had no Issues with my old DVB-T Stick. ince it's used 24h/24h to catch tfa sensors, I bought a new one: Same model, same brand. But it has no more a Raphael Micro R820 Tuner. It now has a Fitipower FC0012 tuner. This Chip has a disadvantage: You can't use it for dump1090 anymore, because it doesn't tune that frequeny (1090Mhz) any more. ( The Fitipower FC0012 frequency range is 22 - 948.6 MHz, not enough for 1090MHz ADS-B ).

Even more, with this chip attached, I've always get a message: Inverted SYNC.

What does it mean?

Thanx

devZer0 commented 3 years ago

yes, i have also issues with this.

tfa klimalog sensors receive fine with R820T tuner, but (optically similar stick) fails with Fitipower FC0012 tuner.

/root/tfrec

Registering demod for TFA_1 KlimaLoggPro Registering demod for TFA_2 sensors, 17240 bit/s type 0x1: Samples per bit: 22.3 Registering demod for TFA_3 sensors, 9600 bit/s type 0x2: Samples per bit: 40.0 Found Rafael Micro R820T tuner Allocating 15 zero-copy buffers TFA1 ID 4356 +23.4 29% seq c lowbat 0 RSSI 81 TFA1 ID 3996 +24.4 29% seq a lowbat 0 RSSI 81 TFA1 ID 6f44 +22.1 35% seq e lowbat 0 RSSI 66 TFA1 ID 3f14 +22.4 35% seq b lowbat 0 RSSI 62

/root/tfrec-master/tfrec

Registering demod for TFA_1 KlimaLoggPro Registering demod for TFA_2 sensors, 17240 bit/s type 0x1: Samples per bit: 22.3 Registering demod for TFA_3 sensors, 9600 bit/s type 0x2: Samples per bit: 40.0 Detached kernel driver Found Fitipower FC0012 tuner Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC Inverted SYNC

merbanan commented 3 years ago

A patch for librtlsdr is needed. >800MHz doesn't work well. If you promise to test the patch I can write it. I had a device but never bothered to write and test it. But as there appear more devices with this tuner now it makes sense to upstream it.

devZer0 commented 3 years ago

fantastic, yes, i hereby promise to test the patch and post the results/work with you to make it work. i can also donate a tfa sensor or fc0012 tuner stick if you like.

merbanan commented 3 years ago

Only FC0013 needed the patch. FC0012 never had the L-band switch in hardware or the driver never activated it.

SchmelleDev commented 3 years ago

Hi, I succesfully run tfrec with a Fitipower FC0012 tuner on a Ubuntu 20.04.1 LTS (GNU/Linux 5.4.0-1029-raspi aarch64) on a raspberry 4 to read seven 30.3180.IT sensors (and two 433 MHz sensors by use of rtl_433, one minute each program). I spend some weeks to get it work:

lsusb: Bus 001 Device 012: ID 0bda:2838 Realtek Semiconductor Corp. RTL2838 DVB-T

Actually, it is mainly about finding the correct command line parameters and observing, that best frequency if shifted compared to previous reports. Usually, I received data for two frequency bands.

For my sensor type it will only work for given -T 1,

I wrote some bash scripts to find my optimum values e.g. for gain:

!/bin/bash

for gain in -9.9 -4.0 7.1 17.9 19.2 ### Outer for loop

for gain in 19.2 17.9 7.1 ### Outer for loop ### do

for (( t = 0 ; t <= 4000; t=t+25 )) ### Inner for loop ###
do
      echo -n "$gain $t"
      echo "" #### print the new line ###
      sudo timeout 15 ./tfrec -T 1 -W -g $gain -t $t > "results1/$gain $t"

done

done

And for frequency after optimized gain:

!/bin/bash

for gain in -9.9 -4.0 7.1 17.9 19.2 ### Outer for loop

for gain in 19.2 17.9 7.1 -4.0 -9.9 ### Outer for loop

do

for (( f = 868250 ; f <= 868360; f=f+1 )) ### Inner for loop ###
do
      echo -n "$f"
      echo "" #### print the new line ###
      sudo timeout 40 ./tfrec -T 1 -g 17 -t 7000 -W -f $f > "results3/$f"

done

done

The scripts save files that one can sort by size (or number of written lines) in order and read optimal values from the filenames. You may play with frequency limits and stepsize.

For my setup (antenna on a metal surface) optimum parameters are: "$TFREC_HOME/tfrec" -T 1 -g 7 -t 7000 -f 868320 -w 60 -e "$TFREC_HOME/publish-tfrec-to-mqtt.sh";

Sometimes I face unstabilities after reboot. Usually these disapper after I run rtl_433 for about 1 minute or reboot a second time. Hope, this will help to close this issue.

baycom commented 1 year ago

On 21.01.23 18:56, Martin Fopp wrote:

It seems my new DVB-T Stick has also a Fitipower FC0012 Tuner and I am receiving also "Inverted Sync" as message. For a @.*** 30.3060.01 with -T 2. Do I need to look for another Tuner or is there a workaround?

The 30.3060.01 is a WeatherHub sensor, which is not enabled by default. If you only have WeatherHub sensors, you can use -T 20, so no other decodings are tried (also getting rid of the "inverted sync"-message). For decoding of all supported sensors, you can use -T ff.

Georg -- Georg Acher - @.*** BayCom GmbH - Broadcast and Media Solutions - AG München HRB 135345 Tulpenweg 2, D-82237 Wörthsee, Tel: +49(0)89/71034545

snoopy21 commented 1 year ago

Hi Georg, thank you for your response - in the meantime I tried this option (-T 20) too and after about 30 minutes I received the messages from the 30.3060.01. For other people having a similar problem, the 30.3060.01 sensor is broadcasting about every 6 minutes 4 times the same message.

devZer0 commented 1 year ago

hello, i have put aside my fitipower dvb-t sticks for a while, but as i need them now and i have no others left, i gave it another try.

i cannot receive anything with those, not even with the scripts from @SchmelleDev

does anybody have a clue why tfrec won't show anything from TFA 30.3180.IT ?

with rtl433 they work fine


# ./rtl_433
rtl_433 version nightly branch master at 202304272301 inputs file rtl_tcp RTL-SDR
Use -h for usage help and see https://triq.org/ for documentation.
Trying conf file at "rtl_433.conf"...
Trying conf file at "/root/.config/rtl_433/rtl_433.conf"...
Trying conf file at "/usr/local/etc/rtl_433/rtl_433.conf"...
Trying conf file at "/etc/rtl_433/rtl_433.conf"...
[Protocols] Registered 211 out of 245 device decoding protocols [ 1-4 8 10-12 15-17 19-23 25-26 29-36 38-60 63 67-71 73-100 102-105 108-116 119-121 124-128 130-149 151-161 163-168 170-175 177-197 199 201-215 217-228 230-232 234-241 243-244 ]
Found Fitipower FC0012 tuner
[SDR] Using device 0: Realtek, RTL2838UHIDIR, SN: 00000001, "Generic RTL2832U OEM"
Exact sample rate is: 250000.000414 Hz
Allocating 15 zero-copy buffers
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
time      : 2023-05-13 10:17:59
model     : Conrad-S3318P ID        : 176
Channel   : 1            Battery   : 1             Temperature: 67.90 F      Humidity  : 56 %          Button    : 0             Integrity : CRC
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
time      : 2023-05-13 10:18:00
model     : TFA-TwinPlus Id        : 46
Channel   : 3            Battery   : 1             Temperature: 19.7 C       Humidity  : 61 %          Integrity : CHECKSUM
^CSignal caught, exiting!
kitebuggylux commented 1 year ago

Hello

I thought, tfrec only works on device's with 868Mhz?

devZer0 commented 1 year ago

TFA 30.3180.IT is 868Mhz. rtl433 was just meant as an example to show that the dvb-t stick basically works

GeorgA commented 1 year ago

tfrec has a quite narrow filter to increase sensitivity, maybe your transmitter is a bit off. You can try the -W option to open up the reception window. I haven't done much testing with Fitipower-based sticks, from my experience with an old Terratec Noxon they are also a bit deaf.