Don't print Running standalone message when local server connection succeeds

This commit is contained in:
Adam Honse 2021-05-23 23:22:46 -05:00
parent 707df85d1f
commit cb656ebdf7
3 changed files with 11 additions and 1 deletions

View file

@ -425,6 +425,11 @@ SettingsManager* ResourceManager::GetSettingsManager()
return(settings_manager);
}
bool ResourceManager::GetDetectionEnabled()
{
return(detection_enabled);
}
unsigned int ResourceManager::GetDetectionPercent()
{
return (detection_percent.load());

View file

@ -118,6 +118,7 @@ public:
void RegisterDetectionEndCallback(DetectionEndCallback new_callback, void * new_callback_arg);
void RegisterI2CBusListChangeCallback(I2CBusListChangeCallback new_callback, void * new_callback_arg);
bool GetDetectionEnabled();
unsigned int GetDetectionPercent();
const char* GetDetectionString();

View file

@ -241,7 +241,11 @@ int main(int argc, char* argv[])
\*---------------------------------------------------------*/
if(!(ret_flags & RET_FLAG_NO_DETECT))
{
printf("Running standalone.\r\n");
if(ResourceManager::get()->GetDetectionEnabled())
{
printf("Running standalone.\r\n");
}
ResourceManager::get()->DetectDevices();
}