From: Markus S. <msv...@ae...> - 2011-02-21 17:31:04
|
Hi Konstantinos, There may be some software available that will allow you to do what you want, without writing and compiling custom code. I have never used anything like this, but there may be someone on this mailing list who could share some experience. I replied to your email privately, but for the benefit of the group, I'll also share the info: Here is a good ALSA tutorial, which I followed to learn how to acquire audio on the Gumstix: http://www.equalarea.com/paul/alsa-audio.html I recommend reading the section "A Minimal Capture Program" to get an idea of how to set up the ALSA library for audio capture. Here are the general programming skills you will need to implement your project: * using ALSA to capture buffers of audio * some knowledge of multi-threaded programming (e.g. producer-consumer pattern, thread synchronization methods) * TCP/IP programming, to create the custom server that will send the audio buffers to another computer on the wireless network * you will need to know how to cross-compile C++ code for the Gumstix, to obtain an IPK file which you will install on your Gumstix Overo Here is the approximate program structure that will accomplish what you need: * From your main() function, start 2 threads: (1) that uses ALSA to capture audio, and (2) that starts a TCP/IP server, receives audio buffers from the audio thread, and sends the buffers to connected clients over the network. * Each time the ALSA thread captures a buffer of audio, it passes it on to the TCP/IP thread. * Each time the TCP/IP thread receives a buffer of audio, it sends it over the network. The TCP/IP thread will have to handle incoming connections from TCP/IP clients and other details of the connection. There are plenty of sample codes and tutorials available on the web that will show you how to accomplish each of these tasks individually. It will be up to you to combine them into one program that does what you want. Regards, Markus. On 20/02/2011 5:30 AM, Konstantinos Birkos wrote: > @Markus > Thank you for your answer. This is very close to what I intend to do: > have each unit operating and streaming for days. I actually want to > create a network of devices for animal sound recording. > > Since my developing skills are not that advanced, I had initially > though of using audio streaming software suitable for the embedded > operating system. I am interested in your solution. > > Regards, > Konstantinos > > > > O/H Markus Svilans έγραψε: >> On the audio capture side, I have written code using the ALSA library >> for continuously recording audio, using the Overo on-board audio >> hardware. It has been run continuously for days and days without a >> problem. Let me know if you would like a snippet of sample code. >> >> As you probably already know, uncompressed single channel audio at >> 44kHz, 16 bits per sample, requires a data rate of ~88000 bytes per >> second. From what I have seen through working on various other >> non-audio projects, I think the wireless network hardware on the >> Overo Air/Fire could easily handle that. >> >> To get your project off the ground, you could probably combine one of >> the ALSA example programs, and write some custom TCP/IP server code >> to send buffers of captured audio to a remote client computer. For >> example from your main() function you could launch a couple of >> threads that handle those two tasks, using the producer/consumer >> structure. >> >> Regards, >> Markus. >> >> >> On 2011.02.19 4:01, Konstantinos Birkos wrote: >>> Hello, >>> >>> I am unfamiliar with the gumstix technology and I would like to >>> investigate its applicability in a specific scenario: I would like >>> to deploy a wireless network for *high quality audio *(44 kHz, 12+ >>> bits)*capturing*. I want to use low-cost, low-energy-consumption >>> wireless devices to record sounds and send them over WiFi to a >>> distant computer. I was wondering whether gumstix can offer the >>> desired functionality. >>> >>> Thank you >>> -- >>> Konstantinos Birkos >>> PhD Candidate >>> Wireless Telecommunication Laboratory >>> Department of Electrical and Computer Engineering >>> University of Patras >>> Patras, Greece >>> Tel.: +30 2610 996465 >>> >>> >>> ------------------------------------------------------------------------------ >>> The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE: >>> Pinpoint memory and threading errors before they happen. >>> Find and fix more than 250 security defects in the development cycle. >>> Locate bottlenecks in serial and parallel code that limit performance. >>> http://p.sf.net/sfu/intel-dev2devfeb >>> >>> >>> _______________________________________________ >>> gumstix-users mailing list >>> gum...@li... >>> https://lists.sourceforge.net/lists/listinfo/gumstix-users >>> >> ------------------------------------------------------------------------ >> >> ------------------------------------------------------------------------------ >> The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE: >> Pinpoint memory and threading errors before they happen. >> Find and fix more than 250 security defects in the development cycle. >> Locate bottlenecks in serial and parallel code that limit performance. >> http://p.sf.net/sfu/intel-dev2devfeb >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> gumstix-users mailing list >> gum...@li... >> https://lists.sourceforge.net/lists/listinfo/gumstix-users >> > > > -- > Konstantinos Birkos > PhD Candidate > Wireless Telecommunication Laboratory > Department of Electrical and Computer Engineering > University of Patras > Patras, Greece > Tel.: +30 2610 996465 |