Skip to content

Commit

Permalink
AP_RangeFinder: mark _add_backend, init and detetct_instance as __INI…
Browse files Browse the repository at this point in the history
…TFUNC__
  • Loading branch information
peterbarker authored and tpwrules committed Mar 6, 2025
1 parent e68be1c commit 75be839
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libraries/AP_RangeFinder/AP_RangeFinder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ void RangeFinder::convert_params(void)
finders here. For now we won't allow for hot-plugging of
rangefinders.
*/
void RangeFinder::init(enum Rotation orientation_default)
__INITFUNC__ void RangeFinder::init(enum Rotation orientation_default)
{
convert_params();

Expand Down Expand Up @@ -260,7 +260,7 @@ void RangeFinder::update(void)
#endif
}

bool RangeFinder::_add_backend(AP_RangeFinder_Backend *backend, uint8_t instance, uint8_t serial_instance)
__INITFUNC__ bool RangeFinder::_add_backend(AP_RangeFinder_Backend *backend, uint8_t instance, uint8_t serial_instance)
{
if (!backend) {
return false;
Expand All @@ -282,7 +282,7 @@ bool RangeFinder::_add_backend(AP_RangeFinder_Backend *backend, uint8_t instance
/*
detect if an instance of a rangefinder is connected.
*/
void RangeFinder::detect_instance(uint8_t instance, uint8_t& serial_instance)
__INITFUNC__ void RangeFinder::detect_instance(uint8_t instance, uint8_t& serial_instance)
{
AP_RangeFinder_Backend_Serial *(*serial_create_fn)(RangeFinder::RangeFinder_State&, AP_RangeFinder_Params&) = nullptr;

Expand Down

0 comments on commit 75be839

Please sign in to comment.