Go Down

Topic: Weather Station (Read 1 time) previous topic - next topic

Jun 14, 2013, 09:25 pm Last Edit: Jun 15, 2013, 12:17 am by caulculatordude123 Reason: 1
Hi guys,
I am making a weather station and I am thinking about the fact that going out to check gauges 2 or 3 times a day, let alone remembering to be consistent with the times, is kind of a pain in the neck. Instead of doing that, I have decided to program the Arduino to take readings from the weather instruments and record them on an SD card (or some other source of extra memory). Then, ONCE a day I will go out and record what the SD card has recorded, on the computer. I will be back for more help with the other sensors, but you have to start somewhere, so I have decided to ask about the thermometer. I have a Seeed Studio thermistor which came in a hand-me-down kit without directions. I don't know how to utilize advanced analog sensors like a thermistor and I could not find anything about this particular thermistor anywhere. All I know is that it is part of the Seeed Studio Electronic Brick: Starter Kit, and that it has its own processor that info goes through before it reaches the Atmega. Also, I have attached a picture of the piece. this is all I know about it.
Thanks,
Caulculatordude :)

P.S. I have and Uno, not a Due. This may cause problems I know, but I would really like to get away with the Uno, if that is at all possible.

#1
Jun 14, 2013, 09:39 pm Last Edit: Jun 15, 2013, 12:17 am by caulculatordude123 Reason: 1
Sorry, forgot photo. Here.

mauried

Without knowing anything about the Sensor, the project will be very difficult unless you can determine
what the data format is.
Proprietary sensors are a pain unless you have some kind of ability to display the data format and decode it.

Riva

The sensor is described in this pdf. The chip looks like it's an amplifier.

Thanks for the schematic! However that doesn't really help me to figure out how to control it. Should I just tinker a bit with some code and figure it out or does the schematic have something that would help me?
Quote
The sensor is described in this pdf. The chip looks like it's an amplifier.

What do you mean when you say it looks like an amplifier. A speaker?

wildbill

It appears that all you need to do is apply vcc (5V), ground and read the analog output from the sensor using analogRead. That'll get you a number between 0 and 1023. Use another thermometer to calibrate it and then a little math will convert that number to Celsius or Fahrenheit.

To start with though, just get the analog readings and display them in the IDE's serial terminal.

#6
Jun 15, 2013, 02:43 pm Last Edit: Jun 15, 2013, 06:56 pm by caulculatordude123 Reason: 1
Good news! I did more research on thermistors and found that a typical one will have temperature maximums at -130 degrees Fahrenheit and 266 degrees Fahrenheit. This means that probably this:
Quote
analogRead(tempSensor)=val;
if val==512 || 511...
and then however you record 68 degrees on an external memory source, should work out to 68 degrees! yeah! Will this work?

I'll try what you said first wildbill

Tested it like you said Wildbill.
here's the code
Quote
const int tempSensor = 1; //thermistor connected to analog pin 1
int val = 0; //stores temperature input value

void setup() {
  Serial.begin(9600); //opens serial port at 9600 bits per sec
}

void loop() {
  val = analogRead(tempSensor); //reads and stores temperature
 
  Serial.println(val); //prints serial info to serial monitor
 
  delay(100); //wait 100 milleseconds
}
I figured out that in 81.5 degrees fahrenheit, the analog value is between 400 and 412. This is nice because of the accuracy you can get between the 0 and 1023.
caulculatordude

wildbill

Glad to hear it's working. If you can't find some on-line data to see how it varies with temperature, see if you can take some readings with varying temps and get an idea what the graph looks like for conversion.

That's exactly what I was going to do. See great minds do think alike:)

Go Up