Jump to content


Photo

it913x USB DVB-T tuner reported as DVB-C after GUI restart

OpenPLi4 it913x Vu+ Duo2

  • Please log in to reply
68 replies to this topic

#1 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 12 December 2013 - 10:45

I have some problem with it913x USB DVB-T dongle.

 

Everything is Ok after start from deep standby, but the dongle somehow 'becomes' DVB-C after enigma2 restart. It is reported as DVB-C in about tuner dialog, it has DVB-C options in tuner config dialog, and tuner is not used for DVB-T input. 

 

After reboot (deep) everything is back to normal, and it913x is reported as DVB-T correctly with correct tuner setup. And it works until next enigma2 restart.

 

Box info:

Vu+ Duo2, OpenPLi 4 (latest with online upgrade from 20131018 flash version).

DVB-S2 Dual + DVB-T\C (set up as DVB-T) + it913x DVB-T USB dongle.

 

Any help appreciated.

Regards.



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #2 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 18:26

I've tested two it913x devices, one was Cabletech URZ0085 (048D:9135), the other one was a borrowed Evolve Venus (it is a twin DVB-T tuner; 048D:9006).

In the latter case two tuners were added - ok. Still they all turns to DVB-C after enigma2 restart.

 

I've noticed that dvb-usb-it9135-01.fw firmware was loaded in both cases, which is contrary to what is stated in http://www.linuxtv.o....php/ITE_IT9135 (dvb-usb-it9135-02.fw should be used in the second case). Actually, when I switched to a service on Evolve Venus stick, the enigma2 hung after a few second of playing a channel (and tv screen went black at the same time).



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #3 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 18:37

...continued (I couldn't edit previous message).

 

 

I've noticed that DVB-T USB related entries in /proc/bus/nim_sockets do not have I2C_Device (if it tells you anything, I do not know what that means). Below is the /proc/bus/nim_sockets (Evolve Venus); in case you find it useful. After enigma2 restart the file is not changed (but USB tuners are reported as DVB-C).

NIM Socket 0:
        Type: DVB-S2
        Name: Vuplus DVB-S NIM(AVL6222)
        Frontend_Device: 0
        I2C_Device: 2
NIM Socket 1:
        Type: DVB-S2
        Name: Vuplus DVB-S NIM(AVL6222)
        Frontend_Device: 1
        I2C_Device: 2
NIM Socket 2:
        Type: DVB-T
        Name: Vuplus DVB-T NIM(CXD1978)
        Mode 0: DVB-C
        Mode 1: DVB-T
        Frontend_Device: 2
        I2C_Device: 3


NIM Socket 3:
        Type: DVB-T
        Name: DVB-T TV Stick
        Frontend_Device: 3
NIM Socket 4:
        Type: DVB-T
        Name: DVB-T TV Stick
        Frontend_Device: 4

 

If you need some other feedback, please let me know, I will be eager to help you with fixing it913x DVB-T USB tuners an have them working on Vu+ Duo2.

 

Regards.



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #4 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 18:56

Maybe we should try this?

https://github.com/o...876812f2e2c1922
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #5 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 19:18

Thank you for your answer but no luck with the patch.

 

I've applied a patch but now enigma2 crashes. See log attached.

Attached Files



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #6 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 19:38

How did you change it?
-        types = [type for type in ["DVB-T2", "DVB-T", "DVB-C", "DVB-S2", "DVB-S", "ATSC"] if eDVBResourceManager.getInstance().frontendIsCompatible(slot.frontend_id, type)]
+        types = [type for type in ["DVB-C", "DVB-T2", "DVB-T", "DVB-S2", "DVB-S", "ATSC"] if eDVBResourceManager.getInstance().frontendIsCompatible(slot.frontend_id, type)]

...
-        split = line.split(": ")
+        split = line.split(":")

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #7 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 19:45

My first try was both changes, then only line 151 and then enigma2 was not crashing.

 

I've applied half a patch, line 151 only (types in different order). I tired many other combinations as well. Depending on the element order, my DVB-T USB stick was 'DVB-S2' or 'DVB-C' (whichever came first)  but NEVER 'DVB-T'.

 

I was testing after 'init 4' with '/usr/bin/enigma2' and I noticed that 'NIM Socket 3' and 'NIM Socket 4' are not present in the '/proc/bus/nim_sockets when enigma2 is not running (sockets 0 through 2 are always present). After enigma2 restart, socket 3 & 4 entries are recreated correctly though.


Edited by macnuts, 13 December 2013 - 19:46.


Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #8 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 19:57

You are right the split(":") is not good...
>>> "Mode 0: DVB-T".split(":")
['Mode 0', ' DVB-T']
Although change order you are getting different tuner type (sometimes DVB-S2 and other DVB-C)?

Maybe you can add some print in NimManager and see if tuners are parsed correctly.

Edited by athoik, 13 December 2013 - 19:57.

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #9 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 20:12

I do not know what to print actually.

 

Yesterday I played with NimManager.py, it was with Cabletech URZ0085 connected, I do not remember the details, but I think I removed DVB-C from compatible list (or some other list). Then, the stick was reported as DVB-T but it was never chosen to 'play' DVB-T service, it was acting as if it was still treated as DVB-C (or non-DVB-T at least) when it went to display DVB-T service.

I think frontendIsCompatible takes wrong assumptions about it9135 (and so some other functions maybe).



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #10 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 20:19

You can add this debug line:
+print "XXXXX IS frontend %s DVB-T compartible == %s" % (str(slot.frontend_id), str(eDVBResourceManager.getInstance().frontendIsCompatible(slot.frontend_id, "DVB-T"))
types = [type for type in ["DVB-T2", "DVB-T", "DVB-C", "DVB-S2", "DVB-S", "ATSC"] if eDVBResourceManager.getInstance().frontendIsCompatible(slot.frontend_id, type)]

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #11 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 21:01

I added checks for all types. According to log DVB-T usb tuners are DVB-C and DVB-S/S2 compatible only! Which is totally wrong. 

[macnuts] IS frontend 0 DVB-T2    compartible == False
[macnuts] IS frontend 0 DVB-T     compartible == False
[macnuts] IS frontend 0 DVB-C     compartible == False
[macnuts] IS frontend 0 DVB-S2    compartible == True
[macnuts] IS frontend 0 DVB-S     compartible == True
[macnuts] IS frontend 0 DVB-ATSC  compartible == False
[macnuts] IS frontend 1 DVB-T2    compartible == False
[macnuts] IS frontend 1 DVB-T     compartible == False
[macnuts] IS frontend 1 DVB-C     compartible == False
[macnuts] IS frontend 1 DVB-S2    compartible == True
[macnuts] IS frontend 1 DVB-S     compartible == True
[macnuts] IS frontend 1 DVB-ATSC  compartible == False
[macnuts] IS frontend 2 DVB-T2    compartible == True
[macnuts] IS frontend 2 DVB-T     compartible == True
[macnuts] IS frontend 2 DVB-C     compartible == False
[macnuts] IS frontend 2 DVB-S2    compartible == False
[macnuts] IS frontend 2 DVB-S     compartible == False
[macnuts] IS frontend 2 DVB-ATSC  compartible == False
[macnuts] IS frontend 3 DVB-T2    compartible == False
[macnuts] IS frontend 3 DVB-T     compartible == False
[macnuts] IS frontend 3 DVB-C     compartible == True
[macnuts] IS frontend 3 DVB-S2    compartible == True
[macnuts] IS frontend 3 DVB-S     compartible == True
[macnuts] IS frontend 3 DVB-ATSC  compartible == False
[macnuts] IS frontend 4 DVB-T2    compartible == False
[macnuts] IS frontend 4 DVB-T     compartible == False
[macnuts] IS frontend 4 DVB-C     compartible == True
[macnuts] IS frontend 4 DVB-S2    compartible == True
[macnuts] IS frontend 4 DVB-S     compartible == True
[macnuts] IS frontend 4 DVB-ATSC  compartible == False
 

 

Just above those lines however:

setSlotInfo for dvb frontend 0 to slotid 0, descr Vuplus DVB-S NIM(AVL6222), need rotorworkaround No, enabled Yes, DVB-S2 Yes
setSlotInfo for dvb frontend 1 to slotid 1, descr Vuplus DVB-S NIM(AVL6222), need rotorworkaround No, enabled Yes, DVB-S2 Yes
setSlotInfo for dvb frontend 2 to slotid 2, descr Vuplus DVB-T NIM(CXD1978), need rotorworkaround No, enabled Yes, DVB-S2 No
setSlotInfo for dvb frontend 3 to slotid 3, descr DVB-T TV Stick, need rotorworkaround No, enabled No, DVB-S2 No
setSlotInfo for dvb frontend 4 to slotid 4, descr DVB-T TV Stick, need rotorworkaround No, enabled No, DVB-S2 No 
 

 

That is also strange:

Input device "ITE Technologies, Inc. DVB-T TV Stick" is a remotecontrol

 

Enigma2 starting log is attached (tuners were reported as DVB-C).

 

Let me say that again, tuners are reported ok on wake from deep standby, the problem is when restarting enigma2.

Attached Files


Edited by macnuts, 13 December 2013 - 21:05.


Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #12 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 21:45

Ok lets assume that problem is in the frontendIsCompatible function ...
http://sourceforge.net/p/openpli/enigma2/ci/master/tree/lib/dvb/dvb.cpp#l739

bool eDVBResourceManager::frontendIsCompatible(int index, const char *type)
{
        for (eSmartPtrList<eDVBRegisteredFrontend>::iterator i(m_frontend.begin()); i != m_frontend.end(); ++i)
        {
                if (i->m_frontend->getSlotID() == index)
                {
                        if (!strcmp(type, "DVB-S2"))
                        {
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBS2, false);
                        }
                        else if (!strcmp(type, "DVB-S"))
                        {
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBS, false);
                        }
                        else if (!strcmp(type, "DVB-T2"))
                        {
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBT2, false);
                        }
                        else if (!strcmp(type, "DVB-T"))
                        {
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBT, false);
                        }
                        else if (!strcmp(type, "DVB-C"))
                        {
#if DVB_API_VERSION > 5 || DVB_API_VERSION == 5 && DVB_API_VERSION_MINOR >= 6
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBC_ANNEX_A, false) || i->m_frontend->supportsDeliverySystem(SYS_DVBC_ANNEX_C, false);
#else
                                return i->m_frontend->supportsDeliverySystem(SYS_DVBC_ANNEX_AC, false);
#endif
                        }
                        else if (!strcmp(type, "ATSC"))
                        {
                                return i->m_frontend->supportsDeliverySystem(SYS_ATSC, false) || i->m_frontend->supportsDeliverySystem(SYS_DVBC_ANNEX_B, false);
                        }
                        break;
                }
        }
        return false;
}
The True/False comes from supportsDeliverySystem...
http://sourceforge.net/p/openpli/enigma2/ci/master/tree/lib/dvb/frontend.cpp#l2357

bool eDVBFrontend::supportsDeliverySystem(const fe_delivery_system_t &sys, bool obeywhitelist)
{
        std::map<fe_delivery_system_t, bool>::iterator it = m_delsys.find(sys);
        if (it != m_delsys.end() && it->second)
        {
                if (obeywhitelist && !m_delsys_whitelist.empty())
                {
                        it = m_delsys_whitelist.find(sys);
                        if (it == m_delsys_whitelist.end() || !it->second) return false;
                }
                return true;
        }
        return false;
}
So i guess something can be wrong there, putting eDebug can help but you need to compile enigma your self (because it is in C++ code).

Edited by athoik, 13 December 2013 - 21:45.

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #13 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 21:54

I can compile openpli, no problem. I have a Linux set up properly, I know C/C++, git and how to build an image without changes. What I do not know is how to add patches (all that bitbake stuff).

 

If you can tell me how to create and apply patches in a way that they survive an image building, I am happy to test further. 



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #14 athoik

  • PLi® Core member
  • 8,395 posts

+321
Excellent

Posted 13 December 2013 - 22:07

This is more or less what i do to test an enigma2 patch:

1. I create the patch and i am copying the patch into sources folder (eg 0001-testXYZ.patch).

2. Create a file named enigma2.bbappend and place it on the same folder where enigma2.bb resides (or here meta-local/recipes-local/images/ will work too)

enigma2.bbappend should contain the following:
PRINC = "1"
SRC_URI += "file://0001-testXYZ.patch"
3. Every time i am making changes to 0001-testXZY.patch i am increasing PRINC by one and trying again. It is obvious that patch is copied on sources folder every time

4. When build success i am getting enigma ipk from build/tmp/deploy/ipk/MACHINE/enigma2_xxxx.ipk and i am testing.

Good luck ;)

PS. When making changes on existing files its ok to issue the command git diff > TestXYZ.patch to quickly create a patch.

PPS. Bitbake will complaing that patch is not found in expected folder but it works.

Edited by athoik, 13 December 2013 - 22:08.

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #15 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 13 December 2013 - 22:16

Thank you. I will test it tomorrow it and let you know about my findings.



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #16 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 14 December 2013 - 21:58

Most likely, the kernel is too old to have proper delsys support?
(which box are you using, with which kernel version?)

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #17 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 14 December 2013 - 22:06

Vu+ Duo2, kernel is 3.3.8-2.0; openpli4 build from upstream now; it was regular openpli4 for vu+duo2 before.



Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #18 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 14 December 2013 - 22:07

Why aren't you using regular openpli4 anymore?
We've just updated it to the latest oe-core heads.

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #19 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 14 December 2013 - 22:08

(though this won't affect this issue I think. Most likely the dvb api version in 3.3.8 does not have full delsys support)

Re: it913x USB DVB-T tuner reported as DVB-C after GUI restart #20 macnuts

  • Senior Member
  • 420 posts

+14
Neutral

Posted 14 December 2013 - 22:19

pieterg, on 14 Dec 2013 - 22:06, said:

Why aren't you using regular openpli4 anymore?
We've just updated it to the latest oe-core heads.

 I just want to put some more debugging info.

 

I have yet another problem which I must solve first. That is images from 02.12.2013 for duo2 do not start when it9135 tuner is plugged in. This information comes from http://openpli.org/f...o2/#entry391507

For now I now that the device is started ok, but then an exception occurs in NimManager.py line 163:

 

 

types.remove("DVB-S")ValueError: list.remove(x): x not in list
 

 

It is strange as it happens only when usb dvb-t is plugged, but the error refers to frontend0 which is dvb-s2 dual card (single card with 2 dvb-s2 tuners).







Also tagged with one or more of these keywords: OpenPLi4, it913x, Vu+ Duo2

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users