aboutsummaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2016-12-02Removed asound.hTaylor Holberton
It was added because bionic didn't have a copy of the file in 2011. But, it was finally added in 2013 and update since. There is no longer a need for this file.
2016-12-02mixer: add ability to update control list with new controlsRichard Fitzgerald
New controls could appear during runtime, for example if a new firmware is downloaded to a DSP. Since ALSA drivers are not supposed to delete or renumber existing controls we can assume that any new controls will be after any controls we already know about. We can use this to enable extending our current list of controls, which is more efficient than closing the mixer session and recreating it. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
2016-12-01bumped minor versionTaylor Holberton
2016-12-01Using frame counts in pcm_readi and pcm_writeiTaylor Holberton
pcm_readi and pcm_writei now use a frame count to specify the buffer length instead of using a byte count.
2016-12-01Added pcm_readi and pcm_writei functionsTaylor Holberton
Added these functions to replace pcm_read and pcm_write, which don't return the number of frames actually transferred. On GCC-like compilers, pcm_read and pcm_write have been marked as deprecated On doxygen documentation, they have been marked as deprecated as well.
2016-12-01Added format related getters for PCMTaylor Holberton
Added functions: - pcm_get_channels - pcm_get_rate - pcm_get_format These were added since they're required for iterating samples and frames.
2016-12-01Added function, mixer_get_num_ctls_by_nameTaylor Holberton
This function is used to get the number of mixer controls by a given name. It was added for use with mixer_get_ctl_by_name_and_index so that client code can expect the last valid index to pass.
2016-12-01Added mixer_get_ctl_constTaylor Holberton
This function was added to make available a mixer control accessor in a function that does not modify its value.
2016-12-01Added const specifier for several mixer functionsTaylor Holberton
Functions changed are: - mixer_get_name - mixer_get_num_ctls - mixer_ctl_get_id - mixer_ctl_get_name - mixer_ctl_get_type - mixer_ctl_get_type_string - mixer_ctl_get_num_values - mixer_ctl_get_num_enums - mixer_ctl_get_enum_string - mixer_ctl_get_percent - mixer_ctl_get_value - mixer_ctl_get_array - mixer_ctl_get_range_min - mixer_ctl_get_range_max
2016-12-01Added const specifier in several functionsTaylor Holberton
pcm_get_file_descriptor pcm_get_error pcm_get_buffer_size pcm_frames_to_bytes pcm_bytes_to_frames pcm_get_subdevice
2016-12-01added const specifier in function, pcm_is_readyTaylor Holberton
2016-12-01Added const specifier in pcm_openTaylor Holberton
The const specifier was added to the struct pcm_config argument.
2016-12-01Added const specifier to params functionsTaylor Holberton
Funtions changed are: - pcm_params_get_mask - pcm_params_get_min - pcm_params_get_max
2016-11-23fixed function reference in docTaylor Holberton
2016-11-23added missing asterisk for docTaylor Holberton
2016-11-19added tinyalsa version headerTaylor Holberton
2016-11-19renamed doxygen group, tinyalsa-pcm to libtinyalsa-pcmTaylor Holberton
2016-11-19origanized and added some documentationTaylor Holberton
2016-10-01added some documentation to mixer interfaceTaylor Holberton
2016-10-01added basic pcm documentationTaylor Holberton
2016-10-01seperated pcm and mixer APIsTaylor Holberton
2016-10-01added support for more signed typesTaylor Holberton
2016-09-16Merge branch 'address-duplicate-control-names' of ↵Taylor Holberton
https://github.com/dawagner/tinyalsa into dawagner-address-duplicate-control-names
2016-08-03Added get_file_descriptor()Taylor Holberton
2015-10-12asound.h: include <time.h> to get struct timespec prototyperofl0r
without including it, we get In file included from mixer.c:44:0: include/sound/asound.h:337:18: error: field 'trigger_tstamp' has incomplete type include/sound/asound.h:338:18: error: field 'tstamp' has incomplete type etc.
2015-09-15Merge pull request #48 from vinodkoul/wait_delaySimon Wilson
Wait delay
2014-09-09mixer: Add mixer_ctl_get_idRichard Fitzgerald
Add a function to get an id of a control that can be passed to mixer_get_ctl(). This can be used to lookup a control by name and store its id for later use rather than have the overhead of name lookup each time it is used. Lookup by id is quick and avoids the disadvantage that storing a pointer to the mixer_ctl object creates a client with a dependency on the address of the internal control array. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
2014-08-12tinyalsa: add pcm_get_subdevice()David Wagner
The users of tinyalsa had no way of knowing on which subdevice a stream had been created. A new API, "unsigned int pcm_get_subdevice(struct *pcm)" returns it. This information is filled during the pcm_open() Change-Id: Ie866e10e06ce6691ede09e2ca46a24441723ea8b Signed-off-by: David Wagner <david.wagner@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
2014-08-12Tinyalsa: add pcm_delay()Hardik T Shah
ALSA supports reporting of pcm_delay, make that availble to the users of tinyalsa too Change-Id: Ic460f5c55137d263fdf7b142503d3bd52c4b7ebd Signed-off-by: Hardik T Shah <hardik.t.shah@intel.com> Signed-off-by: Apelete Seketeli <apeletex.seketeli@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
2014-06-03Update tinypcminfo to display format informationAndy Hung
Change-Id: I0e6a04da5a4b122a3748b16c7eb01c4a224c3d84 Signed-off-by: Andy Hung <hunga@google.com>
2014-06-03Merge pull request #34 from elaurent/masterSimon Wilson
add support for mmap read
2014-05-08Merge pull request #33 from gkasten/CL_avsyncSimon Wilson
pcm_get_htimestamp can now use CLOCK_MONOTONIC
2014-05-06Merge pull request #23 from roml/cleanupSimon Wilson
Clean up asoundlib.h header file
2014-04-29tinyalsa: add separate call for pcm prepareOmair Mohammed Abdullah
Tinyalsa combines PREPARE and START calls to the driver in the pcm_start() function. Typically, this is needed for making a driver allocating hardware resources that are not related to a PCM stream. Change-Id: Ic83fad784936bbebab28e8e425debd449182db88 Signed-off-by: Omair Mohammed Abdullah <omair.m.abdullah@linux.intel.com> Signed-off-by: David Wagner <david.wagner@intel.com> Signed-off-by: Bruce Beare <bruce.j.beare@intel.com> Signed-off-by: Jack Ren <jack.ren@intel.com> Author-Tracking-BZ: 73509
2014-04-22Add a function to disambiguate duplicate control namesFrédéric Boisnard
Control names are not unique and can be shared by multiple mixers controls. When this happens, there is no way of accessing the mixer using its control name, because mixer_get_ctl_by_name() always returns the first match. The only way of accessing the mixer is through its control number, i.e. using mixer_get_ctl(). This patch adds the function mixer_get_ctl_by_name_and_index() to offer the possibility to retrieve a control through its name and index. This index corresponds to the nth occurence of the control name in the global supported controls names list. Change-Id: Ie29bf2a949ecf69f106bbe359155cdbfbe98928c Signed-off-by: Frédéric Boisnard <fredericx.boisnard@intel.com> Signed-off-by: David Wagner <david.wagner@intel.com> Signed-off-by: Bruce Beare <bruce.j.beare@intel.com> Signed-off-by: Jack Ren <jack.ren@intel.com> Author-Tracking-BZ: 139255
2013-09-27add support for mmap readEric Laurent
2013-09-03pcm_get_htimestamp can now use CLOCK_MONOTONICGlenn Kasten
Previously the timebase was not documented. Now a new pcm_open flag can be used to specify the clock. If flag PCM_MONOTONIC is specified, then pcm_open uses SNDRV_PCM_IOCTL_TTSTAMP with parameter SNDRV_PCM_TSTAMP_TYPE_MONOTONIC to request timestamps in CLOCK_MONOTONIC. Change-Id: I40ce359cb38d686cbb2521fb0602a8a17ab4f925
2013-07-17pcm: support S24_LE formatSimon Wilson
S24_LE is 24 bit audio in a 32 bit sample size. Also make the pcm_format_to_bits() function part of the API since it will be required for tinycap.
2013-06-28mixer: add mixer_get_name() APISimon Wilson
2013-06-28mixer: add mixer_ctl_update() APISimon Wilson
Some sound cards update their controls due to external events, such as HDMI EDID byte data changing when an HDMI cable is connected. This API allows the count of elements to be updated.
2013-05-07mixer: add get/set_array APISimon Wilson
This replaces (and extends) the existing get/set_bytes API, which is no longer required.
2012-12-18Clean up asoundlib.h header fileRom Lemarchand
Remove unused constants and unimplemented functions.
2012-12-03pcm: add pcm_get_params APISimon Wilson
This enables the capabilities of any given PCM to be queried. Created with input from Priyesh Bisla and Gabriel Beddingfield.
2012-10-24mixer: Add mixer_ctl_{set,get}_bytes()Dimitris Papastamos
For binary controls we don't want to go through mixer_ctl_{set,get}_value() as that will trigger many calls to our get()/put() callback in the kernel. Set the entire payload at once and trigger the get()/put() callback once. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
2012-10-22Add pcm_wait() to the tinyalsa API.Gabriel M. Beddingfield
2012-10-22pcm: Add support for S8 and S24LE formats.Gabriel M. Beddingfield
2012-05-04pcm: Add PCM_NORESTART flagJohn Grossman
Add a flag which can be passed to pcm_open (called PCM_NORESTART). When set on a playback stream, calls to pcm_write will not automatically attempt to restart an ALSA device in the case of an underflow. Instead, it will propagate the first EPIPE error up to the application to allow it to handle the underflow situation. Subsequent calls to pcm_write will attempt to start the pipeline.
2012-03-08mixer: simplify string get APIsSimon Wilson
Just like the pcm_get_error() API, simplify the mixer API functions to return pointers to constant strings instead of making copies of strings.
2012-02-10pcm: Constify write buffersMark Brown
Mark the write buffers as const - they won't be modified and this is friendlier to applications.
2011-10-27include: fix header comments and argumentsPierre-Louis Bossart
Comment on buffer size was wrong. Argument to bytes_to_frames is bytes, not frames