test public
Dependencies: HttpServer_snapshot_mbed-os
NullSpeaker Class Reference
NullSpeaker class. More...
#include <NullSpeaker.h>
Inherits AUDIO_RBSP.
Public Member Functions | |
NullSpeaker () | |
Create a NullSpeaker. | |
virtual void | power (bool type=true) |
Overloaded power() | |
virtual bool | format (char length) |
Set I2S interface bit length and mode. | |
virtual bool | frequency (int hz) |
Set sample frequency. | |
virtual int | write (void *const p_data, uint32_t data_size, const rbsp_data_conf_t *const p_data_conf=NULL) |
Enqueue asynchronous write request. | |
virtual int | read (void *const p_data, uint32_t data_size, const rbsp_data_conf_t *const p_data_conf=NULL) |
Enqueue asynchronous read request. | |
virtual bool | outputVolume (float leftVolumeOut, float rightVolumeOut) |
Headphone out volume control. | |
virtual bool | micVolume (float VolumeIn) |
Microphone volume. |
Detailed Description
NullSpeaker class.
Definition at line 26 of file NullSpeaker.h.
Constructor & Destructor Documentation
NullSpeaker | ( | ) |
Create a NullSpeaker.
Definition at line 31 of file NullSpeaker.h.
Member Function Documentation
virtual bool format | ( | char | length ) | [virtual] |
Set I2S interface bit length and mode.
- Parameters:
-
length Set bit length to 16 bits
- Returns:
- true = success, false = failure
Implements AUDIO_RBSP.
Definition at line 37 of file NullSpeaker.h.
virtual bool frequency | ( | int | hz ) | [virtual] |
Set sample frequency.
- Parameters:
-
frequency Sample frequency of data in Hz
- Returns:
- true = success, false = failure
supports frequencies: 44.1kHz Default is 44.1kHz
Implements AUDIO_RBSP.
Definition at line 41 of file NullSpeaker.h.
virtual bool micVolume | ( | float | VolumeIn ) | [virtual] |
Microphone volume.
- Parameters:
-
VolumeIn Microphone volume
- Returns:
- Returns "true" for success, "false" if parameters are out of range
Implements AUDIO_RBSP.
Definition at line 63 of file NullSpeaker.h.
virtual bool outputVolume | ( | float | leftVolumeOut, |
float | rightVolumeOut | ||
) | [virtual] |
Headphone out volume control.
- Parameters:
-
leftVolumeOut Left headphone-out volume rightVolumeOut Right headphone-out volume
- Returns:
- Returns "true" for success, "false" if parameters are out of range
Implements AUDIO_RBSP.
Definition at line 59 of file NullSpeaker.h.
virtual void power | ( | bool | type = true ) |
[virtual] |
Overloaded power()
- Parameters:
-
type true=power up, false=power down
Implements AUDIO_RBSP.
Definition at line 35 of file NullSpeaker.h.
virtual int read | ( | void *const | p_data, |
uint32_t | data_size, | ||
const rbsp_data_conf_t *const | p_data_conf = NULL |
||
) | [virtual] |
Enqueue asynchronous read request.
- Parameters:
-
p_data Location of the data data_size Number of bytes to read p_data_conf Asynchronous control block structure
- Returns:
- Number of bytes read on success. negative number on error.
Implements AUDIO_RBSP.
Definition at line 55 of file NullSpeaker.h.
virtual int write | ( | void *const | p_data, |
uint32_t | data_size, | ||
const rbsp_data_conf_t *const | p_data_conf = NULL |
||
) | [virtual] |
Enqueue asynchronous write request.
- Parameters:
-
p_data Location of the data data_size Number of bytes to write p_data_conf Asynchronous control block structure
- Returns:
- Number of bytes written on success. negative number on error.
Implements AUDIO_RBSP.
Definition at line 45 of file NullSpeaker.h.
Generated on Wed Jul 13 2022 05:33:38 by 1.7.2