This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

HDC1080: only 10bit resolution to see instead of 11 or 14bit

Part Number: HDC1080

According to the data sheet the HDC1080 has a resolution of up to 14bits for temperature and moisture measurement. Unfortunately I only see 10bit resolution when trying out 14bit or 11bit - no more.

There is no hint given in the data sheet to this. The needed cap is there. The voltage supply is about 4.2V - bypassed by a small cap.

I am getting values. Some are the same, then this changes to another value - but not so near. The new value is about 0.1% away. Thats not at all a 14bit resolution.

Is this a known problem?

Is my part bad? Should I try getting another one?

Thank you very much for listening and any help with that!

  • TI support team will contact your shortly.
  • Hi user84788

    Are you correctly reading all the 16 bits in the outputs registers?

    - Temperature output register 0x00 [15:00] --> sixteen bits where [01:00] = '00'
    - Humidity output register 0x01 [15:00] --> sixteen bits where [01:00] = '00'

    How much is sampling rate (how often do you perform a conversion humidity + temperature)?

    Regards
    Massimo
  • Yes - I am reading both bytes by I2C. I am shifting right 2 bits of the low byte and I am shifting left 6 bit of the high byte. Both bytes are ored to an unsigned 16bit value.

    I am getting values for humidity that are reasonable. They seem to be quite correct. The sampling rate was different. According to the data sheet 7ms should be working. So I triggered a measurement, waited 7ms or more and got the value. Then I started a new measurement.

    I did not perform the combined mode (temp + humidity) but just humidity or temperature. There is the same problem to see with temperature and humidity. Only 10bit resolution - not 11 or more bit.

    Regards
    Matthias
  • Hi user84788

    The procedure you use to convert the RH and temp output seems not correct.

    After that you read the temperature register you have a string of 16 byte let me call it TEMPERATURE_LSB[15:00].

    1. Convert TEMPERATURE_LSB[15:00] in integer --> TEMPERATURE
    2. Perform the following calculation to get the temperature in degC.

    Temperature (degC) = (TEMPERATURE/ 2^16) *165 C-40degC

    ---------------------------------------------------------------------------------------
    Examples:
    TEMPERATURE-LSB[15:00] = 0x645E (in hexadecimal format to make it more readable)

    TEMPERATURE = 25694

    Temperature(degC)=(25694/2^16)*165-40=24.67degC
    ---------------------------------------------------------------------------------------

    Same process has to be followed for the humidity, with the conversion formula described in the HDC1080 datasheet at page 14

    ---------------------------------------------------------------------------------------
    Examples

    HUMIDITY_LSB[15:00] = 0x42DC

    HUMIDITY = 17116

    Humidity(%RH)=(17116/2^16)*100 = 26.11%RH
    ---------------------------------------------------------------------------------------

    I also suggest to increase a little bit the sampling time waiting 20ms between two measurements

    Regards
    Massimo
  • Thank you Massimo !

    Unfortunately this does not seem to solve the problem.

    The problem is that the raw data is not stable and jumps quite much. Therefore its no wonder that also the calculated values are jumping quite much. When the resolution is not there in the raw bytes - then also its not there in the calculated value.

    "Humidity(%RH)=(17116/2^16)*100 = 26.11%RH"

    Unfortunately this does not help so much in my case because it would require using floating point math on the microcontroller. Therefore I did not use that but tried using integer math instead. 17116/2^16 calculates to 0.26117. Using integer math the result would be zero. Therefore this cannot be used there. Instead first a multiplication to get a higher value has to be done. It has to be made sure not to get an overflow. Its possible using a unsigned long data type then. I did this way. This works - but unfortunately the resolution was 10bit instead of 11 or 14bit as I said above.

    The raw data is the problem.

    Regards
    Matthias
  • "I also suggest to increase a little bit the sampling time waiting 20ms between two measurements"

    Thank you for this. I also tried longer times like 70ms. But unfortunately this did not solve the problem.
  • Dear Matthias

    You are right. If you perform the multiplication first, avoiding overflow, then divide by 2^16 it works.

    Regarding the instability of the raw data:

    - if you see the integer digit change , most probably your set up is not stable or there is something else that has to be fixed.

    - If you see the second digit after the comma change, please consider that whit 10 bit resolution the temperature that is possible to discriminate (resolution) is 0.16degC. If you want to see a stable value your environment set up has to be stable under 0.08degC.

    I do suggest to perform some averaging on the temperature and humidity outputs.

    Regards
    Massimo
  • Thank you Massimo !

    "if you see the integer digit change , most probably your set up is not stable or there is something else that has to be fixed."

    There does not seem to be so much that I could do here.
    The chip seems to be correctly bypassed.
    It could be used an extra voltage regulator for 3.3V.
    But then also a voltage translator has to be used.

    "If you want to see a stable value your environment set up has to be stable under 0.08degC."

    Using a very short measurement time should make sure
    that humidity and temperature does not change much in this time between measurements.
    I did use the shortest possible measurement times to make sure.
    Normally in just 10ms or so temperature and also humidity does
    not change much. I am not able investing in a controlled humidity chamber. 

    "I do suggest to perform some averaging on the temperature and humidity outputs."

    Averaging does not make much sense if the values are stable
    but show only 10bit resolution.

    May be the chip itself has a problem. To make sure another
    one could be tested. I do not have a second one at the moment
    fixed on a pcb to test.

    Regards,
    Matthias