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.

XAM335x AM335x的区别

Other Parts Discussed in Thread: TPS65217, AM3359, AM3352

我之前用的是XAM335x的芯片,启动linux系统没有一点问题,现在新做的板子是用的AM335x的芯片,原来的移植的系统就不行了,引导不起来了,分析启动日志,

 CCCCCCCC
U-Boot SPL 2011.09 (Oct 09 2012 - 13:14:46)
Texas Instruments Revision detection unimplemented
Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
read_eeprom() failure. continuing with ddr3
Could not probe the EEPROM; something fundamentally wrong on the I2C bus. 
卡到这里,没有扫描mmc没有读uboot.img,
之前用XAM335x芯片时输出是这样的
 U-Boot SPL 2011.09 (Oct 09 2012 - 13:14:46)
Texas Instruments Revision detection unimplemented
Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
read_eeprom() failure. continuing with ddr3
Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
OMAP SD/MMC: 0
reading u-boot.img
reading u-boot.img


U-Boot 2011.09 (Oct 09 2012 - 13:14:46)

I2C:   ready
DRAM:  256 MiB
WARNING: Caches not enabled
Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
NAND:  HW ECC Hamming Code selected
No NAND device found!!!
0 MiB
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
*** Warning - readenv() failed, using default environment 。。。。。。
然后会正常引导系统,我的板子没有EEPROM,所以有以上那个错,但是不影响启动。
请大家指导下,谢谢了
  • XAM335x是工程样片,是提供给早期客户做评估的,我建议你还是查查虚焊什么的硬件问题吧

  • 谢谢您的回答,我知道XAM335x是工程样片,那么请问xAM335x与AM335x都一样吧,我昨天从TI官网下载了最新的关于linux的软件资源,我看是十一月份刚更新的,烧进去结果是一样的。请问xam335x与am335x一样吗???如果一样的话就是硬件问题了,

  • 是一样的,AM335x是正式发布的产品

  • 谢谢,也就是说XAM335x的系统移植到AM335x上是没有问题的。

  • liu,

    这个问题解决了么?看log是没有成功的从SD卡启动,有没有尝试过串口启动?

  • 试过串口,拨码开关设置的是00001,按着网页上的来的,可是下载u-boot-spl.bin和u-boot.img下载不进去,下载进去应该输出这些资料的信息,可是我的下载完只会出CCC,等了好久也是这样,我试过超级终端、Tera Term,而且是按着网页上说的版本,这些是没有问题的。

  • 需要修改u-boot 源代码中/board/ti/am335x/evm.c中的spl_board_init()函数和board_init()函数,去掉对eeprom的依赖性。

  • 您好,按着你上午的提示,在board/ti/am335x中修改evm.c,去掉spl_board_init中的if判断如下:

    void spl_board_init(void)
    {
    uchar pmic_status_reg;

    /* init board_id, configure muxes */
    board_init();

    //if (!strncmp("A335BONE", header.name, 8))
    if(0) {
    /* BeagleBone PMIC Code */
    if (i2c_probe(TPS65217_CHIP_PM))
    return;

    if (tps65217_reg_read(STATUS, &pmic_status_reg))
    return;

    /* Increase USB current limit to 1300mA */
    if (tps65217_reg_write(PROT_LEVEL_NONE, POWER_PATH,
    USB_INPUT_CUR_LIMIT_1300MA,
    USB_INPUT_CUR_LIMIT_MASK))
    printf("tps65217_reg_write failure\n");

    /* Only perform PMIC configurations if board rev > A1 */
    if (!strncmp(header.version, "00A1", 4))
    return;

    /* Set DCDC2 (MPU) voltage to 1.275V */
    if (tps65217_voltage_update(DEFDCDC2,
    DCDC_VOLT_SEL_1275MV)) {
    printf("tps65217_voltage_update failure\n");
    return;
    }

    /* Set LDO3, LDO4 output voltage to 3.3V */
    if (tps65217_reg_write(PROT_LEVEL_2, DEFLS1,
    LDO_VOLTAGE_OUT_3_3, LDO_MASK))
    printf("tps65217_reg_write failure\n");

    if (tps65217_reg_write(PROT_LEVEL_2, DEFLS2,
    LDO_VOLTAGE_OUT_3_3, LDO_MASK))
    printf("tps65217_reg_write failure\n");

    if (!(pmic_status_reg & PWR_SRC_AC_BITMASK)) {
    printf("No AC power, disabling frequency switch\n");
    return;
    }

    /* Set MPU Frequency to 720MHz */
    mpu_pll_config(MPUPLL_M_720);

    else 
    {
    uchar buf[4];
    /*
    * EVM PMIC code. All boards currently want an MPU voltage
    * of 1.2625V and CORE voltage of 1.1375V to operate at
    * 720MHz.
    */
    if (i2c_probe(PMIC_CTRL_I2C_ADDR))
    return;

    /* VDD1/2 voltage selection register access by control i/f */
    if (i2c_read(PMIC_CTRL_I2C_ADDR, PMIC_DEVCTRL_REG, 1, buf, 1))
    return;

    buf[0] |= PMIC_DEVCTRL_REG_SR_CTL_I2C_SEL_CTL_I2C;

    if (i2c_write(PMIC_CTRL_I2C_ADDR, PMIC_DEVCTRL_REG, 1, buf, 1))
    return;

    if (!voltage_update(MPU, PMIC_OP_REG_SEL_1_2_6) &&
    !voltage_update(CORE, PMIC_OP_REG_SEL_1_1_3))
    /* Frequency switching for OPP 120 */
    mpu_pll_config(MPUPLL_M_720);
    }
    }
    #endif

    试了试不行,又修改board_init如下:

    int board_init(void)
    {
    /* Configure the i2c0 pin mux */
    enable_i2c0_pin_mux();

    i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);

    if (read_eeprom())
    goto err_out;

    detect_daughter_board();

    //if (!strncmp("SKU#01", header.config, 6)) {
    // board_id = GP_BOARD;
    // detect_daughter_board_profile();
    //} else if (!strncmp("SKU#02", header.config, 6)) {
    // board_id = IA_BOARD;
    // detect_daughter_board_profile();
    //} else if (!strncmp("SKU#03", header.config, 6)) {
    // board_id = IPP_BOARD;
    //} else if (!strncmp("A335BONE", header.name, 8)) {
    // board_id = BONE_BOARD;
    // profile = 1; /* profile 0 is internally considered as 1 */
    // daughter_board_connected = 0;
    //} else if (!strncmp("A335X_SK", header.name, 8)) {
    // board_id = SK_BOARD;
    // profile = 1; /* profile 0 is internally considered as 1 */
    // daughter_board_connected = 0;
    //} else {
    // printf("Did not find a recognized configuration, "
    // "assuming General purpose EVM in Profile 0 with "
    // "Daughter board\n");
    board_id = GP_BOARD;
    profile = 1; /* profile 0 is internally considered as 1 */
    daughter_board_connected = 1;
    //}

    configure_evm_pin_mux(board_id, header.version, profile, daughter_board_connected);

    还是不行,那块XAM3359的板子在这两种情况都可以启动,但是AM3359的板子还是启动不了,

    只输出:

    U-Boot SPL 2011.09 (Jan 23 2013 - 12:50:30)
    Texas Instruments Revision detection unimplemented
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    read_eeprom() failure. continuing with ddr3
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.

  • 你在这段代码附近的位置加打印信息定位一下,或者用仿真器跟踪下

  • 您好,我在附近的位置加可写打印信息,这些信息都可以正常输出:

    U-Boot SPL 2011.09 (Jan 24 2013 - 13:32:15)
    Texas Instruments Revision detection unimplemented
    LL:FUNC:i2c_init@evm.cLine:714
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    read_eeprom() failure. continuing with ddr3
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    LL:FUNC:board_init@evm.cLine:859
    LL:FUNC:spl_board_init@evm.c,Line:631
    LL:FUNC:spl_board_init@evm.cLine:640
    LL:FUNC:spl_board_init@evm.cLine:644
    LL:FUNC:spl_board_init@evm.cLine:649
    LL:FUNC:spl_board_init@evm.cLine:655
    MP S/
    M: 0

    有时是输出这种:

    U-Boot SPL 2011.09 (Jan 24 2013 - 13:32:15)
    Texas Instruments Revision detection unimplemented
    LL:FUNC:i2c_init@evm.cLine:714
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    read_eeprom() failure. continuing with ddr3
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    LL:FUNC:board_init@evm.cLine:859
    LL:FUNC:spl_board_init@evm.c,Line:631
    LL:FUNC:spl_board_init@evm.cLine:640
    LL:FUNC:spl_board_init@evm.cLine:644
    LL:FUNC:spl_board_init@evm.cLine:649
    LL:FUNC:spl_board_init@evm.cLine:655
    MP S/
    M: 0
    mmc_init_setup: timedout waiting for cc2!
    spl: mmc init failed: err - -19
    ### ERROR ### Please RESET the board ###

  • 如果没有用到I2C,就把I2C相关的代码都关掉,试一下

  • 我添加的信息如下:

    void spl_board_init(void)
    {
    uchar pmic_status_reg;

    /* init board_id, configure muxes */
    board_init();
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//585
    //if (!strncmp("A335BONE", header.name, 8))
    if(0) {
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//588
    /* BeagleBone PMIC Code */
    if (i2c_probe(TPS65217_CHIP_PM))
    return;

    if (tps65217_reg_read(STATUS, &pmic_status_reg))
    return;

    /* Increase USB current limit to 1300mA */
    if (tps65217_reg_write(PROT_LEVEL_NONE, POWER_PATH,
    USB_INPUT_CUR_LIMIT_1300MA,
    USB_INPUT_CUR_LIMIT_MASK))
    printf("tps65217_reg_write failure\n");

    /* Only perform PMIC configurations if board rev > A1 */
    if (!strncmp(header.version, "00A1", 4))
    return;

    /* Set DCDC2 (MPU) voltage to 1.275V */
    if (tps65217_voltage_update(DEFDCDC2,
    DCDC_VOLT_SEL_1275MV)) {
    printf("tps65217_voltage_update failure\n");
    return;
    }

    /* Set LDO3, LDO4 output voltage to 3.3V */
    if (tps65217_reg_write(PROT_LEVEL_2, DEFLS1,
    LDO_VOLTAGE_OUT_3_3, LDO_MASK))
    printf("tps65217_reg_write failure\n");

    if (tps65217_reg_write(PROT_LEVEL_2, DEFLS2,
    LDO_VOLTAGE_OUT_3_3, LDO_MASK))
    printf("tps65217_reg_write failure\n");

    if (!(pmic_status_reg & PWR_SRC_AC_BITMASK)) {
    printf("No AC power, disabling frequency switch\n");
    return;
    }

    /* Set MPU Frequency to 720MHz */
    mpu_pll_config(MPUPLL_M_720);
    }
    else
    {
    printk("LL:FUNC:spl_board_init@evm.c,Line:%d\n",__LINE__);//632
    uchar buf[4];
    /*
    * EVM PMIC code. All boards currently want an MPU voltage
    * of 1.2625V and CORE voltage of 1.1375V to operate at
    * 720MHz.
    */
    if (i2c_probe(PMIC_CTRL_I2C_ADDR))
    return;
    printk("LL:FUNC:spl_board_init@evm.cLine:%d\n",__LINE__);//641
    /* VDD1/2 voltage selection register access by control i/f */
    if (i2c_read(PMIC_CTRL_I2C_ADDR, PMIC_DEVCTRL_REG, 1, buf, 1))
    return;
    printk("LL:FUNC:spl_board_init@evm.cLine:%d\n",__LINE__);//645
    buf[0] |= PMIC_DEVCTRL_REG_SR_CTL_I2C_SEL_CTL_I2C;

    if (i2c_write(PMIC_CTRL_I2C_ADDR, PMIC_DEVCTRL_REG, 1, buf, 1))
    return;
    printk("LL:FUNC:spl_board_init@evm.cLine:%d\n",__LINE__);//650
    if (!voltage_update(MPU, PMIC_OP_REG_SEL_1_2_6) &&
    !voltage_update(CORE, PMIC_OP_REG_SEL_1_1_3))
    /* Frequency switching for OPP 120 */
    mpu_pll_config(MPUPLL_M_720);
    }
    printk("LL:FUNC:spl_board_init@evm.cLine:%d\n",__LINE__);//656
    }
    #endif

    board_init函数修改如下:

    int board_init(void)
    {
    /* Configure the i2c0 pin mux */
    enable_i2c0_pin_mux();

    i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//808
    if (read_eeprom())
    goto err_out;
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//811
    detect_daughter_board();
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//813
    //if (!strncmp("SKU#01", header.config, 6)) {
    // board_id = GP_BOARD;
    // detect_daughter_board_profile();
    //} else if (!strncmp("SKU#02", header.config, 6)) {
    // board_id = IA_BOARD;
    // detect_daughter_board_profile();
    //} else if (!strncmp("SKU#03", header.config, 6)) {
    // board_id = IPP_BOARD;
    //} else if (!strncmp("A335BONE", header.name, 8)) {
    // board_id = BONE_BOARD;
    // profile = 1; /* profile 0 is internally considered as 1 */
    // daughter_board_connected = 0;
    //} else if (!strncmp("A335X_SK", header.name, 8)) {
    // board_id = SK_BOARD;
    // profile = 1; /* profile 0 is internally considered as 1 */
    // daughter_board_connected = 0;
    //} else {
    // printf("Did not find a recognized configuration, "
    // "assuming General purpose EVM in Profile 0 with "
    // "Daughter board\n");
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//834
    board_id = GP_BOARD;
    profile = 1; /* profile 0 is internally considered as 1 */
    daughter_board_connected = 1;
    //}

    configure_evm_pin_mux(board_id, header.version, profile, daughter_board_connected);

    #ifndef CONFIG_SPL_BUILD
    board_evm_init();
    printk("LL:FUNC:board_evm_init@evm.cLine:%d\n",__LINE__);//844
    #endif

    gpmc_init();

    return 0;

    err_out:
    /*
    * When we cannot use the EEPROM to determine what board we
    * are we assume BeagleBone currently as we have not yet
    * programmed the EEPROMs.
    */
    board_id = BONE_BOARD;
    profile = 1; /* profile 0 is internally considered as 1 */
    daughter_board_connected = 1;
    configure_evm_pin_mux(board_id, header.version, profile, daughter_board_connected);
    printk("LL:FUNC:board_init@evm.cLine:%d\n",__LINE__);//861
    #ifndef CONFIG_SPL_BUILD
    board_evm_init();
    #endif

    我看输出信息有mmc_init,就在board_mmc_init加输出信息,可是均没有输出:

    #ifdef CONFIG_GENERIC_MMC
    int board_mmc_init(bd_t *bis)
    {
    omap_mmc_init(0);
    printk("LL:FUNC:board_mmc_init@evm.cLine:%d\n",__LINE__);//1177
    omap_mmc_init(1);
    printk("LL:FUNC:board_mmc_init@evm.cLine:%d\n",__LINE__);//1179
    return 0;
    }
    #endif

    串口输出的信息如下:

    U-Boot SPL 2011.09 (Jan 24 2013 - 14:09:43)
    Texas Instruments Revision detection unimplemented
    LL:FUNC:i2c_init@evm.cLine:715
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    read_eeprom() failure. continuing with ddr3
    LL:FUNC:board_init@evm.cLine:808
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    LL:FUNC:board_init@evm.cLine:861
    LL:FUNC:board_init@evm.cLine:585
    LL:FUNC:spl_board_init@evm.c,Line:632
    LL:FUNC:spl_board_init@evm.cLine:641
    LL:FUNC:spl_board_init@evm.cLine:645
    LL:FUNC:spl_board_init@evm.cLine:650
    LL:FUNC:spl_board_init@evm.cLine:656
    MP S/
    M: 0
    mmc_init_setup: timedout waiting for cc2!
    spl: mmc init failed: err - -19
    ### ERROR ### Please RESET the board ###

  • 您好,我不知道evm.c中的board_mmc_init是怎么一回事,我把它改成

    //#ifdef CONFIG_GENERIC_MMC
    int board_mmc_init(bd_t *bis)
    {
    omap_mmc_init(0);
    printk("LL:FUNC:board_mmc_init@evm.cLine:%d\n",__LINE__);
    omap_mmc_init(1);
    printk("LL:FUNC:board_mmc_init@evm.cLine:%d\n",__LINE__);
    return 0;
    }
    //#endif

    希望即使没有定义也可以执行,输出我加入的这两句,可是还是没有输出,

    U-Boot SPL 2011.09 (Jan 24 2013 - 14:57:38)
    Texas Instruments Revision detection unimplemented
    LL:FUNC:i2c_init@evm.cLine:715
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    read_eeprom() failure. continuing with ddr3
    LL:FUNC:board_init@evm.cLine:808
    Could not probe the EEPROM; something fundamentally wrong on the I2C bus.
    LL:FUNC:board_init@evm.cLine:861
    LL:FUNC:board_init@evm.cLine:585
    LL:FUNC:spl_board_init@evm.c,Line:632
    LL:FUNC:spl_board_init@evm.cLine:641
    LL:FUNC:spl_board_init@evm.cLine:645
    LL:FUNC:spl_board_init@evm.cLine:650
    LL:FUNC:spl_board_init@evm.cLine:656
    OMAP SD/MMC: 0                           -------每次都会输出到这里,下面的那一句就输出了一次,
    mmc_send_cmd: timedout waiting for stat!

    期待您的指导,谢谢!我试试去掉I2C的,在来发贴

  • PMIC是用I2C控制的呢

  • 您好,谢谢您的指导,不是软件的事,软件是兼容的,是硬件的问题,解决了,谢谢您的指导!

  • 是硬件哪里的问题呢?

  • 换了个AM3359芯片,就好了

  • 你好,我们这边用到了 AM332 使用 eMMC 卡启动,也碰到了这个问题

    不允许替换芯片的情况下,这个问题要如何处理呢?

    TI是否有了解决方法,或者这个问题是否有定位.谢谢!

  • 楼上的换芯片,我觉得不是真正解决问题的方式,原因可能是虚焊等,XAM和AM的芯片是一样的。

    目前您的问题能不能具体说明下,启动怎么有问题,具体问题具体分析。

  • 1. eMMC 芯片用的是 MTFC8GLWDM-3L AAT Z BGA153

      我试了几块板,都是如下这样的,虚焊的可能性觉得可以排除了.


    2. 将 eMMC 分区并拷贝好fat及ext3分区的文件,SYSBOOT设置为从mmc1启动后,串口中断输出如下

    [14:56:41]U-Boot SPL 2013.01.01 (Aug 08 2016 - 14:07:29)
    [14:56:41]OMAP SD/MMC: 0, OMAP SD/MMC: 1
    [14:56:41]spl: mmc init failed: err - -19
    [14:56:41]### ERROR ### Please RESET the board ###



  • 从log看,是没有找到eMMC卡啊,有试过从其他介质上启动么?

  • 周工好,我用的是 TI-SDK 6.0 里面的 uboot 和linux代码,去掉了eeprom判断那块(我们板上没有eeprom存储板型).

    同样的这个 MLO u-boot 及内核,我现在是可以从 tf 卡(mmc0)启动的,在原来的板上也可以从nandflash起来

    我新做的这个板子,去掉了nand,改用eMMC接到mmc1口上.现在,linux系统起来后也可以挂载上 /dev/mmcblk1p1 mmcblk1p2 两个分区且能正常读写,只是在 MLO 启动时候出现如上错误,并且uboot命令行下输入 fatls mmc 1 也出错,同样是 -19 TIMEOUT错误

    另外,我问了个也用AM3352从emmc1启动的朋友,他说需要修改 u-boot 代码才能从emmc/mmc1口 启动.

    我现在是加了

    1. s_init() => enable_board_pin_mux() => 我增加了mmc1端口初始化 configure_module_pin_mux(mmc1_pin_mux);

    2. enable_per_clocks(); => 启用了mmc1 时钟

    /* MMC1*/
    writel(PRCM_MOD_EN, &cmper->mmc1clkctrl);
    while (readl(&cmper->mmc1clkctrl) != PRCM_MOD_EN)
    ;

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

    所以我现在的问题是, TI-SDK-6.0 中的uboot MLO 需要针对mmc1 口做什么修改,才能访问 emmc 卡(注,emmc参考BBB原理图,没有用到 sdcd wp 两个脚)

    期待你们尽快回答,多谢!

  • 已解决:

    1. MMC1 时钟需要开启

    2. MMC1 pin_mux 需要初始化配置,并确认未被其他地方使用,不会冲突.