aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-05-19add pcm_prepare before pcm_startdvdli
2021-03-22Merge pull request #203 from dvdli/tinyalsa-fixdvdli
fix a variable name in tests
2021-03-22fix bug in testsdvdli
2021-03-15Merge pull request #202 from dvdli/tinyalsa-float-devdvdli
floating-point PCM support
2021-03-11add floating-point PCM supoort to tinyplaydvdli
This change also fixes overwriting the appl_ptr and avail_min when calling the pcm_state function.
2021-03-10add a loopback test for floating point PCMdvdli
2021-02-22support float config and float wave file playbackdvdli
2021-02-22Merge pull request #201 from dvdli/sync-aospdvdli
Sync AOSP: [LSC] Add LOCAL_LICENSE_KINDS to external/tinyalsa_new
2021-02-22Sync AOSP: [LSC] Add LOCAL_LICENSE_KINDS to external/tinyalsa_newdvdli
https://android.googlesource.com/platform/external/tinyalsa_new/+/535e6ea3edcb6e119d465073facc3b2a338bdcb1 [LSC] Add LOCAL_LICENSE_KINDS to external/tinyalsa_new Added SPDX-license-identifier-BSD SPDX-license-identifier-Unlicense to: Android.bp Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: I21fe326f57f35b252901cf1423c4af149694fb51
2021-02-01Merge pull request #198 from dvdli/tinyalsa-devdvdli
fix bugs
2021-01-29upgrade Travis CI dist to bionicdvdli
2021-01-28fix test case to match the APIdvdli
2021-01-28Let pcm_mmap_read/write call pcm_readi/writeidvdli
The pcm_readi and pcm_writei also can deal with the mmap read/write. Also mark the pcm_mmap_read/write functions as deprecated functions and update the test case. Add mmap playback support to tinyplay
2021-01-28prepare in pcm_generic_transferdvdli
2021-01-20Merge pull request #200 from dvdli/tinyalsa-aospdvdli
add LICENSE file and rename modules in Android.bp
2021-01-20add LICENSE file and rename modules in Android.bpdvdli
2021-01-12fix integer character ascii rangedvdli
2021-01-12remove pcm_prepare in pcm_opendvdli
For the dynamic pcm device, it is valid to specify the backend after opening it. However, it is invalid to call prepare on a dynamic pcm device without connecting any backend device. We should not do pcm_prepare in pcm_open. See also: Issue #197
2020-12-09fix mmap-related functions' bugsdvdli
1. sync hw ptr before calculating the avail 2. return zero when reading or writing successfully
2020-12-09fix bugs in the pcm_open_* functionsdvdli
1. Align the document and the code. 2. Copy error messages to bad_pcm object for client to get more info when opening failed.
2020-12-09Merge pull request #194 from dvdli/tinymix-devdvdli
Fix tinymix bugs and support setting negative values
2020-12-09correct index of integer string and reduce the life time of variablesdvdli
2020-12-07add usage of VALUESdvdli
2020-12-07add support setting negative values to tinymixdvdli
2020-12-07formatting and remove tinymix prefix of static functionsdvdli
2020-12-07duplicate an argv list to avoid the argv order changeddvdli
2020-12-04fix printing format and wrong control for data printingdvdli
tinymix_detail_control took controls' name as its parameter to identify which control is that we want to print data of. However, if there are some controls with same name, we will always print the data of the first one.
2020-12-04Merge pull request #192 from dvdli/android-aosp-syncdvdli
fix build breakage in Android
2020-12-04Merge pull request #191 from dvdli/tinyalsa-testsdvdli
Tests for libtinyalsa
2020-12-02fix build breakageDavid Li
1. Add a missing field and a function 2. Disable the deprecated attribute in Android temporarily to allow us to use "pcm_read/write" which are deprecated upstream 3. Remove an unused define and an include in mixer.h 4. Add mixer_ctl_event and copy the snd_ctl_event to mixer_ctl_event 5. Add pcm_ioctl function and mark as deprecated function
2020-12-02fix typo, add comments to describe the tests and fix the loopback testdvdli
2020-12-01add instructions to run tests and fix typodvdli
2020-11-26add unit testsdvdli
1. add mixer event test 2. add pcm capturing test 3. add pcm loopback test
2020-11-23add unit tests for mixer related functionsdvdli
2020-11-16add unit tests for pcm_* functionsdvdli
2020-11-04Merge pull request #189 from wksuper/masterdvdli
Backward compatible for pcm_write() pcm_read()
2020-11-04Merge pull request #190 from dvdli/tinyplay-devdvdli
Fix tinyplay bugs
2020-11-02calcuate the thresholds after options parsingdvdli
The period size and count may be changed after options parsing. We need to set proper threshoulds.
2020-11-02modify the buffer size to the period size to avoid underrundvdli
2020-11-02Merge pull request #188 from dvdli/android-devdvdli
Synchronize the changes on AOSP repo
2020-11-01Backward compatible for pcm_write() pcm_read()Kui Wang
Current return value of pcm_write()/pcm_read() comes from pcm_writei()/pcm_readi() which is the actual frames written/read. But the old pcm_write() /pcm_read() just returns 0 on success and a nagative value on error. This change will keep the pcm_write()/pcm_read() as the old behavior which has been already used by many applications, and is also matching the comment above each function. Signed-off-by: Kui Wang <wangkuisuper@hotmail.com>
2020-10-29AOSP CL "tinymix: fix setting enum str started with digits"dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/f2d93a540297e75815eeb6644bf675cdae3be909 commit f2d93a540297e75815eeb6644bf675cdae3be909 author HW Lee <hwlee@google.com> tinymix: fix setting enum str started with digits For those value strings which are started with digits, they must be set as enum instead of index value. Test: with mixer control values started with digits like '48KHz' Change-Id: I1c70f5613a48d020d3248b71c1e4384f83e33d25 Signed-off-by: HW Lee <hwlee@google.com>
2020-10-29check whether the audio data are still enough to playdvdli
reference: https://android.googlesource.com/platform/external/tinyalsa/+/8b7274b2ec686c87673bf39328381acbdea1a333 commit 8b7274b2ec686c87673bf39328381acbdea1a333 author Haynes Mathew George <hgeorge@codeaurora.org> tinyplay: play PCM up to size specified in the header tinyplay plays to the end of file without checking whether playback goes beyond end of data section which its size is specified in the RIFF wave header. This could lead to playing out unwanted data which is placed at the end of file. authored-by: Patrick Lai <plai@codeaurora.org> Change-Id: I17bd3f6ebca4813f8987585472208c1f52696cae
2020-10-29AOSP CL "tinyalsa: check for NULL mmap_status"dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/62644f7a3c4cfa18d7935f731cf59b675669d17a commit 62644f7a3c4cfa18d7935f731cf59b675669d17a author Phil Burk <philburk@google.com> tinyalsa: check for NULL mmap_status pcm_mmap_get_hw_ptr() was not checking pcm->mmap_status and crashed when it was NULL. Bug: 64346189 Test: input_monitor.cpp, see bug report for repro steps Change-Id: I8436686a231eb01a82dd28ca2cce561d5460bcd6
2020-10-29AOSP CL "pcm: Fix usage of oops() function for use of strerror."dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/50028cd233f8cf8a084e950c951eefc01e1cd15c commit 50028cd233f8cf8a084e950c951eefc01e1cd15c author John Muir <muirj@google.com> pcm: Fix usage of oops() function for use of strerror. The oops() function expected errno to be passed in, but at some point it was broken to look at errno itself, and ignore the passed-in value. Fix the oops() function to check the passed-in value, and modify uses of oops() to actually pass in errno and not -errno or the return value from the errored function call. Bug: None Test: pcm error code printed correctly. Change-Id: I555e1eda0cdd0cc9b94e05423d341f1c08f8e485 (cherry picked from commit 2c1d902ace5f78dcff0c39740642d269b2e17dff) Note: the oops in pcm_mmap_transfer was removed.
2020-10-29AOSP CL "tinyalsa: fix typos in tinyplay and asoundlib.h"dvdli
commit f451f433520fc154de6e371747f21d2f746da83b author Glenn Kasten <gkasten@google.com> tinyalsa: fix typos in tinyplay and asoundlib.h Test: run tinyplay and look for typos in the output Change-Id: Ieedcc1b7610700aa3d5ff913d5c01105db2c1601
2020-10-28AOSP CL "pcm: add API for MMAP NO IRQ mode"dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/5b15b4cbd9e779a4ecd87e0f757fb0f8f6b9bcb8 commit 5b15b4cbd9e779a4ecd87e0f757fb0f8f6b9bcb8 author Eric Laurent <elaurent@google.com> pcm: add API for MMAP NO IRQ mode Bug: 33398120 Test: build Change-Id: Iecb47f76337d98ceb01044ca488a04e1f350c6bc
2020-10-28AOSP CL "Add pcm_get_poll_fd"dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/b42510d55bafc96805a44bd6ac40faac28ebd219 commit b42510d55bafc96805a44bd6ac40faac28ebd219 author Dylan Reid <dgreid@chromium.org> Add pcm_get_poll_fd Similar to ALSA snd_pcm_get_poll_fd, this will allow a user to wait for a sound device to have data in a poll(2) call. The hotword thread will use this to wait for a message on its socket or for audio data to become ready. Change-Id: I61375a73d7a842b00362fc707c12f99aa18e0bdf Signed-off-by: Dylan Reid <dgreid@chromium.org>
2020-10-28AOSP CL "Export pcm_mmap_avail"dvdli
https://android.googlesource.com/platform/external/tinyalsa/+/9074cfc4127cb841f0633b35895141f90da3f0d6 commit 9074cfc4127cb841f0633b35895141f90da3f0d6 author Dylan Reid <dgreid@chromium.org> Export pcm_mmap_avail This is useful for timer based wakeups and for checking how much data has been captured by a hotwording device. Change-Id: I409201a5c9ce73abc807a9dd767beb3a32810f06 Signed-off-by: Dylan Reid <dgreid@chromium.org>
2020-10-28initialize silence_size to zerodvdli