Hi all,
This is my first post here
I'm working on DHT11 library (1-wire protocol) and I would like to share with community,
The coding concept is almost done refer as datasheet. But the bad news is I haven't get any data out yet.
I think the problem come from timing issue or coding, Due to the compiler not support "Time Loop" so far.
Anyway I'll continue working on it ,If someone can help to get it work and share with community, I really appreciate.
Noted, The main VI is "DHT11 Example.vi"
Amornthep.
9:46 pm
March 12, 2015
Hi Amornthep;
Thanks for posting this. In regards to the compiler not supporting Timed Loop, you can take advantage of the timer interrupts in order to implement functionality that would be the equivalent of of a single timed loop in LabVIEW. Refer to the shipping example on timed interrupts for more details on how to use it. That will give you real time execution of a single loop every time the interrupt fires.
Filipe
Cheers
Filipe
the $5.00 Low Cost DHT11 Temperature &Humidity Sensor.
(http://www.adafruit.com/product/386)
Anyone interested on this please find VI and library in .zip file
The zip files include..
1.Weather Station DHT11 with LCD 1.0.0 (Main Application)
2.DHT11 beta 1.0.0 (Library fiels to interface with DHT11 )
3.Document ,Datasheet etc.
*Please noted that I only tested with Arduino Uno (ATmega328)
*Keys to improvement for next version.
1.Handling timeout error function
2.Stability of the code
3.Accuracy
4.Verify with others HW target.
Thanks, Amornthep
11:37 am
August 27, 2015
Hi threeclock,
great that you got your VIs to work with your DHT11 sensor.
One question. Are these VIs specifically for the DHT11 sensor our would they also work
with other digital one wire protocol sensors like for example "DS18S20" ?
Specification Link DS18S20
http://www.maximintegrated.com.....18S20.html
That would be great. I have some of these sensors at home. I worked with these sensors on the NI myRIO.
Worked pretty well.
Thanks a lot
AndreasK
2:23 pm
March 12, 2015
Hello;
If you take a peek inside the Translator.vi; which is the one that contains the C-code that does the glue logic between the corresponding Arduino Library and the LabVIEW API VIs, you will see that the Dallas Temperature library is the one that got ported.
According to this link; https://www.pjrc.com/teensy/td.....eWire.html; the library supports both Maxim and Dallas 1-wire devices. So, my guess is that it would work with the one you are referring to.
Filipe
Cheers
Filipe
10:27 pm
August 5, 2015
Thank you Amornthep! This is exactly what I was looking for. I'd also be very interested in examples of how to read the Dallas temp sensor.
Where do I get and how do I install the required libraries?. I see a bunch of errors reporting Native functions not supported, when I look at the Arduino code. Even ones I believe are basic labview functions for example "Native function "Add" not supported" . . .
Any ideas what I am doing wrong? Where is the "Translator.vi" Filipe refers to above? On my PC I can only find the example translator VI provided by ACC4LV.
3:59 am
March 12, 2015
You are getting the "not supported" messages because you are trying to view the converted code of functions that you are not allowed to view. When using the Arduino Code Viewer you must make sure you only have user APIs in the VI as the tool is only meant to help you develop your custom library and show you the converted code for the API VIs only.
Take a look at the example in the user manual section "Porting an Arduino library to LabVIEW" and the Digilent Analog Shield example, which ships with the compiler. You can find this at “[LABVIEWDIR]\vi.lib\Aledyne-TSXperts\Arduino Compatible Compiler for LabVIEW\addons\Digilent Analog Shield". The Translator.vi is located in the folder for each user library, including this one.
1:34 pm
July 9, 2015
hi sir
I found there are diffenence result if I reverse the sequence between the DHT11.vi and RTC.vi.
The seq1 can got correct data from DHT11.vi, but the seq2 return wrong data.
The another issue is I put the DHT11.vi and RTC.vi into the sequence structure.
The compatiler will show not enough memory error.
Can help me to clarity these issues?
I already update to version 1.0.0.19
2:25 pm
June 24, 2015
Hi Amornthep;
i have try your example DHT11.vi but when i want to compile(verify only) i have this answer
1.0.0.19, Arduino Uno
temp.ino: In function 'void setup()':
temp:70: error: 'Vrai' was not declared in this scope
temp:76: error: 'Faux' was not declared in this scope
temp:93: error: 'Vrai' was not declared in this scope
temp:99: error: 'Faux' was not declared in this scope
'Vrai' was not declared in this scope
Do you have an idear
thanks for your help
4:23 pm
April 8, 2015
molio said
hi sirI found there are diffenence result if I reverse the sequence between the DHT11.vi and RTC.vi.
The seq1 can got correct data from DHT11.vi, but the seq2 return wrong data.
The another issue is I put the DHT11.vi and RTC.vi into the sequence structure.
The compatiler will show not enough memory error.
Can help me to clarity these issues?
I already update to version 1.0.0.19
Hi Molio,
Can you post the VI ?
Amornthep
4:28 pm
April 8, 2015
ehrenfeld said
Hi Amornthep;i have try your example DHT11.vi but when i want to compile(verify only) i have this answer
1.0.0.19, Arduino Uno
temp.ino: In function 'void setup()':
temp:70: error: 'Vrai' was not declared in this scope
temp:76: error: 'Faux' was not declared in this scope
temp:93: error: 'Vrai' was not declared in this scope
temp:99: error: 'Faux' was not declared in this scope
'Vrai' was not declared in this scope
Do you have an idear
thanks for your help
Hi ehrenfeld,
I haven't tried with 1.0.0.19 yet. but I will give a try.
Amornthep
4:34 pm
March 12, 2015
ehrenfeld said
Hi Amornthep;i have try your example DHT11.vi but when i want to compile(verify only) i have this answer
1.0.0.19, Arduino Uno
temp.ino: In function 'void setup()':
temp:70: error: 'Vrai' was not declared in this scope
temp:76: error: 'Faux' was not declared in this scope
temp:93: error: 'Vrai' was not declared in this scope
temp:99: error: 'Faux' was not declared in this scope
'Vrai' was not declared in this scope
Do you have an idear
thanks for your help
It's probably because you have French language setting or French version of LV. Please take a look at the user manual regarding other language support and case statements. This was also discussed in this recent post here:
2:32 pm
June 19, 2016
Amornthep said
the $5.00 Low Cost DHT11 Temperature &Humidity Sensor.
(http://www.adafruit.com/product/386)
Anyone interested on this please find VI and library in .zip file
The zip files include..
1.Weather Station DHT11 with LCD 1.0.0 (Main Application)
2.DHT11 beta 1.0.0 (Library fiels to interface with DHT11 )
3.Document ,Datasheet etc.
*Please noted that I only tested with Arduino Uno (ATmega328)
*Keys to improvement for next version.
1.Handling timeout error function
2.Stability of the code
3.Accuracy
4.Verify with others HW target.
Thanks, Amornthep
Hi Amonhep,
First of all, thank you very much for your program.
I have some experience in labview, but working on arduino uno using labview compatible complier
to unload coding from labview to chip is the first time.
I connect DHT11 to arduino according to your guide. But when i upload that code to arduino but nothing can be shown on LCD.
Could you help me?
Thanks
9
1 Guest(s)