Browse Source

AP_IRLock: Replace find_object with SITL singleton

master
Pierre Kancir 7 years ago committed by Tom Pittenger
parent
commit
0ee6e41f6e
  1. 2
      libraries/AP_IRLock/AP_IRLock_SITL.cpp

2
libraries/AP_IRLock/AP_IRLock_SITL.cpp

@ -38,7 +38,7 @@ AP_IRLock_SITL::AP_IRLock_SITL() : @@ -38,7 +38,7 @@ AP_IRLock_SITL::AP_IRLock_SITL() :
void AP_IRLock_SITL::init(int8_t bus)
{
SITL::SITL *sitl = (SITL::SITL *)AP_Param::find_object("SIM_");
SITL::SITL *sitl = AP::sitl();
// try to bind to a specific port so that if we restart ArduPilot
// Gazebo keeps sending us packets. Not strictly necessary but
// useful for debugging

Loading…
Cancel
Save