Maker Pro
Maker Pro

Hello can somebody teach me how to connect am to arduino

hevans1944

Hop - AC8NS
Jun 21, 2012
4,891
Joined
Jun 21, 2012
Messages
4,891
It appears that a lot of folks who "play" with Arduinos leave them tethered to a PC for convenience, as well as for accessibility to a keyboard, mouse and video display. This isn't necessary if the Arduino application software (the sketch) provides support for human interaction through ports on the Arduino. However, the OP does not appear to have the qualifications necessary to write sketches for stand-alone Arduino projects, nor the qualifications necessary to design and implement the HMI (human-machine interface).

For example, if a stepper motor is to used, presumably attached (somehow) to the tuning capacitor, there needs to be a motor driver shield and at least one toggle switch with a center-off position to select UP and DOWN tuning direction. As somebody here (besides me) has noted, this is NOT a teaching forum. The OP would need to develop Arduino programming skills and become familiar with how to perform simple switch I/O operations, including switch de-bouncing either in software or in hardware. A true hobbyist devours these simple procedures and moves on to bigger and better projects, coming back to EP to share their experience, or to ask targeted questions aimed at specific difficulties they have encountered. This usually results in a useful dialog that benefits everyone involved.

A side note on varicaps versus motor-driven tuning capacitors: I like the idea of motor-driven tuning, although perhaps with a PWM-driven PMDC motor instead of a stepper motor for smoother operation. Also much simpler to implement. And I wonder if it wouldn't be possible to make a DIY voltage-tuned capacitor by using a compliant foam insulation between parallel plates and then adjusting the plate separation by varying the DC bias voltage applied to the plates? Might need a few hundred volts to get a useful change in capacitance, depending on foam compliance and plate area, but it should be something a DIYer can accomplish.
 

michael1978

Mar 17, 2012
388
Joined
Mar 17, 2012
Messages
388
I think heavans has come up with the simple answer to your question. My further thoughts are:

Since everyone with an Arduino seems to play with a little stepper motor, have you thought about using a stepper motor to turn the tuning capacitor on the radio?

Starting with the idea that you will control the radio with an Arduino, why not look for a circuit which already uses a varying voltage to tune it? Admittedly, this is much more common for VHF radios, but you might find an existing design for a varactor tuned MW AM radio. Then all you would need to do is to generate the tuning voltage, which you might do with the built in DAC. The AM portion of this circuit maybe useful.

The reason varicaps are used at VHF and not so much at LF is the amount of capacitance you need. Your circuit shows a 500pF capacitor, but heavans' varicap only goes up to about 100pF I think. That's why you might have to use several in parallel.
Now you can reduce the size of the capacitor needed if you increase the inductance of the coil. So if you increased the turns from 50-60 to maybe 150, perhaps one of these varicaps would get you down to the frequencies you want. But you are likely to find that you still don't get the full MW range, because the ratio of maximum to minimum capacitance may be too small.

(Searching for a suitable circuit I found this varicap which goes up to 400pF and is designed for AM receivers. The BB112 also looks suitable. But I don't know if either is available.)


but you can tune with vc1 or varicap, so the adc is to convert your selected frequency to arduino? right
 
Last edited:

hevans1944

Hop - AC8NS
Jun 21, 2012
4,891
Joined
Jun 21, 2012
Messages
4,891
but you can tune with vc1 or varicap, so the dac is to convert your selected frequency to arduino? right
Yes, it is just one of many ways to interface the Arduino to the rest of the real world. @Merlin3189 has suggested using a stepper motor, with its shaft mechanically coupled to Vc1. That would require at least two available binary output ports, plus MOSFET drivers for the stepper motor coils. You might also be able to drive stepper motor coils directly from Arduino binary outputs, depending on the size of the motor.

I suggested using a varicap, wired in parallel with the Vc1 tuning capacitor, but with a DC blocking capacitor in series with the varicap since you do not want the varicap tuning voltage to appear across Vc1. Depending on how much capacitance variation you can obtain from the varicap, you may have to use Vc1 to get "close" to the station you are trying to tune, and then use the varicap for the final frequency adjustment.

So, yes, if you go this route the DAC will produce a variable output voltage that you apply in parallel with the varicap(s) to adjust their reverse bias voltage and cause their capacitance to be a function of the DAC input word provided by the Arduino. AFAIK, there are no Arduinos with a built-in DAC, but you can synthesize an effective DAC by integrating (in hardware) a binary output bit supplied with pulse-width modulation (PWM). This is an Arduino "feature," but it doesn't work as fast as a real DAC, and the output may have an unacceptable amount of high-frequency ripple. It's worth a try to see if it works for you before actually implementing a DAC connection to the Arduino.

Have you done any work to make this project a reality?
 

Merlin3189

Aug 4, 2011
250
Joined
Aug 4, 2011
Messages
250
If you use a stepper motor to turn the variable capacitor, then the ADC is not needed, as you turn it with the number of steps to get the station you want. (How you find that number is another question.)

If you use a PMDC motor to turn it, then you need some way to sense the position. So you either have some sort of digital position sensor, or you use a potentiometer and measure the voltage, for which you need the ADC input.
(Again, how you know what position is right for a station is another question.)

If you use a varicap to tune it, then you need a variable DC voltage output, so you need a DAC of some sort. This might possibly be as simple as some resistors and a capacitor driven by a PWM output, but I'm not sure if that is good enough here or not

I don't think you will be able to read the actual frequency of an AM signal from a TRF radio like your circuit. What we are trying to read (with the DC motor drive) is the actual position of the capacitor, which determines the receive frequency.

(I see heavans has just said much of this already.)
 

michael1978

Mar 17, 2012
388
Joined
Mar 17, 2012
Messages
388
Yes, it is just one of many ways to interface the Arduino to the rest of the real world. @Merlin3189 has suggested using a stepper motor, with its shaft mechanically coupled to Vc1. That would require at least two available binary output ports, plus MOSFET drivers for the stepper motor coils. You might also be able to drive stepper motor coils directly from Arduino binary outputs, depending on the size of the motor.

I suggested using a varicap, wired in parallel with the Vc1 tuning capacitor, but with a DC blocking capacitor in series with the varicap since you do not want the varicap tuning voltage to appear across Vc1. Depending on how much capacitance variation you can obtain from the varicap, you may have to use Vc1 to get "close" to the station you are trying to tune, and then use the varicap for the final frequency adjustment.

So, yes, if you go this route the DAC will produce a variable output voltage that you apply in parallel with the varicap(s) to adjust their reverse bias voltage and cause their capacitance to be a function of the DAC input word provided by the Arduino. AFAIK, there are no Arduinos with a built-in DAC, but you can synthesize an effective DAC by integrating (in hardware) a binary output bit supplied with pulse-width modulation (PWM). This is an Arduino "feature," but it doesn't work as fast as a real DAC, and the output may have an unacceptable amount of high-frequency ripple. It's worth a try to see if it works for you before actually implementing a DAC connection to the Arduino.

Have you done any work to make this project a reality?
myes, i did it with arduino, i read this books ARDUINO FOR MUSICIANS
Mr thank you for help
 

michael1978

Mar 17, 2012
388
Joined
Mar 17, 2012
Messages
388
If you use a stepper motor to turn the variable capacitor, then the ADC is not needed, as you turn it with the number of steps to get the station you want. (How you find that number is another question.)

If you use a PMDC motor to turn it, then you need some way to sense the position. So you either have some sort of digital position sensor, or you use a potentiometer and measure the voltage, for which you need the ADC input.
(Again, how you know what position is right for a station is another question.)

If you use a varicap to tune it, then you need a variable DC voltage output, so you need a DAC of some sort. This might possibly be as simple as some resistors and a capacitor driven by a PWM output, but I'm not sure if that is good enough here or not

I don't think you will be able to read the actual frequency of an AM signal from a TRF radio like your circuit. What we are trying to read (with the DC motor drive) is the actual position of the capacitor, which determines the receive frequency.

(I see heavans has just said much of this already.)
Merlin i fixit thank you for help
 
Top