Commit Graph

36 Commits

Author SHA1 Message Date
Taku Fukada 56c898da80 Modify some Python stubs 2020-08-07 01:01:28 +09:00
Taku Fukada d356581651 Fix several type hints 2020-07-27 18:05:13 +09:00
dherrada d0d949cd24 Made every init return None 2020-07-03 14:23:34 -04:00
dherrada 522b17ca93 Made suggested changes 2020-07-02 13:25:07 -04:00
dherrada 3d1e0051e6 Added type hints to audioio 2020-07-02 12:02:07 -04:00
Jeff Epler 90571e7b7f Various doc examples: Fix the "/ 18" copypasta bug 2020-05-27 16:43:35 -05:00
Scott Shawcroft 4e8de3c554
Swap sphinx to autoapi and the inline stubs 2020-05-12 17:28:24 -07:00
dherrada d65e851044
Did audioio, audiomixer, audiomp3 2020-04-30 13:06:09 -04:00
dherrada c7b721f4f1
Fixed some more whitespace 2020-04-28 19:22:03 -04:00
dherrada 1363e6e724
Added inline pyi to audiocore 2020-04-27 17:02:48 -04:00
Dan Halbert 817b5be320 rename routines to be clearer; fix wiznet arg types 2020-03-05 16:35:31 -05:00
Dan Halbert b6206406de new pin validation routines; don't use mp_const_none if NULL will do 2020-02-28 23:43:04 -05:00
sommersoft 750ffcc81a docs: correct audiomixer refs 2019-08-25 14:57:29 -05:00
Jeff Epler 91b7ba7dcc docs: An `audiocore.Mixer` suffices where another audio source would 2019-07-26 07:57:21 -05:00
Jeff Epler a53720810b docs: corrections that stem from the "audiocore" rename 2019-07-26 07:57:21 -05:00
Jeff Epler 6b44e40ee8 audiocore: Factor from audioio
When nrf pwm audio is introduced, it will be called `audiopwmio`.  To
enable code sharing with the existing (dac-based) `audioio`, factor
the sample and mixer types to `audiocore`.

INCOMPATIBLE CHANGE: Now, `Mixer`, `RawSample` and `WaveFile` must
be imported from `audiocore`, not `audioio`.
2019-07-25 06:44:26 -05:00
Scott Shawcroft a35d9b469d
Refactor deinit check to reduce code size. 2019-06-12 11:36:43 -07:00
Scott Shawcroft 747f2cfe26
Add subclass support to displayio.
Also, swap make_news to accept a kwarg map and refine param checking.

Fixes #1237
2019-01-14 17:29:19 -08:00
Dan Halbert 72e3cfdfb8 Fix arg type for AudioOut(..., quiescent_value=...) 2018-12-03 11:20:33 -05:00
Scott Shawcroft 4eb1fe18e5
Tweaks from feedback:
* default_value is now quiescent_value
* Use step = -step format for sign switch
* Add note about analogout_reset being empty
2018-10-17 11:31:08 -07:00
Scott Shawcroft c209165d43
Ramp values to and from a default value while active.
This reduces the popping sound on initial playback of an audio
sample.

The M4 DAC has a pop on startup that cannot be prevented. It also
does not allow readback so current values of the DAC are ignored.

Fixes #1090
2018-10-16 16:23:29 -07:00
Scott Shawcroft 933add6cd8
Support internationalisation. 2018-08-07 14:58:57 -07:00
Kattni Rembor a10c61ef89 Fixed issue with code in docs for audioio
Removed incorrect arg from RawSample in AudioOut example code.
Replaced variable sample with dac.
2018-06-29 16:46:25 -04:00
jerryneedell 1d9bcc5ddf
fix doc error in audioOut.c
fixes #851
2018-05-19 10:41:36 -04:00
Scott Shawcroft fc7c25af6d Make resume idempotent (allowing you to call it twice without complaining.) 2018-05-08 13:00:05 -07:00
Scott Shawcroft 24116eff23 Tweak exception message. 2018-05-08 12:44:27 -07:00
Scott Shawcroft 50fc90bc5f Add pause/resume control to AudioOut and I2SOut
Fixes #808
2018-05-08 11:53:13 -07:00
Scott Shawcroft 28642ab10d Add audio output support!
This evolves the API from 2.x (and breaks it). Playback devices are now
separate from the samples themselves. This allows for greater playback
flexibility. Two sample sources are audioio.RawSample and audioio.WaveFile.
They can both be mono or stereo. They can be output to audioio.AudioOut or
audiobusio.I2SOut.

Internally, the dma tracking has changed from a TC counting block transfers
to an interrupt generated by the block event sent to the EVSYS. This reduces
the overhead of each DMA transfer so multiple can occure without using up TCs.

Fixes #652. Fixes #522. Huge progress on #263
2018-04-12 16:35:13 -07:00
Kattni 446a31302c
Merge pull request #600 from tannewt/clarify_property_comments
Clarify style of attribute comments in the Design Guide.
2018-02-14 22:03:37 -05:00
Scott Shawcroft 15db02664d Clarify style of attribute comments in the Design Guide.
And update the core attributes to match the style.
2018-02-07 13:08:42 -08:00
arturo182 ff041caa52 shared-bindings: Fix incorrect code comments
Most likely caused by copy-paste.
2018-02-06 22:03:17 +01:00
Dan Halbert c478c10923 Do not allow a *io object to be used after deinit().
Fixes #278, #277, #276, #275.
2017-10-03 12:07:17 -07:00
Scott Shawcroft f878bc4efc atmel-samd: Fix AudioOut buffer playback by supporting bytes_per_sample.
Thanks to @ntoll for finding this bug!
2017-07-12 11:55:49 -07:00
Scott Shawcroft 714521a4c7 shared-bindings: Update docs to remove with statements from examples but add more detail to the design guide about their use. 2017-06-07 14:39:12 -07:00
Scott Shawcroft 3f5028c666 atmel-samd: Support wav file playback. Tested up to 16bit 22.1khz. Must be mono file!
SD card support may work but likely needs buffer tuning. Its untested.

Fixes #105
2017-05-15 19:52:38 -07:00
Scott Shawcroft 58b9789d0c atmel-samd: Introduce audio sample playback via audioio.AudioOut. 2017-05-01 13:10:03 -07:00