This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NRF52832 TWI at 50 KHz (SMBus Compatibility)

I am running the NRF52832 (BMD-300 module) and I'm trying to talk to battery over SMBus. SMBus is compatible with devices up to 100 KHz.

I was wondering if there was a way to talk to an I2C device on the NRF52832 with a lower clock rate than the 100 KHz rate given in the TWI library.

I see here that the frequency is not configurable beyond 3 predefined clock rates, 100K, 250K, and 400K. infocenter.nordicsemi.com/index.jsp

What I'm experiencing is inconsistent readings between my battery and board. I have about a 60% success rate when reading. The battery manufacturer stressed that I need to be SMBus compliant, not just I2C. They suggested that I use a slower clock rate than 100 KHz.

I was wondering if anyone out there knew if it was possible to use a slower clock rate for I2C communication using the NRF52832?

Thanks,

Greg

Parents Reply
  • bitbanging means you generate the signal yourself by setting and reading the GPIOs and using software timers to time the transitions (when to change a bit, when to read). This doesn't work with the softdevice running (ie advertising or in connection) as it can and does interrupt for fairly lengthy periods whenever it needs to do some bluetooth operations and that has higher priority than any timer or timer interrupt. So the timing of the software-generated protocol has large gaps in it and communications fail.

Children
No Data
Related