Apologies, 8-bit resolution was meant to mean the bits reserved for specifying a PWM frequency. You may have misunderstood my question about generating sine waves. This was in my *original* message: "Is it possible to attach caps in a "dodgy" fashion to "smooth out" the square wave, creating a sine-ish wave?", I wasn't referring to generating different levels, just looking for a hardware square->sine "converter". I decided against this, and so it wasn't included in my re-post of the message. Also, the code demonstrated used fixed output levels (on/off) and I didn't mention other waveforms... but sorry to have confused you! -Kieren ----- Original Message ----- From: "Olin Lathrop" To: Sent: Friday, August 09, 2002 12:56 PM Subject: Re: [PIC]: Best frequency synthesis method > > Surely if TMR0 overflows at 19.5 KHz, by switching a PWM every time I > could > > get 9.7 KHz, > > Yes, but at what *resolution*. You will make a descision and possibly > change the output at 19.5KHz rate, or every 51.2uS. You can use this to > produce a square wave at half that rate, but I thought you originally wanted > sine waves and other arbitrary waveforms out. At one point you said you > wanted 8 bit resolution. Show me how you're going to create 256 different > average voltage levels with the averaging period less than 500uS. > > > every 256 interrupts I could get about 76 Hz; in the original > > post I mentioned 4.9 KHz being the highest note I'd consider.. > > Yes, so doesn't that show this method won't work? I don't understand your > point. > > > ***************************************************************** > Embed Inc, embedded system specialists in Littleton Massachusetts > (978) 742-9014, http://www.embedinc.com > > -- > http://www.piclist.com hint: To leave the PICList > mailto:piclist-unsubscribe-request@mitvma.mit.edu > -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu