Class daisy::DaisyPod¶
Class that handles initializing all of the hardware specific to the Daisy Patch Board. Helper funtions are also in place to provide easy access to built-in controls and peripherals.More...
#include <daisy_pod.h>
Public Types¶
Type | Name |
---|---|
enum | Knob |
enum | Sw |
Public Attributes¶
Type | Name |
---|---|
Switch | button1 |
Switch | button2 |
Switch * | buttons |
Encoder | encoder |
AnalogControl | knob1 |
AnalogControl | knob2 |
AnalogControl * | knobs |
RgbLed | led1 |
RgbLed | led2 |
MidiUartHandler | midi |
DaisySeed | seed |
Public Functions¶
Type | Name |
---|---|
size_t | AudioBlockSize () |
float | AudioCallbackRate () |
float | AudioSampleRate () |
void | ChangeAudioCallback (AudioHandle::InterleavingAudioCallback cb) |
void | ChangeAudioCallback (AudioHandle::AudioCallback cb) |
void | ClearLeds () |
DaisyPod () |
|
void | DelayMs (size_t del) |
float | GetKnobValue (Knob k) |
void | Init (bool boost=false) |
void | ProcessAllControls () |
void | ProcessAnalogControls () |
void | ProcessDigitalControls () |
void | SetAudioBlockSize (size_t blocksize) |
void | SetAudioSampleRate (SaiHandle::Config::SampleRate samplerate) |
void | StartAdc () |
void | StartAudio (AudioHandle::InterleavingAudioCallback cb) |
void | StartAudio (AudioHandle::AudioCallback cb) |
void | StopAdc () |
void | StopAudio () |
void | UpdateLeds () |
~DaisyPod () |
Detailed Description¶
Author:
Stephen Hensley
Date:
November 2019
Public Types Documentation¶
enum Knob¶
Knobs
enum Sw¶
Switches
Public Attributes Documentation¶
variable button1¶
&
variable button2¶
&
variable buttons¶
&
variable encoder¶
&
variable knob1¶
&
variable knob2¶
&
variable knobs¶
&
variable led1¶
&
variable led2¶
&
variable midi¶
variable seed¶
Public Members
autotoc_md0¶
Public Functions Documentation¶
function AudioBlockSize¶
Returns the number of samples per channel in a block of audio.
function AudioCallbackRate¶
Returns the rate in Hz that the Audio callback is called
function AudioSampleRate¶
Returns the audio sample rate in Hz as a floating point number.
function ChangeAudioCallback [½]¶
Switch callback functions
Parameters:
cb
New interleaved callback function.
function ChangeAudioCallback [2/2]¶
Switch callback functions
Parameters:
cb
New multichannel callback function.
function ClearLeds¶
Reset Leds
function DaisyPod¶
function DelayMs¶
Wait for a bit
Parameters:
del
Time to wait in ms.
function GetKnobValue¶
&
function Init¶
Init related stuff.
function ProcessAllControls¶
Process Analog and Digital Controls
function ProcessAnalogControls¶
Call at same rate as analog reads for smooth reading.
function ProcessDigitalControls¶
Process digital controls
function SetAudioBlockSize¶
Sets the number of samples processed per channel by the audio callback.
function SetAudioSampleRate¶
Updates the Audio Sample Rate, and reinitializes. Audio must be stopped for this to work.
function StartAdc¶
Start analog to digital conversion.
function StartAudio [½]¶
Starts the callback
Parameters:
cb
Interleaved callback function
function StartAudio [2/2]¶
Starts the callback
Parameters:
cb
multichannel callback function
function StopAdc¶
Stops Transfering data from the ADC
function StopAudio¶
Stops the audio if it is running.
function UpdateLeds¶
Update Leds to set colors
function ~DaisyPod¶
The documentation for this class was generated from the following file external-docs/libDaisy/src/daisy_pod.h