1 / 6

Audio effects implementation

Audio effects implementation . ECE 3551 – Microcomputer Systems I By Abdulrahman Bin Humood. Overview.

ziya
Download Presentation

Audio effects implementation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Audio effects implementation ECE 3551 – Microcomputer Systems I By AbdulrahmanBin Humood

  2. Overview • This project was created to use the OMAP L137 Texas Instruments DSP Board to control audio outputand display some audio effects that have been taught during the course of the class.

  3. Code Imlementation • switch(mode) • { • case 1: • Passthrough(pIn, pOut); • break; • case 2: • Process_Data(pIn, pOut); • Delay(pIn, pOut); • break; • case 3: • Process_Data(pIn, pOut); • Vibrato(pIn, pOut); • break; • default: • Passthrough(pIn, pOut); • break; • }

  4. Delay Code • void Delay(short *pIn, short *pOut) //Applies delay effect to signal. • { inti; • for (i = 0; i < BUFLEN; i++) • { • int delay = temp - (2000 - 20); • buffer_in2[temp] = pIn[i * 2]; • buffer_in1[temp] = pIn[i * 2 + 1]; • if ( delay < 0 ) • { • delay = delay + 2000; • } • output1 = buffer_in1[temp] + 0.9 * buffer_in1[delay]; • output2 = buffer_in2[temp] + 0.9 * buffer_in2[delay]; • pOut[i * 2] = (short)output1; • pOut[i * 2 + 1] = (short)output2; • temp++; • temp = temp % 2000; • } • }

  5. Vibrato Code • void Vibrato(short *pIn, short *pOut) • { • inti; • for (i = 0; i < BUFLEN; i++) • { • var_time_delay = (int)(0.5 * (1 + cos (2 * 3.14 * 0.4 * temp / 2000)) * BUFSIZE); • var_delay = temp - var_time_delay; • buffer_in1[temp] = pIn[i * 2 + 1]; • buffer_in2[temp] = pIn[i * 2]; • if (var_delay < 0) • { • var_delay = var_delay + 2000; • } • output1 = buffer_in1[temp] + 0.6 * (buffer_in1[var_delay]); // implementation equation of vibrato effect • output2 = buffer_in2[temp] + 0.6 * (buffer_in2[var_delay]); // implementation of vibrato effect • pOut[i * 2] = output1; • pOut[i * 2 + 1] = output2; • temp++; • temp = temp % 2000; • }}

  6. END • THANK YOU!

More Related