X-Git-Url: http://code.vuplus.com/gitweb/?p=vuplus_openvuplus_3.0;a=blobdiff_plain;f=meta-openvuplus%2Frecipes-vuplus%2Faio-grab%2Faio-grab%2Faio-grab_vuplus_8394e1ba98c73d7c56d3235ef16cce253dc597cd.patch;h=ace4dbe07a93a591edbf3a4b2e741888c6aa4ea0;hp=b984de8a6440b6e766a399965c4760320988e403;hb=0d6acda3c9daf671af6c3a8e02270bae96286cd6;hpb=5a2998f220be01927c231fee1c9f2a6c6300ce7a diff --git a/meta-openvuplus/recipes-vuplus/aio-grab/aio-grab/aio-grab_vuplus_8394e1ba98c73d7c56d3235ef16cce253dc597cd.patch b/meta-openvuplus/recipes-vuplus/aio-grab/aio-grab/aio-grab_vuplus_8394e1ba98c73d7c56d3235ef16cce253dc597cd.patch index b984de8..ace4dbe 100644 --- a/meta-openvuplus/recipes-vuplus/aio-grab/aio-grab/aio-grab_vuplus_8394e1ba98c73d7c56d3235ef16cce253dc597cd.patch +++ b/meta-openvuplus/recipes-vuplus/aio-grab/aio-grab/aio-grab_vuplus_8394e1ba98c73d7c56d3235ef16cce253dc597cd.patch @@ -8,7 +8,7 @@ index ccfb515..a6f8d11 100644 stamp-h1 +aio-grab_vuplus_* diff --git a/main.c b/main.c -index 190ff5f..dd22bc4 100644 +index 190ff5f..ef186a8 100644 --- a/main.c +++ b/main.c @@ -1,5 +1,5 @@ @@ -33,7 +33,7 @@ index 190ff5f..dd22bc4 100644 +#define IS_VUPLUS 1 +#if IS_VUPLUS +enum {UNKNOWN,PALLAS,VULCAN,XILLEON,BRCM7401,BRCM7400,BRCM7405,BRCM7335,BRCM7325,BRCM7346,BRCM7425}; -+char *stb_name[]={"unknown","Pallas","Vulcan","Xilleon","Brcm7401","Brcm7400","Brcm7405","Brcm7335","Brcm7325","Brcm7346","Brcm7425"}; ++char *stb_name[]={"unknown","Pallas","Vulcan","Xilleon","Brcm7401","Brcm7400","Brcm7405","Brcm7335","Brcm7325","Brcm7346","Brcm7425\/7241"}; +#else enum {UNKNOWN,PALLAS,VULCAN,XILLEON,BRCM7401,BRCM7400,BRCM7405}; static const char *stb_name[]={"unknown","Pallas","Vulcan","Xilleon","Brcm7401","Brcm7400","Brcm7405"}; @@ -63,7 +63,7 @@ index 190ff5f..dd22bc4 100644 unsigned int xres_v = 0,yres_v = 0,xres_o,yres_o,xres,yres,aspect,width; int c,osd_only,video_only,use_osd_res,use_png,use_jpg,jpg_quality,no_aspect,use_letterbox; -@@ -205,11 +219,29 @@ int main(int argc, char **argv) { +@@ -205,11 +219,31 @@ int main(int argc, char **argv) { char filename[256] = { "/tmp/screenshot.bmp" }; // detect STB @@ -90,11 +90,13 @@ index 190ff5f..dd22bc4 100644 + stb_type=BRCM7425; + else if (strstr(upcase(line),"7425")) + stb_type=BRCM7425; ++ else if (strstr(upcase(line),"7241")) ++ stb_type=BRCM7425; +#else line = file_getline("/proc/stb/info/model"); if (line == NULL) return 1; -@@ -221,6 +253,7 @@ int main(int argc, char **argv) { +@@ -221,6 +255,7 @@ int main(int argc, char **argv) { !strcmp(line, "dm800se") || !strcmp(line, "dm7020hd")) stb_type = BRCM7405; @@ -102,7 +104,7 @@ index 190ff5f..dd22bc4 100644 } else if (strstr(line, "xilleonfb")) { stb_type = XILLEON; } else if (strstr(line, "Pallas FB")) { -@@ -563,16 +596,34 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -563,16 +598,34 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre perror("/dev/mem"); return false; } @@ -139,7 +141,7 @@ index 190ff5f..dd22bc4 100644 unsigned char data[100]; unsigned int adr,adr2,ofs,ofs2,offset/*,vert_start,vert_end*/; -@@ -582,12 +633,30 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -582,12 +635,30 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre memcpy(data,memory,100); //vert_start=data[0x1B]<<8|data[0x1A]; //vert_end=data[0x19]<<8|data[0x18]; @@ -170,7 +172,7 @@ index 190ff5f..dd22bc4 100644 munmap(memory, 100); -@@ -609,7 +678,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -609,7 +680,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre assert(chroma); // grabbing luma & chroma plane from the decoder memory @@ -182,7 +184,7 @@ index 190ff5f..dd22bc4 100644 // on dm800/dm500hd we have direct access to the decoder memory memory = mmap(0, offset + stride*(ofs2+64), PROT_READ, MAP_SHARED, mem_fd, adr); if (memory == MAP_FAILED) { -@@ -620,7 +693,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -620,7 +695,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre usleep(50000); // we try to get a full picture, its not possible to get a sync from the decoder so we use a delay // and hope we get a good timing. dont ask me why, but every DM800 i tested so far produced a good // result with a 50ms delay @@ -194,7 +196,7 @@ index 190ff5f..dd22bc4 100644 // on dm8000 we have to use dma, so dont change anything here until you really know what you are doing ! unsigned int i = 0; -@@ -639,7 +716,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -639,7 +718,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre } volatile unsigned long *mem_dma; @@ -206,7 +208,7 @@ index 190ff5f..dd22bc4 100644 if (mem_dma == MAP_FAILED) { perror("mmap"); return false; -@@ -675,8 +756,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -675,8 +758,11 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre unsigned int t = 0, t2 = 0, dat1 = 0; unsigned int chr_luma_stride = 0x40; unsigned int sw; @@ -219,7 +221,7 @@ index 190ff5f..dd22bc4 100644 chr_luma_stride *= 2; xsub=chr_luma_stride; -@@ -710,10 +794,17 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre +@@ -710,10 +796,17 @@ static bool getvideo(unsigned char *video, unsigned int *xres, unsigned int *yre dat1+=stride; } }