打印
[运放]

关于TDA7564B的IIC驱动问题

[复制链接]
1391|5
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
小渠儿绿豆|  楼主 | 2016-11-29 14:00 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
各位亲们,最近我在调试一款音频功放芯片TDA7564B,按照数据手册配置,总共7个步骤。能工作输出音频,可是只能配置一次,就是说如果配置后打开芯片使他工作,然后做其他操作(比如配置13db增益,静音、低功耗什么的),就不工作了,IIC通信是正常的。简单来说就是那7个步骤只能操作一次,在操作芯片就失效了,需要重新上电。
有哪位亲们对这方面配置有了解的,帮帮忙,感激不尽。

相关帖子

沙发
小渠儿绿豆|  楼主 | 2016-11-29 14:03 | 只看该作者
ubyte Open_TDA7564B(void)
{
    ubyte Databyte[2];
    /* 1 */
    Databyte[0]   = 0B01000000;
    Databyte[1]   = 0B00000000;
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_RECEIVE, Databyte, 2);
    if(StartIIC0(Transmit) == FALSE)//主控发送
    {
        return FALSE;
    }
    PIT1_DelayMs(2);
   
    /* 2 */
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_TRANSMISSION, Databyte, 4);
    if(StartIIC0(Receive) == FALSE)//主控接收
    {
        return FALSE;
    }
    PIT1_DelayMs(1);

    /* 3 */
    Databyte[0]  = 0B00000001;
    Databyte[1]  = 0B00010011;
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_RECEIVE, Databyte, 2);
    if(StartIIC0(Transmit) == FALSE)//主控发送
    {
        return FALSE;
    }
    PIT1_DelayMs(1);

    /* 4 */
    Databyte[0]   = 0B00100110;
    Databyte[1]   = 0B00010000;
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_RECEIVE, Databyte, 2);
    if(StartIIC0(Transmit) == FALSE)//主控发送
    {
        return FALSE;
    }
    PIT1_DelayMs(1);

    /* 5 */
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_TRANSMISSION, Databyte, 4);
    if(StartIIC0(Receive) == FALSE)//主控接收
    {
        return FALSE;
    }
    PIT1_DelayMs(1);

    /* 6 */
    Databyte[0]   = 0B00011110;
    Databyte[1]   = 0B00010100;
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_RECEIVE, Databyte, 2);
    if(StartIIC0(Transmit) == FALSE)//主控发送
    {
        return FALSE;
    }
    PIT1_DelayMs(2);

    /* 7 */
    CorfigIICData(IIC_TDA7564B_ADDR, IIC_TDA7564B_TRANSMISSION, Databyte, 4);
    if(StartIIC0(Receive) == FALSE)//主控接收
    {
        return FALSE;
    }

    return TRUE;
}
这是配置代码

使用特权

评论回复
板凳
小渠儿绿豆|  楼主 | 2016-11-29 14:08 | 只看该作者
Examples of bytes sequence
1 - Turn-on diagnostic - Write operation
2 - Turn-on diagnostic - Read operation
The delay from 1 to 2 can be selected by software, starting from 1 ms
3a - Turn-on of the power amplifier with 26dB gain, mute on, diagnostic defeat, High eff.
mode both channels.
.
3b - Turn-off of the power amplifier
4 - Offset detection procedure enable
5 - Offset detection procedure stop and reading operation (the results are valid only for the
offset detection bits (D2 of the bytes DB1, DB2, DB3, DB4)
.
● The purpose of this test is to check if a D.C. offset (2V typ.) is present on the outputs,
produced by input capacitor with anomalous leakage current or humidity between pins.
● The delay from 4 to 5 can be selected by software, starting from 1ms
6 - Current detection procedure start (the AC inputs must be with a proper signal that
depends on the type of load)
7 - Current detection reading operation (the results valid only for the current sensor detection
bits - D5 of the bytes DB1, DB2, DB3, DB4)
.
● During the test, a sinus wave with a proper amplitude and frequency (depending on the
loudspeaker under test) must be present. The minimum number of periods that are
needed to detect a normal load is 5.
● The delay from 6 to 7 can be selected by software, starting from 1ms.

使用特权

评论回复
地板
小渠儿绿豆|  楼主 | 2016-11-29 14:08 | 只看该作者
小渠儿绿豆 发表于 2016-11-29 14:08
Examples of bytes sequence
1 - Turn-on diagnostic - Write operation
2 - Turn-on diagnostic - Read op ...

数据手册的7个步骤

使用特权

评论回复
5
小渠儿绿豆|  楼主 | 2016-11-29 16:02 | 只看该作者
有谁用过这款芯片

使用特权

评论回复
6
小渠儿绿豆|  楼主 | 2016-11-29 19:53 | 只看该作者
已解决,步骤之间需要延时,在手册里有说明

使用特权

评论回复
发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

4

主题

16

帖子

0

粉丝