💬 Insulated Whole House Fan
-
@petewill wow, your screen case looks amazing! Is that acryl glass? Did you build that yourself too?
-
@enlo Thanks. Yeah, it's acrylic glass (Plexiglas). It was a pain to use though as I couldn't clean off the paint very well. My next project I'm working on I'm going to try to use regular glass.
-
@rechin304 said:
dht.setup(DHT_DATA_PIN);
if (UPDATE_INTERVAL <= dht.getMinimumSamplingPeriod()) {
Serial.println("Warning: UPDATE_INTERVAL is smaller than supported by the sensor!");
}
// Sleep for the time of the minimum sampling period to give the sensor time to power up
// (otherwise, timeout errors might occure for the first reading)
sleep(dht.getMinimumSamplingPeriod());For what it's worth, I just went through a very long debug session trying to get a simple dht11 based sensor built and working. For reasons I don't even pretend to understand, the one thing I changed that allows it to work is changing the 'sleep' command in this section of the setup function to a 'wait' command.
-
@flyswiftly thanks for trying,
in my case still i do not see any data. What library do you use ? The one from MySensorsArduinoExamples-master.zip ?
-
What library do you use ? The one from MySensorsArduinoExamples-master.zip ?
Actually, no. It turns out when I looked through my IDE that I am using the prior version of the DHT library. That did also force me to comment out the read sensor line just to make it compile. Maybe the combination of the two changes is what does the trick. I hadn't made those changes together, so I missed the possible significance of this change:
void loop() { // Force reading sensor, so it works also after sleep() // dht.readSensor(true);
Running a diff on both the library you point out and the one I'm using shows that adding that bool to the readSendor function is the only code difference.
-
@flyswiftly
I also did that try an older version library for DHT and receive data. So conclusion is that on current (latest) DHT library for DHT11 is not working. Now I'm on a business trip to China for a week and With this chance i will buy there DHT 22 to be sure. I will be back in a week with conclusion.
-
I can confirm that DHT library that is in example do not work with DHT11 and DHT22 in my case, using other (older) library i can see data.
-
@rechin304 Sorry, just to make sure I understand, are you saying it works with a DHT22 or not? I may still be on an old library too.
-
@petewill
Works with DHT22 and other library (old one). I could not make it work withe one from example.I'm almost ready with build, waiting for final pieces. hope to receive them this week.
one more ting i noticed is that clock is behind with 2minutes, so i need to check the code again.
-
I have an working prototype, see video https://goo.gl/photos/VSQeaevHh7UbbStr9
Many thanks to @petewill for his work and inspiration.
I will post final pictures when ready.
-
Added new lead screw pitch of 2Mm that decrease open/close time from 3 minutes to 40 sec. see pics https://goo.gl/photos/mQvF1S9FrdNYPpdH9
buyed from here http://www.ebay.com/itm/322139119923?_trksid=p2057872.m2749.l2649&var=511054006707&ssPageName=STRK%3AMEBIDX%3AIT
for who is interested.
-
@rechin304 Awesome! Glad you got it working!!
-
@petewill Hi Pete
Just Start building the system and got an error at sketch verify.
"exit status 1
'class Adafruit_ST7735' has no member named 'setFont'"
-
@lis610 Sorry for the delay. Work has been very busy. I have attached the libraries I'm using. I was able to get it to compile when I just tested. https://drive.google.com/file/d/1wauxHRf5pyqLnBGsfCP8UPJQR1wNdkoF/view?usp=sharing
Let me know if you have issues with this.
-
THANK YOU so much for sharing. Most of the errors gone, but one left (using Arduino v.1.8.5; MySensors v 2.3.0):
[C:\Users\BEAST\Documents\Arduino\Whole-House-Fan\code\New folder\WholeHouseFan2.0\WholeHouseFan2.0.ino: In function 'void presentation()':
WholeHouseFan2.0:197: error: 'TEMP_CHILD_NAME' was not declared in this scope present(TEMP_ID, S_TEMP, TEMP_CHILD_NAME);
exit status 1]
'TEMP_CHILD_NAME' was not declared in this scope
-
@lis610 Sorry about that. I just fixed the code on the build page. Hopefully that will get you up and running
-
Thank you. Did you upload the file for download?
-
@lis610 yes, I uploaded it to the page in the link at the top of this page.
-
Cannot locate file "WholeHouseFan2.0.ino"
-
@lis610 Strange. It disappeared. I added it again and just downloaded it so you should be good. Sorry for all the issues!
-
Thank you. The box is ready. Next step connect all hardware. So far no luck with the display (KMR-1.8 SPI). What kind of display model you used in this project.
-
@lis610 This is the display I used.
http://www.ebay.com/itm/331443126874?_trksid=p2057872.m2749.l2649&ssPageName=STRK%3AMEBIDX%3AIT
-
Got the same display. It is working with Adafruit graphicstest example. I did not connect any components just display. If I ran the FAN sketch should be something showing on the display?
Or need to connect everything?
-
@lis610 is #define TFT_DISPLAY_ON uncommented? Also, you will at least need the radio attached so the MySensors code can fully load (you can also setup defines to proceed without connecting to gateway but I don't remember them off the top of my head). I don't remember if there are any other dependencies since it as been so long since I built this.
-
Please help
Display is working with Adafruit graphicstest example pins:
#define TFT_CS 10 #define TFT_RST 9 #define TFT_DC 8# define TFT_SCLK 13 #define TFT_MOSI 11
I did try the same pins in FAN sketch -nothing on display
Tryed pin# from FAN sketch on Adafruit graphicstest- nothing on display.
Nothing come up
I did connect to the radio. Got something from MY_DUBUG not sure is it good or bad:624893 TSF:MSG:SEND,5-5-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=1,st=OK:
626903 !TSM:FPAR:NO REPLY
626905 TSM:FPAR
626941 TSF:MSG:SEND,5-5-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
628951 !TSM:FPAR:NO REPLY
628953 TSM:FPAR
628989 TSF:MSG:SEND,5-5-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
630999 !TSM:FPAR:NO REPLY
631001 TSM:FPAR
631037 TSF:MSG:SEND,5-5-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
633047 !TSM:FPAR:FAIL
633049 TSM:FAIL:CNT=7
633051 TSM:FAIL:DIS
633053 TSF:TDI:TSL
693057 TSM:FAIL:RE-INIT
693059 TSM:INIT
693067 TSM:INIT:TSP OK
693069 TSF:SID:OK,ID=5
693071 TSM:FPAR
693108 TSF:MSG:SEND,5-5-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
693432 TSF:MSG:READ,0-0-5,s=255,c=3,t=8,pt=1,l=1,sg=0:0
693438 TSF:MSG:FPAR OK,ID=0,D=1
695117 TSM:FPAR:OK
695119 TSM:ID
695119 TSM:ID:OK
695121 TSM:UPL
695160 !TSF:MSG:SEND,5-5-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=0,st=NACK:1
697171 TSM:UPL
697178 TSF:MSG:SEND,5-5-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=1,st=OK:1
699187 TSM:UPL
699224 !TSF:MSG:SEND,5-5-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=0,st=NACK:1
701233 TSM:UPL
-
@lis610 It looks like it's having issues communicating with your gateway. Here is a link to the log parser. You can use this in the future to check out your logs.
Also, did you comment/uncomment the proper defines as noted above and in the code comments?
Try adding this line before #include <MySensors.h>
#define MY_TRANSPORT_WAIT_READY_MS 4000 //This will allow the sensor to function if it can't find the gateway when it first starts up
-
-
-
VeraEdge:
-
Hi Pete,
Do you see anything wrong with gateway, node and vera
-
@lis610 sorry, I'm not a place where I can look in depth. It looks like your code isn't communicating with the gateway though. Did you try the line of code above? The device should work with the push button even if it can't communicate with the gateway (with that code).
-
I will come back to the communication issue later.
In your resent code SPI is comment out " //#include <SPI.h> " what is the reason you comment SPI?
The display is not showing anything even with: #define TFT_DISPLAY_ON. and #include <SPI.h>
-
@lis610 if it can't communicate with the gateway and controller the node will never get to the loop which could be why the display isn't working. The SPI include used to be required for MySensors.
-
@lis610 It seems you have two problems.
1 The radio is not connecting reliably with the gateway and may blocking the display from starting.
There are lots of other messages on troubleshooting radio problems.2 The Graphic Display is not operating correctly.
For Item one, You eventually need to resolve the radio problem, However as pete stated in his message if you add the following define it will allow the sketch to run, I can confirm this as i have just tested with just a arduino and just a graphics display.
#define MY_TRANSPORT_WAIT_READY_MS 4000 //This will allow the sensor to function if it can't find the gateway when it first starts up
So if you add this and the display still does not display then you need to test the display connections.
You stated
"Display is working with Adafruit graphicstest example pins:
#define TFT_CS 10 #define TFT_RST 9 #define TFT_DC 8# define TFT_SCLK 13 #define TFT_MOSI 11
I did try the same pins in FAN sketch -nothing on display
Tryed pin# from FAN sketch on Adafruit graphicstest- nothing on display."So with standard connections the display is working.
So you need to test and get the display working with the adafruit test program using the correct pins required for the house fan program.Add the following info the adafruit test sketch as option 3 and comment out the options 1 and 2. Wire the graphic display as per the house fan requirements and it should work.
// Option 3: testing pins used in Whole House Fan Node #define TFT_CS 3 #define TFT_DC 6 #define TFT_MOSI 7 #define TFT_SCLK 8 #define TFT_RST 0 // you can also connect this to the Arduino reset // in which case, set this #define pin to 0 Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_MOSI, TFT_SCLK, TFT_RST);
If it does not work the same as when connected to the standard connections , then your wiring is in error and need to be changed to make it work before proceeding to the other sketch.
-
Thank you very much. Star Over. Rewire display and change the code. Never thought I would be excited to see the word ”Error” on display :).
I got five NRF24L01+. Two of them are not working at all. Looks like the one on the gateway working ok, but the node is unstable.
Do I need to create an additional device for Fan in Vera or, it will be displayed within the MySensors serial gateway?
-
@hard-shovel Thanks for the help.
@lis610 You are picking a very advanced project to start with. If you have the time I'd suggest an easier project like a motion sensor to get started. If you want to keep going I'd suggest doing some additional reading/watching on how this all works. Not trying to be critical but rather save you frustration.
I'm not running UI7 on my Vera so I haven't tested but it should automatically create your device as long as you are including it when first starting the node. For me I press the "Start" button then power up my node (the fan in this case).
However, if you don't have good communication it may not add correctly.
-
.......Thanks
-
Replaced NRF24L01+ and it is working now.
Having trouble with DHT22 it is working on MEGA, but not on Pro Mini ATMega328P 3.3V 8MHz any suggestions
-
@lis610 I find that at 3.3 some of my DHT22s are unreliable and at 3.2V it just gets worse..
The data sheet shows the minimum voltage as being 3.3V, and i suspect my Chinese supplied items are not within specification.
while you are using a 3.3V pro mini do you have a 5V supply for the DHT22?
You will find they are much more reliable at the higher voltage.
-
@lis610 Great news! I echo what @hard-shovel said. I try to supply my 5v sensors with 5v power from a regulator (with the appropriate capacitors) instead of my Arduino.
-
I am using 5V power supply and testing sensor with DHT example. DHT is working with MEGA power by 3.3 or 5 v. Maybe it is not working because of Pro Mini 8MHz?
-
@lis610 It should work at 8MHz. Have you double checked the wiring? Did you try with the default sketch in the DHT library? What are the debug messages saying?
-
@lis610 DHT22 being a "one wire" protocol, are timing dependent. Make sure that you have defined #define F_CPU 8000000L or have selected the 8mhz option in the newer versions of the IDE. If #define F_CPU gives you an error, you have to do it in the IDE.
Are you using the Adafruit DHT library? Which version? To double check that your CPU frequency is correct, create a new sketch with the following:void setup() { pinMode(13, OUTPUT); } void loop() { digitalWrite(13,HIGH); delay(10000); digitalWrite(13,LOW); delay(10000); }
Then time the speed of the blinks. it should be 10 seconds on and 10 seconds off. if you're getting 20 seconds on and 20 seconds off, your F_CPU is wrong.
-
Thank you, guys.
Got the DHT working! Next step connect motor and fan, fingers crossed
-
@lis610 you can't just leave us hanging and say "it's working", tell us what the problem was. Was it wiring, was it the 8mhz, was it a wrong library setting, was it a bad sensor? What did you do to make it work? The next person will want to know because they could have the same issue and it teaches the rest of us which troubleshooting tips are working.
-
In the beginning, I connected the DHT sensor to Pro Mini A0 and separate power supply (5V) and ran DHT Example sketch and eading was "nan". Want to mention that all other wires (FAN setup ) attached to Pro Mini as well. Then I disconnect Pro Mini from setup and connect DHT to it (GND, VCC, and A0) got numbers by running DHT Example. Connect everything together (motor, display, radio) and connect DHT to Pro Mini (GND, VCC, and A0) turn on and got zeros for Temp and Hum. Got frustrated and left for a walk. When I come back, Temp: 85 and Hum 52. I was not patient enough. It takes 5 to 6 min for Temp to show on display. I also tried to connect DHT VCC to the external power supply 3.3 and 5 V, but leave GND connected to Pro Mini and it works.
-
Finish! Thank you for all your help!
![alt text](image url)
-
@lis610 Awesome! Congratulations and great job for not giving up. That was a lot to tackle for a first project! Nice enclosure to house everything. Looks way cleaner than mine
-
Can you add additional code; Close the cover if Fan does not start and display error that fan has no power. Thank you.
-
Display. I used old case from iPod. Sprayed a little red paint and top it with black. Push button at the bottom of the case.
-
Looks great @lis610 !
-
I am using RCWL-0516 Microwave Radar Sensor for on/off the display. This sensor is very sensitive. I just want to activate the display in a close range. Any suggestions?
-
@lis610 said in Insulated Whole House Fan:
RCWL-0516
https://www.rogerclark.net/investigating-a-rcwl-9196-rcwl-0516-radar-motion-detector-modules/ shows some possible ways to read something other than a digital output of motion at 5 to 7 meters.
It doesn't look like there is a simple way to just make it less sensitive.
-
@lis610 said in Insulated Whole House Fan:
I am using RCWL-0516 Microwave Radar Sensor for on/off the display. This sensor is very sensitive. I just want to activate the display in a close range. Any suggestions?
You could try the XYC-WB-DC radar sensor. This one allows the sensitivity to be adjusted by changing a resitor value. Here's a Youtube video about it:
Modifying a XYC-WB-DC Microwave Motion Sensor for use in a Sonoff SC – 19:09
— Blair ThompsonI'm waiting for mine to come in from China, so no first hand experience yet on how these sensors work.
-
@lis610 I have found with a 499K resistor the range is reduced to about 1.2m in a ABS box.
With a 1Mohm it was about 3m, I do not have many high value SMD resistors to experiment with but the lower the value the lower the range.Just tried with a 333K and it operates about 0.8m in free air.