lil code formatting
This commit is contained in:
@@ -20,8 +20,8 @@ void Application::hassThread(const std::stop_token& st) {
|
||||
applog(LOG::START, "Thread started");
|
||||
HomeAssistant::Config config;
|
||||
config.address = m_config.hass.url;
|
||||
config.entity = m_config.hass.entity;
|
||||
config.token = m_config.hass.token;
|
||||
config.entity = m_config.hass.entity;
|
||||
config.token = m_config.hass.token;
|
||||
HomeAssistant pc_power(config);
|
||||
|
||||
pc_power.connect();
|
||||
@@ -87,7 +87,7 @@ void Application::displayThread(const std::stop_token& st) {
|
||||
// actual main display loop
|
||||
while (!st.stop_requested()) {
|
||||
m_control.display.try_acquire_for(std::chrono::milliseconds(static_cast<int>(m_config.lcd.refresh_interval_ms * 1.25))); // holds the loop until sensor data is ready, max 1.25x of the loop time
|
||||
if (st.stop_requested()) break; // needed, otherwise it wont quit correctly
|
||||
if (st.stop_requested()) break; // needed, otherwise it wont quit correctly
|
||||
{
|
||||
std::lock_guard lock(m_control.sensors);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user