This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Switch #10 of S3 doesn't work

Hi,

   My camera is PAL, so I put on switch #10 of S3 in EVM board (for PAL region), and then I debug "encodedecode" demo in dvevm_1_20 folder.

  In function detectVideoStandard(void), when I run to 

     if (ioctl(fd, FBIO_GETSTD, &std) == -1) {
        ERR("Failed to get video standard from display device driver\n");
        return FAILURE;
    }

    if ((std >> 16) == 0x1) {
        DBG("NTSC selected\n");
        gblSetYFactor(NTSCSTD);
    }
    else {
        DBG("PAL selected\n");
        gblSetYFactor(PALSTD);
    }

 

 

  I find that (std >> 16) is always 0x1, no matter switch #10 is on or off, I don't know whether there is something wrong with my board. (I've tried to reboot my linux and montavista linux.)

 

Thanks. 

  • I am assuming you are working with a DM6446. There is a bit more to setting the board up for PAL than the S3 #10 dip switch, although it may seem that way from glancing over the documentation. This switch actually is just a pin that is checked by U-Boot, and causes U-Boot to set the environment variable 'videostd' to be 'pal' or 'ntsc', which unfortunately is not quite enough to change your standard to PAL on its own, however it does allow you to setup U-Boot options so that the switch does change between PAL and NTSC. Essentially you need to change your 'bootcmd' U-Boot environment variable to contain a reference to 'videostd' so it passes it on to the kernel such that the kernel can recognize if it should be working with NTSC or PAL. Your 'bootcmd' variable should look something like below.

    bootcmd="setenv setboot setenv bootargs \$(bootargs) video=dm64xxfb:output=\$(videostd);run setboot;bootm 0x2050000"

    With 'bootargs' set as something like:

    bootargs="mem=120M console=ttyS0,115200n8 root=/dev/hda1 rw noinitrd ip=dhcp"

    This is actually discussed in section 4.3.6 of the getting started guide which can be found below.

    http://focus.ti.com/lit/ug/sprue66c/sprue66c.pdf