• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » OMAP™ Applications Processors » OMAP 4 Forum » How to connect 8-bit data interface of camera module to OMAP4460 CPI interface
Share
OMAP™ Applications Processors
  • Forums
Options
  • Subscribe via RSS

Forums

How to connect 8-bit data interface of camera module to OMAP4460 CPI interface

This question is answered
wells zhu
Posted by wells zhu
on Apr 26 2012 21:18 PM
Prodigy235 points

Dear expert,

Our product have two cameras, one is low resolution for front facing, another is high resolution for back facing. As we know, parallel interface is familiar for low resolution camera module.

The low resolution camera has 8-bit or 10-bit parallel interface named Y0~Y7 or Y0~Y9. How  do these signals connect to CPI interface (cam2_d0~ d15) of  OMAP4460?

Camera module Y0 <-> OMAP4460 cam2_dxx

Camera module Y1 <-> OMAP4460 cam2_dxx

...

Camera module Y9 <-> OMAP4460 cam2_dxx

Best regards,

wells

Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Venkat Ramana Peddigari
    Posted by Venkat Ramana Peddigari
    on Apr 27 2012 06:32 AM
    Expert4080 points

    Hi Wells,

    You can refer to the OMAP4460 TRM at http://www.ti.com/general/docs/wtbu/wtbudocumentcenter.tsp?templateId=6123&navigationId=12037 for further details on the cam2_d0~d15 in regards to their pad configurations. You can refer to in particular to Table 18.10 Device Core Control Module Pad Configuration Register Fields under Control Module Functional Description section.

    You can observe that when these cam2_dxx pins are muxed with the CSI2 pins and few of Key Pad Pins. You can look at the above Table for making appropriate assignment as per your needs.

    Thanks & Best Regards,

    Venkat

    Please click the Verify Answer button on this post if it answers your question
    _____________________________________________

    Be sure to read the OMAP4 Forum Guidelines & FAQ-

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • wells zhu
    Posted by wells zhu
    on Apr 27 2012 11:41 AM
    Prodigy235 points

    Hi Venkat,

    First thank you for your kind reply. But I still can not find the answer to my question.

    In the TRM, I can find the description of CPI pad configurations. But I can not find the real connection description between camera parallel data port and OMAP4460 CPI port.

    If the interface of camera module is 8-bit parallel interface named cam_d[7:0], how does cam_d[7:0] connect to OMAP4460 CPI cam2_d[15:0]? similarly, how about 10-bit parallel interface?

    Best regards

    wells

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Mayank Mangla
    Posted by Mayank Mangla
    on Apr 30 2012 10:46 AM
    Expert3845 points

    Can you please help us understand the scope of the work? I hope you realize that TI provides no software support for parallel camera interface. We can help you with hardware related questions, but you will have to develop the driver from scratch.

    ------------------------------------------------------------------------------------------------------------------

    Please click the Verify Answer button on this post if it answers your question.
    ------------------------------------------------------------------------------------------------------------------

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on Apr 30 2012 12:23 PM
    Intellectual630 points

    Hello

    Please do not paint the picture in dark colors :)

    If he wants to get only 8-bit data without any other ISP functionality he can write driver by himself. All that he have to do is to read TRM carefully.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • wells zhu
    Posted by wells zhu
    on May 07 2012 08:11 AM
    Prodigy235 points

    Dear Experts,

    I think what I ask is hardware related question. I can understand that TI don't support the software of CPI interface.
    But for front facing, the low resolution camera is enough. And for low resolution camera module, parallel port is much popular.
    So our company will develop the software of CPI interface by ourselves.

    I want to connect camera sensor OV7690 to CPI interface of OMAP4460. The output format of OV7690 is 8-bit YUV422/YCbCr422/RGB565/CCIR656/raw RGB data. The signal of OV7690 digital video port is DATA0~DATA7.
    If the MSB bit of OV7690 digital video port is DATA7, then what is the MSB bit of OMAP4460 CPI interface?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on May 07 2012 23:45 PM
    Verified Answer
    Verified by wells zhu
    Intellectual630 points

    Hello.

    It depends on what you wan to get :)

    If you connect your 8-bit sensor interface to cam2_d0...cam2_d7 you will get usual 1 byte video data. If you want something other you may connect sensors MSB to other higher bits of CPI.

    All this thing wrapped by ISP settings. Please read TRM carefully and you'll find the answer for most of your questions.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • wells zhu
    Posted by wells zhu
    on May 10 2012 10:11 AM
    Prodigy235 points

    Hi Egor,

    I read TRM again, but can not find the answer.

    Can you show me the related ISP setting register and description?

    I learn that you got CPI working on Variscite DVK.

    Can you share some document about it?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on May 11 2012 09:25 AM
    Intellectual630 points

    In short to make CPI support is easy enough:

    1. read TRM - to understand ISS and ISP

    2. read OMAP4 ISS opensource driver - to understand how you can control ISP (whithout this some parts of TRM confuse my understanding :) )

    i made driver not V4L as i spent match time to understand 2 things: V4L and ISS...so i decided to move one of them :)

    driver just alloc dma memory, mmap it to user space, and set up ISS ans ISP...thats all

    I use the following path for video data: ISS VP -> IPIPEIF ->ISIF -> Memory.

    So i switched off all IPIPEIF and ISIF submodules and got an image.

    WBR,

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Krisztián KAUTH
    Posted by Krisztián KAUTH
    on Oct 04 2012 02:45 AM
    Prodigy110 points

    Hello,

    Could this path: CPI -> VP -> IPIPEIF -> ISIF -> memory also work when output buffer is in shared region w/out any DMA configured?

    I am trying it on TI 8127 / 8147 / 8148 so board is different, but main question regarding data flow in ISS should be almost the same.

    PRCM registers, ISS_CTRL and ISS_CLKCTRL are set up,  image size related parameters are given, external write (SWEN: ISIF_MODESET bit5 = 1)  and immediate write of registers (ISIF_CCDCFG = 0x8000) enabled, storage of image in memory is enabled (ISIF_SYNCEN = 2; // bit1: DWEN), CADU and CADL are filled with adress pointing into SR1, sync enabled (ISIF_SYNCEN = 3; // bit0: SYEN).

    What could be wrong? I tried with PG input too, but I don't know if I have problem with input or output configuration. 

    Regards 

    Krisztián 

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on Oct 04 2012 04:14 AM
    Intellectual630 points

    Hi.

    I didn't make any espiciall DMA settings. I alloc CMA buffer and set up pointer to it on ISIF settings.

    WBR,

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Krisztián KAUTH
    Posted by Krisztián KAUTH
    on Oct 08 2012 02:38 AM
    Prodigy110 points

    Hello Egor,

    thank You for the swift answer! Meanwhile it has turned out that there are obvious problems with the input: no HS_VS_IRQ at all. :-\

    Any ideas what could be the root cause here? Could it be exclusively hw (wiring, pinmux?) or something with ISS input interface configuration?

    Regards
    Krisztián 

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on Oct 08 2012 03:22 AM
    Intellectual630 points

    Hi.

    I also have same problems in early stage. The reason can be any thing like: incorrect ISS settings or IPIPE/ISIF settings. As i made this driver in April i do not remember exaclty all problems and detailt of develop process...sorry.

    Check all setting with TRM again....i'm regular user...so i also had only TRM whithout any magic information about CPI in OM4460. All TI's people told that this interface doesn't support....so i read TRM that's all.

    But next week i'll have to add new sensor to my driver ( with YUV output )...so may be i can answer to you more correctly.

    WBR,

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Krisztián KAUTH
    Posted by Krisztián KAUTH
    on Oct 08 2012 06:05 AM
    Prodigy110 points

    Hi Egor,

    Do You have any hints which 'modules' to program at all and in which order?

    Now I keep trying with following sequence:
    0. image sensor PLL and reasonable gain / exp
    1. PRCM for ISP
    2. CSI2 and SC reset 
    3. ISS / ISP5 CTRL, CLKCTRL and SYSCONF registers
    (4. PG - selected if my config with VP input fails)
    5. ISIF
    6. IPIPEIF - not even enabled at this time
    7. IPIPE
    8. RSZ

    I followed Programming Model subchapters of each modules from 4 to 8. I did not subsribed to interrupts at this stage. I just want the device to put something in the shared memory area..

    May I add to my friends on E2E? 

    Krisztián

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Egor Rumjantsev
    Posted by Egor Rumjantsev
    on Oct 08 2012 07:16 AM
    Intellectual630 points

    I programmed IPIPEIF and ISIF. I didn't  use PG, RESIZER and IPIPE.

    this is my init sequence:

     if(!VALID_DEVICE(dev))
                    return (-ENODEV);
            
            //prepare register links
            dev->ipipeif.regs_sys1 = dev->regs[OMAP4_ISS_MEM_ISP_SYS1];
            dev->ipipeif.regs_isif = dev->regs[OMAP4_ISS_MEM_ISP_ISIF];
            dev->ipipeif.regs_ipipeif = dev->regs[OMAP4_ISS_MEM_ISP_IPIPEIF];

            //wait until ISP in reset
            while(--timeout > 0)
            {
                    //read SOFTRESET bit
                    val = readl(dev->regs[OMAP4_ISS_MEM_ISP_SYS1] + ISS_HL_SYSCONFIG );
                    deb(0, "ISS ISP state: 0x%.8lX", val);
                    if( !(val & 0x02) )
                            break;
            
                    msleep(500);
            }

            if(!timeout)
            {
                    deb(0, "Timeout expired while waiting ISS ISP reset finished");
                    return (-EBUSY);
            }

            val = readl(dev->regs[OMAP4_ISS_MEM_TOP] + ISS_PM_STATUS );
            deb(0, "ISS PMSTATUS: 0x%.8lX", val);


            //configure PHY level (OMAP4_CTRL_MODULE_PAD_CORE_CONTROL_CAMERA_RX reg)
            ret = omap4iss_cpiphy_config( dev );
            if(SUCCESS != ret)
            {
                    deb(0, "Failed to config CPI PHY: %d", ret);
                    return ret;
            }
            
            //configure bridge to CPI VP (ISS level ISP5_CTRL reg)
            omap4iss_configure_bridge( dev );

            val = readl(dev->regs[OMAP4_ISS_MEM_ISP_SYS1] + ISP5_CTRL_REG );
            deb(0, "ISS ISP5_CTRL: 0x%.8lX", val);
            val = readl( dev->regs[OMAP4_ISS_MEM_ISP_SYS1] + ISP5_IRQSTATUS_RAW_REG(0) );
            deb(0, "ISS ISP5_IRQSTATUS_RAW0: 0x%.8lX", val);
            val = readl(dev->regs[OMAP4_ISS_MEM_ISP_SYS1] + ISP5_IRQSTATUS(0));
            deb(0, "ISS ISP5_IRQSTATUS0: 0x%.8lX", val);

            //enable IPIPEIF & ISIF clk's
            omap4iss_isp_subclk_enable(dev, IPIPEIF_DRV_SUBCLK_MASK);
            msleep(1);

            deb(0, "init IPIPEIF");
            ipipeif_apply_ipipeif_cfg( &dev->ipipeif );

            deb(0, "init ISIF");
            ipipeif_apply_isif_cfg( &dev->ipipeif );

            //disable IPIPEIF & ISIF clocks
            omap4iss_isp_subclk_disable(dev, IPIPEIF_DRV_SUBCLK_MASK);

            return SUCCESS;

    Hope this will help.

    WBR,

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • andy Shen
    Posted by andy Shen
    on Jan 01 2013 08:18 AM
    Prodigy20 points

    hi, Egor.

    I'm working on omap4460 and want to make the cpi interface available.  As far as I know, Ti do not support the cpi interface, and I have read all the information you posted  on the forum. But I am still not clear with all the things, So I want to ask you some questions:

    1. you said your cpi driver based on Sergio Aguirre CSI driver, did you mean http://dev.omapzoom.org/?p=saaguirre/linux-omap-camera.git;a=summary ?

    but i t is for omap3iss. If i was wrong, please tell me the right code tree.

    2.Did you have some document or tips about how to make cpi work ? If convenient, can I have a copy of your source code?

    Thank you for you reply.

    4460
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
12
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use