Hi everybody,
I'm using FRDM-KE02Z40M to interface with LT7680 (https://www.levetop.cn/uploadfiles/2023/05/LT768x_DS_V42_ENG.pdf) via 4-wire SPI.
I'm using the SPI driver from SDK 2.15 and I'm able to communicate it. Kinda.
As a test I'm writing to a register and reading back from it.
I chose register 0x0F, because it seems like because any value I write to it is valid.
I would write 0xC3 to it and read back 0xC3. So far so good.
If I try however to write 0x08, I read back 0x0F. In fact, any value with alternating bits (010) would not be read correctly.
It seems I have SPI Mode set correctly. Reducing the speed does not help.
The waveform looks good and matches what I observe in the software.
I'm quite sure the problem is not with the MCU or the driver, but as I'm getting desperate I'd appreciate any help or ideas to troubleshoot this.
I'm happy to provide more details if needed. Thanks in advance!
Dear @xiangjun_rong
Sorry if I wasn't clear. I don't connect MISO and MOSI together but rather follow the lt7680 datasheet (referenced in the original message)
Write Register’s Address:
Write Data to Register or Memory:
Read Register’s Data:
Hi,
do you use SPI interface or the other interface?
BR
XiangJun Rong
Hi,
I do not know how you read back the data you have written. Do you connect MOSI and MISO together? in the case, I suppose that the data the SPI master transmitted is the same as that the SPI master received.
Pls have a check
BR
XiangJun Rong