Skip to content

Commit

Permalink
Removing used pins logic in analog pins (#413)
Browse files Browse the repository at this point in the history
Removing used pins in webconfig.cpp as it breaks our add-on pin logic. This will need to be reworked
  • Loading branch information
arntsonl authored Jul 18, 2023
1 parent 7dbd834 commit 5b6e1ae
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/configs/webconfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -367,11 +367,12 @@ void addUsedPinsArray(DynamicJsonDocument& doc)
// addPinIfValid(boardOptions.i2cSDAPin);
// addPinIfValid(boardOptions.i2cSCLPin);

const AnalogOptions& analogOptions = Storage::getInstance().getAddonOptions().analogOptions;
addPinIfValid(analogOptions.analogAdc1PinX);
addPinIfValid(analogOptions.analogAdc1PinY);
addPinIfValid(analogOptions.analogAdc2PinX);
addPinIfValid(analogOptions.analogAdc2PinY);
// TODO: Used Pins logic does not work in add-ons, fix this
// const AnalogOptions& analogOptions = Storage::getInstance().getAddonOptions().analogOptions;
// addPinIfValid(analogOptions.analogAdc1PinX);
// addPinIfValid(analogOptions.analogAdc1PinY);
// addPinIfValid(analogOptions.analogAdc2PinX);
// addPinIfValid(analogOptions.analogAdc2PinY);

// TODO: Exclude non-button pins from validation for now, fix this when validation reworked
// addPinIfValid(addonOptions.buzzerPin);
Expand Down

0 comments on commit 5b6e1ae

Please sign in to comment.