alternating current using pic microcontroller

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
hello guys my question is for experienced members
we all know that the pic microcontroller output is 5volts and 25 mA as maximum
now am trying to design a metal detector using pic technology
and my problem is as followed
i need an alternating current with frequency about 20 KHZ passing through a coil
how can i get this constant frequency using pic microcontroller
i know i need another stuffs in addition with the pic what are they ?
:confused:
 

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
its VLF metal detector
u apply an alternating current with constant frequency to a transmitter loop producing a magnetic field if this magnetic field interacts with a metal object for example a reversed magnetic field from this object will be detected by a reciever coil in other words a current with a certain frequency will pass through the reciever coil due to the object magnetic field
now i need the microcontroller for two purposes first to create a current with constant frequency through the transmitter loop and to read the frequency through the reciever loop
now the different between the 2 frequencies is known as the phase shift and every object has a constant phase shift depending on many varibles such as the conuctivity
its a great idea but i need help using the pic microcontroller
if u have good ideas to use the pic microcontroller please msg me on private and lets discuss every thing
peace
 

Alec_t

Joined Sep 17, 2013
14,330
I doubt that 25mA will be enough for the Tx coil current. You will probably need to use the PIC output to drive the coil via an amplifier.
 

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
I doubt that 25mA will be enough for the Tx coil current. You will probably need to use the PIC output to drive the coil via an amplifier.
so if i change the output voltage of the pic into AC voltage with certain frequency using PWM will that make the output amplified current AC also,,,, and with the same properties of the voltage
 

Alec_t

Joined Sep 17, 2013
14,330
You can apply the amplified PWM via a capacitor to the coil if you want to eliminate the DC; but do you really need AC? Won't the Tx coil be happy with pulsed DC?
 

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
You can apply the amplified PWM via a capacitor to the coil if you want to eliminate the DC; but do you really need AC? Won't the Tx coil be happy with pulsed DC?
using alternating current to create a magnetic field that is distorted by a metallic object
here is what i need if u can give me a detailed help

i need to change the output of the MC into alternating also the output current of the MC is very low so i need to amplify it and then filter it through an LC circuit to get the wanted frequency
was that correct or i need to do other steps ??
 

Alec_t

Joined Sep 17, 2013
14,330
using alternating current to create a magnetic field that is distorted by a metallic object
I think you'll find that DC pulses would would give a similar result. How much current do you need for the Tx coil? How important is the coil frequency? What size object are you hoping to detect at what distance?
 
Last edited:

BobTPH

Joined Jun 5, 2013
8,998
I don't understand your detection scheme. If you are outputting a fixed frequency to the transmitter, how does the receiver get a variable frequency? A metal object will not change the frequency your PIC is outputting. The normal way this is done, is that the coil is part of an LC oscillator, and a nearby metal object changes L and thus the frequency generated.

Bob
 

Alec_t

Joined Sep 17, 2013
14,330
That's my understanding of conventional metal detectors. But the OP at one point mentioned phase shift detection?
 

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
I don't understand your detection scheme. If you are outputting a fixed frequency to the transmitter, how does the receiver get a variable frequency? A metal object will not change the frequency your PIC is outputting. The normal way this is done, is that the coil is part of an LC oscillator, and a nearby metal object changes L and thus the frequency generated.

Bob
hmmmm ,As the magnetic field pulses back and forth into the ground, it interacts with any conductive objects it encounters, causing them to generate weak magnetic fields of their own. The polarity of the object's magnetic field is directly opposite the transmitter coil's magnetic field. If the transmitter coil's field is pulsing downward, the object's field is pulsing upward.Therefore, when the receiver coil passes over an object giving off a magnetic field, a small electric current travels through the coil. This current oscillates at the same frequency as the object's magnetic field. The coil amplifies the frequency and sends it to the microcontroller again to distnguish the frequency
How does a VLF metal detector distinguish between different metals? It relies on a phenomenon known as phase shifting. Phase shift is the difference in timing between the transmitter coil's frequency and the frequency of the target object
thats the explanation
also can u give me more tips on how using the LC circuit to produce the needed frequency
my friend told me about connecting the L and C once in series and once in parallel to recharge the capacitor contiuosly to avoid damping effect
do u have any comments on that or a detailed way to use that via microcontroller
the LC circuit is my only problem now so lets work together to make it come true
 

Alec_t

Joined Sep 17, 2013
14,330
Since the frequency is set by the micro why do you need the LC circuit?
my friend told me about connecting the L and C once in series and once in parallel to recharge the capacitor contiuosly to avoid damping effect
I don't understand that. Perhaps you can get your friend to build the circuit, or at least provide a schematic?
 

Thread Starter

sayf alawneh

Joined Aug 4, 2014
20
the current of the micro is not enough for the coil of the transmitter friend
so i need this current amplified the current of the MC only works as the base current of the transistor switch
any ways once he tell me exactly about the circuit it will be our new topic
and am gonna visit him this day for further explanations so this day u will know
regards
 
Top