public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [linux-dvb] Problems with new S2API and DVB-T
@ 2008-10-06 12:22 Jose Alberto Reguero
  2008-10-07  1:06 ` Steven Toth
  0 siblings, 1 reply; 4+ messages in thread
From: Jose Alberto Reguero @ 2008-10-06 12:22 UTC (permalink / raw)
  To: linux-dvb

[-- Attachment #1: Type: text/plain, Size: 338 bytes --]

I am trying to use the new API for DVB-T and I have some problems. They are 
not way to set code_rate_HP, code_rate_LP, transmission_mode, and 
guard_interval , and the default values are 0, that are not the AUTO ones.
Also the bandwidth is not treated well. The attached patch is a workaround 
that works for me.

Thanks.
Jose Alberto



[-- Attachment #2: dvb_frontend.diff --]
[-- Type: text/x-patch, Size: 1774 bytes --]

diff -r 979d14edeb2e linux/drivers/media/dvb/dvb-core/dvb_frontend.c
--- a/linux/drivers/media/dvb/dvb-core/dvb_frontend.c	Sat Oct 04 21:37:36 2008 -0300
+++ b/linux/drivers/media/dvb/dvb-core/dvb_frontend.c	Mon Oct 06 14:14:39 2008 +0200
@@ -974,15 +974,7 @@
 		c->delivery_system = SYS_DVBC_ANNEX_AC;
 		break;
 	case FE_OFDM:
-		if (p->u.ofdm.bandwidth == BANDWIDTH_6_MHZ)
-			c->bandwidth_hz = 6000000;
-		else if (p->u.ofdm.bandwidth == BANDWIDTH_7_MHZ)
-			c->bandwidth_hz = 7000000;
-		else if (p->u.ofdm.bandwidth == BANDWIDTH_8_MHZ)
-			c->bandwidth_hz = 8000000;
-		else
-			/* Including BANDWIDTH_AUTO */
-			c->bandwidth_hz = 0;
+		c->bandwidth_hz = p->u.ofdm.bandwidth;
 		c->code_rate_HP = p->u.ofdm.code_rate_HP;
 		c->code_rate_LP = p->u.ofdm.code_rate_LP;
 		c->modulation = p->u.ofdm.constellation;
@@ -1031,19 +1023,12 @@
 		break;
 	case FE_OFDM:
 		printk("%s() Preparing OFDM req\n", __FUNCTION__);
-		if (c->bandwidth_hz == 6000000)
-			p->u.ofdm.bandwidth = BANDWIDTH_6_MHZ;
-		else if (c->bandwidth_hz == 7000000)
-			p->u.ofdm.bandwidth = BANDWIDTH_7_MHZ;
-		else if (c->bandwidth_hz == 8000000)
-			p->u.ofdm.bandwidth = BANDWIDTH_8_MHZ;
-		else
-			p->u.ofdm.bandwidth = BANDWIDTH_AUTO;
-		p->u.ofdm.code_rate_HP = c->code_rate_HP;
-		p->u.ofdm.code_rate_LP = c->code_rate_LP;
+		p->u.ofdm.bandwidth = c->bandwidth_hz;
+		p->u.ofdm.code_rate_HP = FEC_AUTO;
+		p->u.ofdm.code_rate_LP = FEC_AUTO;
 		p->u.ofdm.constellation = c->modulation;
-		p->u.ofdm.transmission_mode = c->transmission_mode;
-		p->u.ofdm.guard_interval = c->guard_interval;
+		p->u.ofdm.transmission_mode = TRANSMISSION_MODE_AUTO;
+		p->u.ofdm.guard_interval = GUARD_INTERVAL_AUTO;
 		p->u.ofdm.hierarchy_information = c->hierarchy;
 		c->delivery_system = SYS_DVBT;
 		break;

[-- Attachment #3: Type: text/plain, Size: 150 bytes --]

_______________________________________________
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-10-07 14:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-06 12:22 [linux-dvb] Problems with new S2API and DVB-T Jose Alberto Reguero
2008-10-07  1:06 ` Steven Toth
2008-10-07  9:34   ` Jose Alberto Reguero
2008-10-07 14:44     ` Steven Toth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox