ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Raspberry Pi2 Geniatech T230 drivers (media_build error)

Tue Feb 17, 2015 4:56 pm

Hi, I'm trying to get my DVB-T2 usb stick working with my Raspberry Pi 2. My raspbian version is 3.18.7-v7+.
It is a Geniatech T230 aka August DVB-T210. It states here http://www.linuxtv.org/wiki/index.php/Geniatech_T230 that it is supported out of the box with 3.19 but for previous versions can be built with the V4L media_build.

I've tried the instructions here http://www.linuxtv.org/wiki/index.php/H ... ce_Drivers but am getting the following error :-

Code: Select all

Preparing to compile for kernel version 3.18.7
File not found: /lib/modules/3.18.7-v7+/build/.config at ./scripts/make_kconfig.pl line 33, <IN> line 4.
Makefile:366: recipe for target 'allyesconfig' failed
make[1]: *** [allyesconfig] Error 2
make[1]: Leaving directory '/home/pi/media_build/v4l'
Makefile:26: recipe for target 'allyesconfig' failed
make: *** [allyesconfig] Error 2
can't select all drivers at ./build line 490.
Anyone any ideas?
Thanks in advance

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Wed Feb 18, 2015 3:53 am

The first hurdle is to ensure that CONFIG_I2C_MUX is enabled in the kernel. I've got mine built by crosscompiling. You need CONFIG_I2C_MUX enabled in the kernel. The latest raspbian might have it activated. I am not sure. But the previous built definitely does not.



This link is a good read to get you started

https://tvheadend.org/boards/5/topics/1 ... 10&r=12911

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Wed Feb 18, 2015 5:56 pm

thanks for the reply. Struggling to find if i have CONFIG_I2C_MUX enabled, the command on the link doesn't seem to work on my my pi cat /boot/config-`uname -r`, seems to work on my linux mint laptop though.

May give compiling my own kernel on my laptop using this guidehttp://elinux.org/Raspberry_Pi_Kernel_Compilation

Will need a bit of luck as its all new to me!

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Wed Feb 18, 2015 9:15 pm

found this in /proc/config.gz

Code: Select all

#
# I2C support
#
CONFIG_I2C=y
CONFIG_I2C_BOARDINFO=y
CONFIG_I2C_COMPAT=y
CONFIG_I2C_CHARDEV=m
CONFIG_I2C_MUX=m

#
# Multiplexer I2C Chip support
#
# CONFIG_I2C_ARB_GPIO_CHALLENGE is not set
# CONFIG_I2C_MUX_GPIO is not set
# CONFIG_I2C_MUX_PCA9541 is not set
# CONFIG_I2C_MUX_PCA954x is not set
# CONFIG_I2C_MUX_PINCTRL is not set
CONFIG_I2C_HELPER_AUTO=y
CONFIG_I2C_ALGOBIT=m
this means the kernel i'm using already has it enabled then?

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Feb 19, 2015 2:45 am

It should be. So now you just need your kernel source to compile your dvb. I suppose your first error means
/lib/modules/3.18.7-v7+/build doesnt exist? Thats where the kernel source should be or linked.


Do you need dvb-c or t2? Oddly on the pi, i cant seem to detect dvb-c but t2 works fine.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Feb 19, 2015 11:29 am

thanks for helping, getting a lot further now after a lot of reading, managed to build and install. I don't need DVB-C just DVB-T/T2. I've put the two firmware files in /lib/firmware but Unfortunately driver is not getting loaded.

Here's my full method how I got to where I am.

Code: Select all

cd /usr/src
sudo wget https://github.com/raspberrypi/linux/archive/rpi-3.18.y.tar.gz
sudo tar xvfz rpi-3.18.y.tar.gz
sudo ln -s /usr/src/linux-rpi-3.18.y/ /lib/modules/3.18.7-v7+/build
cd /lib/modules/3.18.7-v7+/build
sudo make clean
make mrproper
sudo su 
gzip -dc /proc/config.gz > .config
make prepare
make oldconfig
make modules_prepare
wget https://github.com/raspberrypi/firmware/raw/master/extra/Module7.symvers

git clone git://linuxtv.org/media_build.git
#(alternately to get only the latest revision without history)
#git clone --depth=1 git://linuxtv.org/media_build.git
cd media_build 
./build
Think the error may be something to do with with Modules7.symvers after realising the Modules7.symvers is for RPi 2. Was getting media: disagrees about version of symbol module_layout with Modules.symvers from https://github.com/raspberrypi/firmware ... ster/extra

Here's my dmesg output

Code: Select all

[    4.223683] usb 1-1.4.3: new high-speed USB device number 6 using dwc_otg
[    4.330431] usb 1-1.4.3: New USB device found, idVendor=0572, idProduct=c688
[    4.345316] usb 1-1.4.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    4.358080] usb 1-1.4.3: Product: USB Stick
[    4.365717] usb 1-1.4.3: Manufacturer: Max
[    4.375136] usb 1-1.4.3: SerialNumber: 080116
[    4.645624] media: no symbol version for module_layout
Last edited by ukdaveuk on Thu Feb 19, 2015 4:25 pm, edited 2 times in total.

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Fri Feb 20, 2015 4:08 am

I'm trying to emulate your instructions on my spare pi. i need to download the latest raspbian though. So thats gonna take some time. I suppose now your compilation produces no error? Its just that the modules dont get loaded? try to issue the command modinfo and pay attention to vermagic. Heres mine

Code: Select all

pi@raspberrypi ~ $ modinfo si2168
filename:       /lib/modules/3.18.3+/kernel/drivers/media/dvb-frontends/si2168.ko
firmware:       dvb-demod-si2168-b40-01.fw
firmware:       dvb-demod-si2168-a30-01.fw
firmware:       dvb-demod-si2168-a20-01.fw
license:        GPL
description:    Silicon Labs Si2168 DVB-T/T2/C demodulator driver
author:         Antti Palosaari <crope@iki.fi>
srcversion:     D6C115F0C3558E62EC5B216
alias:          i2c:si2168
depends:        i2c-mux
intree:         Y
vermagic:       3.18.3+ preempt mod_unload modversions ARMv6 
pi@raspberrypi ~ $  modinfo i2c-mux
filename:       /lib/modules/3.18.3+/kernel/drivers/i2c/i2c-mux.ko
license:        GPL v2
description:    I2C driver for multiplexed I2C busses
author:         Rodolfo Giometti <giometti@linux.it>
srcversion:     8830D8D8C8E1766344ACDEA
depends:        
intree:         Y
vermagic:       3.18.3+ preempt mod_unload modversions ARMv6 
what i found out is that the vermagic doesnt turn out the way that i want it sometimes. Thats why it doesnt get loaded. I am no expert in linux but i try to understand what i'm doing and i was working on this for weeks before i got it right. I'll get back to you once i've emulated what you did.

more useful read with regards to gcc https://github.com/notro/rpi-source/wiki

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Fri Feb 20, 2015 7:37 am

yep, it compiles without error now. I've issued the two commands here's the output, vermagic differs 3.18.7-v7 -> 3.18.7-v7+

Code: Select all

pi@raspberrypi /lib/firmware $ modinfo si2168
filename:       /lib/modules/3.18.7-v7+/kernel/drivers/media/dvb-frontends/si2168.ko
firmware:       dvb-demod-si2168-b40-01.fw
firmware:       dvb-demod-si2168-a30-01.fw
firmware:       dvb-demod-si2168-a20-01.fw
license:        GPL
description:    Silicon Labs Si2168 DVB-T/T2/C demodulator driver
author:         Antti Palosaari <crope@iki.fi>
srcversion:     E3A08DF47680BC968C847AC
alias:          i2c:si2168
depends:
vermagic:       3.18.7-v7 SMP preempt mod_unload modversions ARMv7
pi@raspberrypi /lib/firmware $ modinfo i2c_mux
filename:       /lib/modules/3.18.7-v7+/kernel/drivers/i2c/i2c-mux.ko
license:        GPL v2
description:    I2C driver for multiplexed I2C busses
author:         Rodolfo Giometti <giometti@linux.it>
srcversion:     8830D8D8C8E1766344ACDEA
depends:
intree:         Y
vermagic:       3.18.7-v7+ SMP preempt mod_unload modversions ARMv7

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Fri Feb 20, 2015 9:31 am

I just tried building it on the pi. Everything went smoothly. Even got the vermagic right. But after make install and reboot. the pi wouldnt boot with the T230 attached. It might have something to do with the fact that the Module.symvers is for 3.18.6 instead of 3.18.7. https://github.com/raspberrypi/firmware ... ster/extra

When i compiled my own kernel, the Module.symvers is created in the process. Anyway, I'm giving it another go.

As for getting the vermagic right, instead of doing ./build in media_build, i did the following.

Code: Select all

git clone git://linuxtv.org/media_build.git
cd media_build
export CCSRC=/dir-of-your-linux-source #in your case its probably /usr/src/linux-rpi-3.18.y
SRCDIR=$CCSRC make download untar
SRCDIR=$CCSRC make -C v4l allyesconfig
# The following command is the reason why i did not do a ./build. I wanna make sure the version is correct. Very important especially when you cross compile.
SRCDIR=$CCSRC make release VER='$(uname -r)'
SRCDIR=$CCSRC make
modinfo ./v4l/si2168.ko
sudo SRCDIR=$CCSRC make install

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Feb 22, 2015 2:33 pm

tried using the above code, mine too would not boot with stick attached. I see there is a new version of Module7.symvers will try that
https://github.com/raspberrypi/firmware ... ster/extra

agitatedclimax
Posts: 7
Joined: Sun Feb 22, 2015 4:11 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Feb 22, 2015 4:41 pm

Hi,

I'm also trying to get the T230 working on a Pi2.

@ukdaveuk I was wondering if your boot issue when the tuner is attached is caused by the increased power used when the USB stick initialises. I had a similar problem when I first built v4l and rebooted, so now I'm using a powered USB hub, which enables the Pi to boot again but the tuner still doesn't actually work. I'm going to give everything a fresh build using the manual build instructions provided by fuzurie and see if that gets me any further.

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Feb 22, 2015 5:34 pm

fwiw, I've been struggling to get it working with the latest media build. Never managed to get it to compile nicely on the pi. Must have been doing something wrong. Keeps throwing kernel error even when i crossed-compiled the kernel. You should really try cross compiling. It makes things less frustrating. I did however gained success when i compiled against an old version of media_build provided here. https://tvheadend.org/boards/5/topics/1 ... =8&r=12911

So I am suspecting something is wrong with the latest media_build. I strongly recommend you to cross compile. Its much much faster.
This is more or less the command i used. Be sure to use it on a spare SD card as i do not want to screw your current setup.

You might need some dependancies. I dont have the complete list but this is a rough idea.

Code: Select all

apt-get install  libdigest-sha-perl make gcc git patch patchutils libproc-processtable-perl  libncurses5-dev rsync
might need more depending on how prepared your pc is to cross compile

Code: Select all


##this is done on your pc
git clone https://github.com/raspberrypi/tools
cd tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/  #gcc-linaro-arm-linux-gnueabihf-raspbian-x64 might be different if you are using 32bit pc. Check out other guides for your pi2 or if you using 32bit pc
export PATH=$(pwd):$PATH
ln -s arm-linux-gnueabihf-strip strip #to prevent compile error regarding strip in media-build
cd ../../../../

git clone --depth=1 https://github.com/raspberrypi/linux
cd linux
make clean
make mrproper
scp pi@x.x.x.x:/proc/config.gz ./ #adjust to your pi IP
gzip -dc config.gz > .config
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make oldconfig
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make prepare
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make modules_prepare
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make # this command can be faster if you add a -j3 or -j5 depending on your pc. Check other guides for full explanation.
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make modules
mkdir modules
export MODULES_TEMP=$(pwd)/modules
ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- INSTALL_MOD_PATH=$MODULES_TEMP make modules_install #Pay attention to the last line (DEPMOD  3.18.7+) when the command completes. remember this number
scp arch/arm/boot/Image pi@x.x.x.x:/home/pi/kernel.img #adjust the ip according to your pi


cd ../
wget https://tvheadend.org/attachments/download/2696/media_build.tar.bz2 #confirmed working source from the links above
tar xjvf media_build.tar.bz2
cd media_build
export CCSRC=/path-to-raspberry-pi-source/linux #adapt to your path. Make sure its the full path.
ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf- make untar
ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf- make release VER='3.18.7+' # this is the number earlier. It has to match.
ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf- make -C v4l allyesconfig
ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf- make -C v4l menuconfig # not important/compulsary unless you know what to unselect to compile lesser modules.
ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf- make 
modinfo v4l/si2168.ko #check the vermagic

ARCH=arm SRCDIR=$CCSRC CROSS_COMPILE=arm-linux-gnueabihf-   DESTDIR=$MODULES_TEMP make install

rsync -av $MODULES_TEMP pi@x.x.x.x:/home/pi/
then, in your raspberry pi home folder, you should find a directory called module and a file called kernel.img.

Code: Select all

sudo cp kernel.img /boot/kernel.img # or maybe yours is /boot/kernel7.img
sudo rsync -av modules/ /
sudo reboot
if everything works fine (on my B+ its fine.), my dmesg is

Code: Select all

[    8.873914] WARNING: You are using an experimental version of the media stack.
[    8.873914] 	As the driver is backported to an older kernel, it doesn't offer
[    8.873914] 	enough quality for its usage in production.
[    8.873914] 	Use it with care.
[    8.873914] Latest git patches (needed if you report a bug to linux-media@vger.kernel.org):
[    8.873914] 	504febc3f98c87a8bebd8f2f274f32c0724131e4 Revert [media] lmed04: add missing breaks
[    8.873914] 	6b281d830f09a4f58651839030b39571dea1b56d [media] siano: unnecessary check before rc_unregister_device()
[    8.873914] 	1cc6adfef42615478e9af1228377acbc9f54f00f [media] media: v4l2-image-sizes.h: add SVGA, XGA and UXGA size definitions
[   10.680095] WARNING: You are using an experimental version of the media stack.
[   10.680095] 	As the driver is backported to an older kernel, it doesn't offer
[   10.680095] 	enough quality for its usage in production.
[   10.680095] 	Use it with care.
[   10.680095] Latest git patches (needed if you report a bug to linux-media@vger.kernel.org):
[   10.680095] 	504febc3f98c87a8bebd8f2f274f32c0724131e4 Revert [media] lmed04: add missing breaks
[   10.680095] 	6b281d830f09a4f58651839030b39571dea1b56d [media] siano: unnecessary check before rc_unregister_device()
[   10.680095] 	1cc6adfef42615478e9af1228377acbc9f54f00f [media] media: v4l2-image-sizes.h: add SVGA, XGA and UXGA size definitions
[   11.677265] pcm512x 1-004d: Failed to reset device: -5
[   11.684947] pcm512x: probe of 1-004d failed with error -5
[   11.734707] dvb-usb: found a 'Mygica T230 DVB-T/T2/C' in warm state.
[   11.755886] pcm512x 1-004c: Failed to reset device: -5
[   11.763882] pcm512x: probe of 1-004c failed with error -5
[   12.007391] dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer.
[   12.022903] DVB: registering new adapter (Mygica T230 DVB-T/T2/C)
[   12.077995] i2c i2c-2: Added multiplexed i2c bus 3
[   12.084990] si2168 2-0064: Silicon Labs Si2168 successfully attached
[   12.144381] si2157 3-0060: Silicon Labs Si2147/2148/2157/2158 successfully attached
[   12.183421] usb 1-1.4: DVB: registering adapter 0 frontend 0 (Silicon Labs Si2168)...
[   12.213189] input: IR-receiver inside an USB DVB receiver as /devices/platform/bcm2708_usb/usb1/1-1/1-1.4/input/input0
[   12.238329] dvb-usb: schedule remote query interval to 100 msecs.
[   12.254266] dvb-usb: Mygica T230 DVB-T/T2/C successfully initialized and connected.
[   12.284526] usbcore: registered new interface driver dvb_usb_cxusb
[   14.337227] dvb-usb: recv bulk message failed: -110
and my lsmod is

Code: Select all

Module                  Size  Used by
snd_bcm2835            21342  0 
evdev                  11000  1 
si2157                  4426  1 
si2168                  6822  1 
i2c_mux                 2471  1 si2168
dvb_usb_cxusb          53003  0 
dib0070                 9107  1 dvb_usb_cxusb
dvb_usb                23127  1 dvb_usb_cxusb
snd_soc_wm8804          8225  0 
snd_soc_pcm512x_i2c     2130  0 
snd_soc_tas5713         5866  0 
regmap_spi              2307  1 snd_soc_wm8804
snd_soc_pcm512x         8468  1 snd_soc_pcm512x_i2c
regmap_i2c              2944  3 snd_soc_wm8804,snd_soc_pcm512x_i2c,snd_soc_tas5713
dvb_core              100041  1 dvb_usb
snd_soc_bcm2708_i2s     7539  0 
regmap_mmio             3548  1 snd_soc_bcm2708_i2s
snd_soc_core          177952  4 snd_soc_pcm512x,snd_soc_wm8804,snd_soc_tas5713,snd_soc_bcm2708_i2s
snd_compress            8698  1 snd_soc_core
snd_pcm_dmaengine       5850  1 snd_soc_core
snd_pcm                93100  4 snd_bcm2835,snd_soc_wm8804,snd_soc_core,snd_pcm_dmaengine
snd_seq                61097  0 
snd_seq_device          7209  1 snd_seq
snd_timer              23007  2 snd_pcm,snd_seq
rc_core                23779  2 dvb_usb,dvb_usb_cxusb
snd                    67211  7 snd_bcm2835,snd_soc_core,snd_timer,snd_pcm,snd_seq,snd_seq_device,snd_compress
spi_bcm2708             6018  0 
i2c_bcm2708             6200  0 
Last edited by fuzurie on Sun Feb 22, 2015 5:55 pm, edited 2 times in total.

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Feb 22, 2015 5:46 pm

you also need to download the firmware to /lib/firmware on your pi. And if you plan to use tvheadend, make sure its the compiled version (compiled on the pi). From what i read, to use T230, you gotta compile the latest version of complimentary software(wscan, tvheadend...). Those you can compile on the pi. Not much headache. Go read other guides for explanation of the commands. I was compiling for a B+ on a 64bit pc. For a PI2 or a 32bit pc, it might be slightly different. Just adapt my commands to whatever guide that you refer to.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Feb 22, 2015 8:19 pm

it failed to boot connected with my last effort. My next step is try openelec just to test the T230 on the pi2 as i know the T230 works out of the box on my htpc. My overall goal is to have my pi2 running Kodi mysql database, deluge, and to be my tvheadend backend. So far 2 out of three ok. I have tried another DVB-T stick (Geniatech T328B, detected out of the box) but that just stops working after a few hours and requires me to unplug and reboot.

Will also have a go at cross compiling on my laptop.

agitatedclimax
Posts: 7
Joined: Sun Feb 22, 2015 4:11 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Mon Feb 23, 2015 9:24 pm

I've just tried this tuner on OpenELEC and it works out of the box. I would probably want to go back to raspbian though because I prefer a more complete Linux system. I might give cross-compiling a go at some point, otherwise I'll just wait for the 3.20 kernel to come to raspbian (there seems to be a 3.19 branch already). I'm just relieved to see this tuner work. I'm currently recording three HD streams at the same time (off the same MUX as I've only got the one tuner plugged in) and the Pi2 is coping with it fine. Amazing what these devices can do.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Fri Feb 27, 2015 8:56 pm

agitatedclimax wrote:@ukdaveuk I was wondering if your boot issue when the tuner is attached is caused by the increased power used when the USB stick initialises
I was using a powered hub by the way. Looks like I'll have to wait until 3.19 raspbian is out for this, spent way too much time trying to get this sorted!!

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Sun Mar 01, 2015 1:59 am

There wasnt any power problem for me at all. My T230 is connected directly to the pi in addition to an additional thumbdrive that i used for external booting. Just got my RPI2. The instruction i posted , works on the RPI2 as well. Managed to work around dvb-c as well. For some reason, Tvheadend could only identify it as a dvb-t/dvb-t2 device. To use it as a dvb-c device, momentarily ran wscan for dvb-c and then killed the command. Then i ran tvheadend. Only then, tvheadend would identify it as dvb-c. I have the luxury of both dvb-c and dvb-t2 signal here. Both received the same channel. But i chosed wired rather than wireless for long term reluability.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Tue Mar 17, 2015 2:58 pm

Finally returned to this after a few weeks when i had some spare time, and thought i would try the cross compile route as in this post above by fuzurie http://www.raspberrypi.org/forums/viewt ... 84#p702184

All working great for me now on 3.18.9-v7+, so many thanks to fuzurie for all your help. :D :D :D :D :D

agitatedclimax
Posts: 7
Joined: Sun Feb 22, 2015 4:11 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Tue Mar 17, 2015 4:08 pm

That's weird. I've just done exactly the same. Cross-compiled 3.18.9-v7+ using the media_build linked to in the instructions, and sure enough the tuner is detected okay, so a big thanks to fuzurie for the instructions. However, I've used both w_scan and tvheadend and neither of them detect any of the DVB-T2 muxes properly. I get all of the SD and Radio channels detected okay. When I tried this tuner on OpenELEC it just detected and scanned the HD muxes and channels without me having to do anything special. Not sure why. Are you successfully detecting DVB-T2 HD channels, ukdaveuk?
I had a quick search around and found some discussion around the way that the DVB-T MUX handling code would also try DVB-T2, but that had changed in the latest kernel and the programme now had to explicitly select DVB-T or DVB-T2 for a MUX. Off the back of that information I tried out the latest 3.9 version of tvheadend, that lets you set the "Delivery System" to DVB-T2 manually, but that doesn't make any difference either. A bit stumped now. I might try building the 3.19 kernel from the raspbian GitHub and see if that makes any difference.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Tue Mar 17, 2015 4:26 pm

yes the DVB-T2 channels are working, but none were to start with. I was under the impression two firmware files were required dvb-demod-si2168-b40-01.fw and dvb-tuner-si2158-a20-01.fw but this post here mentions a third dvb-demod-si2168-02.fw

https://tvheadend.org/boards/5/topics/1 ... sage-14874

I also copied the input and channel folders from a working openelec and placed them in the /home/hts/.hts/tvheadend folder so whether it was that that sorted it or the third firmware file I don't know.

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Mar 19, 2015 3:33 pm

Did you compile tvheadend? When you guys add or edit mux, did you change the delivery system to dvbt2? HD channels works okay for me. But the signal is not that strong. At the same position, the same antenna and receiver could pick up the channels easily in windows. But on linux, it wouldnt pick up any. Had to move my antenna outdoor.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Mar 19, 2015 3:42 pm

Yeah, I compiled tvheadend on the pi2, pretty straight forward following this guide https://tvheadend.org/boards/5/topics/15426. It didn't take long at all.

I did choose the DVBT2 setting in tvh,bandwidth of 8Mhz and everything else set to auto, but it wouldn't scan for channels to start with. After copying the input and channel folders from a working openelec and the extra firmware file, I rebooted and everything started working fine.

fuzurie
Posts: 15
Joined: Wed Feb 18, 2015 3:42 am

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Mar 19, 2015 4:05 pm

Ahh. Did encounter the same problem too if i remembered correctly. It took some time to start scanning after enabling the tuner in tvheadend interface. Restarting tvheadend did the trick. I guess restarting the pi would would work the same too. Fyi, i used the only 2 firmware for the tuner. Not sure whether the third firmware helps you in anyway. Check your dmesg output after starting tvheadend to see what firmware was loaded.

ukdaveuk
Posts: 20
Joined: Tue Feb 17, 2015 4:39 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Thu Mar 19, 2015 7:47 pm

dmesg output, only 2 firmware files loaded by the look of it

Code: Select all

[    3.718877] usb 1-1.4: New USB device found, idVendor=0572, idProduct=c688
[    3.727884] usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    3.737269] usb 1-1.4: Product: USB Stick
[    3.743551] usb 1-1.4: Manufacturer: Max
[    3.749704] usb 1-1.4: SerialNumber: 080116
[    4.109737] bcm2708_i2c_init_pinmode(1,2)
[    4.122107] WARNING: You are using an experimental version of the media stack.
[    4.122107]  As the driver is backported to an older kernel, it doesn't offer
[    4.122107]  enough quality for its usage in production.
[    4.122107]  Use it with care.
[    4.122107] Latest git patches (needed if you report a bug to linux-media@vger.kernel.org):
[    4.122107]  504febc3f98c87a8bebd8f2f274f32c0724131e4 Revert [media] lmed04: add missing breaks
[    4.122107]  6b281d830f09a4f58651839030b39571dea1b56d [media] siano: unnecessary check before rc_unregister_device()
[    4.122107]  1cc6adfef42615478e9af1228377acbc9f54f00f [media] media: v4l2-image-sizes.h: add SVGA, XGA and UXGA size definitions
[    4.129632] bcm2708_i2c_init_pinmode(1,3)
[    4.130622] bcm2708_i2c bcm2708_i2c.1: BSC1 Controller at 0x3f804000 (irq 79) (baudrate 100000)
[    4.133679] bcm2708_spi bcm2708_spi.0: master is unqueued, this is deprecated
[    4.216362] bcm2708_spi bcm2708_spi.0: SPI Controller at 0x3f204000 (irq 80)
[    4.289492] WARNING: You are using an experimental version of the media stack.
[    4.289492]  As the driver is backported to an older kernel, it doesn't offer
[    4.289492]  enough quality for its usage in production.
[    4.289492]  Use it with care.
[    4.289492] Latest git patches (needed if you report a bug to linux-media@vger.kernel.org):
[    4.289492]  504febc3f98c87a8bebd8f2f274f32c0724131e4 Revert [media] lmed04: add missing breaks
[    4.289492]  6b281d830f09a4f58651839030b39571dea1b56d [media] siano: unnecessary check before rc_unregister_device()
[    4.289492]  1cc6adfef42615478e9af1228377acbc9f54f00f [media] media: v4l2-image-sizes.h: add SVGA, XGA and UXGA size definitions
[    4.410359] dvb-usb: found a 'Mygica T230 DVB-T/T2/C' in warm state.
[    4.655873] pcm512x 1-004d: Failed to reset device: -5
[    4.663602] pcm512x: probe of 1-004d failed with error -5
[    4.672149] pcm512x 1-004c: Failed to reset device: -5
[    4.680456] pcm512x: probe of 1-004c failed with error -5
[    4.688549] dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer.
[    4.703260] DVB: registering new adapter (Mygica T230 DVB-T/T2/C)
[    4.733324] i2c i2c-2: Added multiplexed i2c bus 3
[    4.740656] si2168 2-0064: Silicon Labs Si2168 successfully attached
[    4.765126] si2157 3-0060: Silicon Labs Si2147/2148/2157/2158 successfully attached
[    4.777214] usb 1-1.4: DVB: registering adapter 0 frontend 0 (Silicon Labs Si2168)...
[    4.791401] input: IR-receiver inside an USB DVB receiver as /devices/platform/bcm2708_usb/usb1/1-1/1-1.4/input/input0
[    4.806451] dvb-usb: schedule remote query interval to 100 msecs.
[    4.814917] dvb-usb: Mygica T230 DVB-T/T2/C successfully initialized and connected.
[    4.827719] usbcore: registered new interface driver dvb_usb_cxusb
[    6.907718] dvb-usb: recv bulk message failed: -110
[    7.524718] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[    7.772538] random: nonblocking pool is initialized
[    7.827379] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[   12.100729] smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup
[   13.616769] smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0xCDE1
[   18.617383] Adding 102396k swap on /var/swap.  Priority:-1 extents:2 across:2134012k SSFS
[   20.193557] si2168 2-0064: found a 'Silicon Labs Si2168' in cold state
[   20.362251] si2168 2-0064: downloading firmware from file 'dvb-demod-si2168-b40-01.fw'
[   20.922273] si2168 2-0064: found a 'Silicon Labs Si2168' in warm state
[   20.931392] si2157 3-0060: found a 'Silicon Labs Si2146/2147/2148/2157/2158' in cold state
[   20.942765] si2157 3-0060: downloading firmware from file 'dvb-tuner-si2158-a20-01.fw'

agitatedclimax
Posts: 7
Joined: Sun Feb 22, 2015 4:11 pm

Re: Raspberry Pi2 Geniatech T230 drivers (media_build error)

Fri Mar 20, 2015 11:16 am

I downloaded those firmware files and thought I'd just do a quick md5sum to check if any of them were different from the ones I already had, and found this:

d8da7ff67cd56cd8aa4e101aea45e052 dvb-demod-si2168-02.fw
d8da7ff67cd56cd8aa4e101aea45e052 dvb-demod-si2168-b40-01.fw
0cba7ce61c1411cbe7f22c0746e24e33 dvb-tuner-si2158-a20-01.fw

which suggests the first two firmware files are identical. Very weird. Anyway it doesn't look like the dvb-demod-si2168-02.fw one is ever actually loaded (not according to ukdaveuk's dmesg, or mine).

I tried tvheadend 3.9 (unstable) as that one allows you to select the delivery system (DVB-T or DVB-T2) which I thought might help, but still nothing. Can I just ask which version of tvheadend you guys are running? I'm assuming @fuzurie that you are running the "unstable" version (with the delivery system setting in the mux config). How about you @ukdaveuk? I'm wondering if the tuner files you took from your OpenELEC build include the correct delivery system for each MUX for each area, whereas the default tvheadend build only has the non-HD muxes, and if you add them manually, the delivery system isn't correct (or settable).

Return to “Media centres”