The 1-wire sensor only requires a pull-up resistor on an I/O line and maybe one of the Prop C guys can chime in on some code. 1w devices all have serial numbers so that you could have dozens of sensors on the same wire but this requires far more complicated code and is not necessary for single devices.
As for the pulse counting sensor you can just set up a counter to accumulate pulses however the application schematic shows another I/O being used as the supply for the sensor so that when you take this supply pin high then the sensor will output the number of pulses corresponding to the temperature and then stop. So this circuit requires 2 I/O and a pull-down resistor although the code is extremely simple. Looking at the specs though it seems like it could be hooked-up with a single I/O and a pullup resistor just like the 1w devices but I would have to check this circuit.
The other thing about the 1-wire sensors is that you can also buy leaded probe versions on ebay for around the same price as genuine sensors. Here's one link.
I will go with the thermistor, cant find this sensor anywhere in my country.
Anyway I will keep on working on thermistor calibration and if i get reliable results i will post them.
In the link below I had developed a C version of the SPI interface from the PropTool Spin library and made it into a SimpleIDE library. In the library I had included functions for the 3208 8 channel, 12 bit ADC. I also have examples for using the 3208.
I don't know if that is what you are looking for or if your cable lengths would be a problem, but I think it would be worth a try.
Here is a simple circuit I have used to measure temperature using thermistors. Works really well with the Propeller by either counting the number of pulses over a period of time, measuring the low time, or using the ratio of the high and low times. In theory the ratio method would be the most accurate since it cancels out most of any drift, but I really have not seen much difference between the three.
At various times I have built it by soldering the resistors and capacitors to the dip chip and potting it, on a perf board, and on a PCB, and each method works just fine.
PS The schematic calls for a polyethylene capacitor but any film capacitor should work just as well.
Thank you for your video and code.
yet I have the propeller that has no build in a/d.
Thus my question is how to connect an external, and the code needed from there onwards.
if you have an ADC0831here's the code and the schematics below I'll be making a vid in a few... : ]
#include "simpletools.h" // Include simple tools
const int DATA = 2;
const int CLK = 1;
const int CS = 0;
int main() // Main function
{
while(1)
{
high(CS);
low(CLK);
low(CS);
int ADC0831 = shift_in(DATA, CLK, MSBPOST, 9);
high(CS);
putChar(HOME);
print("ADC0831 = %.2f V%c\n", ADC0831 * 0.0196);
pause(100);
}
}
Comments
As for the pulse counting sensor you can just set up a counter to accumulate pulses however the application schematic shows another I/O being used as the supply for the sensor so that when you take this supply pin high then the sensor will output the number of pulses corresponding to the temperature and then stop. So this circuit requires 2 I/O and a pull-down resistor although the code is extremely simple. Looking at the specs though it seems like it could be hooked-up with a single I/O and a pullup resistor just like the 1w devices but I would have to check this circuit.
The other thing about the 1-wire sensors is that you can also buy leaded probe versions on ebay for around the same price as genuine sensors.
Here's one link.
Anyway I will keep on working on thermistor calibration and if i get reliable results i will post them.
I don't know if that is what you are looking for or if your cable lengths would be a problem, but I think it would be worth a try.
Tom
forums.parallax.com/discussion/comment/1310288/#Comment_1310288
Here is a simple circuit I have used to measure temperature using thermistors. Works really well with the Propeller by either counting the number of pulses over a period of time, measuring the low time, or using the ratio of the high and low times. In theory the ratio method would be the most accurate since it cancels out most of any drift, but I really have not seen much difference between the three.
At various times I have built it by soldering the resistors and capacitors to the dip chip and potting it, on a perf board, and on a PCB, and each method works just fine.
PS The schematic calls for a polyethylene capacitor but any film capacitor should work just as well.