PCF85263 RTC I2C Communication Issue - All Registers Returning 0x00

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

PCF85263 RTC I2C Communication Issue - All Registers Returning 0x00

跳至解决方案
2,457 次查看
ohck
Contributor I

Hi,

I'm configuring the PCF85263 RTC and encountering an issue where all registers return 0x00 when I attempt to read them via I2C. Here’s my setup and the steps I’ve followed:

HW setup:

- PCF85263 rtc connected to a Quectel BG95-m3 module.

- pull-up resistors are present

Issue:

- I have tried to write different commands to different registers but when verifying the registers state they all return as 0x00

Steps I have taken:

- I have confirmed that the rtc gets 1.8v on VDD, SDA and SCL using a multimeter.

- Tested on two separate devices.

 

My code is in the attached file(set_alarm function gets called).

Is there some step I'm missing in the configuration?

Thanks in advance.

0 项奖励
回复
1 解答
2,436 次查看
TomasVaverka
NXP TechSupport
NXP TechSupport

Hi Oscar,

If you have a logic analyzer or an oscilloscope, could you please share some screenshots to check what is going on the bus?

It should also help us to verify each I2C operation's acknowledgment. If a command is not acknowledged, subsequent operations could fail.

Looking at your code, the I2C device address being used is correct. Just verify if the I2C library expects this 7-bit address (0x51) and automatically handles the read/write bit.

BRs, Tomas

 

在原帖中查看解决方案

0 项奖励
回复
2 回复数
2,437 次查看
TomasVaverka
NXP TechSupport
NXP TechSupport

Hi Oscar,

If you have a logic analyzer or an oscilloscope, could you please share some screenshots to check what is going on the bus?

It should also help us to verify each I2C operation's acknowledgment. If a command is not acknowledged, subsequent operations could fail.

Looking at your code, the I2C device address being used is correct. Just verify if the I2C library expects this 7-bit address (0x51) and automatically handles the read/write bit.

BRs, Tomas

 

0 项奖励
回复
2,374 次查看
ohck
Contributor I
Thank you, forgot to answer... Got a logic analyzer and looking at the addresses I found out that I had to use the 0x51 address as is. Our other sensors required the R/W bit included in the address so I thought this one also needed.
0 项奖励
回复
%3CLINGO-SUB%20id%3D%22lingo-sub-1978175%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EPCF85263%20RTC%20I2C%20%E9%80%9A%E4%BF%A1%E9%97%AE%E9%A2%98%20-%20%E6%89%80%E6%9C%89%E5%AF%84%E5%AD%98%E5%99%A8%E8%BF%94%E5%9B%9E%200x00%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1978175%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3E%E6%88%91%E6%AD%A3%E5%9C%A8%E9%85%8D%E7%BD%AE%20PCF85263%20RTC%EF%BC%8C%E5%B9%B6%E9%81%87%E5%88%B0%E4%B8%80%E4%B8%AA%E9%97%AE%E9%A2%98%EF%BC%9A%E5%BD%93%E6%88%91%E5%B0%9D%E8%AF%95%E9%80%9A%E8%BF%87%20I2C%20%E8%AF%BB%E5%8F%96%E6%89%80%E6%9C%89%E5%AF%84%E5%AD%98%E5%99%A8%E6%97%B6%EF%BC%8C%E5%AE%83%E4%BB%AC%E9%83%BD%E8%BF%94%E5%9B%9E%200x00%E3%80%82%E4%BB%A5%E4%B8%8B%E6%98%AF%E6%88%91%E7%9A%84%E8%AE%BE%E7%BD%AE%E5%92%8C%E6%88%91%E9%81%B5%E5%BE%AA%E7%9A%84%E6%AD%A5%E9%AA%A4%EF%BC%9A%3C%2FP%3E%3CP%3E%E7%A1%AC%E4%BB%B6%E8%AE%BE%E7%BD%AE%EF%BC%9A%3C%2FP%3E%3CP%3E-%20PCF85263%20rtc%20%E8%BF%9E%E6%8E%A5%E5%88%B0%20Quectel%20BG95-m3%20%E6%A8%A1%E5%9D%97%E3%80%82%3C%2FP%3E%3CP%3E-%20%E5%AD%98%E5%9C%A8%E4%B8%8A%E6%8B%89%E7%94%B5%E9%98%BB%3C%2FP%3E%3CP%3E%E9%97%AE%E9%A2%98%EF%BC%9A%3C%2FP%3E%3CP%3E-%20%E6%88%91%E5%B0%9D%E8%AF%95%E5%B0%86%E4%B8%8D%E5%90%8C%E7%9A%84%E5%91%BD%E4%BB%A4%E5%86%99%E5%85%A5%E4%B8%8D%E5%90%8C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D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E5%A4%8D%EF%BC%9APCF85263%20RTC%20I2C%20%E9%80%9A%E4%BF%A1%E9%97%AE%E9%A2%98%20-%20%E6%89%80%E6%9C%89%E5%AF%84%E5%AD%98%E5%99%A8%E8%BF%94%E5%9B%9E%200x00%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1983666%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E8%B0%A2%E8%B0%A2%EF%BC%8C%E5%BF%98%E4%BA%86%E5%9B%9E%E7%AD%94...%E5%BE%97%E5%88%B0%E4%BA%86%E4%B8%80%E4%B8%AA%E9%80%BB%E8%BE%91%E5%88%86%E6%9E%90%E4%BB%AA%E5%B9%B6%E6%9F%A5%E7%9C%8B%E5%9C%B0%E5%9D%80%EF%BC%8C%E6%88%91%E5%8F%91%E7%8E%B0%E6%88%91%E5%BF%85%E9%A1%BB%E6%8C%89%E5%8E%9F%E6%A0%B7%E4%BD%BF%E7%94%A8%200x51%20%E5%9C%B0%E5%9D%80%E3%80%82%E6%88%91%E4%BB%AC%E7%9A%84%E5%85%B6%E4%BB%96%E4%BC%A0%E6%84%9F%E5%99%A8%E9%9C%80%E8%A6%81%E5%9C%B0%E5%9D%80%E4%B8%AD%E5%8C%85%E5%90%AB%20R%2FW%20%E4%BD%8D%EF%BC%8C%E6%89%80%E4%BB%A5%E6%88%91%E8%AE%A4%E4%B8%BA%E8%BF%99%E4%B8%AA%E4%B9%9F%E9%9C%80%E8%A6%81%E3%80%82%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1978313%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E5%A4%8D%EF%BC%9APCF85263%20RTC%20I2C%20%E9%80%9A%E4%BF%A1%E9%97%AE%E9%A2%98%20-%20%E6%89%80%E6%9C%89%E5%AF%84%E5%AD%98%E5%99%A8%E8%BF%94%E5%9B%9E%200x00%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