summaryrefslogtreecommitdiff
path: root/firmware/export/audiohw.h
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/export/audiohw.h')
-rw-r--r--firmware/export/audiohw.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/firmware/export/audiohw.h b/firmware/export/audiohw.h
index b3493b86d9..d450613aff 100644
--- a/firmware/export/audiohw.h
+++ b/firmware/export/audiohw.h
@@ -23,6 +23,10 @@
23#include "config.h" 23#include "config.h"
24#include <stdbool.h> 24#include <stdbool.h>
25 25
26/* define some audiohw caps */
27#define TREBLE_CAP (1 << 0)
28#define BASS_CAP (1 << 1)
29
26#ifdef HAVE_UDA1380 30#ifdef HAVE_UDA1380
27#include "uda1380.h" 31#include "uda1380.h"
28#elif defined(HAVE_WM8751) 32#elif defined(HAVE_WM8751)
@@ -49,6 +53,17 @@
49#include "tsc2100.h" 53#include "tsc2100.h"
50#endif 54#endif
51 55
56/* convert caps into defines */
57#ifdef AUDIOHW_CAPS
58#if (AUDIOHW_CAPS & TREBLE_CAP)
59#define AUDIOHW_HAVE_TREBLE
60#endif
61
62#if (AUDIOHW_CAPS & BASS_CAP)
63#define AUDIOHW_HAVE_BASS
64#endif
65#endif /* AUDIOHW_CAPS */
66
52enum { 67enum {
53 SOUND_VOLUME = 0, 68 SOUND_VOLUME = 0,
54 SOUND_BASS, 69 SOUND_BASS,
@@ -141,6 +156,26 @@ void audiohw_mute(bool mute);
141 */ 156 */
142void audiohw_enable_output(bool enable); 157void audiohw_enable_output(bool enable);
143 158
159#ifdef AUDIOHW_HAVE_TREBLE
160/**
161 * Set new treble value.
162 * @param val to set.
163 * NOTE: AUDIOHW_CAPS need to contain
164 * TREBLE_CAP
165 */
166void audiohw_set_treble(int val);
167#endif
168
169#ifdef AUDIOHW_HAVE_BASS
170/**
171 * Set new bass value.
172 * @param val to set.
173 * NOTE: AUDIOHW_CAPS need to contain
174 * BASS_CAP
175 */
176void audiohw_set_bass(int val);
177#endif
178
144#ifdef HAVE_RECORDING 179#ifdef HAVE_RECORDING
145 180
146/** 181/**