Is that possible to use GPIO to simulate I2C in LPC18xx? It seem NXP don't allow the GPIO to be configured as both input and output.
Hi Lidou,
The LPC18xx contains the below features that you can use:
– One Fast-mode Plus I2C-bus interface with monitor mode and with open-drain I/O pins conforming to the full I2C-bus specification. Supports data rates of up to 1 Mbit/s.
– One standard I2C-bus interface with monitor mode and standard I/O pins.
However, it is possible to implement a GPIO to simulate I2C, but you need to create your own algorithm and change the pin configuration between output and input every time you need.
Have a nice day!
Have a great day,
Sol
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------