implemented adsr_envelope() function

adsr_envelope function return value of amplitude related to adsr par