Jump to content


Photo

[ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2)


  • Please log in to reply
28 replies to this topic

#1 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 15 November 2011 - 13:04

Finally yesterday night I managed to fix the PCTV 290e driver in order to make it working also in DVB-T mode (DVB-T2 was already working as discussed in the old thread).

I spent quite a bit of time comparing logs, inserting debug code and dumping registers everywhere in the em28xx and cxd2820r driver modules.

In the end, in DVB-T mode the 290e was not able to acquire the lock on the channel due to timing issues. In fact, increasing the wait time from 50 to 200ms in the tuning loop was enough to get the lock on any channel. But channel change was quite slow and sometimes, doing an automatic scan, a frequency was not scanned properly (again for timing issues). So instead of playing with the timings I changed the condition to exit the wait loop from "HAVE_SIGNAL" to "HAVE_LOCK". I think this was the original intention of the driver author (I've asked his feedback on this point).

With this modification, channel scan is 100% reliable and channel change is really fast.

But there was a further issue: a few weak channels were plagued by high BER and badly corrupted pictures. The same channels were working fine on the A867 stick, so I tried to improve the reception.

I noticed that the driver has an option to enable a "Low Noise Amplifier" (LNA) before the demodulator. This LNA is enabled by default for DVB-T2 and DVB-C, but it was disabled for DVB-T.
So I tried to enable it and the reception of weak channels improved a lot!

I collected some data:

LNA OFF:

MUX AGC BER picture

RAI mux 4 72% 32000 corrupted
TIMB 2 75% 14 OK
TVA Vicenza 68% 32000 corrupted
TV7 77% 0 OK
RETE CAPRI 69% 0 OK <------- QPSK modulation!
RAI mux 2 78% 14 OK

LNA ON:

MUX AGC BER picture

RAI mux 4 73% 1500 OK
TIMB 2 76% 0 OK
TVA Vicenza 69% 0 OK
TV7 78% 0 OK
RETE CAPRI 70% 0 OK <------- QPSK modulation!
RAI mux 2 79% 0 OK


So it's clear that the LNA is very useful also for DVB-T reception and should be enabled by default.

In attachment you can find 3 patches. The first one is a collection of all the changes in the em28xx/cxd2820r/tda18271 drivers from kernel 3.1.0 to the latest linux-media drivers available (due for integration in Linux 3.2.0).
This patch adds also support for the PCTV 460e DVB-S2 USB stick. In fact I was too lazy to cherry-pick only the changes relevant to the PCTV 290e, so I just took all changes related to em28xx and dependent drivers. I have no idea if the driver is working or not since I don't have that stick.
The other 2 patches apply the 2 modifications described above (fixed wait loop exit condition and LNA enabled by default).

I think it's better to keep the 2 extra patches separated for the time being, as I don't know if and when they will be integrated in the kernel. I will propose them to the driver author and on the linux-media mailing list.

I'm also including a zip package with the modified modules already compiled (for ET9000).

Attached Files


Edited by Gennar1, 15 November 2011 - 13:06.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #2 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 15 November 2011 - 23:35

thanks, I'll add them.

I see two new frontends are being introduced.
Do we need autoload/modutils changes for the devices which are using these frontends?

Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #3 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 16 November 2011 - 01:55

Yes, I forgot to mention that the PCTV 460e requires this 2 new modules:

Allegro a8293
NXP tda10071

which are the DVB-S2 tuner and demodulator.
No modutil change is needed, as the em28xx-dvb module will auto-load those modules when needed.

Edited by Gennar1, 16 November 2011 - 01:58.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #4 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 16 November 2011 - 02:04

This is the list of modules you need to install to run the PCTV 290e:
tda18271
cxd2820r
em28xx_dvb
em28xx
v4l2_common
videodev
videobuf_vmalloc
videobuf_core
tveeprom

This should be the list for the PCTV 460e (not tested):
a8293
tda10071
em28xx_dvb
em28xx
v4l2_common
videodev
videobuf_vmalloc
videobuf_core
tveeprom


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #5 gnu_andrew

  • Member
  • 1 posts

0
Neutral

Posted 29 November 2011 - 02:35

Thanks for the loop patch! It was essential in getting DVB-T working here. Only had 4 HD channels on the new tuner prior to that :-(

Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #6 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 16 May 2013 - 14:39

Anyone have tried this on a box with an older kernel, e.g. dm8000 (with 3.2 kernel)?


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #7 reg

  • Senior Member
  • 62 posts

0
Neutral

Posted 31 May 2013 - 23:10

I am using this USB tuner (actually 2 of them) on my DM8000, kernel 3.2.

It is mostly working fine except that:

  • Once every few days I get a tuning failed error on all channels that are using this tuner. I have to reboot the box completely (not just enigma) in order to get it to work again.
  • The tuners are displayed as being DVB-T (instead of DVB-T2) in the tuner settings.

There was some discussion about this a while ago in this thread.

 

Anything else let me know.



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #8 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 2 June 2013 - 14:06

Looks like you are facing the memory fragmentation problem that was solved with this patch a long time ago:

https://linuxtv.org/patch/9875/

If I remember correctly, this patch was merged in kernel 3.3, so you are still having the issue with the 3.2 kernel used by Dreamboxes.



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #9 reg

  • Senior Member
  • 62 posts

0
Neutral

Posted 2 June 2013 - 14:59

Interesting! Is there anything I can do to get this running on my box? Or should I just wait until kernel 3.3 comes to DM8000?



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #10 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 3 June 2013 - 14:24

Interesting! Is there anything I can do to get this running on my box? Or should I just wait until kernel 3.3 comes to DM8000?

Hmmm, I don't know how patient you are? I mean, chances are about 0.0% that any newer kernel will EVER come for the dm8000!


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #11 reg

  • Senior Member
  • 62 posts

0
Neutral

Posted 3 June 2013 - 14:42

I cannot say I'm surprised ;) Anything else I can do (except buying a new box)?

Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #12 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 3 June 2013 - 14:43

Write a letter to DMM ;)


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #13 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 3 June 2013 - 22:44

drivers/media/video/em28xx/em28xx-cards.c | 16 +++-
drivers/media/video/em28xx/em28xx-core.c | 145 +++++++++++++++++++----------
drivers/media/video/em28xx/em28xx-dvb.c | 14 +--
drivers/media/video/em28xx/em28xx-video.c | 10 +-
drivers/media/video/em28xx/em28xx.h | 23 ++++-

 

Those are not drivers from DMM... So writing a patch  for 3.2 kernel is not enough?


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: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #14 littlesat

  • PLi® Core member
  • 57,159 posts

+698
Excellent

Posted 3 June 2013 - 22:47

I think erik meant that dmm should create drivers for a more recent linux kernal so wierd patches if possible at all are not requered at al... So it is working right away....
I suggest dmm is getting ancient regards the drivers kernel background....

Edited by littlesat, 3 June 2013 - 22:48.

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #15 atilaks

  • Senior Member
  • 245 posts

+5
Neutral

Posted 4 June 2013 - 06:54

at least dmm is on 3.2, vu+ duo still runs on 3.1, such a shame...



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #16 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 4 June 2013 - 15:38

I think erik meant that dmm should create drivers for a more recent linux kernal so wierd patches if possible at all are not requered at al... So it is working right away....

 

Yes that would be great, but if you stack with an old kernel, backporting drivers or patching them is the only viable solution.


Edited by athoik, 4 June 2013 - 15:38.

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: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #17 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 5 June 2013 - 08:26

That patch was developed against a 3.1 or 3.2 kernel (I can't remember) so it should apply to the DMM 3.2 kernel without any big problem.

Eventually, you could look into the old repository for the Xtrend 3.1 or 3.2 kernels: I'm sure you can find a ready-to-use patch.



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #18 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 6 June 2013 - 14:17

You mean? The memory fragmentation patch? That would be interesting indeed.


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #19 Gennar1

  • Senior Member
  • 296 posts

+31
Good

Posted 7 June 2013 - 10:23

You mean? The memory fragmentation patch? That would be interesting indeed.

 

Yes.

I found an old archive on my PC with the patches in attachment against a vanilla 3.2 kernel:

patch -p1 < em28xx-reworked-device-probing-to-get-max-dvb-iso-packet-size.patch
patch -p1 < em28xx-pre-allocate-DVB-iso-transfer-buffers.patch
patch -p1 < em28xx-dvb-stop-URBs-when-stopping-the-streaming.patch

You should be able to apply them to the DMM kernel.

Attached Files



Re: [ETxx00] PCTV nanostick T2 290e fully working (DVB-T + DVB-T2) #20 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 7 June 2013 - 11:47

It this patch specific for problems in relation with em28xx (as the name suggest) or generic?

* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.



4 user(s) are reading this topic

0 members, 4 guests, 0 anonymous users