Skip to content

Commit

Permalink
Test
Browse files Browse the repository at this point in the history
  • Loading branch information
AzonInc committed Feb 4, 2025
1 parent 25ca7d3 commit bd3e360
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions components/tc_bus/tc_bus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ namespace esphome
listener->turn_off(&listener->timer_);
}
#endif

#ifdef USE_API
register_service(&TCBusComponent::save_settings, "save_settings");
#endif
}

void TCBusComponent::save_settings()
Expand Down
4 changes: 4 additions & 0 deletions components/tc_bus/tc_bus.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,11 @@ namespace esphome
uint32_t serial_number;
};

#ifdef USE_API
class TCBusComponent : public Component, public remote_base::RemoteReceiverListener, public esphome::api::CustomAPIDevice
#else
class TCBusComponent : public Component, public remote_base::RemoteReceiverListener
#endif
{
#ifdef USE_TEXT_SENSOR
SUB_TEXT_SENSOR(bus_command)
Expand Down

0 comments on commit bd3e360

Please sign in to comment.