Wrong temperature measurement with your demo

I am unable to measure correct temperature with the Cubecell HTCC-AB01 with the sample sketches from Heltec (ReadSHT2x.ino and BMP180basic.ino).

Regardless of whether I connect an SHT20/21 or a BMP180 sensor, the temperature is always measured way too high (+/- 45 degrees Celsius and not the actual 25 degrees Celsius). I have several sensors in stock and it doesn’t matter if I change them. I measured the Vext voltage, which is 3.29 volts. The same sensors work well on an Arduino Nano and Uno, so they are okay.

Can someone tell me if I am doing something wrong?

Thanks to the posting from dserrano (SHT20 Strange behavior) I was able to get the SHT sensor to work properly now using the uFire library. I recommend Heltec to change the demo sketch because it doesn’t work.

For others who run into this problem, below my working sketch:

#include “uFire_SHT20.h”
uFire_SHT20 sht20;

void setup()
{
Serial.begin(115200);
sht20.begin();
pinMode(Vext, OUTPUT);
Serial.println(“SHT-sensor Test”);
}

void loop()
{
digitalWrite(Vext,LOW);
Wire.begin();
delay(500);
float temperature = (float)(sht20.temperature());
float humidity = (float)(sht20.humidity());
Serial.print(temperature);
Serial.print(" C - “);
Serial.print(humidity);
Serial.println(” %");
Wire.end();
digitalWrite(Vext,HIGH);
delay(5000);
}

hi,

We will update this example code in the next two days.

I have a similar problem on a HTCC-AC01 with the original BMP180-sensor from Heltec: The example BMP180basic.ino provides correct values. But the example LoRaWan_BMP180.ino delivers wrong values.
CubeCell Development Framework 1.2.0

Output from BMP180basic.ino and LoRaWan_BMP180.ino (Only adapt devEui, appEui, appKey):

Nobody have an idea? From the technical data, “the egg” makes a good impression, but now I think I have bet on the wrong hardware.

hi,

i have tested it. it works fine.

could you check your pins’ connect? and code.
%E5%9B%BE%E7%89%87

Hi, it seems I habe the solution. A little delay between the setting of Vext and the begin of the bmp in the prepareTxFrame:

pinMode (Vext, OUTPUT);
digitalWrite (Vext, LOW);
delay(10);
if (bmp.begin ()) {

Probably an unfavorable timing between the BMP180 and the capsule.

2 Likes