Hello All,
I am working on DHT11 temp sensor. I have connected the sensor on pin10. Now when I am trying to read the value from pin10 , the value is one(1).
please suggest how can I get the raw temperature value from pin10.
Please find below the sketch..
I am working on DHT11 temp sensor. I have connected the sensor on pin10. Now when I am trying to read the value from pin10 , the value is one(1).
please suggest how can I get the raw temperature value from pin10.
Please find below the sketch..
B4X:
#Region Project Attributes
#AutoFlushLogs: True
#CheckArrayBounds: True
#StackBufferSize: 300
#End Region
Sub Process_Globals
Public Serial1 As Serial
Private timer1 As Timer
Private pin10 As Pin
End Sub
Private Sub AppStart
Serial1.Initialize(115200)
Log("AppStart")
pin10.Initialize(10,pin10.MODE_INPUT)
timer1.Initialize("temp_calc",1000)
timer1.Enabled=True
End Sub
Private Sub temp_calc
'Dim temp As Boolean = pin10.DigitalRead
Log("The Read value is :",pin10.DigitalRead)
End Sub