Monitoring a DC voltage signal with the BS2
Otaku1031
Posts: 34
Hi all,
I'm using the BS2 to control a TC junction test system. The program turns on small lamps that are used to heat these junctions. When the amplified junction voltage exceeds a certain threshold level, the test is considered a "Pass". The problem here is that some junctions require longer heating times, so using a fixed "lamp on" time is not very efficient. The reverse is also a problem - I need to allow enough time for each heated junction to cool down before proceeding to the next test. There are eight TC's being tested and after the TC under test passes, the remaining seven are tested to see if any wires are cross-coupled which would result in more than one TC reading "high". A false positive can be generated due to residual heat in the fixture, hence the requirement for the cool-down time.
Here's what I'd like to do: I would like to monitor the amplified DC voltage signal. This signal will typically be between 1.0VDC and 1.5VDC. I would put the BS2 into a loop that monitors the amplified TC voltage. Once the voltage crosses the threshold, say, 1.4VDC, the remaining seven TC's would be tested. If all pass, then the code would go into another loop that looks at the incoming voltage signal and when it dips below the threshold, the next test in the sequence would start.
Right now I'm trying use a "one size fits all" program with fixed heating and cool-down times. Depending on varying thermal characteristics of each TC, this doesn't always work. Ambient temperatures also play a part. By monitoring the voltage, both rising and falling, I can essentially customize the test on the fly.
So here's the question - can a BS2 accept and evaluate a DC voltage signal based on it's actual value, not just "high" or "low"? I may have to use a comparator to look at the signal and report a high or low signal to the BS2, but it would be less complicated if the Stamp can do this directly.
All advice is greatly appreciated! Thanks!
Gary
I'm using the BS2 to control a TC junction test system. The program turns on small lamps that are used to heat these junctions. When the amplified junction voltage exceeds a certain threshold level, the test is considered a "Pass". The problem here is that some junctions require longer heating times, so using a fixed "lamp on" time is not very efficient. The reverse is also a problem - I need to allow enough time for each heated junction to cool down before proceeding to the next test. There are eight TC's being tested and after the TC under test passes, the remaining seven are tested to see if any wires are cross-coupled which would result in more than one TC reading "high". A false positive can be generated due to residual heat in the fixture, hence the requirement for the cool-down time.
Here's what I'd like to do: I would like to monitor the amplified DC voltage signal. This signal will typically be between 1.0VDC and 1.5VDC. I would put the BS2 into a loop that monitors the amplified TC voltage. Once the voltage crosses the threshold, say, 1.4VDC, the remaining seven TC's would be tested. If all pass, then the code would go into another loop that looks at the incoming voltage signal and when it dips below the threshold, the next test in the sequence would start.
Right now I'm trying use a "one size fits all" program with fixed heating and cool-down times. Depending on varying thermal characteristics of each TC, this doesn't always work. Ambient temperatures also play a part. By monitoring the voltage, both rising and falling, I can essentially customize the test on the fly.
So here's the question - can a BS2 accept and evaluate a DC voltage signal based on it's actual value, not just "high" or "low"? I may have to use a comparator to look at the signal and report a high or low signal to the BS2, but it would be less complicated if the Stamp can do this directly.
All advice is greatly appreciated! Thanks!
Gary
Comments
It is quite easy to add an external ADC and you can also use a comparator. The BS2px model does have built-in comparator. All of the BS2 models can act as DACs with the PWM statement along with an external filter (resistor and capacitor). This makes it easy for the BS2px to set its comparator threshold.
If reversed TC polarity is very likely, you could route each TC voltage through a bridge rectifier using 4 Schottky diodes (~0.3V drop each), which would correct any polarity issues and drop each signal by about 0.6 volts. That's still plenty of signal to measure and you can calibrate it with the 339.