mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-21 01:01:43 +00:00
HAL sim: Fix incorrectly setting dio port to initialized on cleanup (#1813)
This commit is contained in:
committed by
Peter Johnson
parent
09d00a6227
commit
a4530243e1
@@ -1,5 +1,5 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
/* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */
|
||||
/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */
|
||||
/* Open Source Software - may be modified and shared by FRC teams. The code */
|
||||
/* must be accompanied by the FIRST BSD license file in the root directory of */
|
||||
/* the project. */
|
||||
@@ -78,7 +78,7 @@ void HAL_FreeDIOPort(HAL_DigitalHandle dioPortHandle) {
|
||||
// no status, so no need to check for a proper free.
|
||||
digitalChannelHandles->Free(dioPortHandle, HAL_HandleEnum::DIO);
|
||||
if (port == nullptr) return;
|
||||
SimDIOData[port->channel].initialized = true;
|
||||
SimDIOData[port->channel].initialized = false;
|
||||
}
|
||||
|
||||
HAL_DigitalPWMHandle HAL_AllocateDigitalPWM(int32_t* status) {
|
||||
|
||||
Reference in New Issue
Block a user