Files
tftest/include/audio_test.h
DESKTOP-PUHFO60\dsx2016 b44bd7d3f0 Snapshot Beep + WAV UI before Pomodoro rewrite.
Keep LEDC tones, TF WAV playback, and compact list layout as a tagged baseline.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-10-18 18:51:05 +08:00

30 lines
624 B
C
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#pragma once
#include <Arduino.h>
#include <stdint.h>
void audio_init();
void audio_set_enabled(bool on);
bool audio_is_enabled();
void audio_set_volume(uint8_t percent);
uint8_t audio_get_volume();
// 内置提示音
uint8_t sound_count();
const char *sound_name(uint8_t idx);
int8_t sound_selected();
void sound_set_selected(int8_t idx);
void audio_play_sound(uint8_t idx);
// WAV(TF)
void audio_play_wav_index(uint8_t idx);
void audio_play_selected(); // 按当前 tab 语义由 UI 决定;保留播 beep 选中
void audio_stop();
bool audio_is_playing();
void audio_tick();
const char *audio_last_status();