how to generate sine wave using the ATMEGA 168A ?

hey friends, im new to microcontrollers, i have to generate a pure sine wave from my controller ATMEGA 168A using the induino board. can u help me with the code ?

thank u.

Hardware will be more of a problem than code.
What did Google tell you?

What's an "induino"?

When is our assignment due?

induino is the indian version of the arduino or something similar. i can manage with the hardware. just an adc after the controller.

There's a whole DDS project somewhere - I'm surprised your Google search didn't find it.

its a project work and must be complete within april 15th.. done with the hardware..only coding is left

done with the hardware

That'll probably have some bearing on how you structure your code and what technique you use.

Good luck for the 15th.

done with the hardware..only coding is left

Then you should detail your hardware because that determines how the program will be written.

Truth is I don't know how you could get a "pure" sine wave from an Arduino unless you have an external function-generator chip. How are you doing the analogue circuit?


Rob

Depending on the load you could get a properly sized rc filter and use pwm to get a crude sine wave, not ever gonna be perfect but an approximation