Wrap VA code (#4800)

This commit is contained in:
Jesse Hills 2023-05-10 16:46:32 +12:00 committed by GitHub
parent 39a650ee54
commit 5099595aee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 0 deletions

View file

@ -1,5 +1,7 @@
#include "voice_assistant.h"
#ifdef USE_VOICE_ASSISTANT
#include "esphome/core/log.h"
#include <cstdio>
@ -192,3 +194,5 @@ VoiceAssistant *global_voice_assistant = nullptr; // NOLINT(cppcoreguidelines-a
} // namespace voice_assistant
} // namespace esphome
#endif // USE_VOICE_ASSISTANT

View file

@ -1,5 +1,9 @@
#pragma once
#include "esphome/core/defines.h"
#ifdef USE_VOICE_ASSISTANT
#include "esphome/core/automation.h"
#include "esphome/core/component.h"
#include "esphome/core/defines.h"
@ -86,3 +90,5 @@ extern VoiceAssistant *global_voice_assistant; // NOLINT(cppcoreguidelines-avoi
} // namespace voice_assistant
} // namespace esphome
#endif // USE_VOICE_ASSISTANT