mirror of https://github.com/ArduPilot/ardupilot
AP_HAL_ChibiOS: Change the magic number to a defined value
This commit is contained in:
parent
e5f4f87b9e
commit
70046e0d58
|
@ -2300,7 +2300,7 @@ void RCOutput::safety_update(void)
|
|||
bool safety_pressed = palReadLine(HAL_GPIO_PIN_SAFETY_IN);
|
||||
if (safety_pressed) {
|
||||
AP_BoardConfig *brdconfig = AP_BoardConfig::get_singleton();
|
||||
if (safety_press_count < 255) {
|
||||
if (safety_press_count < UINT8_MAX) {
|
||||
safety_press_count++;
|
||||
}
|
||||
if (brdconfig && brdconfig->safety_button_handle_pressed(safety_press_count)) {
|
||||
|
|
Loading…
Reference in New Issue