Frequency multiplier

Hey, anyone know how make a fFrequency multiplier or a mixer not too complicated?

A bit more information is needed first... MIN/MAX Input frequency? MIN/MAX Output frequency? Fixed or variable input/output frequencies? Signal amplitude? The list goes on so maybe start with what your trying to achieve.

Doubling frequency is relatively easy. You use the rising and falling edges of the original signal to trigger a one-shot pulse. This produces two pulses for every input pulse. However for something with a bit more bite you could look at this, and any number of google-found sites http://electronicsproject.org/frequency-multiplier/

audio? RF? What specification? Harmonic distortion specs?

We need better information about the application to advise. For instance frequency multipliers (with a fixed frequency) are used in radio transmitters to multiply a crystal frequency and these multipliers have to have low phase-noise and filter out harmonics - do you need this?

The frequencies I'm using are 1000-2500 Hz. The signal are short some in microseconds. I'm using pulseIn() to measure the frequency but it cant measure the shortest ones but it can measure higher frequencies >5000 hz even when short. By shifting the input frequencies higher its easier to measure them. If possible I like do this without IC's but with simple components. I tired some phase shifting circuit but they didn't work.

Look up monostable multivibrator to use as a "pulse stretcher". A 555 will do nicely.

shakki87: The frequencies I'm using are 1000-2500 Hz. The signal are short some in microseconds.

How many microseconds - a single cycle of 2500Hz is 400us to start with so I can't quite reconcile what you are saying.

PulseIn() cant measure the signal if the sample is too short it has about 500ms to measure the frequency. It cant measure a 2500hz signal it that time but can measure a 10000hz signal.

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

Reads a pulse (either HIGH or LOW) on a pin. For example, if value is HIGH, pulseIn() waits for the pin to go HIGH, starts timing, then waits for the pin to go LOW and stops timing. Returns the length of the pulse in microseconds. Gives up and returns 0 if no pulse starts within a specified time out.

The timing of this function has been determined empirically and will probably show errors in longer pulses. Works on pulses from 10 microseconds to 3 minutes in length.

That does not sound like it is useful to measure frequency. Pulsein is measuring the length that the incoming signal is HIGH or LOW, not the time from one positive going transition to the next.

If you are trying to measure frequency by measuring period, how about using an external interrupt and micros()?

http://playground.arduino.cc/Code/Interrupts

The processor at the heart of any Arduino has two different kinds of interrupts: “external”, and “pin change”. There are only two external interrupt pins on the ATmega168/328 (ie, in the Arduino Uno/Nano/Duemilanove), INT0 and INT1, and they are mapped to Arduino pins 2 and 3. These interrupts can be set to trigger on RISING or FALLING signal edges, or on low level. The triggers are interpreted by hardware, and the interrupt is very fast. The Arduino Mega has a few more external interrupt pins available.

On the other hand the pin change interrupts can be enabled on many more pins. For ATmega168/328-based Arduinos, they can be enabled on any or all 20 of the Arduino's signal pins; on the ATmega-based Arduinos they can be enabled on 24 pins. They are triggered equally on RISING or FALLING signal edges, so it is up to the interrupt code to set the proper pins to receive interrupts, to determine what happened (which pin? ...did the signal rise, or fall?), and to handle it properly. Furthermore, the pin change interrupts are grouped into 3 “port”s on the MCU, so there are only 3 interrupt vectors (subroutines) for the entire body of pins. This makes the job of resolving the action on a single interrupt even more complicated.

Sounds like the external interrupts are a good fit for this.

Of course, the other way is to simply have the Arduino count rising edges for 1 second and display the answer in Hz.

Sounds not easy

Versus doesn't work?

Using a frequency multiplier sounds a lot more difficult.

shakki87: The frequencies I'm using are 1000-2500 Hz. The signal are short some in microseconds. I'm using pulseIn() to measure the frequency but it cant measure the shortest ones but it can measure higher frequencies >5000 hz even when short. By shifting the input frequencies higher its easier to measure them. If possible I like do this without IC's but with simple components. I tired some phase shifting circuit but they didn't work.

So are these logic signals? Sounds like it. What exactly are you trying to - shifting frequencies lower enables you to measure them more accurately, but such techniques use continuous signals, not short bursts, phase detectors and low pass filters. What precision do you need? How many cycles per pulse?

Increasing a signal frequency can be done by harmonic resonators, but that's a narrow band technique.

Found information using phase shift to measure frequency. Ones found a software to generate sine wave software that generates 8bit sample files but don't remember its name? Anyone familier with it or similiar?

The circuit you want to use is called a phase locked loop or PLL.
You need a divide by two circuit between the phase comparator and the reference oscillator. The the reference oscillator will be twice the frequency of your input signal. Trying to do this in the other ways described here is very sub optimal.

Hello everyone! I have a 100Hz sine signal and I want to have a 100KHz sine signal using arduino Could you help me making a program that generates this frequency?

THank you so much everyone

Not an Arduino question as such.

100 kHz sinewave? How accurate do you want it? Does this have any connection with a 100 Hz signal that you already have?

This thread started in 2013,do not resurrect old threads. Start your own. Also before posting again read the how to use this forum sticky post.