To decode you need an integer FFT to determine the frequenciesTo encode a signal in software is more difficult as the Arduino has no analog out, so you need extra hardware and if you buy extra HW why not a DTMF chip directly ...

What is your project/goal with the DTMF? can you tell us more? maybe there are other solutions.