i want to try to stop communicaton I2C between arduino and lcd I2C but i don't see any command to stop this communication. I try with Wire.endTransmission or Wire.end but the transmission to the LCD continue without problem. I'm using this library NewliquidCrystal and inside no command for end transmission. I need to interupt that communicaton for have a good management of lcd or if know a new library with best features. Thank's for help
-
1What do you mean "stop" communication? If you don't perform any LCD manipulation commands you won't be communicating, so just don't do anything if you don't want to do anything.– Majenko ♦Mar 13, 2017 at 13:34
-
i wan't to interrupt communcication becouse after some time i have some spikes on i2c bus and lcd print casual char, and i thinked with interrupted communication i can avoid this stuff , thanks for help– Francesco VallaMar 13, 2017 at 13:59
-
2No. If you have noise on the I2C bus you need to find and suppress the cause of that noise, or harden your I2C bus. The simplest way to harden the I2C bus is to not rely on the (completely incorrect) internal pullups on the GPIO pins and instead fit (protocol standard) 3.3kΩ pullup resistors.– Majenko ♦Mar 13, 2017 at 14:28
1 Answer
I need to interupt that communicaton for have a good management of lcd or if know a new library with best features. Thank's for help
This sounds like a classical X-Y problem. You have decided on a solution and asking about some "magic" functionality without understanding the library or how the I2C bus works.
It would be better to try to describe the original issue, investigate, propose and discuss solutions. Basically better understand the original issue.
Back to your question:
Wire.endTransmission()
does not really do what you think. It marks the end of a block to be transmitted (previous Wire.write()) and starts the actual transmission to the slave.
This is what the manual says:
Wire.endTransmission()
Description
Ends a transmission to a slave device that was begun by beginTransmission() and transmits the bytes that were queued by write().