Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Help with a project

Status
Not open for further replies.

helz15

New Member
Hi,

Can (and how) do I take a current reading from an AVO (or multimeter) and get it into a computer as a value?

Background:
I have made a (very simple) level indicator working of capacitance, basically I placed 2 brass plates a very close distance apart and placed it into a bucket (with changing oil level).
I used a 555 timer diode pump circuit, and measured a current value in the circuit, as the capacitance changed so did the current.

I now want to build on my project to look at situations with non-linear shaped vessels of oil, such as a cylinder on its side, the way I thought I would do this, is take the current value and get it into a computer, then using something as simple as excel, create some formulas that will tell me how full the vessel is, (ie half full, empty etc).

Alternatively, I was thinking of using a set of LEDS that would maybe be all lit up when the vessel is full and when it is half full, half of the lights would be on, and so on.
 
Wow, that's an unusual-sounding application :) Not sure whether the charge-pump approach is the best way of reading the capacitance or not (other approaches might be an oscillator using the capacitor for timing or something?), but as for measuring the current out, I think one common way would be to pass the current through a resistor and put the terminals of a differential amplifier over it. Then use an analogue-digital converter to get the voltage reading.

OR for that matter, pass the current through the resistor to ground, and just put the ADC's input onto the top end of the resistor. Much simpler but AFAIR it's supposed to be a bit less accurate for some purposes (I forget why). You'd probably want an Op-amp follower between the resistor and ADC to buffer it though.

Getting it into your computer is probably the harder part. Using a microcontroller (eg a PIC or an AVR or whatever else) with a MAX232 or similar (there are lots of clones and variants of MAX232) to send it to the serial port would probably be the easiest way. If you do this you can also use the microcontroller's ADC, if yours has one :D
 
You might consider changing the shape of the brass plates to get the response you desire. Experiment with a simple taper.
 
stevez said:
You might consider changing the shape of the brass plates to get the response you desire. Experiment with a simple taper.

hi,
Something like the 'angel wing' profile used on old radio tuning capacitors, to spread the band more evenly.

Reference, using the possible metal tank as ground is not a good idea, consider cathodic/anodic corrosion problems you could have with the plumbing.
 
Last edited:
With regard to getting the data into a computer, I can recommend a good book - Visual BASIC for Electronic Engineering Applications - reviewed in the books section of this forum.

Brian
 
Thanks for all your help so far, those are some really good suggestions!
I have also got hold of a copy of that book, so hopefully that will help.

Anymore ideas will be greatly appreciated!!
 
Have you thought about using a microcontroller?

That way you don't need to worry about using a PC, all the processing can be done on board and it could control your LEDs too.
 
To be honnest, i really want to use a computer so i canget all then infomation on the screen. i found these

**broken link removed**

for interfacing with computers, and i was wondering if they are suitable for what i am trying to do?

thanks for your help so far.
 
Tomble said:
Getting it into your computer is probably the harder part. Using a microcontroller (eg a PIC or an AVR or whatever else) with a MAX232 or similar (there are lots of clones and variants of MAX232) to send it to the serial port would probably be the easiest way. If you do this you can also use the microcontroller's ADC, if yours has one
I'm going to call you on that, if only to provide an option should the OP be adverse or unable to use a microcontroller for some reason. I think the easiest way would be to use common components to get to an ADC, as you've mentioned, but from there have the output as a TTL parallel signal into the computer's parallel port. Then it's just a simple program to read the parallel port whenever he likes. However, I should mention this method has a fault: if using Windows, the OS might at anytime lower the priority of accessing the parallel port at anytime in favour of other tasks - we're talking potential delays of anywhere from 10ms (more common) to 1s here. So it could make time-based readings tricky to impossible, and introduce more error to data/graphs. The advantage is, this method doesn't require a microcontroller or TTL-to-RS232 converter.


Hero999 said:
Have you thought about using a microcontroller?

That way you don't need to worry about using a PC, all the processing can be done on board and it could control your LEDs too.
But he wants to get the data into his computer and Excel? To back up Tomble instead, now that I've called him out, using a microcontroller to log data at consistent time intervals (essentially making the mcu a bus) and then using either RS232 (probably worth the extra time) or the parallel port to get it into your computer.

BTW, I use Liberty Basic for RS-232 and parallel port data collection. It's a cheap programming language and super easy to use, and you can make stand-alone apps with great looking graphic interfaces in no time. I think Just Basic, the freeware version of the same program, even has RS-232 (but not parallel port) support.*
https://www.libertybasic.com/
https://www.justbasic.com/
*I just checked: yes, it does have RS-232 support - and the price is right!
 
Last edited:
Wh at iz uproject I cantunderstand youverywell spaceout yourlet ers cor erctly.

Point is, What is your project and why should we help you? You seem like you are at a last second chance. You should use your time better if you want to suceed in life.
 
helz15 said:
Hi,

Can (and how) do I take a current reading from an AVO (or multimeter) and get it into a computer as a value?
.

Hi,
If is a current reading, you can use a series resistor and measure the voltage drop across the resistor, which be proportional to the current flow.

If you want to feed this voltage say, 0 to +5V into a PC, you can do so by driving/reading a Dual channel 12bit A/D convertor type MCP3202 connected to the PC's parallel port.

I use a MCP on my parallel port, it gives an update rate of about 50 dual samples/second.

The PC program for operating the MCP is written using Visual Basic 5.

Does this help?
 
Hi subramanyam,

Please start a new thread for your questions.
 
And please say exactly what it is you need help with.

Also, kindly refrain from making three posts in a row as I find it very annoying.
 
Ok Chaps, thanks for all your help so far, but i have to admit that my knowledge and understanding in this area is very limited and i am trying to do something a bit above my level, none the less, i still want to give it a go.

I have attached my circuit (i think) for measuring the capacitance, where cx is the unknown capacitor that is being created in the oil. Sorry about the missing values (and even the ones that are there might be a bit wrong, i'm afraid i have left my diagram somewhere.)

I am prob expecting this to be much simpler than it is, but what i was hoping for was some sort of addition to my circuit that would allow me to basically plug my circuit into my computer and i would be able to see (and manipulate) data.
By the sounds of thins HANKS liberty basic and just basic suggestion are the closest to what i was looking for.

But i have to confess i don't know what RS-232 is?
Also, is the parallel port that cable with the screw things in it?

I have searched RS-232 on sites such as maplins and RS and have found millions of items ranging from pennys to hundreds of pounds and really don't have a clue what i am looking for.

If its not too much to ask, can you break things down for me as i am a bit slow. :)

Oh and by the way, i'm not a 'he' i'm a girly :p
 

Attachments

  • cap.GIF
    cap.GIF
    6.6 KB · Views: 168
ericgibbs said:
Hi,
If is a current reading, you can use a series resistor and measure the voltage drop across the resistor, which be proportional to the current flow.

If you want to feed this voltage say, 0 to +5V into a PC, you can do so by driving/reading a Dual channel 12bit A/D convertor type MCP3202 connected to the PC's parallel port.

I use a MCP on my parallel port, it gives an update rate of about 50 dual samples/second.

The PC program for operating the MCP is written using Visual Basic 5.

Does this help?


Ah, so is this 'Dual channel 12bit A/D convertor type MCP3202' like a component that i can add on to my circuit? If it is, that sounds good. If not, how do i use it?
 
RS232 is a standard for voltages when sending serial data between systems.

You could use the MCP3202, but since most of the microprocessors include ADCs, it's probably not necessary to have a separate one. A separate one would be needed if you actually want up to 12-bit accuracy.

Look at the smaller PICs and AVRs with ADC and serial ports.

I think you can get some good beginner information on **broken link removed** site.
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top