I am trying to use TWIC as a simple master talking to one slave device at 400kHz. My code works - sometimes. Other times it hangs, waiting for either the RIF or WIF interrupt flags (it’s a polled environment).
i am writing the code in assembler, and don’t want to use a library. I want to understand the hardware down to the last bit. Has anyone written a successful TWIC driver without using a library? Could some kind soul please point me to functional source code for such a thing?
Thanks in advance.
Altazi