|
76 | 76 | <div class="line"><a name="l00005"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a2513e2bd0eb45a0ccefbbcd3f289ca47"> 5</a></span> <span class="preprocessor"># define DRIVER_DEFAULT_VOLUME 70</span></div>
|
77 | 77 | <div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="preprocessor">#endif</span></div>
|
78 | 78 | <div class="line"><a name="l00007"></a><span class="lineno"> 7</span>  </div>
|
79 |
| -<div class="line"><a name="l00008"></a><span class="lineno"> 8</span>  </div> |
80 |
| -<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment">// To increase the max volume e.g. for ai_thinker (ES8388) 2957 or A202 -> set</span></div> |
81 |
| -<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment">// to 1 or 2 0 AUX volume is LINE level 1 you can control the AUX volume with</span></div> |
82 |
| -<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment">// setVolume()</span></div> |
83 |
| -<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="preprocessor">#ifndef AI_THINKER_ES8388_VOLUME_HACK</span></div> |
84 |
| -<div class="line"><a name="l00013"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a97f42a9050aeb02705fa0bc7ad10aaef"> 13</a></span> <span class="preprocessor"># define AI_THINKER_ES8388_VOLUME_HACK 1</span></div> |
85 |
| -<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="preprocessor">#endif</span></div> |
| 79 | +<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment">// AudioBoard getVolume() can report the volume reported by the driver or the volume that was last</span></div> |
| 80 | +<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment">// set. When using the driver volume, there might be small rounding errors compared to</span></div> |
| 81 | +<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment">// the last defined value.</span></div> |
| 82 | +<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#ifndef DRIVER_REPORT_DRIVER_VOLUME</span></div> |
| 83 | +<div class="line"><a name="l00012"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a9d56c6ea19f3b09ed4850731fd1e6726"> 12</a></span> <span class="preprocessor"># define DRIVER_REPORT_DRIVER_VOLUME false</span></div> |
| 84 | +<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#endif</span></div> |
| 85 | +<div class="line"><a name="l00014"></a><span class="lineno"> 14</span>  </div> |
86 | 86 | <div class="line"><a name="l00015"></a><span class="lineno"> 15</span>  </div>
|
87 |
| -<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment">// Define the default gain for the microphone amp (see values from</span></div> |
88 |
| -<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">// es_mic_gain_t) Alternativly you can call es8388_set_mic_gain(es_mic_gain_t</span></div> |
89 |
| -<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment">// gain) if you prefer to use value from an comprehensive enum</span></div> |
90 |
| -<div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="preprocessor">#ifndef ES8388_DEFAULT_INPUT_GAIN</span></div> |
91 |
| -<div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a14378984cebc3425ec1941bb1e0217ef"> 20</a></span> <span class="preprocessor"># define ES8388_DEFAULT_INPUT_GAIN 25</span></div> |
| 87 | +<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment">// To increase the max volume e.g. for ai_thinker (ES8388) 2957 or A202 -> set</span></div> |
| 88 | +<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">// to 1 or 2 0 AUX volume is LINE level 1 you can control the AUX volume with</span></div> |
| 89 | +<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment">// setVolume()</span></div> |
| 90 | +<div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="preprocessor">#ifndef AI_THINKER_ES8388_VOLUME_HACK</span></div> |
| 91 | +<div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a97f42a9050aeb02705fa0bc7ad10aaef"> 20</a></span> <span class="preprocessor"># define AI_THINKER_ES8388_VOLUME_HACK 1</span></div> |
92 | 92 | <div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="preprocessor">#endif</span></div>
|
93 | 93 | <div class="line"><a name="l00022"></a><span class="lineno"> 22</span>  </div>
|
94 |
| -<div class="line"><a name="l00023"></a><span class="lineno"> 23</span>  </div> |
95 |
| -<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="comment">// For AI Thinker Audiokit we mute the power amplifier if the line is defined;</span></div> |
96 |
| -<div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="comment">// set to -1 to deactivate this functionality</span></div> |
97 |
| -<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#ifndef ES8388_PA_LINE </span></div> |
98 |
| -<div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a9407f00066bbd25c1bd46d20fa83ddb7"> 27</a></span> <span class="preprocessor"># define ES8388_PA_LINE 1</span></div> |
| 94 | +<div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="comment">// Define the default gain for the microphone amp (see values from</span></div> |
| 95 | +<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="comment">// es_mic_gain_t) Alternativly you can call es8388_set_mic_gain(es_mic_gain_t</span></div> |
| 96 | +<div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="comment">// gain) if you prefer to use value from an comprehensive enum</span></div> |
| 97 | +<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#ifndef ES8388_DEFAULT_INPUT_GAIN</span></div> |
| 98 | +<div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a14378984cebc3425ec1941bb1e0217ef"> 27</a></span> <span class="preprocessor"># define ES8388_DEFAULT_INPUT_GAIN 25</span></div> |
99 | 99 | <div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="preprocessor">#endif</span></div>
|
100 | 100 | <div class="line"><a name="l00029"></a><span class="lineno"> 29</span>  </div>
|
| 101 | +<div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="comment">// For AI Thinker Audiokit we mute the power amplifier if the line is defined;</span></div> |
| 102 | +<div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="comment">// set to -1 to deactivate this functionality</span></div> |
| 103 | +<div class="line"><a name="l00032"></a><span class="lineno"> 32</span> <span class="preprocessor">#ifndef ES8388_PA_LINE</span></div> |
| 104 | +<div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a9407f00066bbd25c1bd46d20fa83ddb7"> 33</a></span> <span class="preprocessor"># define ES8388_PA_LINE 1</span></div> |
| 105 | +<div class="line"><a name="l00034"></a><span class="lineno"> 34</span> <span class="preprocessor">#endif</span></div> |
| 106 | +<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  </div> |
| 107 | +<div class="line"><a name="l00036"></a><span class="lineno"> 36</span> <span class="comment">// If set to true, call Wire.close() on end: this might cause that the</span></div> |
| 108 | +<div class="line"><a name="l00037"></a><span class="lineno"> 37</span> <span class="comment">// functionality can not be restarted</span></div> |
| 109 | +<div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="preprocessor">#ifndef FORCE_WIRE_CLOSE</span></div> |
| 110 | +<div class="line"><a name="l00039"></a><span class="lineno"><a class="line" href="_audio_driver_config_8h.html#a9ea061072f5a0efeb0ad929f13a29e2e"> 39</a></span> <span class="preprocessor"># define FORCE_WIRE_CLOSE false</span></div> |
| 111 | +<div class="line"><a name="l00040"></a><span class="lineno"> 40</span> <span class="preprocessor">#endif</span></div> |
| 112 | +<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  </div> |
101 | 113 | </div><!-- fragment --></div><!-- contents -->
|
102 | 114 | <!-- start footer part -->
|
103 | 115 | <hr class="footer"/><address class="footer"><small>
|
|
0 commit comments