PN7462 I2CM怎么用?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

PN7462 I2CM怎么用?

997件の閲覧回数
onlineit
Contributor II

我用PN7462的I2C读EPSON 的RTC RX-8025SA,没有读到任何数据,程序如下:

phStatus_t status;

uint8_t bBaudRate;

uint32_t pbuffer[32];


bBaudRate = (uint8_t) ((PH_EXHIF_HW_CRYSTAL_CLK / gpkphCfg_EE_HW_I2CM->dwDataRateHz)
- PH_EXHIF_HW_CRYSTAL_CLK_MHZ);

PH_USER_ASSERT(
phhalI2CM_Init(PH_EXHIF_HW_I2CM_TX_FIFO_THRES,PH_EXHIF_HW_I2CM_RX_FIFO_THRES, \
PH_EXHIF_HW_I2CM_TIMEOUT, PH_EXHIF_HW_I2CM_RETRY_CNT) == PH_ERR_SUCCESS);

/* SDA_HOLD field is 0x0, the I2C Master IP will internal take care of hold time. */
//E_I2CM_7BIT_ADDR_MODE=0x00;
PH_USER_ASSERT(phhalI2CM_Config(bBaudRate, 0x09, /*E_I2CM_7BIT_ADDR_MODE */ 0x00) == PH_ERR_SUCCESS);

do{
status = phhalI2CM_QueueRx(0x32,0x0f,pbuffer);
if (status == PH_ERR_SUCCESS)
{

   //
}

调用status = phhalI2CM_Receive(0x32,0x0f,pbuffer);会死机。

如何使用PN7462的I2CM???

ラベル(1)
0 件の賞賛
1 返信

710件の閲覧回数
jimmychan
NXP TechSupport
NXP TechSupport

have you try to add some code in phhalI2CM_Receive to see where it stop?

0 件の賞賛