1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2024-12-23 21:01:25 +01:00

Fix digital read bug

This commit is contained in:
peteGSX 2023-02-04 09:19:32 +10:00
parent ec83a345dc
commit abe79b854e

View File

@ -158,7 +158,7 @@ private:
int _read(VPIN vpin) override {
int pin = vpin - _firstVpin;
uint8_t pinByte = pin / 8;
bool value = _digitalInputStates[pinByte] >> (pin - pinByte * 8);
bool value = bitRead(_digitalInputStates[pinByte], pin - pinByte * 8);
return value;
}