I have done sort of this before. I had a shaft encoder giving to few pulses out, so the plan was to multiply the incoming A and B pulses by some factor. I measured the width of the incoming pulse, divided the time into the multiplying factor and outputed the needed amount of pulses with the width proportional to the incoming pulse. Everything worked fine for more or less steady rotation of the shaft (approximately constant frequency). When the shaft was accelerating fast or breaking fast everything was wrong, the unit started to drop pulses for obvious reasons. So I'm very interested to hear if everyone has a better idea of how to do this but with changing frequencies at a fast rate. best regards RA ----- Original Message ----- From: "Picdude" To: Sent: Thursday, April 24, 2003 7:02 AM Subject: Re: [PIC]: Frequency multiplier? > Since you put this as the [PIC] topic, I'm going to invent a PIC solution for > this, which I haven't tried, but thinking should be doable... > > Measure the low-time and high-time of the first pulse, then generate pulses at > 130% the frequency of that ..... repeatedly in a loop. While that's > happening, in a sort of feedback mechanism, count both input and output > pulses and adjust accordingly by offsetting the next pulse(s). > > This method should provide low jitter, but would add a small (approx 1/2 to > 1-pulse) delay from input to output, and depending on the actual coding, may > introduce a limitation on how fast the output will follow the input on freq > change. > > Of course this is not totally trivial, but it should be doable with any simple > PIC. > > Cheers, > -Neil. > > > > > > > On Wednesday 23 April 2003 20:08, Gary Neal wrote: > > Hi, > > > > I've got a variable frequency signal (200hz to 4khz) whose frequency I want > > to increase by 30% (5v signal). IE if the input frequency is 1000hz, I > > want to output 1300hz. Is there an easy method of doing this? I've heard > > of PLL, but don't have a clue how to build them, so if there's an easier > > option that would be great. > > > > Thanks, > > > > Gary > > -- > http://www.piclist.com hint: The PICList is archived three different > ways. See http://www.piclist.com/#archives for details. > -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.