Intel® FPGA University Program
University Program Material, Education Boards, and Laboratory Exercises
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.

de2_115 audio core

Altera_Forum
Honored Contributor II
1,063 Views

hi dear members, 

i make a simple project on DE2_115 board.It record sound and play it.But sound is very dirty.my c code is : 

#include 

<stdio.h> 

 

int 

i=0; 

 

#include 

"altera_up_avalon_audio.h" 

 

int 

main(void

 

 

alt_up_audio_dev * audio_dev; 

 

/* used for audio record/playback */ 

 

unsigned 

int l_buf; 

 

unsigned 

int r_buf; 

 

// open the Audio port 

 

audio_dev = alt_up_audio_open_dev ( 

"/dev/audio"); 

 

if 

( audio_dev == null

 

printf( 

"Error: could not open audio device \n"); 

 

else 

 

printf ( 

"Opened audio device \n"); 

 

/* read and echo audio data */ 

 

 

 

 

// read audio buffer 

 

alt_up_audio_read_fifo (audio_dev, &(r_buf), 1, ALT_UP_AUDIO_RIGHT); 

 

alt_up_audio_read_fifo (audio_dev, &(l_buf), 1, ALT_UP_AUDIO_LEFT); 

 

 

// write audio buffer 

 

alt_up_audio_write_fifo (audio_dev, &(r_buf), 1, ALT_UP_AUDIO_RIGHT); 

 

alt_up_audio_write_fifo (audio_dev, &(l_buf), 1, ALT_UP_AUDIO_LEFT); 

 

 

&#12288; 

 

 

 

 

0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
92 Views

What does "dirty" mean?

Altera_Forum
Honored Contributor II
92 Views

sizzle.I solved it.Due to frequency sizzle doing

Altera_Forum
Honored Contributor II
92 Views

I have the same issue. How did you fix it?

Reply