send warning message if no tags

This commit is contained in:
ackimixs
2024-03-21 18:35:43 +01:00
parent 96465f967d
commit 399abbc51e

View File

@@ -18,9 +18,14 @@ void MyClient::handleMessage(const std::string& message)
{
std::string res;
for (auto& [tag, pos] : arucoTags)
if (arucoTags.empty())
{
res += std::to_string(tag.id) + " ";
res = "No Aruco Tags Found";
} else {
for (auto& [tag, pos] : arucoTags)
{
res += std::to_string(tag.id) + " ";
}
}
this->sendMessage(res.c_str());