Browse Source

Rover: remove rcmap member from AP_AdvancedFailsafe

Also correct constructor for barometer

Also make it compile again
mission-4.1.18
Peter Barker 7 years ago committed by Randy Mackay
parent
commit
0b1091231c
  1. 2
      APMrover2/Parameters.cpp
  2. 4
      APMrover2/afs_rover.cpp
  3. 2
      APMrover2/afs_rover.h
  4. 2
      APMrover2/failsafe.cpp

2
APMrover2/Parameters.cpp

@ -562,7 +562,7 @@ const AP_Param::GroupInfo ParametersG2::var_info[] = { @@ -562,7 +562,7 @@ const AP_Param::GroupInfo ParametersG2::var_info[] = {
ParametersG2::ParametersG2(void)
:
#if ADVANCED_FAILSAFE == ENABLED
afs(rover.mission, rover.barometer, rover.gps, rover.rcmap),
afs(rover.mission, rover.gps),
#endif
beacon(rover.serial_manager),
motors(rover.ServoRelayEvents),

4
APMrover2/afs_rover.cpp

@ -7,8 +7,8 @@ @@ -7,8 +7,8 @@
#if ADVANCED_FAILSAFE == ENABLED
// Constructor
AP_AdvancedFailsafe_Rover::AP_AdvancedFailsafe_Rover(AP_Mission &_mission, const AP_GPS &_gps, const RCMapper &_rcmap) :
AP_AdvancedFailsafe(_mission, _gps, _rcmap)
AP_AdvancedFailsafe_Rover::AP_AdvancedFailsafe_Rover(AP_Mission &_mission, const AP_GPS &_gps) :
AP_AdvancedFailsafe(_mission, _gps)
{}

2
APMrover2/afs_rover.h

@ -27,7 +27,7 @@ @@ -27,7 +27,7 @@
class AP_AdvancedFailsafe_Rover : public AP_AdvancedFailsafe
{
public:
AP_AdvancedFailsafe_Rover(AP_Mission &_mission, const AP_GPS &_gps, const RCMapper &_rcmap);
AP_AdvancedFailsafe_Rover(AP_Mission &_mission, const AP_GPS &_gps);
// called to set all outputs to termination state
void terminate_vehicle(void) override;

2
APMrover2/failsafe.cpp

@ -123,7 +123,7 @@ void Rover::handle_battery_failsafe(const char* type_str, const int8_t action) @@ -123,7 +123,7 @@ void Rover::handle_battery_failsafe(const char* type_str, const int8_t action)
#if ADVANCED_FAILSAFE == ENABLED
char battery_type_str[17];
snprintf(battery_type_str, 17, "%s battery", type_str);
afs.gcs_terminate(true, battery_type_str);
g2.afs.gcs_terminate(true, battery_type_str);
#else
disarm_motors();
#endif // ADVANCED_FAILSAFE == ENABLED

Loading…
Cancel
Save