Skip to content

Incorrect SimpleDHTErr* status returned by read(int pin, ...) and read2(int pin, ...) methods #26

@phd

Description

@phd

There is a nasty bug in read()/read2() methods taking the pin argument:

  • int SimpleDHT::read(int pin, byte* ptemperature, byte* phumidity, byte pdata[40])
  • int SimpleDHT11::read2(int pin, float* ptemperature, float* phumidity, byte pdata[40])
  • int SimpleDHT22::read2(int pin, float* ptemperature, float* phumidity, byte pdata[40])

They do not have return statements, so they return random value as temperature reading status.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions