Bug Report
Bug report
Issue details
The RC failsafe simulation behavior is not working for any values of SIM_RC_FAIL set while the SITL is running. While the SIM_RC_FAIL parameter does retain the asserted value between runs of the SITL, the simulated flight controller does not issue any message pertaining to RC failsafes regardless of the value. However, the RC Failsafe behavior does exist when RC_PROTOCOLS is set to zero between runs of the SITL, but as soon as this is set to 1, the virtual flight controller clears the failsafe, and the RC controls are available to the virtual flight controller even when this is set back to zero. Hence, there is no work-around by setting and clearing RC_PROTOCOLS.
Starting at 964c30e , the SITL RC data source was is switched from AP_RCProtocol_UDP to AP_RCProtocol_FDM if that source is available. A quick comparison between the libraries shows that while the _UDP library is sensitive to the SIM_RC_FAIL parameter, the _FDM does not handle this.
Steps to reproduce:
- Start a RealFlight SITL session (flightaxis), download either stable (4.6.3) or latest/dev (4.8.0) for the SITL binary.
- In Mission Planner, find SIM_RC_FAIL and set to any value (1, 2, or 3)
- Observe no indication that the aircraft is in RC failsafe.
- Manually populate the Documents\Mission Planner\sitl folder with a ArduPlane.exe SITL binary of 4.6.0 or earlier. Repeat the above steps. The RC Failsafe behavior should manifest.
Version
4.6.3 and 4.80 both tested and fail. 4.6.0 has correct behavior.
Platform
[?] All
[ ] AntennaTracker
[ ] Copter
[X] Plane
[ ] Rover
[ ] Submarine
Airframe type
Simulated Fixed-Wing Quadplane
Hardware type
SITL: Various versions launched from Mission Planner 1.3.82 on Windows 10
RealFlight 9.5S on Windows 10, same PC as Mission Planner and SITL instance
Logs
No meaningful logs
Bug Report
Bug report
Issue details
The RC failsafe simulation behavior is not working for any values of SIM_RC_FAIL set while the SITL is running. While the SIM_RC_FAIL parameter does retain the asserted value between runs of the SITL, the simulated flight controller does not issue any message pertaining to RC failsafes regardless of the value. However, the RC Failsafe behavior does exist when RC_PROTOCOLS is set to zero between runs of the SITL, but as soon as this is set to 1, the virtual flight controller clears the failsafe, and the RC controls are available to the virtual flight controller even when this is set back to zero. Hence, there is no work-around by setting and clearing RC_PROTOCOLS.
Starting at 964c30e , the SITL RC data source was is switched from AP_RCProtocol_UDP to AP_RCProtocol_FDM if that source is available. A quick comparison between the libraries shows that while the _UDP library is sensitive to the SIM_RC_FAIL parameter, the _FDM does not handle this.
ardupilot/libraries/AP_RCProtocol/AP_RCProtocol_UDP.cpp
Line 152 in c117003
Steps to reproduce:
Version
4.6.3 and 4.80 both tested and fail. 4.6.0 has correct behavior.
Platform
[?] All
[ ] AntennaTracker
[ ] Copter
[X] Plane
[ ] Rover
[ ] Submarine
Airframe type
Simulated Fixed-Wing Quadplane
Hardware type
SITL: Various versions launched from Mission Planner 1.3.82 on Windows 10
RealFlight 9.5S on Windows 10, same PC as Mission Planner and SITL instance
Logs
No meaningful logs