Pages: [1]   Go Down
Author Topic: ADSR working in Guitar Help :)  (Read 758 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 19
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello Guys,


i have try this code https://github.com/rmosquito/PolyEGg which is generate ADSR working on arduino and successfully working. but i am wonder how would be work in audio signal such guitar? i believe the code will work only with the build in audio in arduino. ??

i want to work it like this
to increase the guitar sustain. smiley

what should i do to work it?
any answer would be appreciated thank you so much in advance.smiley


Regards
Darwin

Logged

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 179
Posts: 8068
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The way to add sustain is to amplify the signal inversely to the magnitude of the signal.  That is probably easier to do in with analog signals, although it can be done with digital signals IF you have a fast enough processor.  To get reasonable sound quality you will need a faster processor (and A/D)  than a 16 MHz ATmega.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 508
Posts: 31431
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

But the code says:-
Quote
this software is currently pre-alpha and non-functional.
That means it does not work. And seeing it was 5 months ago it looks like it never did.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 19
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi guys thanks for response. =)

if the code is not working ? what would be to do to start ADSR? (ATTACT, DECAY, SUSTAIN, RELEASE). can we share as the method to work with  arduino?  what should be the idea? audio buffer or ringbuffer?,timer?,etc? something like the output in pwm 11 in arduino and analog 0 for audio signal?

any idea? =)

 

Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 508
Posts: 31431
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I don't think you can do what this with the arduino. Basically it has not got enough memory to store the signals and there is not enough processing power to process the samples fast enough. Also with only 10 bits input and 8 bits output on PWM the sound quality will be very poor.

This is the best I have sen for real time processing:-
http://interface.khm.de/index.php/labor/experimente/arduino-realtime-audio-processing/
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 19
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Grumpy_Mike,

Great Research. i have already try this. and really works!=) but i have a question. what would be the recommendation to upgrade or extend the arduino memory? to output long delay...   others told me that i need to use sd card.?

I am very thankful all the response smiley
Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 508
Posts: 31431
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The problem with an SD card is that it is too slow for random access at audio speeds. This is especially true if you need to read and write to it. Also there is a write limit so it will fail quite soon. You are better using SRAM there are some boards about or you could build your own.
Extra memory shield for the Mega:-
http://www.ruggedcircuits.com/html/megaram.html
Logged

Pages: [1]   Go Up
Jump to: