Hi all,
I've been checking out the various problems encountered by people using the KL25Z and external I2C devices. I thought I'd share some of what I've learned.
My test is a DS1307 realtime clock IC. This requires a 5V PSU and thence generates 5V I2C signals.
Using my KL25Z powered from the USB, and driving the DS1307 from its 5V pi I get no I2C connection at all. Sadly this is exactly the configuration that the arduino datalogger shield uses (where my DS1307 is located).
If however, I drive te DS1307 from a 3.3V supply (which is not recommended and requires some reworking of the arduino board) it does in fact work ok , even allowing writing of the internal eeprom!
Why ?
Well, several references across the net suggest that the KL25Z's inputs are not really 5V tolerant - they are pulled down to ground via a diode which can breakdown at this voltage (occasionally).
What's a fix ? Probably a bidirectional level shifter like the adafruit one which uses the BSS138 mosfet.
Hope this is useful to people struggling with this IC.
Hi all, I've been checking out the various problems encountered by people using the KL25Z and external I2C devices. I thought I'd share some of what I've learned. My test is a DS1307 realtime clock IC. This requires a 5V PSU and thence generates 5V I2C signals. Using my KL25Z powered from the USB, and driving the DS1307 from its 5V pi I get no I2C connection at all. Sadly this is exactly the configuration that the arduino datalogger shield uses (where my DS1307 is located).
If however, I drive te DS1307 from a 3.3V supply (which is not recommended and requires some reworking of the arduino board) it does in fact work ok , even allowing writing of the internal eeprom!
Why ?
Well, several references across the net suggest that the KL25Z's inputs are not really 5V tolerant - they are pulled down to ground via a diode which can breakdown at this voltage (occasionally).
What's a fix ? Probably a bidirectional level shifter like the adafruit one which uses the BSS138 mosfet.
Hope this is useful to people struggling with this IC.