Sound: Difference between revisions

From OLPC
Jump to navigation Jump to search
No edit summary
(clean up, provide an overview)
Line 1: Line 1:
{{stub}}
{{stub}}
A few notes on sound: Ogg vorbis and speex as our preferred codecs for general audio and human speech.
A few notes on sound, see also [[:Category:Audio]].


== Software overview ==
[[Vorbis]], [[Theora]], [[Speex]] (and FLAC) are all under the xiph.org umbrella, and all can be sent in .ogg files.
Starting from user activities and working down...


=== Sound playback ===
We are also looking into using [[Pulseaudio|Pulse Audio Server]], which uas transparency across the network.
You play back sound files in [[Browse]].
Ogg vorbis and [[Speex]] are our preferred codecs for general audio and human speech.
These compressed representations of sound are stored in files using the [[Ogg]] container file format.
The sound files generally have the extension <tt>.ogg</tt>.


The [[Totem plugin|Totem browser plugin]] handles .ogg files.
It uses the [[GStreamer]] multimedia framework to unpack Ogg containers and decode audio and video streams.
The


== Speex ==
=== Sound generation ===
You create sounds in the [[TamTam]] suite of music and sound activities.
[[Gstreamer]] has a speex decoder, so things which use gstreamer, like the totem Browse plug-in, should play it.
TamTam programs use the [[Csound]] music and audio signal processing language as their audio "engine".


== Speaker Capabilities ==
=== Sound recording ===
The [[Record]] activity also uses the [[GStreamer]] multimedia framework to record video and audio from the XO's camera and microphone.

=== Low-level ===
The low-level sound API and kernel drivers are ALSA ([[wikipedia:Advanced Linux Sound Architecture]]).
We are looking into using [[PulseAudio]] sound server in the future, which has transparency across the network.

Some Linux software packages require other sound software such as jack and portaudio.

== Hardware==
See [[Audio hardware]]

=== Speaker Capabilities ===
(most data from the leader of the [[TamTam]] project [[User:Ethrop | Ethrop]] who might have more data on the subject)
(most data from the leader of the [[TamTam]] project [[User:Ethrop | Ethrop]] who might have more data on the subject)


Line 35: Line 56:
causing distortion and possible damage.
causing distortion and possible damage.


In listening to podcasts, certainly headphones sound better.


== DTMF ==
== Random bits ==
=== DTMF ===


For your collective interest, the speakers can reproduce DTMF tones
For your collective interest, the speakers can reproduce DTMF tones
Line 44: Line 67:
to transmit tones over a ham radio for making an IRLP request. The DTMF
to transmit tones over a ham radio for making an IRLP request. The DTMF
tones include 697 Hz for the top row.
tones include 697 Hz for the top row.

In listening to podcasts, certainly headphones sound better.




== Overcoming lack of Tonic ==
=== Overcoming lack of Tonic ===


Music activities should thus default to a bassoon.
Music activities should thus default to a bassoon.

Revision as of 20:47, 14 August 2008

This article is a stub. You can help the OLPC project by expanding it.

A few notes on sound, see also Category:Audio.

Software overview

Starting from user activities and working down...

Sound playback

You play back sound files in Browse. Ogg vorbis and Speex are our preferred codecs for general audio and human speech. These compressed representations of sound are stored in files using the Ogg container file format. The sound files generally have the extension .ogg.

The Totem browser plugin handles .ogg files. It uses the GStreamer multimedia framework to unpack Ogg containers and decode audio and video streams. The

Sound generation

You create sounds in the TamTam suite of music and sound activities. TamTam programs use the Csound music and audio signal processing language as their audio "engine".

Sound recording

The Record activity also uses the GStreamer multimedia framework to record video and audio from the XO's camera and microphone.

Low-level

The low-level sound API and kernel drivers are ALSA (wikipedia:Advanced Linux Sound Architecture). We are looking into using PulseAudio sound server in the future, which has transparency across the network.

Some Linux software packages require other sound software such as jack and portaudio.

Hardware

See Audio hardware

Speaker Capabilities

(most data from the leader of the TamTam project Ethrop who might have more data on the subject)

The speakers in the XO are from and for cellphone speakers. They are optimized for voice, and have less quality frequency response at the low end of the spectrum. The XO speakers have a severely biased frequency response. We have recently performed a thorough analysis of the audio response curve of the machine and there is a spectacular 12dB peak between 3000 and 4500 Hz, this on all models. I suspect these are mobile phone speakers designed for voice clarity. What this means is kids will likely crank up the volume so that they can hear some of the lower frequencies. Since the physical size of the speakers prohibits any frequencies below 350 HZ, as they try to get a decent bandwidth, they will get the "membrane-against-the-casing" distortion (which has the merit of making the kids lower the volume but risks killing the speakers if done routinely). Someone on the hardware side really should look at the long term prospects for audio hardware failure and see what correction we can bring, by limiting signal output and/or equalising the output of the AD1888 (we dont know what can be done on chip...)

The speakers start rolling off at about 600 Hz and are virtually worthless below 400 Hz.

The hardware has a one-pole highpass filter at about 400 Hz (I forget the exact frequency but it doesn't matter much) in order to reduce the amount of useless LF energy that is presented to the speakers. The rolloff is only in the speaker path; the headphone path has flat response across the audio band.

In my experience, equalization doesn't improve the sound from the speakers very much. They sound tinny and weak no matter what you do. Taming the big peak in the 4 Khz range is of some value, but most program material has little information in that region, so the perceived improvement is small. Boosting the bass makes things worse - the speakers don't have enough air-moving capacity (cone diameter times linear motion range) to render low frequencies, and sending them more signal just slams the mechanical structure against its physical limits, causing distortion and possible damage.

In listening to podcasts, certainly headphones sound better.

Random bits

DTMF

For your collective interest, the speakers can reproduce DTMF tones reliably provided the levels are set down from maximum.

At lunch today on a B2 with build-debian, the dtmfdial package was used to transmit tones over a ham radio for making an IRLP request. The DTMF tones include 697 Hz for the top row.


Overcoming lack of Tonic

Music activities should thus default to a bassoon.

The odd thing about a bassoon is that the fundamental frequency is nearly absent. The ear-brain system fills in this frequency, making the bassoon sound very low pitched without actually containing much of the very low frequencies.

At the other extreme, a sine wave is worst case. Recorders produce this, and flutes nearly do.

See also