Open Sound System

Sound server for Unix-like operating systems

Open Sound System

Original author(s)| Hannu Savolainen
Developer(s)| NCR Corporation
Stable release|

4.2 build 2019 / March 5, 2019; 6 years ago (2019-03-05)[1]

Operating system| Cross-platform[2]
Type| Audio
License|

* BSD-2-Clause
* CDDL-1.0
* GPL-2.0-only
* Proprietary (formerly)

Website| www.opensound.com

The Open Sound System (OSS) is an interface for making and capturing sound in Unix and Unix-like operating systems. It is based on standard Unix devices system calls (i.e. POSIX read, write, ioctl, etc.). The term also sometimes refers to the software in a Unix kernel that provides the OSS interface; it can be thought of as a device driver (or a collection of device drivers) for sound controller hardware. The goal of OSS is to allow the writing of sound-based applications that are agnostic of the underlying sound hardware.

OSS was created by Hannu Savolainen and is distributed under four license options, three of which are free software licences, thus making OSS free software.[3]

## API

[edit]

The API is designed to use the traditional Unix framework of open(), read(), write(), and ioctl(), via device files. For instance, the default device for sound input and output is /dev/dsp. Examples using the shell:

cat /dev/random > /dev/dsp # plays white noise through the speaker
cat /dev/dsp > a.a # reads data from the microphone and copies it to file a.a

OSS implements the /dev/audio interface. Detailed access to individual sound devices is provided via the /dev/oss directory. OSS also has MIDI support in /dev/sequencer, /dev/music (both legacy) and /dev/mini.[4][5]

On Linux, OSS4 is also able to emulate ALSA, its open-source replacement.[6]

## History

[edit]

OSS was originally "VoxWare", a Linux kernel sound driver by Hannu Savolainen. Savolainen made the code available under free software licenses, GPL for Linux and BSD for BSD distributions. Between November 1993 (and Linux 1.00)[7] and 1997, OSS was the sole choice of sound system in FreeBSD and Linux. This was changed when Luigi Rizzo wrote a new "pcm" driver for FreeBSD in 1997, and when Jaroslav Kysela started Advanced Linux Sound Architecture in 1998.[8]

In 2002, Savolainen was contracted by the company 4Front Technologies and made the upcoming OSS 4, which includes support for newer sound devices and improvements, proprietary. In response, the Linux community abandoned the OSS/free implementation included in the kernel and development effort switched to the replacement Advanced Linux Sound Architecture (ALSA). FreeBSD by this time had switched to a "newpcm" project started in 1999 and was not affected.[8]

In July 2007, 4Front Technologies released sources for OSS under CDDL-1.0 for OpenSolaris and GPL-2.0-only for Linux. Drivers for some soundcards remained closed-source and were not included in the release.[3] In January 2008, 4Front Technologies released OSS for FreeBSD (and other BSD systems) under the BSD-2-Clause.[9]

## Adoption status

[edit]

### Code

[edit]

OSS4 now exists mostly as a standalone piece of software, not integrated into the kernel source code. The exception is Solaris and OpenSolaris, which use a fork of OSS4 called Boomer. It combines the OSS4 framework (audio and mixer) together with Sun's earlier SADA (/dev/audio) API.[10]

Although Linux distributions such as Ubuntu made OSS4 available as a software package after it was made free software, they have chosen to ignore any bugs filed against these packages.[11]

### API

[edit]

The OSS API has remained influential despite the obscurity of the original library. NetBSD's documentation describes it as "the preferred API in FreeBSD and Solaris".[12]

FreeBSD contains an independently developed implementation of the OSS API, which includes, among other things, in-kernel resampling, mixing (vchans), equalizer, surround sound, and independent volume control for each application. It also supports bit-perfect mode.[13] It gradually evolved from the "newpcm" replacement written in 1999 and caught up with OSS4 API around 2005.[8]

NetBSD supports a compatibility mode for the OSS API, by providing the `soundcard.h` header file and the `libossaudio` library, which internally operate using the native Sun-like audio interface. The replacement was first seen in NetBSD 1.3 of 1998.[12]

Linux had, as aforementioned, switched to Advanced Linux Sound Architecture since 2003 (kernel 2.6). ALSA provides an optional, in-kernel, OSS emulation mode that appears to programs as if it were OSS.[14] ALSA also has a aoss userspace program that works by intercepting systems calls directed to the OSS device files.[15]

## OSS/3D

[edit]

OSS/3D is a plugin for music players, which acts as an audio postprocessing engine. Supported players include Winamp, Windows Media Player (9 or later), musicmatch, Sonique, Foobar2000, JetAudio, XMMS. It is ported to Windows and Linux platforms. Unlike the OSS, it is shareware.

4Front OSS3D was later renamed to Joesoft Hear.[16]

## Criticism

[edit]

OSS both as API and as software has been criticized by some developers, such as Paul Davis (of JACK Audio Connection Kit) and Lennart Poettering (of competing PulseAudio).[17][failed verification][18]

## See also

[edit]

* Free and open-source software portal

* Advanced Linux Sound Architecture – prevailing sound framework in the Linux kernel
* PulseAudio – a sound server for desktop use, commonly used on Linux systems
* JACK Audio Connection Kit – prevailing sound server for professional audio production on Linux

## References

[edit]

1. ^ OSS v4.2 build 2019, archived from the original on 2022-09-25, retrieved 2019-05-10
2. ^ "OSS Download Registration".
3. ^ a b 4Front technologies releases the source code for open sound system, Linux PR, archived from the original on July 25, 2011, retrieved 2012-01-08
4. ^ "OSS v4.x API reference - OSS API basics". manuals.opensound.com.
5. ^ "Open Sound System (3.x) Programmer's Guide" (PDF). 2000. Retrieved 22 February 2023.
6. ^ "Tips And Tricks - Open Sound System". ossnext.trueinstruments.com.
7. ^ "Linux 0.99 patchlevel 14 - Diff - 75bb5836a8a8c0ee44ffd60a51f357b9568f1381^! - pub/scm/linux/kernel/git/nico/archive - Git at Google". kernel.googlesource.com. Retrieved 2024-03-22.
8. ^ a b c "Sound - FreeBSD Wiki". wiki.freebsd.org.
9. ^ 4Front Technologies releases OSS for FreeBSD under the BSD license, opensound.com, retrieved 2012-01-08
10. ^ Hannu's Blog » Boomer, 4front-tech.com, archived from the original on 2012-03-16, retrieved 2012-01-08
11. ^ Ubuntu Documentation: OpenSound, ubuntu.com, retrieved 2012-01-08
12. ^ a b "ossaudio(3) - NetBSD Manual Pages". man.netbsd.org.
13. ^ sound, Freebsd.org, 2009-07-13, retrieved 2012-01-08
14. ^ OSS Emulation, archived from the original on 2012-06-05, retrieved 2012-07-07
15. ^ "aoss(1) — Arch manual pages". man.archlinux.org.
16. ^ · Obsolete product reference, Yohng.com, retrieved 2012-01-08
17. ^ "A tutorial on using the ALSA Audio API".
18. ^ "Interview with Lennart Poettering (LinuxFR.org) [LWN.net]". lwn.net.

## External links

[edit]

* Official website
* Building the Open Sound System From Source
* State of sound in Linux not so sorry after all

* v
* t
* e

Linux kernel

Organization|

| Kernel|

* Linux Foundation
* Linux Mark Institute
* Linus's law
* Tanenbaum–Torvalds debate
* Tux
* SCO disputes
* Linaro
* GNU GPL v2
* menuconfig
* Supported computer architectures
* Version history
* Criticism

|

Support|

* Developers
* The Linux Programming Interface
* kernel.org
* LKML
* Linux conferences
* Users
* Linux User Group (LUG)

People|

* Werner Almesberger
* H. Peter Anvin
* Jens Axboe
* Moshe Bar
* Suparna Bhattacharya
* Andries Brouwer
* Rémy Card
* Alan Cox
* Matthew Garrett
* Avi Kivity
* Con Kolivas
* Greg Kroah-Hartman
* Benson Leung
* Robert Love
* David S. Miller
* Ingo Molnár
* Andrew Morton
* Hans Reiser
* Rusty Russell
* Shuah Khan
* Linus Torvalds
* Theodore Ts'o
* Stephen Tweedie
* Harald Welte
* Chris Wright

Technical|

| Debugging|

* CRIU
* ftrace
* kdump
* Linux kernel oops
* SystemTap
* BPF

|

Startup|

* vmlinux
* System.map
* dracut
* initrd
* initramfs

ABIs|

* Linux Standard Base
* x32 ABI

APIs|

| Kernel|

| System Call
Interface|

* POSIX
* ioctl
* select
* open
* read
* close
* sync
* …
* Linux-only
* futex
* epoll
* splice
* dnotify
* inotify
* readahead
* …

|

In-kernel|

* ALSA
* Crypto API
* io uring
* DRM
* kernfs
* Memory barrier
* New API
* RCU
* Video4Linux
* IIO

Userspace|

| Daemons,
File systems|

* bpffs
* configfs
* devfs
* devpts
* debugfs
* FUSE
* hugetlbfs
* pipefs
* procfs
* securityfs
* sockfs
* sysfs
* tmpfs
* systemd
* udev
* Kmscon
* binfmt_misc

|

Wrapper
libraries|

* C standard library
* glibc
* uClibc
* Bionic
* libhybris
* dietlibc
* EGLIBC
* klibc
* musl
* Newlib
* libcgroup
* libdrm
* libalsa
* libevdev
* libusb
* liburing

Components|

* Kernel modules
* BlueZ
* cgroups
* Console
* bcache
* Device mapper
* dm-cache
* dm-crypt
* DRM
* EDAC
* evdev
* Kernel same-page merging (KSM)
* LIO
* Framebuffer
* LVM
* KMS driver
* Netfilter
* Netlink
* nftables
* Network scheduler
* perf
* SLUB
* zram
* zswap

* Process and I/O schedulers:
* Brain Fuck Scheduler
* Completely Fair Scheduler (CFS)
* Earliest eligible virtual deadline first (EEVDF)
* Noop scheduler
* O(n) scheduler
* O(1) scheduler
* SCHED_DEADLINE
* SCHED_FIFO
* SCHED_RR

* Security Modules: AppArmor
* Exec Shield
* seccomp
* SELinux
* Smack
* Tomoyo Linux
* Linux PAM

* Device drivers
* 802.11
* graphics
* Raw device

* initramfs
* KernelCare
* kexec
* kGraft
* kpatch
* Ksplice

Variants|

* Mainline
* Linux kernel
* Linux-libre
* High-performance computing
* INK
* Compute Node Linux
* SLURM
* Real-time computing
* RTLinux
* RTAI
* Xenomai
* PREEMPT_RT
* MMU-less
* μClinux
* PSXLinux

| Virtualization|

* Hypervisor
* KVM
* Xen
* OS-level virtualization
* Linux-VServer
* Lguest
* LXC
* OpenVZ
* Other
* L4Linux
* User-mode Linux
* MkLinux
* coLinux

|

Adoption|

| Range
of use|

* Desktop
* Embedded
* Gaming
* Thin client:
* LTSP
* Server:
* LAMP
* LYME-LYCE
* Devices

|

Adopters|

* List of Linux adopters

* Linux portal
* Free and open-source software portal
* Category

*[v]: View this template
*[t]: Discuss this template
*[e]: Edit this template