There are basically two ways to generate sound from the Arduino -
1) using the timers to generate squarewaves
2) using DDS to generate waveforms which may include square, triangle, sine, noise and many others.
DDS has the advantage that you can easily add envelopes to create a more interesting sound, you can also add more channels or mix multiple channels into fewer channels etc. Then you can get into waveshapers, digital filters, wavefolding etc etc etc.
Peizo projects will tend to be based on 1) the output volume is not controlled by software, only the frequency, a lot like just using the tone library.
With the timer based methods you can fake envelopes to a degree by dropping the fequency rapidly which creates and effect similar to a note tailing off as it decays for a more interesting sound.