• Several years ago I asked about modernizing my grain bin monitoring system that uses legacy OPI-ONE cables.
Message 1 of 25 , Dec 11, 2012
View Source
• 0 Attachment
Several years ago I asked about modernizing my grain bin monitoring system that uses legacy OPI-ONE cables. http://dics.voicecontrol.ro/process_mails/arata_discutia/82222/measure_temp_with_diodes.html In talking to the company, I came to understand that these cables used diodes to measure temp. Tonight I found an old broken cable and did some tests...
1 -It appears to have one common (gnd) wire and another wire for each sensor.
2 - The reader for these cables reads 2.927 v open circuit.
3 - At 66 deg F that voltage drops to 0.652, at 81 it is 0.636 V.
But then it gets confusing to me at least. I unplugged the power (reference voltage) from the cable and checked some resistances...
4 - I thought I'd see low resistance in one direction (say sensor cable to ground) and infinite resistance in the other direction, but low and behold, I get an infinite resistance for 2-3 seconds in EITHER direction, then the resistance drops to 38-40 megaohms and then continues to go down gradually to 20 ish megaohms in 10-15 seconds. But conductivity nonetheless. Similar resistance behavior when two leads are checked for conductivity between them.

Anyway, I was hoping to turn this into an arduino project. So can I supply that just under 3 v - I bet it has to be very stable, right?
And if I can, then I've got to figure out how to only energize on one line at a time...

Any help would be great.
Chuck
• Sure looks like a diode, but the resistance readings are confusing. This sensor would be current driven rather than voltage, you should measure the current
Message 2 of 25 , Dec 11, 2012
View Source
• 0 Attachment
Sure looks like a diode, but the resistance readings are confusing.
This sensor would be current driven rather than voltage, you should
measure the current with the sensor connected.
(The meter inserts a fixed current and the voltage is measured).

I'd use digital one-wire sensors (Maxim) instead. Each sensor has a
fixed address and they are all just put int parallel. I use them in my
heating controller with good results.

This system appears to use them or something similar since you can
just daisy-chain sensors together:
<http://www.flaman.com/agriculture/pdfs/66-Cables.060714.pdf>

The conduit is also a neat idea, but excludes any moisture measurements.

ST

On Wed, Dec 12, 2012 at 7:18 AM, ebiz_59 <chuckm@...> wrote:
> Several years ago I asked about modernizing my grain bin monitoring system that uses legacy OPI-ONE cables. http://dics.voicecontrol.ro/process_mails/arata_discutia/82222/measure_temp_with_diodes.html In talking to the company, I came to understand that these cables used diodes to measure temp. Tonight I found an old broken cable and did some tests...
> 1 -It appears to have one common (gnd) wire and another wire for each sensor.
> 2 - The reader for these cables reads 2.927 v open circuit.
> 3 - At 66 deg F that voltage drops to 0.652, at 81 it is 0.636 V.
> But then it gets confusing to me at least. I unplugged the power (reference voltage) from the cable and checked some resistances...
> 4 - I thought I'd see low resistance in one direction (say sensor cable to ground) and infinite resistance in the other direction, but low and behold, I get an infinite resistance for 2-3 seconds in EITHER direction, then the resistance drops to 38-40 megaohms and then continues to go down gradually to 20 ish megaohms in 10-15 seconds. But conductivity nonetheless. Similar resistance behavior when two leads are checked for conductivity between them.
>
> Anyway, I was hoping to turn this into an arduino project. So can I supply that just under 3 v - I bet it has to be very stable, right?
> And if I can, then I've got to figure out how to only energize on one line at a time...
>
> Any help would be great.
> Chuck
>
>
>
> ------------------------------------
>
>
>
>
• Thanks Stefan, And that Flaman pdf is a good find. I hadn t seen that. I already have the old (DB9) cables in all my bins, but need to go to each bin with a
Message 3 of 25 , Dec 12, 2012
View Source
• 0 Attachment
Thanks Stefan,

And that Flaman pdf is a good find. I hadn't seen that. I already have
the old (DB9) cables in all my bins, but need to go to each bin with a
\$150 cable reader that hooks to the DB9 cable end and then allows me to
cycle through the sensors on that cable and record (WITH A PENCIL) the
temps. I contacted the company about getting an appliance that stayed
connected to the bin, read the temps a few times a day, (every hour
ish??) recorded that data and/or transmitted data over my farm wide WIFI
to a location that I could access from anywhere (internet). The company
said I'd have to REPLACE all cables with their new digital (2wire)
system. So I asked for a quote...I have 2 bin sites and thought I'd have
them do the easy one first... 7 bins... US\$28,000! That's US\$4k per
bin. So now you see my motivation to use the existing cables, even if I
have to have a microcontroller on each bin. And if done correctly, I
could add an in bin humidity sensor as well as one outside with an
outside temp sensor and I'd have enough info to add automatic control to
my bin fans and optimizing grain quality.

I've had some success with Arduino and DS18B20 and a generic humidity
sensor, so I'm looking for a way to read these existing OPI-ONE (DB9)
cables with an arduino (since I have several) or similar unit. I'm
thinking I could do the interpreting of old cables, plus new humidity
and temp for maybe \$200 per bin, and another couple hundred for motor
starters and I'd literally have something like \$500 per bin in a data
logging and fan controlling (money saving and grain quality optimizing)
system...a savings of \$3500 per bin times 20 total bins is like
\$70,000. And I "think" it's within reach for me technically, so I'm
motivated to get it done before the \$70,000 payback period, which is
maybe 15 years:o))

So back to the cables...I just used auto ranging ohms to measure the
unenergized cables. Maybe that wasn't appropriate - another poster on
[arduinohome yahoo group] mentioned that ohms setting might not have
enough oomph to measure the diodes. I've got a meter with diode tester
and will go do that today.

The open circuit voltage referenced is on the cable reader with the
cable not attached (DB9 unplugged). I took apart the cable reader to
measure the voltages with the cable attached. The cable attached
voltages (0.6ish) are with the cable attached to the cable reader and
probed where the cables come onto the PC board.

Inside the OPI-ONE cable reader, the main chip is a 40 pin 3.5 digit A/D
converter TC7106CPL 9641BC. There are 3 other 16 pin chips and 2 14
pin chips that I haven't tracked down yet... MC74HC4051W (8 channel
multiplexer), MC74HC00N, MC14588CP, MC145438CP, MC14070BCP. There are a
few resistors - mostly 4 band, but a few 6 band ones, a diode, a
transistor or two along with an LCD to display sensor # and temp. Looks
pretty simple, except I haven't found a couple of the chips. But this
cable reader is 30 years old - seriously.

But can I do something like create this constant current source (not
sure how to do or how to say), multiplex that to the cables and use an
analog input of arduino to measure the voltage, then use some math
(calibration) or a lookup table to convert to temp...? For bigger
cables (up to 8 leads) I'd have to use a mega (16?) or a multiplexer?
Actually, after saying this, for testing, I think I could just make a
breakout of the DB9 connection and plug those pins into an analog port
of the Arduino to see what I can see. How good is the A/D converter on
the Arduino? might I need better resolution? I noticed last night that
1 degree F was roughly 0.00x Volts DC. Can I get resolution of 0.000x
Volts DC without going to a high cost A/D?

Thanks Again, C

On 12/11/2012 11:38 PM, Stefan Trethan wrote:
>
> Sure looks like a diode, but the resistance readings are confusing.
> This sensor would be current driven rather than voltage, you should
> measure the current with the sensor connected.
> (The meter inserts a fixed current and the voltage is measured).
>
> I'd use digital one-wire sensors (Maxim) instead. Each sensor has a
> fixed address and they are all just put int parallel. I use them in my
> heating controller with good results.
>
> This system appears to use them or something similar since you can
> just daisy-chain sensors together:
> <http://www.flaman.com/agriculture/pdfs/66-Cables.060714.pdf>
>
> The conduit is also a neat idea, but excludes any moisture measurements.
>
> ST
>
> On Wed, Dec 12, 2012 at 7:18 AM, ebiz_59 <chuckm@...
> <mailto:chuckm%403rivers.net>> wrote:
> > Several years ago I asked about modernizing my grain bin monitoring
> system that uses legacy OPI-ONE cables.
> http://dics.voicecontrol.ro/process_mails/arata_discutia/82222/measure_temp_with_diodes.html
> In talking to the company, I came to understand that these cables used
> diodes to measure temp. Tonight I found an old broken cable and did
> some tests...
> > 1 -It appears to have one common (gnd) wire and another wire for
> each sensor.
> > 2 - The reader for these cables reads 2.927 v open circuit.
> > 3 - At 66 deg F that voltage drops to 0.652, at 81 it is 0.636 V.
> > But then it gets confusing to me at least. I unplugged the power
> (reference voltage) from the cable and checked some resistances...
> > 4 - I thought I'd see low resistance in one direction (say sensor
> cable to ground) and infinite resistance in the other direction, but
> low and behold, I get an infinite resistance for 2-3 seconds in EITHER
> direction, then the resistance drops to 38-40 megaohms and then
> continues to go down gradually to 20 ish megaohms in 10-15 seconds.
> But conductivity nonetheless. Similar resistance behavior when two
> leads are checked for conductivity between them.
> >
> > Anyway, I was hoping to turn this into an arduino project. So can I
> supply that just under 3 v - I bet it has to be very stable, right?
> > And if I can, then I've got to figure out how to only energize on
> one line at a time...
> >
> > Any help would be great.
> > Chuck
> >
> >
> >
> > ------------------------------------
> >
> >
> >
> >
>
>

[Non-text portions of this message have been removed]
• Depending on your meter, if it applies a low enough voltage so that it doesn t go past the knee of the diode, it may appear as if it is (nearly) open-circuit
Message 4 of 25 , Dec 12, 2012
View Source
• 0 Attachment
Depending on your meter, if it applies a low enough voltage so that it
doesn't go past the "knee" of the diode, it may appear as if it is
(nearly) open-circuit in both directions.

It might also be that the sensor is a diode plus other circuitry,
designed to negate the effects of cable resistance.

A few decades ago I was using BE junctions of bipolar transistors to
measure temperature, which was part of a simple V-F converter, and
then the AC signal was sent over the wires, with a counter at the
other end to measure the frequency.

Andy
• I got a better multimeter and checked the cable, which again contains sensors every 4 feet so we can see if there is any stratification in a grain bin. The
Message 5 of 25 , Dec 12, 2012
View Source
• 0 Attachment
I got a better multimeter and checked the cable, which again contains
sensors every 4 feet so we can see if there is any stratification in a
grain bin. The diode function on the multimeter revealed a "OL" on one
polarity and an 0.698 with the other polarity, when measured to the
white (gnd) lead. So we have a diode on each of the lines in a
cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
molded into a heavy HDPE coating that has allowed these cables to 30
years. So I am not looking to replace the existing sensors in this
tough cable with the digital DS18B20.

In the existing data reader the lines come in and straight to a
MC74HC4051N an analog multiplexer. No resistor, just straight in.

So I think this leaves me hoping I can create a constant current source,
and read the cables into the analog ports of an arduino. A poster on
arduinohome thinks this might be too much for a limited electronics guy

thanks, Chuck

On 12/12/2012 1:36 PM, Stefan Trethan wrote:
> I haven't myself used a diode as temperature sensor.
>
> There is some basic information here, or anywhere on the web really:
> <http://www.tij.co.jp/jp/lit/an/sboa019/sboa019.pdf>
>
> For the electronics, you could go the old fashioned way with an A/D
> converter (10 bit internal to the microcontroller would suffice) and
> some analog conditioning electronics. But there are more elegant ways now.
>
> Turns out temperature measurement via a P/N junction is still very
> relevant, like in computer CPUs and such. They make ICs that take a
> diode input, and provide the data via digital interface like I2C. This
> one for example, but there are also multiple input types:
> <http://www.ti.com/product/lm82>
>
> ST
>
> On Wed, Dec 12, 2012 at 6:51 PM, chuck merja <chuckm@...
> <mailto:chuckm@...>> wrote:
>
> Thanks Stefan,
>
> And that Flaman pdf is a good find. I hadn't seen that. I already
> have the old (DB9) cables in all my bins, but need to go to each
> bin with a \$150 cable reader that hooks to the DB9 cable end and
> then allows me to cycle through the sensors on that cable and
> record (WITH A PENCIL) the temps. I contacted the company about
> getting an appliance that stayed connected to the bin, read the
> temps a few times a day, (every hour ish??) recorded that data
> and/or transmitted data over my farm wide WIFI to a location that
> I could access from anywhere (internet). The company said I'd
> have to REPLACE all cables with their new digital (2wire) system.
> So I asked for a quote...I have 2 bin sites and thought I'd have
> them do the easy one first... 7 bins... US\$28,000! That's US\$4k
> per bin. So now you see my motivation to use the existing cables,
> even if I have to have a microcontroller on each bin. And if done
> correctly, I could add an in bin humidity sensor as well as one
> outside with an outside temp sensor and I'd have enough info to
> add automatic control to my bin fans and optimizing grain quality.
>
> I've had some success with Arduino and DS18B20 and a generic
> humidity sensor, so I'm looking for a way to read these existing
> OPI-ONE (DB9) cables with an arduino (since I have several) or
> similar unit. I'm thinking I could do the interpreting of old
> cables, plus new humidity and temp for maybe \$200 per bin, and
> another couple hundred for motor starters and I'd literally have
> something like \$500 per bin in a data logging and fan controlling
> (money saving and grain quality optimizing) system...a savings of
> \$3500 per bin times 20 total bins is like \$70,000. And I "think"
> it's within reach for me technically, so I'm motivated to get it
> done before the \$70,000 payback period, which is maybe 15 years:o))
>
> So back to the cables...I just used auto ranging ohms to measure
> the unenergized cables. Maybe that wasn't appropriate - another
> poster on [arduinohome yahoo group] mentioned that ohms setting
> might not have enough oomph to measure the diodes. I've got a
> meter with diode tester and will go do that today.
>
> The open circuit voltage referenced is on the cable reader with
> the cable not attached (DB9 unplugged). I took apart the cable
> reader to measure the voltages with the cable attached. The cable
> attached voltages (0.6ish) are with the cable attached to the
> cable reader and probed where the cables come onto the PC board.
>
> Inside the OPI-ONE cable reader, the main chip is a 40 pin 3.5
> digit A/D converter TC7106CPL 9641BC. There are 3 other 16 pin
> chips and 2 14 pin chips that I haven't tracked down yet...
> MC74HC4051W (8 channel multiplexer), MC74HC00N, MC14588CP,
> MC145438CP, MC14070BCP. There are a few resistors - mostly 4 band,
> but a few 6 band ones, a diode, a transistor or two along with an
> LCD to display sensor # and temp. Looks pretty simple, except I
> haven't found a couple of the chips. But this cable reader is 30
> years old - seriously.
>
> But can I do something like create this constant current source
> (not sure how to do or how to say), multiplex that to the cables
> and use an analog input of arduino to measure the voltage, then
> use some math (calibration) or a lookup table to convert to
> temp...? For bigger cables (up to 8 leads) I'd have to use a mega
> (16?) or a multiplexer? Actually, after saying this, for testing,
> I think I could just make a breakout of the DB9 connection and
> plug those pins into an analog port of the Arduino to see what I
> can see. How good is the A/D converter on the Arduino? might I
> need better resolution? I noticed last night that 1 degree F was
> roughly 0.00x Volts DC. Can I get resolution of 0.000x Volts DC
> without going to a high cost A/D?
>
> Thanks Again, C
>
>

[Non-text portions of this message have been removed]
• If you, personally, can t do it, I suspect you could find a collaborator here. Saving the amount of money you are looking at would make it worth a few months
Message 6 of 25 , Dec 13, 2012
View Source
• 0 Attachment
If you, personally, can't do it, I suspect you could find a collaborator here. Saving the amount of money you are looking at would make it worth a few months of research, experimentation and development. I suspect you can do it, though. You've already done more than many in your shoes would have, and you figured it out by asking appropriate questions in an appropriate forum. Well on your way to success.

Donald.
--
*Plain Text* email -- it's an accessibility issue
() no proprietary attachments; no html mail
/\ ascii ribbon campaign - <www.asciiribbon.org>

----- Original Message -----
> From: "chuck merja" <chuckm@...>
> To: "Stefan Trethan" <stefan_trethan@...>, "Electronics 101" <Electronics_101@yahoogroups.com>
> Sent: Wednesday, December 12, 2012 11:43:19 PM
> Subject: Re: [Electronics_101] OPI-ONE cables again...
> I got a better multimeter and checked the cable, which again contains
> sensors every 4 feet so we can see if there is any stratification in a
> grain bin. The diode function on the multimeter revealed a "OL" on one
> polarity and an 0.698 with the other polarity, when measured to the
> white (gnd) lead. So we have a diode on each of the lines in a
> cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
> molded into a heavy HDPE coating that has allowed these cables to 30
> years. So I am not looking to replace the existing sensors in this
> tough cable with the digital DS18B20.
>
> In the existing data reader the lines come in and straight to a
> MC74HC4051N an analog multiplexer. No resistor, just straight in.
>
> So I think this leaves me hoping I can create a constant current
> source,
> and read the cables into the analog ports of an arduino. A poster on
> arduinohome thinks this might be too much for a limited electronics
> guy
>
> thanks, Chuck
>
> On 12/12/2012 1:36 PM, Stefan Trethan wrote:
> > I haven't myself used a diode as temperature sensor.
> >
> > There is some basic information here, or anywhere on the web really:
> > <http://www.tij.co.jp/jp/lit/an/sboa019/sboa019.pdf>
> >
> > For the electronics, you could go the old fashioned way with an A/D
> > converter (10 bit internal to the microcontroller would suffice) and
> > some analog conditioning electronics. But there are more elegant
> > ways now.
> >
> > Turns out temperature measurement via a P/N junction is still very
> > relevant, like in computer CPUs and such. They make ICs that take a
> > diode input, and provide the data via digital interface like I2C.
> > This
> > one for example, but there are also multiple input types:
> > <http://www.ti.com/product/lm82>
> >
> > ST
> >
> > On Wed, Dec 12, 2012 at 6:51 PM, chuck merja <chuckm@...
> > <mailto:chuckm@...>> wrote:
> >
> > Thanks Stefan,
> >
> > And that Flaman pdf is a good find. I hadn't seen that. I
> > have the old (DB9) cables in all my bins, but need to go to each
> > bin with a \$150 cable reader that hooks to the DB9 cable end and
> > then allows me to cycle through the sensors on that cable and
> > record (WITH A PENCIL) the temps. I contacted the company about
> > getting an appliance that stayed connected to the bin, read the
> > temps a few times a day, (every hour ish??) recorded that data
> > and/or transmitted data over my farm wide WIFI to a location
> > that
> > I could access from anywhere (internet). The company said I'd
> > have to REPLACE all cables with their new digital (2wire)
> > system.
> > So I asked for a quote...I have 2 bin sites and thought I'd have
> > them do the easy one first... 7 bins... US\$28,000! That's US\$4k
> > per bin. So now you see my motivation to use the existing
> > cables,
> > even if I have to have a microcontroller on each bin. And if
> > done
> > correctly, I could add an in bin humidity sensor as well as one
> > outside with an outside temp sensor and I'd have enough info to
> > add automatic control to my bin fans and optimizing grain
> > quality.
> >
> > I've had some success with Arduino and DS18B20 and a generic
> > humidity sensor, so I'm looking for a way to read these existing
> > OPI-ONE (DB9) cables with an arduino (since I have several) or
> > similar unit. I'm thinking I could do the interpreting of old
> > cables, plus new humidity and temp for maybe \$200 per bin, and
> > another couple hundred for motor starters and I'd literally have
> > something like \$500 per bin in a data logging and fan
> > controlling
> > (money saving and grain quality optimizing) system...a savings
> > of
> > \$3500 per bin times 20 total bins is like \$70,000. And I "think"
> > it's within reach for me technically, so I'm motivated to get it
> > done before the \$70,000 payback period, which is maybe 15
> > years:o))
> >
> > So back to the cables...I just used auto ranging ohms to measure
> > the unenergized cables. Maybe that wasn't appropriate - another
> > poster on [arduinohome yahoo group] mentioned that ohms setting
> > might not have enough oomph to measure the diodes. I've got a
> > meter with diode tester and will go do that today.
> >
> > The open circuit voltage referenced is on the cable reader with
> > the cable not attached (DB9 unplugged). I took apart the cable
> > reader to measure the voltages with the cable attached. The
> > cable
> > attached voltages (0.6ish) are with the cable attached to the
> > cable reader and probed where the cables come onto the PC board.
> >
> > Inside the OPI-ONE cable reader, the main chip is a 40 pin 3.5
> > digit A/D converter TC7106CPL 9641BC. There are 3 other 16 pin
> > chips and 2 14 pin chips that I haven't tracked down yet...
> > MC74HC4051W (8 channel multiplexer), MC74HC00N, MC14588CP,
> > MC145438CP, MC14070BCP. There are a few resistors - mostly 4
> > band,
> > but a few 6 band ones, a diode, a transistor or two along with
> > an
> > LCD to display sensor # and temp. Looks pretty simple, except I
> > haven't found a couple of the chips. But this cable reader is 30
> > years old - seriously.
> >
> > But can I do something like create this constant current source
> > (not sure how to do or how to say), multiplex that to the cables
> > and use an analog input of arduino to measure the voltage, then
> > use some math (calibration) or a lookup table to convert to
> > temp...? For bigger cables (up to 8 leads) I'd have to use a
> > mega
> > (16?) or a multiplexer? Actually, after saying this, for
> > testing,
> > I think I could just make a breakout of the DB9 connection and
> > plug those pins into an analog port of the Arduino to see what I
> > can see. How good is the A/D converter on the Arduino? might I
> > need better resolution? I noticed last night that 1 degree F was
> > roughly 0.00x Volts DC. Can I get resolution of 0.000x Volts DC
> > without going to a high cost A/D?
> >
> > Thanks Again, C
> >
> >
>
>
>
> [Non-text portions of this message have been removed]
>
>
>
> ------------------------------------
>
>
>
>
• Arduinos are specifically for people learning electronics and programming, so why not? http://arduino.cc/en/Reference/AnalogRead The Mega Arduino has 16 analog
Message 7 of 25 , Dec 13, 2012
View Source
• 0 Attachment
Arduinos are specifically for people learning electronics and programming, so why not?

The Mega Arduino has 16 analog to digital inputs, 10 bits resolution. Default is 0 to 5V via an internal 5V reference (really just Vcc), and you could use OpAmps to correct for this. Or you can configure the analog inputs differently.

http://arduino.cc/en/Reference/AnalogReference

You can switch to an internal 1.1V reference (see the difference between Arduinos in the above link) or use an external reference. With 10 bits of coverage (1024 differences) which means about 1mV per bit, and about -2mV/C, that is just about 0.5C per bit. A little calibration trimming can put it right at 1C per bit, or you can use an external reference and adjust that so it is 1C per bit.

The Mega uses the ATMeta2560 microcontroller.
http://www.atmel.com/Images/doc2549.pdf

If you don't need more than 8 ADC input channels, or if you need more than 16, you can use an external analog switch and use a "lesser" Arduino. It is also relatively simple to send the data from the Arduino to a computer if you wish to display it there. Check out the language "Processing".

http://www.processing.org/

Steve Greenfield AE7HD

--- In Electronics_101@yahoogroups.com, chuck merja <chuckm@...> wrote:
>
> I got a better multimeter and checked the cable, which again contains
> sensors every 4 feet so we can see if there is any stratification in a
> grain bin. The diode function on the multimeter revealed a "OL" on one
> polarity and an 0.698 with the other polarity, when measured to the
> white (gnd) lead. So we have a diode on each of the lines in a
> cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
> molded into a heavy HDPE coating that has allowed these cables to 30
> years. So I am not looking to replace the existing sensors in this
> tough cable with the digital DS18B20.
>
> In the existing data reader the lines come in and straight to a
> MC74HC4051N an analog multiplexer. No resistor, just straight in.
>
> So I think this leaves me hoping I can create a constant current source,
> and read the cables into the analog ports of an arduino. A poster on
> arduinohome thinks this might be too much for a limited electronics guy
>
> thanks, Chuck
>
• For the cost savings, you can pay for a 4 year college EE course and a couple of years of grad school! You asked if the Arduino can measure down to 0.000x
Message 8 of 25 , Dec 13, 2012
View Source
• 0 Attachment
For the cost savings, you can pay for a 4 year college EE course and a couple of years of grad school!

You asked if the Arduino can measure down to 0.000x volts. Any A/D converter has the same capability. Take the A/D max voltage (say 5V for the Arduino) and divide by the full scale count (say 1024 for a 10 bit converter). So, 5V / 1024 means that the least signigicant bit is 0.0048 volts. So, no, it can't measure down to 0.000x.

Conceptually, your problem isn't measuring to 5V, it is measuring small parts of 0.3V because, over temperature, the diode voltage will vary between 0.5V and 0.8V

http://www.ti.com/lit/an/sbaa073a/sbaa073a.pdf

So, it varies by 0.3V or about 100 counts on a 1024 count A/D converter. Not too good!

What has to happen (and you may not be seeing it since you don't have a real schematic) is the the voltage needs to be rescaled to take up more bits in the converter. Multiplying by 10 would be a good start. Then the voltage would span about 1000 counts.

Short answer, an op amp can be used to rescale and offset the voltage to use more of the conversion capability.

If we multiply by 10, the diode voltage will vary between 5V and 8V! We need to offset that by subtracting something like 5V so that the result is around 0V to 3V. That's what offsetting does.

When you get that far, see "Op Amps For Everyone" Chapter 4
http://www.ti.com/lit/an/slod006b/slod006b.pdf

It takes a decent op amp and 4 resistors - no big deal!

So, you can run the cable inputs through a MUX and then through an op-amp to rescale and offset before running the result into the Arduino A/D input.

Do a lot of reading re: using diodes to measure temperature. In most cases, there will be a constant current source. Remember that an analog MUX is a bidirectional thing. The current source is probably on the 'output' side just ahead of whatever the existing device uses to amplify and convert the signal. They could use a single transistor as a current source!

Almost every uC on the planet has at least a 10 bit multi-input A/D converter with multiple inputs. There is also an Arduino shield for WiFi and it appears that the shield itself contains all the code for the TCP/IP stack.

http://www.cooking-hacks.com/index.php/blog/tutorial-wifi-module-for-arduino-roving-rn-xvee

I would worry about the environmental conditions for the electronics. Locating the electronics where temperatures aren't extreme would be good. Or, add a heater and temperature controller to the box. I don't know your location so I don't know whether I would worry about the high temperatures. Mounting the box in the shade might be enough. Remember that every component will change characteristics over temperature. I would pay a great deal of attention to the Op Amp because it is multiplying by at least 10. Similarly, the A/D converter isn't immune to temperature swings.

Fun experiment: take an existing diode (or just buy a 1N4001), connect it to your multimeter and then subject it to various temperatures. In the freezer, in the room, outdoors, in boiling water (insulate the wires, of course). Just to see... The voltage display on the meter should change.

Richard
• Chuck, nothing is ever too much for you to handle. You can research any topic you want and learn. Don t give up. I didn t. Larry From:
Message 9 of 25 , Dec 13, 2012
View Source
• 0 Attachment
Chuck, nothing is ever too much for you to handle. You can research any
topic you want and learn.

Don't give up. I didn't.

Larry

From: Electronics_101@yahoogroups.com
[mailto:Electronics_101@yahoogroups.com] On Behalf Of chuck merja
Sent: Wednesday, December 12, 2012 11:43 PM
To: Stefan Trethan; Electronics_101@yahoogroups.com
Subject: Re: [Electronics_101] OPI-ONE cables again...

I got a better multimeter and checked the cable, which again contains
sensors every 4 feet so we can see if there is any stratification in a
grain bin. The diode function on the multimeter revealed a "OL" on one
polarity and an 0.698 with the other polarity, when measured to the
white (gnd) lead. So we have a diode on each of the lines in a
cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
molded into a heavy HDPE coating that has allowed these cables to 30
years. So I am not looking to replace the existing sensors in this
tough cable with the digital DS18B20.

In the existing data reader the lines come in and straight to a
MC74HC4051N an analog multiplexer. No resistor, just straight in.

So I think this leaves me hoping I can create a constant current source,
and read the cables into the analog ports of an arduino. A poster on
arduinohome thinks this might be too much for a limited electronics guy

thanks, Chuck

On 12/12/2012 1:36 PM, Stefan Trethan wrote:
> I haven't myself used a diode as temperature sensor.
>
> There is some basic information here, or anywhere on the web really:
> <http://www.tij.co.jp/jp/lit/an/sboa019/sboa019.pdf>
>
> For the electronics, you could go the old fashioned way with an A/D
> converter (10 bit internal to the microcontroller would suffice) and
> some analog conditioning electronics. But there are more elegant ways now.
>
> Turns out temperature measurement via a P/N junction is still very
> relevant, like in computer CPUs and such. They make ICs that take a
> diode input, and provide the data via digital interface like I2C. This
> one for example, but there are also multiple input types:
> <http://www.ti.com/product/lm82>
>
> ST
>
> On Wed, Dec 12, 2012 at 6:51 PM, chuck merja <chuckm@...
<mailto:chuckm%403rivers.net>
> <mailto:chuckm@... <mailto:chuckm%403rivers.net> >> wrote:
>
> Thanks Stefan,
>
> And that Flaman pdf is a good find. I hadn't seen that. I already
> have the old (DB9) cables in all my bins, but need to go to each
> bin with a \$150 cable reader that hooks to the DB9 cable end and
> then allows me to cycle through the sensors on that cable and
> record (WITH A PENCIL) the temps. I contacted the company about
> getting an appliance that stayed connected to the bin, read the
> temps a few times a day, (every hour ish??) recorded that data
> and/or transmitted data over my farm wide WIFI to a location that
> I could access from anywhere (internet). The company said I'd
> have to REPLACE all cables with their new digital (2wire) system.
> So I asked for a quote...I have 2 bin sites and thought I'd have
> them do the easy one first... 7 bins... US\$28,000! That's US\$4k
> per bin. So now you see my motivation to use the existing cables,
> even if I have to have a microcontroller on each bin. And if done
> correctly, I could add an in bin humidity sensor as well as one
> outside with an outside temp sensor and I'd have enough info to
> add automatic control to my bin fans and optimizing grain quality.
>
> I've had some success with Arduino and DS18B20 and a generic
> humidity sensor, so I'm looking for a way to read these existing
> OPI-ONE (DB9) cables with an arduino (since I have several) or
> similar unit. I'm thinking I could do the interpreting of old
> cables, plus new humidity and temp for maybe \$200 per bin, and
> another couple hundred for motor starters and I'd literally have
> something like \$500 per bin in a data logging and fan controlling
> (money saving and grain quality optimizing) system...a savings of
> \$3500 per bin times 20 total bins is like \$70,000. And I "think"
> it's within reach for me technically, so I'm motivated to get it
> done before the \$70,000 payback period, which is maybe 15 years:o))
>
> So back to the cables...I just used auto ranging ohms to measure
> the unenergized cables. Maybe that wasn't appropriate - another
> poster on [arduinohome yahoo group] mentioned that ohms setting
> might not have enough oomph to measure the diodes. I've got a
> meter with diode tester and will go do that today.
>
> The open circuit voltage referenced is on the cable reader with
> the cable not attached (DB9 unplugged). I took apart the cable
> reader to measure the voltages with the cable attached. The cable
> attached voltages (0.6ish) are with the cable attached to the
> cable reader and probed where the cables come onto the PC board.
>
> Inside the OPI-ONE cable reader, the main chip is a 40 pin 3.5
> digit A/D converter TC7106CPL 9641BC. There are 3 other 16 pin
> chips and 2 14 pin chips that I haven't tracked down yet...
> MC74HC4051W (8 channel multiplexer), MC74HC00N, MC14588CP,
> MC145438CP, MC14070BCP. There are a few resistors - mostly 4 band,
> but a few 6 band ones, a diode, a transistor or two along with an
> LCD to display sensor # and temp. Looks pretty simple, except I
> haven't found a couple of the chips. But this cable reader is 30
> years old - seriously.
>
> But can I do something like create this constant current source
> (not sure how to do or how to say), multiplex that to the cables
> and use an analog input of arduino to measure the voltage, then
> use some math (calibration) or a lookup table to convert to
> temp...? For bigger cables (up to 8 leads) I'd have to use a mega
> (16?) or a multiplexer? Actually, after saying this, for testing,
> I think I could just make a breakout of the DB9 connection and
> plug those pins into an analog port of the Arduino to see what I
> can see. How good is the A/D converter on the Arduino? might I
> need better resolution? I noticed last night that 1 degree F was
> roughly 0.00x Volts DC. Can I get resolution of 0.000x Volts DC
> without going to a high cost A/D?
>
> Thanks Again, C
>
>

[Non-text portions of this message have been removed]

[Non-text portions of this message have been removed]
• ... Sometimes the part numbers are a little difficult to read. I ll guess at the following: MC14543B (not ..438) - BCD - 7 Segment Display Driver - makes
Message 10 of 25 , Dec 13, 2012
View Source
• 0 Attachment
--- In Electronics_101@yahoogroups.com, chuck merja <chuckm@...> wrote:

> Inside the OPI-ONE cable reader, the main chip is a 40 pin 3.5 digit A/D
> converter TC7106CPL 9641BC. There are 3 other 16 pin chips and 2 14
> pin chips that I haven't tracked down yet... MC74HC4051W (8 channel
> multiplexer), MC74HC00N, MC14588CP, MC145438CP, MC14070BCP. There are a
> few resistors - mostly 4 band, but a few 6 band ones, a diode, a
> transistor or two along with an LCD to display sensor # and temp. Looks
> pretty simple, except I haven't found a couple of the chips. But this
> cable reader is 30 years old - seriously.

Sometimes the part numbers are a little difficult to read. I'll guess at the following:

MC14543B (not ..438) - BCD - 7 Segment Display Driver - makes sense
MC1458B - Dual Op amps - Maybe the constant current source and scaling
MC74HC00N - Quad 2 input NAND gates

Those 6 band resistors are probably near the Op Amps.

Before you settle on the Arduino/WiFi scheme, make sure the module has enough power to reliably reach your router.

The Arduino WiFi Shield documentation doesn't show how to connect an external antenna. Also, it won't connect to hidden networks. It will connect to encrypted networks.

https://www.sparkfun.com/products/11287

Here is a WiFi web server using the Arduino to serve up 6 analog inputs:

http://arduino.cc/en/Tutorial/WiFiWebServer

This webserver approach is pretty much the standard way to do remote sensors. Whether the client wants to display a web page or not, it would do an HTTP GET to receive the data. It could just parse the returned message and toss all the nonsense surrounding the data values.

I would look around for WiFi modules that have a connector for an external antenna. They are around. I think the reason that they aren't quite as readily available may have to do with FCC issues.

Assuming that your electronics is both distant and enclosed in a metal weatherproof box it would seem to me that an external antenna is a requirement.

I might try a completely different approach to WiFi and use this Lantronix Serial<->WiFi module (which does work with an external antenna). It's a little more money than the Arduino WiFi Shield but it makes WiFi completely independent of the uC platform. If you want to start with an Arduino, fine. But if you want to migrate to something else, well, the WiFi module stays the same.

http://www.lantronix.com/device-networking/embedded-device-servers/wiport.html#tabs

One other thought: Some of the newer Arduinos are 3.3V versus 5.0V. This always matters and it especially matters for the A/D inputs. The math for scaling and offset would change.

Richard
• I use temp sensors in many places around the house. My favorite is a series string of four silicon diodes (1N4148). Each diode changes voltage with
Message 11 of 25 , Dec 13, 2012
View Source
• 0 Attachment
I use temp sensors in many places around the house. My favorite is a series
string of four silicon diodes (1N4148). Each diode changes voltage with
temperature at -2.5 mV/C. Use four diodes and you get about -10mV/C. I
generate a 1.0 mA of current thru the diodes. What is your power supply
voltage? You use a resistor in series with your power supply, preferably a
12 Vdc supply to get your 1.0 mA of current. Then the voltage across the
diodes (or diode) is exactly inversely proportional to temperature.

I use an op amp to change the voltage gain and offset to get the band of
temperature desired. Then there is now the 0 to 5V needed for your
microprocessor A to D input.

That is how I would do it.

Larry

From: Electronics_101@yahoogroups.com
[mailto:Electronics_101@yahoogroups.com] On Behalf Of rtstofer
Sent: Thursday, December 13, 2012 3:10 PM
To: Electronics_101@yahoogroups.com
Subject: [Electronics_101] Re: OPI-ONE cables again...

[Non-text portions of this message have been removed]
• Measuring temperature with a diode is an old idea. But the semiconductor houses have taken it to a new level. You can buy a one-chip solution that handles
Message 12 of 25 , Dec 13, 2012
View Source
• 0 Attachment
Measuring temperature with a diode is an old idea. But the semiconductor houses have taken it to a new level. You can buy a one-chip solution that handles ALL of the analog stuff and just presents the data over an I2C connection. Among many other devices is:

Some of the devices can handle up to 1500 ohms of series resistance and that's good because you would put an external analog switch in the circuit to select among the diodes.

The advantage to this approach is pretty obvious: You don't have to understand a darn thing about analog electronics. You do have to get I2C working on some uC but this is usually included in some kind of library.

Digikey has that chip for \$1.42 in qty 1 so it might be worth an experiment or two. I could see building a PCB with the analog switch controlled by Arduino IO pins and the single temperature sensor. Or I might buy an SMD->DIP adapter and breadboard the thing. Just to see...

Another nice device is the ON Semi NVT210 but I can't find a place to buy it in qty 1:

Richard
• If you go with the SPI/I2C IC, is there really any advantage to use the switch? I mean it would be like \$10 to provide individual ICs, and those that take up
Message 13 of 25 , Dec 13, 2012
View Source
• 0 Attachment
If you go with the SPI/I2C IC, is there really any advantage to use the switch?
I mean it would be like \$10 to provide individual ICs, and those that
take up to 4 diodes probably make it even cheaper.

ST

On Thu, Dec 13, 2012 at 11:09 PM, rtstofer <rstofer@...> wrote:
> Measuring temperature with a diode is an old idea. But the semiconductor houses have taken it to a new level. You can buy a one-chip solution that handles ALL of the analog stuff and just presents the data over an I2C connection. Among many other devices is:
>
> Some of the devices can handle up to 1500 ohms of series resistance and that's good because you would put an external analog switch in the circuit to select among the diodes.
>
> The advantage to this approach is pretty obvious: You don't have to understand a darn thing about analog electronics. You do have to get I2C working on some uC but this is usually included in some kind of library.
>
> Digikey has that chip for \$1.42 in qty 1 so it might be worth an experiment or two. I could see building a PCB with the analog switch controlled by Arduino IO pins and the single temperature sensor. Or I might buy an SMD->DIP adapter and breadboard the thing. Just to see...
>
> Another nice device is the ON Semi NVT210 but I can't find a place to buy it in qty 1:
>
>
> Richard
>
>
>
>
> ------------------------------------
>
>
>
>
• ... One thing that may not be apparent is that you need to switch two signal lines, use two multiplexers and a differential amplifier to convert the diode
Message 14 of 25 , Dec 14, 2012
View Source
• 0 Attachment
On 12/12/2012 10:43 PM, chuck merja wrote:
>
> I got a better multimeter and checked the cable, which again contains
> sensors every 4 feet so we can see if there is any stratification in a
> grain bin. The diode function on the multimeter revealed a "OL" on one
> polarity and an 0.698 with the other polarity, when measured to the
> white (gnd) lead. So we have a diode on each of the lines in a
> cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
> molded into a heavy HDPE coating that has allowed these cables to 30
> years. So I am not looking to replace the existing sensors in this
> tough cable with the digital DS18B20.
>
> In the existing data reader the lines come in and straight to a
> MC74HC4051N an analog multiplexer. No resistor, just straight in.
>
> So I think this leaves me hoping I can create a constant current source,
> and read the cables into the analog ports of an arduino. A poster on
> arduinohome thinks this might be too much for a limited electronics guy
>
> thanks, Chuck
>

One thing that may not be apparent is that you need to switch two signal
lines, use two multiplexers and a differential amplifier to convert the
diode signal to a single ended signal for use with a microprocessor like
an Arduido UNO.

Or you could use an Arduino compatible microprocessor that has a
differential A to D. This would eliminate the need for a differential
amplifier. But with 8 diodes per cable you still need two
multiplexers. A low cost Arduino compatible microprocessor with 8
differential inputs is a lot harder to find.

The other Howard.

[Non-text portions of this message have been removed]
• ... The thing is, those chips don t have address select pins. There s one address and, therefore, only one of the devices can be on the I2C bus. Well, in one
Message 15 of 25 , Dec 14, 2012
View Source
• 0 Attachment
--- In Electronics_101@yahoogroups.com, Stefan Trethan <stefan_trethan@...> wrote:
>
> If you go with the SPI/I2C IC, is there really any advantage to use the switch?
> I mean it would be like \$10 to provide individual ICs, and those that
> take up to 4 diodes probably make it even cheaper.
>
> ST
>

The thing is, those chips don't have address select pins. There's one address and, therefore, only one of the devices can be on the I2C bus. Well, in one case, there was an optional part # with a second address but it might be difficult to source.

I have no idea how many sensors are in a cable but I couldn't see implementing that many I2C channels with bit-banging.

It could be done either way, I suppose, but I really dislike bit-banging.

Richard
• Ah yes, that s a problem. One could use a bus multiplexer or disable the ICs in some other way, but then you might as well just mux the analog side. ST
Message 16 of 25 , Dec 14, 2012
View Source
• 0 Attachment
Ah yes, that's a problem.
One could use a bus multiplexer or disable the ICs in some other way,
but then you might as well just mux the analog side.

ST

On Fri, Dec 14, 2012 at 5:38 PM, rtstofer <rstofer@...> wrote:
>
>
> The thing is, those chips don't have address select pins. There's one address and, therefore, only one of the devices can be on the I2C bus. Well, in one case, there was an optional part # with a second address but it might be difficult to source.
>
> I have no idea how many sensors are in a cable but I couldn't see implementing that many I2C channels with bit-banging.
>
> It could be done either way, I suppose, but I really dislike bit-banging.
>
> Richard
>
• I m not sure I understand your comments. There are a maximum of 8 sensor wires and one ground wire in the cable. I m not sure how this all occurs, but I
Message 17 of 25 , Dec 14, 2012
View Source
• 0 Attachment
I'm not sure I understand your comments. There are a maximum of 8
sensor wires and one ground wire in the cable. I'm not sure how this
all occurs, but I guess that each of the sensor leads has a diode at the
end of it and the other side of each diode is then tapped into the
common ground cable. If this is true, then I definitely need to read
these cables one at a time.

But given that wiring, does your comment still apply, or do I just need
up a single 8 channel mux?

And can I dump the output of that 8 channel mux into one analog port on
ish to 0.6 volts high end so a "full range" of 0.2 volts, is that going
to be a problem in the arduino?

C

On 12/14/2012 9:35 AM, Howard Hansen wrote:
>
> On 12/12/2012 10:43 PM, chuck merja wrote:
> >
> > I got a better multimeter and checked the cable, which again contains
> > sensors every 4 feet so we can see if there is any stratification in a
> > grain bin. The diode function on the multimeter revealed a "OL" on one
> > polarity and an 0.698 with the other polarity, when measured to the
> > white (gnd) lead. So we have a diode on each of the lines in a
> > cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
> > molded into a heavy HDPE coating that has allowed these cables to 30
> > years. So I am not looking to replace the existing sensors in this
> > tough cable with the digital DS18B20.
> >
> > In the existing data reader the lines come in and straight to a
> > MC74HC4051N an analog multiplexer. No resistor, just straight in.
> >
> > So I think this leaves me hoping I can create a constant current source,
> > and read the cables into the analog ports of an arduino. A poster on
> > arduinohome thinks this might be too much for a limited electronics guy
> >
> > thanks, Chuck
> >
>
> One thing that may not be apparent is that you need to switch two signal
> lines, use two multiplexers and a differential amplifier to convert the
> diode signal to a single ended signal for use with a microprocessor like
> an Arduido UNO.
>
> Or you could use an Arduino compatible microprocessor that has a
> differential A to D. This would eliminate the need for a differential
> amplifier. But with 8 diodes per cable you still need two
> multiplexers. A low cost Arduino compatible microprocessor with 8
> differential inputs is a lot harder to find.
>
> The other Howard.
>
> [Non-text portions of this message have been removed]
>
>

[Non-text portions of this message have been removed]
• ... Yes, one way or another you need an 8 input MUX. The reader you are using has just such a MUX. Stefan and I were discussing using 8 of the IC solutions I
Message 18 of 25 , Dec 14, 2012
View Source
• 0 Attachment
--- In Electronics_101@yahoogroups.com, chuck merja <chuckm@...> wrote:
>
> I'm not sure I understand your comments. There are a maximum of 8
> sensor wires and one ground wire in the cable. I'm not sure how this
> all occurs, but I guess that each of the sensor leads has a diode at the
> end of it and the other side of each diode is then tapped into the
> common ground cable. If this is true, then I definitely need to read
> these cables one at a time.
>
> But given that wiring, does your comment still apply, or do I just need
> up a single 8 channel mux?
>
> And can I dump the output of that 8 channel mux into one analog port on
> ish to 0.6 volts high end so a "full range" of 0.2 volts, is that going
> to be a problem in the arduino?
>
> C

Yes, one way or another you need an 8 input MUX. The reader you are using has just such a MUX.

Stefan and I were discussing using 8 of the IC solutions I posted earlier instead of a MUX and, under normal I2C bus circumstances, that would be a great solution. Except that the I2C chips I linked aren't addressable in the normal way.

As I pointed out earlier, your existing reader is using an op amp and I bet it's arranged to scale and offset. Again, that's probably what the 6 band resistors are all about. Precision resistors for precision scaling.

You can do the math as well as anybody. I showed you earlier. 5V / 1024 counts means each count is about 0.005V so your entire range is just 40 counts. Is that good enough? Is that enough resolution? Go back and get the temperatures at each voltage end point and figure how many degrees they span. Then divide by 40 and that's what each count is worth in degrees.

As a first approximation of the diode drop, figure 2.6 mV per degree C. So, about the best you can measure directly when using the Arduino A/D is every 2 degrees C. Is that good enough?

Without knowing exactly what is in your reader, it's not possible to know how they accounted for other error factors. They may have figured that the reader would never get very cold or very hot.

I kind of like the chip solutions to measuring the diode drop and rescaling.

One thing the single chip solutions do is measure the voltage drop with 2 bias currents about a factor of 10 apart. In this way they can eliminate some of the possible error factors. Here is a good discussion of the process:
http://www.latticesemi.com/documents/TN1115.pdf

For the cost of a single op amp and 4 resistors, you can spread that 0.2V change across the entire 5V range of the A/D. Then 0.2V / 1024 implies that you can measure to 0.1 degree C - somewhere around 13 counts per degree C.

An advanced topic related to the calculations above is the use of a precision external Vref for the A/D converter. Why would you want to use one? First of all, it rescales the A/D! If you use an external 2.5V reference, all of a sudden the full scale is 2.5V and with 2.5V / 1024 you are measuring in terms of 0.002V per count. That will get you down to about 1 degree C per count. Next, the reference can be precision, not just whatever Vcc happens to be doing. The ATmegas also have an internal Vref but it doesn't come anywhere close to precision.

But one thing that is going to happen is that this device will be exposed to the environment long enough for the internals to change temperature. This is going to be a problem. I suggested earlier that you come up with a heater and temp controller to keep the inside of the enclosure warm. Something around 100 degrees F comes to mind. So, you will want to insulate the box to keep the energy costs down.

Build up something as an experiment. Put the probe in boiling water and then in ice water. This will give you the 0-100 degree span on the input. Then put your electronics in an over heated to 100 degrees F and in an ice chest full of melting ice (I have no idea how to get the internals down into the cold water). You can put the box in the freezer overnight I suppose. This will give you some indication about the accuracy of the device over temperature.

Richard

Richard
• ... Hello Richard, Don t give up on the I2C approach. From recent comments from Chuck it looks like the existing system is switching the current source going
Message 19 of 25 , Dec 14, 2012
View Source
• 0 Attachment
On 12/14/2012 3:28 PM, rtstofer wrote:
>
>
>
> --- In Electronics_101@yahoogroups.com
> <mailto:Electronics_101%40yahoogroups.com>, chuck merja <chuckm@...>
> wrote:
> >
> > I'm not sure I understand your comments. There are a maximum of 8
> > sensor wires and one ground wire in the cable. I'm not sure how this
> > all occurs, but I guess that each of the sensor leads has a diode at
> the
> > end of it and the other side of each diode is then tapped into the
> > common ground cable. If this is true, then I definitely need to read
> > these cables one at a time.
> >
> > But given that wiring, does your comment still apply, or do I just need
> > up a single 8 channel mux?
> >
> > And can I dump the output of that 8 channel mux into one analog port on
> > ish to 0.6 volts high end so a "full range" of 0.2 volts, is that going
> > to be a problem in the arduino?
> >
> > C
>
> Yes, one way or another you need an 8 input MUX. The reader you are
> using has just such a MUX.
>
> Stefan and I were discussing using 8 of the IC solutions I posted
> earlier instead of a MUX and, under normal I2C bus circumstances, that
> would be a great solution. Except that the I2C chips I linked aren't
> addressable in the normal way.
>
> As I pointed out earlier, your existing reader is using an op amp and
> I bet it's arranged to scale and offset. Again, that's probably what
> the 6 band resistors are all about. Precision resistors for precision
> scaling.
>
> You can do the math as well as anybody. I showed you earlier. 5V /
> 1024 counts means each count is about 0.005V so your entire range is
> just 40 counts. Is that good enough? Is that enough resolution? Go
> back and get the temperatures at each voltage end point and figure how
> many degrees they span. Then divide by 40 and that's what each count
> is worth in degrees.
>
> As a first approximation of the diode drop, figure 2.6 mV per degree
> C. So, about the best you can measure directly when using the Arduino
> A/D is every 2 degrees C. Is that good enough?
>
> Without knowing exactly what is in your reader, it's not possible to
> know how they accounted for other error factors. They may have figured
> that the reader would never get very cold or very hot.
>
> I kind of like the chip solutions to measuring the diode drop and
> rescaling.
>
> One thing the single chip solutions do is measure the voltage drop
> with 2 bias currents about a factor of 10 apart. In this way they can
> eliminate some of the possible error factors. Here is a good
> discussion of the process:
> http://www.latticesemi.com/documents/TN1115.pdf
>
> For the cost of a single op amp and 4 resistors, you can spread that
> 0.2V change across the entire 5V range of the A/D. Then 0.2V / 1024
> implies that you can measure to 0.1 degree C - somewhere around 13
> counts per degree C.
>
> An advanced topic related to the calculations above is the use of a
> precision external Vref for the A/D converter. Why would you want to
> use one? First of all, it rescales the A/D! If you use an external
> 2.5V reference, all of a sudden the full scale is 2.5V and with 2.5V /
> 1024 you are measuring in terms of 0.002V per count. That will get you
> down to about 1 degree C per count. Next, the reference can be
> precision, not just whatever Vcc happens to be doing. The ATmegas also
> have an internal Vref but it doesn't come anywhere close to precision.
>
> But one thing that is going to happen is that this device will be
> exposed to the environment long enough for the internals to change
> temperature. This is going to be a problem. I suggested earlier that
> you come up with a heater and temp controller to keep the inside of
> the enclosure warm. Something around 100 degrees F comes to mind. So,
> you will want to insulate the box to keep the energy costs down.
>
> Build up something as an experiment. Put the probe in boiling water
> and then in ice water. This will give you the 0-100 degree span on the
> input. Then put your electronics in an over heated to 100 degrees F
> and in an ice chest full of melting ice (I have no idea how to get the
> internals down into the cold water). You can put the box in the
> freezer overnight I suppose. This will give you some indication about
> the accuracy of the device over temperature.
>
> Richard
>

Hello Richard,

Don't give up on the I2C approach. From recent comments from Chuck it
looks like the existing system is switching the current source going to
the diodes and only one diode is energized at a time. If this is true
then one could connect the I2C temperature reader to the input of the 8
channel multiplexer. Hence only one I2C device is required. What is
the on resistance of a typical analog multiplexer these days?

The other Howard

[Non-text portions of this message have been removed]
• Chuck, I know nothing of arduino and the like but I ve been reading about the Raspberry Pi project and there seems to be a few ideas there talking about web
Message 20 of 25 , Dec 14, 2012
View Source
• 0 Attachment
Chuck,

I know nothing of arduino and the like but I've been reading about the
Raspberry Pi project and there seems to be a few ideas there talking
about web links and the like. Even something using an arduino as the
front end interface for a r'pi web smart device.http://www.raspberrypi.org/

Just more stuff to read I'm afraid. I have my own binder of 'circuits
of interest' from way back in time!
• ... Absolutely! That would be my first approach. I don t want to do any more analog stuff than I have to. One of the single chip solutions I reviewed could
Message 21 of 25 , Dec 14, 2012
View Source
• 0 Attachment
--- In Electronics_101@yahoogroups.com, Howard Hansen <hrhan@...> wrote:

> Hello Richard,
>
> Don't give up on the I2C approach. From recent comments from Chuck it
> looks like the existing system is switching the current source going to
> the diodes and only one diode is energized at a time. If this is true
> then one could connect the I2C temperature reader to the input of the 8
> channel multiplexer. Hence only one I2C device is required. What is
> the on resistance of a typical analog multiplexer these days?
>
>
> The other Howard
>

Absolutely! That would be my first approach. I don't want to do any more analog stuff than I have to.

One of the single chip solutions I reviewed could compensate for 1500 ohms of series resistance going to the diode. The little bit of resistance in the analog switch will be insignificant.

I think I would spend a day or so reviewing the single chip options. It will be time well spent. There are some very interesting devices but, unfortunately, some sell in quantities of a gazillion (minimum). It comes down to selecting a device that will work and is readily available in qty 1.

Keywords seem to be 'diode remote temperature sensing IC'

A device like the TI TMP400 can compensate for up to 3k of series resistance:

See Figure 5

As it turns out, this device is not a stocked item at Digikey but they have 250+ available in qty 1 at \$2.87

I worry about CDiff as it has a huge effect on the accuracy. There is a discussion where it is recommended to keep the capacitance below 1000 pf Figure 6 and Page 7. I guess I have no idea how much capacitance the cable presents.

Richard
• ... OK I could be wrong. I was thinking the 8 diodes are wired in series. One lead for the current source, one lead for the return and 1 lead connected to
Message 22 of 25 , Dec 15, 2012
View Source
• 0 Attachment
On 12/14/2012 12:09 PM, chuck merja wrote:
> I'm not sure I understand your comments. There are a maximum of 8
> sensor wires and one ground wire in the cable. I'm not sure how this
> all occurs, but I guess that each of the sensor leads has a diode at
> the end of it and the other side of each diode is then tapped into the
> common ground cable. If this is true, then I definitely need to read
> these cables one at a time.

OK I could be wrong. I was thinking the 8 diodes are wired in series.
connected to each junction of two diodes.

Whereas if one thinks in terms of switching the current source instead
of switching a signal coming from a diode your comments above make
sense. I have uploaded a schematic of the OPI-ONE temperature monitor
to this groups Temp folder. It is named Chucks version.pdf. I used
the comments you made above to guide me. Look it over to see if you
agree/disagree with it. It will help future discussions if we have a
reasonable accurate representation of your existing temperature monitor.

>
> But given that wiring, does your comment still apply, or do I just
> need up a single 8 channel mux?

So yes If the circuit is design to switch the current source and apply
current to only one diode at a time you only need a single 8 channel
multiplexer.

>
> And can I dump the output of that 8 channel mux into one analog port
> on the arduino and read it there? We are talking about low end
> reading 0.4 ish to 0.6 volts high end so a "full range" of 0.2 volts,
> is that going to be a problem in the arduino?

If the circuit is designed to switch the current source you would
connect the input to the multiplexer to one channel of the Arduino.

With 5 volt full scale range a 10 bit A to D you only get 5 mV
resolution. For 1 mV resolution you will need to add an op amp wit a
gain of 5.

The other Howard

>
> C
>
> On 12/14/2012 9:35 AM, Howard Hansen wrote:
>>
>> On 12/12/2012 10:43 PM, chuck merja wrote:
>> >
>> > I got a better multimeter and checked the cable, which again contains
>> > sensors every 4 feet so we can see if there is any stratification in a
>> > grain bin. The diode function on the multimeter revealed a "OL" on one
>> > polarity and an 0.698 with the other polarity, when measured to the
>> > white (gnd) lead. So we have a diode on each of the lines in a
>> > cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
>> > molded into a heavy HDPE coating that has allowed these cables to 30
>> > years. So I am not looking to replace the existing sensors in this
>> > tough cable with the digital DS18B20.
>> >
>> > In the existing data reader the lines come in and straight to a
>> > MC74HC4051N an analog multiplexer. No resistor, just straight in.
>> >
>> > So I think this leaves me hoping I can create a constant current
>> source,
>> > and read the cables into the analog ports of an arduino. A poster on
>> > arduinohome thinks this might be too much for a limited electronics guy
>> >
>> > thanks, Chuck
>> >
>>
>> One thing that may not be apparent is that you need to switch two signal
>> lines, use two multiplexers and a differential amplifier to convert the
>> diode signal to a single ended signal for use with a microprocessor like
>> an Arduido UNO.
>>
>> Or you could use an Arduino compatible microprocessor that has a
>> differential A to D. This would eliminate the need for a differential
>> amplifier. But with 8 diodes per cable you still need two
>> multiplexers. A low cost Arduino compatible microprocessor with 8
>> differential inputs is a lot harder to find.
>>
>> The other Howard.
>>
>> [Non-text portions of this message have been removed]
>>
>>
>

[Non-text portions of this message have been removed]
• ... That was the way I understood it. I think the cable is connected via a DB9 and that pretty much determines how the diodes are connected. Richard
Message 23 of 25 , Dec 15, 2012
View Source
• 0 Attachment
--- In Electronics_101@yahoogroups.com, Howard Hansen <hrhan@...> wrote:
> I have uploaded a schematic of the OPI-ONE temperature monitor
> to this groups Temp folder. It is named Chucks version.pdf. I used
> the comments you made above to guide me. Look it over to see if you
> agree/disagree with it. It will help future discussions if we have a
> reasonable accurate representation of your existing temperature monitor.

That was the way I understood it. I think the cable is connected via a DB9 and that pretty much determines how the diodes are connected.

Richard
• It s great to see you guys working while I was off playing with a middle school robotics team this weekend (they won an FTC tourney here in MT). I ve uploaded
Message 24 of 25 , Dec 17, 2012
View Source
• 0 Attachment
It's great to see you guys working while I was off playing with a middle school robotics team this weekend (they won an FTC tourney here in MT). I've uploaded pix of the front and back side of the PCB for the OPI-ONE cable reader to the TEMP area.
At the bottom of the front side one can see the cable come in from the DB9 and go through the MUX.
The red button is POWER.
The white button is what is used to cycle through the cables. When the device powers on, it always starts with sensor "0", and every press of the white button increments to the next cable.
I was unable to find 3 of the chips at the top of the pix. i think the mux enable logic (pins ABC) comes from the MC14518BCP which has some leads to the MC14543BCP. But couldn't the logic could be supplied with 3 pins on an arduino, I'm thinking.
I don't know about the blue rectangles near the power switches, but that is also where the 6 band resistors reside. The blue rectangles have 2 leads each and one is B32521..."mu"22J100, the other 470n.
The transistor to the right is 3904.
I don't see an opamp - but ...
And lastly, someone on the arduinohome group who I'm also bothering hooked a diode up to arduino nano this weekend and ice bathed and hot coffeed it and got reasonable results (at those endpoints)...pretty sure without an opamp. Do I understand that the opamp rescales the the output range so I get better resolution?
I'll try to do the same this week...and look at the opamp pages that Richard sent me.
Thanks,
Chuck

--- In Electronics_101@yahoogroups.com, Howard Hansen <hrhan@...> wrote:
>
> On 12/14/2012 3:28 PM, rtstofer wrote:
> >
> >
> >
> > --- In Electronics_101@yahoogroups.com
> > <mailto:Electronics_101%40yahoogroups.com>, chuck merja <chuckm@>
> > wrote:
> > >
> > > I'm not sure I understand your comments. There are a maximum of 8
> > > sensor wires and one ground wire in the cable. I'm not sure how this
> > > all occurs, but I guess that each of the sensor leads has a diode at
> > the
> > > end of it and the other side of each diode is then tapped into the
> > > common ground cable. If this is true, then I definitely need to read
> > > these cables one at a time.
> > >
> > > But given that wiring, does your comment still apply, or do I just need
> > > up a single 8 channel mux?
> > >
> > > And can I dump the output of that 8 channel mux into one analog port on
> > > the arduino and read it there? We are talking about low end reading 0.4
> > > ish to 0.6 volts high end so a "full range" of 0.2 volts, is that going
> > > to be a problem in the arduino?
> > >
> > > C
> >
> > Yes, one way or another you need an 8 input MUX. The reader you are
> > using has just such a MUX.
> >
> > Stefan and I were discussing using 8 of the IC solutions I posted
> > earlier instead of a MUX and, under normal I2C bus circumstances, that
> > would be a great solution. Except that the I2C chips I linked aren't
> > addressable in the normal way.
> >
> > As I pointed out earlier, your existing reader is using an op amp and
> > I bet it's arranged to scale and offset. Again, that's probably what
> > the 6 band resistors are all about. Precision resistors for precision
> > scaling.
> >
> > You can do the math as well as anybody. I showed you earlier. 5V /
> > 1024 counts means each count is about 0.005V so your entire range is
> > just 40 counts. Is that good enough? Is that enough resolution? Go
> > back and get the temperatures at each voltage end point and figure how
> > many degrees they span. Then divide by 40 and that's what each count
> > is worth in degrees.
> >
> > As a first approximation of the diode drop, figure 2.6 mV per degree
> > C. So, about the best you can measure directly when using the Arduino
> > A/D is every 2 degrees C. Is that good enough?
> >
> > Without knowing exactly what is in your reader, it's not possible to
> > know how they accounted for other error factors. They may have figured
> > that the reader would never get very cold or very hot.
> >
> > I kind of like the chip solutions to measuring the diode drop and
> > rescaling.
> >
> > One thing the single chip solutions do is measure the voltage drop
> > with 2 bias currents about a factor of 10 apart. In this way they can
> > eliminate some of the possible error factors. Here is a good
> > discussion of the process:
> > http://www.latticesemi.com/documents/TN1115.pdf
> >
> > For the cost of a single op amp and 4 resistors, you can spread that
> > 0.2V change across the entire 5V range of the A/D. Then 0.2V / 1024
> > implies that you can measure to 0.1 degree C - somewhere around 13
> > counts per degree C.
> >
> > An advanced topic related to the calculations above is the use of a
> > precision external Vref for the A/D converter. Why would you want to
> > use one? First of all, it rescales the A/D! If you use an external
> > 2.5V reference, all of a sudden the full scale is 2.5V and with 2.5V /
> > 1024 you are measuring in terms of 0.002V per count. That will get you
> > down to about 1 degree C per count. Next, the reference can be
> > precision, not just whatever Vcc happens to be doing. The ATmegas also
> > have an internal Vref but it doesn't come anywhere close to precision.
> >
> > But one thing that is going to happen is that this device will be
> > exposed to the environment long enough for the internals to change
> > temperature. This is going to be a problem. I suggested earlier that
> > you come up with a heater and temp controller to keep the inside of
> > the enclosure warm. Something around 100 degrees F comes to mind. So,
> > you will want to insulate the box to keep the energy costs down.
> >
> > Build up something as an experiment. Put the probe in boiling water
> > and then in ice water. This will give you the 0-100 degree span on the
> > input. Then put your electronics in an over heated to 100 degrees F
> > and in an ice chest full of melting ice (I have no idea how to get the
> > internals down into the cold water). You can put the box in the
> > freezer overnight I suppose. This will give you some indication about
> > the accuracy of the device over temperature.
> >
> > Richard
> >
>
>
> Hello Richard,
>
> Don't give up on the I2C approach. From recent comments from Chuck it
> looks like the existing system is switching the current source going to
> the diodes and only one diode is energized at a time. If this is true
> then one could connect the I2C temperature reader to the input of the 8
> channel multiplexer. Hence only one I2C device is required. What is
> the on resistance of a typical analog multiplexer these days?
>
>
> The other Howard
>
>
> [Non-text portions of this message have been removed]
>
• ... Hello Chuck, Another way you can save money on this project is by using Zigbee in place of WiFi. Zigbee is a low power spin off of WiFi with the emphasis
Message 25 of 25 , Dec 17, 2012
View Source
• 0 Attachment
On 12/12/2012 10:43 PM, chuck merja wrote:
>
> I got a better multimeter and checked the cable, which again contains
> sensors every 4 feet so we can see if there is any stratification in a
> grain bin. The diode function on the multimeter revealed a "OL" on one
> polarity and an 0.698 with the other polarity, when measured to the
> white (gnd) lead. So we have a diode on each of the lines in a
> cable...every 4 ft. These sensors and a 1/8 diameter steel cable are
> molded into a heavy HDPE coating that has allowed these cables to 30
> years. So I am not looking to replace the existing sensors in this
> tough cable with the digital DS18B20.
>
> In the existing data reader the lines come in and straight to a
> MC74HC4051N an analog multiplexer. No resistor, just straight in.
>
> So I think this leaves me hoping I can create a constant current source,
> and read the cables into the analog ports of an arduino. A poster on
> arduinohome thinks this might be too much for a limited electronics guy
>
> thanks, Chuck
>
> O
>

Hello Chuck,

Another way you can save money on this project is by using Zigbee in
place of WiFi. Zigbee is a low power spin off of WiFi with the emphasis
on low data rate, 250 kbps, system sensors. For example see:
<https://www.sparkfun.com/products/10416> And for an antenna
<https://www.sparkfun.com/products/145> During the development stage you
should have at last 2 Xbee Explorers.
<https://www.sparkfun.com/products/8687>

This combination is less than 1/2 the cost of the WiFi shield R Stofer
suggested using.
<https://www.sparkfun.com/products/11287>
Although Wi-Fi shields are available for approximately \$50 from other
vendors.

Not knowing the distance between the grain bins and your office I
suggest using a Xbee modules with Mesh capability as shown above. Zigbee
devices when used in a mesh network can transmit data over long
distances by passing data through intermediate devices. The XBee 2mW
RPSMA has a range of about 400 feet. To extend the range to 1 mile add
a XBee Pro at each storage site and your office. The XBee Pros at the
storage sites will function as repeaters.

Zigbee is designed for building low cost low data rate networks. However
it is not plug and play. You will need a good book like the following