I have gone back and re examined the video Example 8 as previously pointed to in earlier comments to this post.
OK the penny has dropped, and I finally get it and understand.
It is all a case of just finding a library which you can pass &Wire1 as part of the constructor for the device you want to use. I have found one for the BME280 - https://github.com/bolderflight/bme280 this works just fine with the touch screen.
Now I need to find one for my DS3231 RTC.
I would like to thank those who have taken the time to comment and help, but if you have already found one for the DS3231 then could you please put a comment in this post for me to try.
I try to connect ADS115 to the board. Tanks to david i found a very simple solution.
define pointer pWire with "TwoWire* pWire" before setup function.
Initialize pointer in setup function with "pWrire =&Wire" after initializing the screen.
use pWire-> instead of wire.
for example "pWire->BeginTransmission(ADR_ADS1115)" etc.
I also have a problem with i2c and temperature sensor SHT31D.
In my case, if I use the sensor library, I have no display image.
ESP32 works, I get information on the serial port but no image on the screen.
Please Elecrow put some sample code so that we can work with our selected i2c devices, however we use touchscreen and display together with them.
I Cant use I2C to talk to other I2C devices when touch is active.
I am using the 7imch HMI to drive the Gui. I have one button on the screen that when released should send a wire.write a nother ESP32 s32 and trigger one of the GPIOs to high. I have had no success.
I have tried connecting from the 7inch HMI display ESPs3 to the Slave ESP wihtout screen functionality and i have accheived success, but as soon as I enable the display and touch. BOOM!!! FAILURE!!!
I have set y addresses on both Master and slave, NO LUCK.
Can anyone help. Also the videos that Elecrow had are not showing, they display.. PRIVATE VIDEO...
Comments
I have gone back and re examined the video Example 8 as previously pointed to in earlier comments to this post.
OK the penny has dropped, and I finally get it and understand.
It is all a case of just finding a library which you can pass &Wire1 as part of the constructor for the device you want to use. I have found one for the BME280 - https://github.com/bolderflight/bme280 this works just fine with the touch screen.
Now I need to find one for my DS3231 RTC.
I would like to thank those who have taken the time to comment and help, but if you have already found one for the DS3231 then could you please put a comment in this post for me to try.
Further to my last post. All libraries found and all now working.
I try to connect ADS115 to the board. Tanks to david i found a very simple solution.
define pointer pWire with "TwoWire* pWire" before setup function.
Initialize pointer in setup function with "pWrire =&Wire" after initializing the screen.
use pWire-> instead of wire.
for example "pWire->BeginTransmission(ADR_ADS1115)" etc.
Sorry, mistake in the comment before.
"pWire =&Wire1" in Setup() function is right.
Please send me your all working code for i2c device.
I also have a problem with i2c and temperature sensor SHT31D.
In my case, if I use the sensor library, I have no display image.
ESP32 works, I get information on the serial port but no image on the screen.
Please Elecrow put some sample code so that we can work with our selected i2c devices, however we use touchscreen and display together with them.
Edit:
I did it.
Instead of the Adafruit library, I used this one:
https://github.com/RobTillaart/SHT31/tree/master
Hello @davidwoolterton I have the same issue with real time clock can tell the library you used in that?
I Cant use I2C to talk to other I2C devices when touch is active.
I am using the 7imch HMI to drive the Gui. I have one button on the screen that when released should send a wire.write a nother ESP32 s32 and trigger one of the GPIOs to high. I have had no success.
I have tried connecting from the 7inch HMI display ESPs3 to the Slave ESP wihtout screen functionality and i have accheived success, but as soon as I enable the display and touch. BOOM!!! FAILURE!!!
I have set y addresses on both Master and slave, NO LUCK.
Can anyone help. Also the videos that Elecrow had are not showing, they display.. PRIVATE VIDEO...
ANyhelp would be great.
Thanks