Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 5 of 5

Thread: Teensy 3.2 with Pmod Hygro only reads I2C when ground is removed and reconnected.

  1. #1
    Junior Member
    Join Date
    Apr 2021
    Posts
    5

    Teensy 3.2 with Pmod Hygro only reads I2C when ground is removed and reconnected.

    This is a weird problem. I didn't have it before when I used the pmod on the 3.6

    Very simple setup.
    This RH sensor: https://reference.digilentinc.com/pmod/pmodhygro/start
    Standard Teensy 3.2
    3.3v and ground from teensy (right next to the 3.3V source, above pin 23)
    Tried both analog and digital grounds (GND and AGND)
    Tried swapping SLC and SDA (pin 18, 19)
    Tried removing the pull up resistor jumpers and no go. only works with jumpers in place.
    Code is from digilent https://reference.digilentinc.com/_m...brary_demo.zip


    I upload the code and check the serial monitor. I get the following repeating forever
    "TEMPERATURE=-40.00 degrees Celsius; HUMIDITY=0.00 percent Relative Humidity"
    if while running, I disconnect and reconnect the pmod ground, I get a real reading
    "TEMPERATURE=25.52 degrees Celsius; HUMIDITY=39.71 percent Relative Humidity"
    This reading also repeats forever unless I disconnect and reconnect ground.

    The teensy works perfectly fine with two other devices (MS5803 pressure sensor on SPI, and the teensyview which I think is also SPI)

  2. #2
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany
    Posts
    8,576
    Yes, the pullups are required. Check their value - it should be well below 4k7.

  3. #3
    Junior Member
    Join Date
    Apr 2021
    Posts
    5
    From the schematic, they are 2.2k
    https://reference.digilentinc.com/_m...dhygro_sch.pdf

  4. #4
    Junior Member
    Join Date
    Apr 2021
    Posts
    5
    I just hooked up to the teensy 3.5 and had the same result.
    used the SHG31-D which is also an i2c device and same...no go.

    uninstalled arduino 1.8.15 and reinstalled 1.8.13 including the appropriate teensyduino, and same results.

  5. #5
    Junior Member
    Join Date
    Apr 2021
    Posts
    5
    I got a hold of a scope. The SDA/SLC signals is normally high, and data bits go low.
    I'm not too familiar with I2C, but my intuition (probably wrong) is that the signal should normally be low and go high with bits.

    Edited: voltage is fine. I forgot the probes had an attenuation.
    Last edited by tgomez; 05-27-2021 at 08:59 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •