Homework board and 5v for SHT1x?
markj
Posts: 9
Hi-
I'm using a homework board to build a temp/humidity logger with the SHT1x. I need to supply 5v to the SHT1x and the homework board doesn't have a built-in 5v power supply.
What would be the best way to supply 5v to the SHT1x? I'd really like to be able to power down the SHT1x when I sleep the BS2 so the 9v battery will last as long as possible with the program waking up every couple of hours to take a reading.
Thanks- mj
I'm using a homework board to build a temp/humidity logger with the SHT1x. I need to supply 5v to the SHT1x and the homework board doesn't have a built-in 5v power supply.
What would be the best way to supply 5v to the SHT1x? I'd really like to be able to power down the SHT1x when I sleep the BS2 so the 9v battery will last as long as possible with the program waking up every couple of hours to take a reading.
Thanks- mj
Comments
You can use the Vdd (black header strip) at the top of the breadboard to supply the 5v.
Vdd=5v
Vin= voltage in
Vss=ground
Dave
Dave
Thanks for the response. When I measure the voltage from Vdd it measure 5v, thanks. I should have checked that first.
So that's not the problem I'm having I guess.
Here's what's going on...
I created this first on the BOE and everything worked great. Now I've moved it all the the homework board and I get very strange readings from the SHT1x. Using the same program that works on the BOE the homework board says it's 615.3C in my house. On the BOE with a BS2 it says the right temp.
Any ideas?
Thanks- mj
The BASIC Stamp regulator shouldn't be sourcing more than 50 mA. Our own Sensirion documentation indicates that it uses about 30 microwatts, which is very low. I went to the SHT1x datasheet and it indicates that the part uses less than 800 microamps during measure and sleep. The datasheet shows output peak current at 5 mA with 10 mA tri-state turned off. Somewhere else it says that the power consumption increases by 8 mA when the heating element is turned on.
Bottom line is that it appears safe to power from the BASIC Stamp's voltage regulator, but I recommend you carefully review the datasheet to come to the same conclusion as me.
Ken Gracey
Parallax, Inc.
Yes, I agree that it uses very little power (and I'm not using the heater function). Also, I have a serial LCD hooked up but the specs on that show it uses 3mA without the backlight (and mine doesn't have a backlight so no danger of turning it on by mistake.
I've attached my code that works on the BOE but not on the homework board just in case...
It's pretty much the sample code from the SHT1x package from you guys as far as the SHT1x code goes. I've included a debug statement that outputs the temp so you should be able to run it without the LCD to see the funky temp reading.
Thanks again for the fast response!
-mj
Dave
I have set this up and it is·running just fine.· I recommend double checking your set up and if that isn't the case, please set it up on the Board of Education and see if it still works.· This will tell us if· it is damaged or not.
Thanks,
Dave
Yes, I doubled checked the setup just now (in fact removed it and just re-did it). Still the errors on the Homework board.
Moving the SHT1x over to the BOE everything works as expected.
Also, I've tried switching which pins I'm using on the homework board (am now using pins 2 and 3) to connect to the SHT1x and still the same funky readings.
Is the homework board bad?
Thanks again-
mj
Let's have you try the basics first, I've attached a file for you to try.· let me know if this works.
Dave
Ok, on the BOE I get output like this:
soT...... 6098
tC....... 20.9∫
tF....... 69.7∫
soRH..... 1483
rhLin.... 55.6%
rhTrue... 51.5%
On the Homework board it looks like this:
soT...... 65535
tC....... 615.2∫
tF....... 1139.5∫
soRH..... 65535
rhLin.... 2641.1%
rhTrue... 6526.9%
Also, I should mention that I'm programming this from a MAC using MacBS2 using the 1.23 tokenizer (not that I think this would explain why it's working differently on the BOE and homework board)--but just so you have all the facts.
Thanks-
mj
Bad ground from the SHT-11 to the Homework board?
It's very suspicious that you are reading "All-Ones" from the SHT-11.
Just to be sure... I swapped the wire I was using for ground and moved the SHT1x to a new location on the breadboard to make sure I wasn't in a dead row on the bread board.
Still the same output.
-mj
Dave
No luck. Same issue using pins 14 and 15.
ShtData PIN 15
Clock PIN 14
soT...... 65535
tC....... 615.2∫
tF....... 1139.5∫
soRH..... 65535
rhLin.... 2641.1%
rhTrue... 6526.9%
Thanks- mj
Thanks,
Dave
There seems to be something seriously wrong there.
I see two things you could try to get closer to a solution:
1 imagine under which conditions your sensor can give the readings you see. From there you can work backwards to find more clues.
2 take everything out of the homework board and check every connection of it. Are the additional resistors, is there a short somewhere or a break in the printed cicuit. Do the voltages on pins have the value they should have, etc.
I hope you find the bug fast !!
Klaus
No problem and thanks for all of the time and help so far. Just got the RMA and it's on the way later today. I live in Santa Cruz so it might even be there tomorrow.
Again, thanks!
-mj
Dave
Hi mj,
Did you have the pulldown resistor installed on the clock pin, as suggested in the PDF file?
http://www.parallax.com/dl/src/prod/shtdocscode.zip
Lack of that resistor can cause the effect you observed, that is, raw readings of 65535. It is a mystery to me why it would work on the BOE but not on the homework board, but it may have to do with stray capacitance or something of that sort. The SHTxx will lock up if the clock pin comes up high when the power is applied. Some individual SHTxx chips are more subject to this effect than others. (I have used hundreds of these in field applications where I always hear about it if any of them act up! All my boards now have the pulldown resistor on the clock line, and that particular problem disappeared. The need for the resistor was not mentioned in the original Sensirion documentation.)
Another way to avoid that problem is to power the SHTxx from a stamp pin, and make the clock line a low output before applying the power.
A note about the power consumption. In between measurements, when it is asleep, the SHTxx draws less than one microamp (0.3 ua typical), so leaving it powered all the time from 5 volts will not add much to the power budget. When it takes a reading, the current drain pulses briefly to 0.5 milliamp, which is feasible from a Stamp pin. (However, it will not be as accurate, because the pin voltage is not as well controlled as Vdd.) Taking one reading per second takes an average current of about 30 microamps. The chip automatically goes to sleep between readings.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com
Thanks for the suggestions and advice. Yes on the pulldown resistor as described in the parallax docs--it was there and I swapped it for another one when I was debugging the circuit.
That's great news on the sleeping between readings for the SHT1x--I think I'll just try it connected to Vdd and see how long it lasts.
I may also try powering it from a stamp pin as you suggested.
Thanks very much for your response.
-mj