Dear All,
I need help for the conncetion with I2C, between Sparkfun Si7021 and ESP8266 Huzzah Feather Huzzah, I don’t find the correct code, can someone help me?
Best
Dear All,
I need help for the conncetion with I2C, between Sparkfun Si7021 and ESP8266 Huzzah Feather Huzzah, I don’t find the correct code, can someone help me?
Best
Hi gneiddu,
I am afraid SparkFun Tech Support cannot help with using SparkFun boards with development boards we do not carry. A simple test would be to use our [example code and in the wire.begin(); function, declare the SDA and SCL pins like this:
Wire.begin(SDA_PIN#, SCL_PIN#);
where SDA_PIN# and SCL_PIN# are the I/O pins set for SDA and SCL on your Feather.
This library has a function for initializing the Si7021 so declaring them in your code may not be sufficient and you may need to adjust the C++ source file. [Here is a link to that line in the source file to adjust the Wire.begin(); function. You will need to locate this source file if you have already installed the library on your computer and edit it manually. That may help but a lot of I2C libraries like the one for the Si7021 have issues working with the ESP8266 chipset since it was written for an AVR chip so you may need to make further adjustments to the library or search for one that will work with the ESP8266.
I hope this helps.](SparkFun_Si7021_Arduino_Library/src/SparkFun_Si7021_Breakout_Library.cpp at main · sparkfun/SparkFun_Si7021_Arduino_Library · GitHub)](Si7021 Humidity and Temperature Sensor Hookup Guide - SparkFun Learn)
I tried to change this fields, but I thonk it is not enough, or am I doing it wrong?
Like I mentioned in my previous post, you may need to alter the library further or find one for the SI7021 specifically for the ESP8266 due to how I2C functions on that chipset. If declaring your SDA and SCL pins in the Wire.begin(); function does not work, the library most likely is not compatible with the ESP8266 and will need to be modified to work with it. SparkFun Technical Support cannot assist with this type of custom code so you may want to search for an ESP8266-specific library or go to the [ESP8266 Community Forum for help.
Some other resources that may help would be the [ESP8266 Arduino Core GitHub Repository and [Espressif’s ESP8266 Landing Page.](ESP8266 Wi-Fi SoC | Espressif Systems)](GitHub - esp8266/Arduino: ESP8266 core for Arduino)](https://www.esp8266.com/)