• General Support
  • RPi2, DVB-C - Data errors / Continuity errors in stream. I don't know what to do more.

Jan Kowalski wrote:
> Today I tested OrangePi Zero.
>

> Probably this would be good solution but.... kernel is now just 4.13 and is unable to have DVB-C drivers with this kernel version. Minimum for this 4.4.1 kernel is required.

4.13 is newer than 4.4.1. It should work out of the box on the Zero. You should NOT need to install/make any drivers, perhaps firmware, but nothing else.

"Drivers are included in kernel 3.17 (for version 1) and 3.19 (for version 2). They can be built with media_build for older kernels."

What does dmesg say on the zero with the device plugged in (without any drivers installed)?
Well, if I put T330 to OrangePi Zero it looks promising. Stick is recognize (dmesg) and has firmware loaded. But.... DVB-C is not supported. TVHeadend show only DVB-T from this stick. I was trying compile drivers from dvbsky website: http://www.dvbsky.net/Support_linux.html but no succsess (errors after make command).

Strange.

Can you post the dmesg, lsmod and what kernel are you running?
Sure, so:
lsusb:
Bus 003 Device 002: ID 0572:0320 Conexant Systems (Rockwell), Inc. DVBSky T330 DVB-T2/C tuner

dmesg | grep dvb
root@orangepizero:~# dmesg | grep dvb
[   10.461217] usb 3-1: dvb_usb_v2: found a 'DVBSky T330' in warm state
[   10.503596] usb 3-1: dvb_usb_v2: will pass the complete MPEG2 transport stream to the software demuxer
[   10.503678] dvbdev: DVB: registering new adapter (DVBSky T330)
[   10.505153] usb 3-1: dvb_usb_v2: MAC address: 00:cc:10:a5:33:0c
[   10.639306] Registered IR keymap rc-dvbsky
[   10.640015] usb 3-1: dvb_usb_v2: schedule remote query interval to 300 msecs
[   10.640034] usb 3-1: dvb_usb_v2: 'DVBSky T330' successfully initialized and connected
[   10.640173] usbcore: registered new interface driver dvb_usb_dvbsky

lsmod
root@orangepizero:~# lsmod
Module                  Size  Used by
zram                   20480  4
evdev                  20480  0
rc_dvbsky              16384  0
si2157                 16384  1
si2168                 16384  1
sun8i_codec_analog     24576  0
snd_soc_core          118784  1 sun8i_codec_analog
snd_pcm_dmaengine      16384  1 snd_soc_core
snd_pcm                69632  2 snd_pcm_dmaengine,snd_soc_core
snd_timer              24576  1 snd_pcm
dvb_usb_dvbsky         16384  0
snd                    45056  3 snd_timer,snd_soc_core,snd_pcm
soundcore              16384  1 snd
m88ds3103              20480  1 dvb_usb_dvbsky
xradio_wlan            94208  1
sun4i_gpadc_iio        16384  0
mac80211              446464  1 xradio_wlan
cfg80211              376832  2 mac80211,xradio_wlan
rfkill                 20480  3 cfg80211
uio_pdrv_genirq        16384  0
uio                    16384  1 uio_pdrv_genirq
usb_f_acm              16384  1
u_serial               20480  3 usb_f_acm
g_serial               16384  0
libcomposite           40960  2 g_serial,usb_f_acm
pwrseq_simple          16384  1
Now do sudo modinfo dvb_usb_dvbsky
root@orangepizero:~# sudo modinfo dvb_usb_dvbsky
filename:       /lib/modules/4.13.12-sunxi/kernel/drivers/media/usb/dvb-usb-v2/dvb-usb-dvbsky.ko
license:        GPL
description:    Driver for DVBSky USB
author:         Max nibble <nibble.max@gmail.com>
alias:          usb:v0CCDp0105d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0CCDp10A5d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0B48p3017d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0B48p3015d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0B48p3012d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0B48p3014d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0572p0320d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0572p680Cd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0572p960Cd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0572p6831d*dc*dsc*dp*ic*isc*ip*in*
depends:        m88ds3103
intree:         Y
name:           dvb_usb_dvbsky
vermagic:       4.13.12-sunxi SMP mod_unload ARMv7 thumb2 p2v8 
parm:           disable_rc:Disable inbuilt IR receiver. (int)
parm:           adapter_nr:DVB adapter numbers (array of short)

Little edit: After reboot (after first plug DVB Stick) dmesg looks that:
root@orangepizero:~# dmesg | grep dvb
[   10.489050] usb 3-1: dvb_usb_v2: found a 'DVBSky T330' in warm state
[   10.489756] usb 3-1: dvb_usb_v2: will pass the complete MPEG2 transport stream to the software demuxer
[   10.489834] dvbdev: DVB: registering new adapter (DVBSky T330)
[   10.491239] usb 3-1: dvb_usb_v2: MAC address: 00:cc:10:a5:33:0c
[   10.649097] Registered IR keymap rc-dvbsky
[   10.649704] usb 3-1: dvb_usb_v2: schedule remote query interval to 300 msecs
[   10.649722] usb 3-1: dvb_usb_v2: 'DVBSky T330' successfully initialized and connected
[   10.649844] usbcore: registered new interface driver dvb_usb_dvbsky
[   14.234467] si2168 0-0064: Direct firmware load for dvb-demod-si2168-b40-01.fw failed with error -2
[   14.238739] si2168 0-0064: Direct firmware load for dvb-demod-si2168-02.fw failed with error -2
[   14.243320] si2168 0-0064: firmware file 'dvb-demod-si2168-02.fw' not found

If I install firmware from DVBSky website:

wget http://www.dvbsky.net/download/linux/dvbsky-firmware.tar.gz
tar -zxvf dvbsky-firmware.tar.gz
cd dvbsky-firmware
sudo ./copy-firmware.sh

After reboot dmesg looks:
root@orangepizero:~# dmesg | grep dvb
[   10.369196] usb 3-1: dvb_usb_v2: found a 'DVBSky T330' in warm state
[   10.370093] usb 3-1: dvb_usb_v2: will pass the complete MPEG2 transport stream to the software demuxer
[   10.370184] dvbdev: DVB: registering new adapter (DVBSky T330)
[   10.371577] usb 3-1: dvb_usb_v2: MAC address: 00:cc:10:a5:33:0c
[   10.589278] Registered IR keymap rc-dvbsky
[   10.589884] usb 3-1: dvb_usb_v2: schedule remote query interval to 300 msecs
[   10.589912] usb 3-1: dvb_usb_v2: 'DVBSky T330' successfully initialized and connected
[   10.590068] usbcore: registered new interface driver dvb_usb_dvbsky
[   13.352236] si2168 0-0064: downloading firmware from file 'dvb-demod-si2168-b40-01.fw'

But DVB-C is still unrecognized in Tvh.

You might want to give this a try. https://tvheadend.org/d/2643-pctv-292e-stick-fails-dvb-c?r=15657

specifically this..


rm -f /dev/dvb/adapter0/frontend0
 ln -s /dev/dvb/adapter0/frontend1 /dev/dvb/adapter0/frontend0

Also what version of tvh are you using 4.0?
Tvh version installed from armbian-config: HTS Tvheadend 4.0.9-13~g64fec81
Jan Kowalski wrote:

> Tvh version installed from armbian-config: HTS Tvheadend 4.0.9-13~g64fec81

That would explain a lot - 4.0 has some bugs (as noted by that previous post)

The RPi 4.2 builds should work okay on the OPi zero.

You can use my RPI [[AptRepository]] for 4.2 :).

If not, let me know & I'll build you an Armbian specific deb :)

Jan Kowalski wrote:
> Thank very much!!! :)
>
> I will try repo first.
>
> Also I found building instructions for OP Zero:
> https://opoczno.ovh/2017/01/15/tvheadend-install-orange-pi-zero/ >

> Is this building procedure correct?

It is for master, if you want stable do "git checkout release/4.2" after the clone.

You can speed up the compile using --disable-ffmpeg_static (transcoding won't work anyway). Check ./configure --help for options.

Is working :)

I've installed Tvh from yours repo with any problems, of course DVB-C is now recognized, all channels are visible etc.

Now it's time for testing. I will see how many errors will get on FHD recording.
OP Zero hangs every time after start recording :(
Jan Kowalski wrote:

> OP Zero hangs every time after start recording :(

Are you supplying it enough power? I had a similar issue with the Banana Pi. It just wasn't getting enough juice - try using your device (the tuner) with a powered hub?

At the moment I haven't any powered hub to test this. I'm using 2A power supply which is recommended for OP Zero.

Is maybe some option to force more power to USB like in RPi?
Jan Kowalski wrote:
> At the moment I haven't any powered hub to test this. I'm using 2A power supply which is recommended for OP Zero.
>

>Is maybe some option to force more power to USB like in RPi?

I don't think there is any limit to the power draw from usb on the zero. I'm guessing the drive (I assume you've attached a usb drive for recordings) and the tuner are fighting each other for power.

OP Zero has just one USB port and DVB Stick is connected to it. Recordings go to sd card.
Jan Kowalski wrote:

> OP Zero has just one USB port and DVB Stick is connected to it. Recordings go to sd card.

Do channels play ok? Is it just recordings?

This is good question.

Looks that only when I record OP Zero hangs. When I copy link stream and play on mpv, everything looks ok, no hangs.

If it's not the problem - could you compile Tvh for me to OP Zero like you mention couple post before? Maybe is some bug in Tvh when I install staight from your repo.

--- [EDIT] ---
Also is strange Tvh behavior - when I reboot OP, DVB-C network (tab) is empty, EPG stays, no channel etc.
Jan Kowalski wrote:
> This is good question.
>

> Looks that only when I record OP Zero hangs. When I copy link stream and play on mpv, everything looks ok, no hangs.

You could try setting the DVR profile cache scheme to don't keep instead of system. This may wear your card out faster, but I suspect there is some sort of data backlog causing the hang - usually your card being slow. You could avoid this by recording to a external hard drive or network share.

>
> If it's not the problem - could you compile Tvh for me to OP Zero like you mention couple post before? Maybe is some bug in Tvh when I install staight from your repo.

>

Sure, see if changing the above first & I'll build you one :)

> --- [EDIT] ---

> Also is strange Tvh behavior - when I reboot OP, DVB-C network (tab) is empty, EPG stays, no channel etc.

Again this sounds like a slow card, tvh is starting up before the driver has had time to load.