PVR250 MCE with cxm driver under 6.0
Dylan Reid
dgreid at gmail.com
Wed Nov 9 05:27:05 GMT 2005
I have been trying to set up mythtv on FreeBSD 6.0 with an amd64 system.
First thing was to get the capture card to work. I first applied patches for
ports/85433 and ports/87518. This got me compiling. In order to get the
module to load, I had to ignore the missing IR receiver.
Next I wanted to use composite input, so I had to change which mode the
saa7115 was configured to when the composite input was selected. I could not
find a good way to determine dynamically if the card is an MCE or not. I did
not look into this too hard however. So i just went with the easiest
possible change. I did notice the Linux ivtv driver does not know the
difference.
Below are the patches I made in case anyone else wants to use the cxm driver
with a 250 MCE.
-Dylan
--- cxm.c.orig Wed Nov 9 04:42:14 2005
+++ cxm.c Wed Nov 9 04:51:56 2005
@@ -1762,8 +1762,10 @@
*/
if (cxm_ir_init(sc) < 0) {
device_printf(dev, "could not initialize IR remote\n");
+#ifndef PVR250_MCE
error = ENXIO;
goto fail;
+#endif
}
sc->dec_mbx = -1;
--- cxm.h.orig Wed Nov 9 04:59:32 2005
+++ cxm.h Wed Nov 9 05:00:13 2005
@@ -41,6 +41,8 @@
#define NUM_ELEMENTS(array) (sizeof(array) / sizeof(*array))
+#define PVR250_MCE // define for media center edition
+
/*
* For simplicity several large buffers allocate during
* driver attachment which normally occurs early on
--- cxm_video.c.orig Wed Nov 9 04:44:24 2005
+++ cxm_video.c Wed Nov 9 05:21:44 2005
@@ -147,6 +147,21 @@
}
};
+#ifdef PVR250_MCE
+static struct cxm_saa7115_command
+saa7115_select_line_in_composite = {
+ 3,
+ {
+ /* Amp plus anti-alias filter, CVBS from AI24 */
+ { 0x02, 1, { 0xc5 } },
+ /* Adaptive luminance comb filter */
+ { 0x09, 1, { 0x40 } },
+
+ /* Enable AD2, audio clock, scaler, decoder */
+ { 0x88, 1, { 0xb0 } }
+ }
+};
+#else
static struct cxm_saa7115_command
saa7115_select_line_in_composite = {
3,
@@ -160,6 +175,7 @@
{ 0x88, 1, { 0x70 } }
}
};
+#endif
static struct cxm_saa7115_command
saa7115_select_line_in_svideo = {
More information about the freebsd-multimedia
mailing list