Pulldown button pin so you can put an LED on the probe

This commit is contained in:
Kevin Santo Cappuccio 2024-03-06 09:32:51 -08:00
parent f5d41711f6
commit 47f1449c8b
3 changed files with 7 additions and 4 deletions

View File

@ -857,7 +857,7 @@ void replaceSFNamesWithDefinedInts(void)
specialFunctionsString.replace("CURRENT_SENSE_MINUS", "109");
specialFunctionsString.replace("CURRENT_SENSE_PLUS", "108");
specialFunctionsString.replace("ISENSE_MINUS", "109");
specialFunctionsString.replace("IENSE_PLUS", "108");
specialFunctionsString.replace("ISENSE_PLUS", "108");
specialFunctionsString.replace("EMPTY_NET", "127");

View File

@ -745,6 +745,7 @@ int checkProbeButton(void)
{
int buttonState = 0;
pinMode(buttonPin, INPUT);
startProbe();
if (readFloatingOrState(buttonPin, 0) == probe)
@ -756,6 +757,8 @@ int checkProbeButton(void)
buttonState = 0;
}
stopProbe();
pinMode(buttonPin, OUTPUT );
digitalWrite(buttonPin, LOW);
return buttonState;
}

View File

@ -99,8 +99,8 @@ void setup()
clearAllNTCC();
delay(20);
setupAdcUsbStuff(); // I took this out because it was causing a crash on
//delay(20);
//setupAdcUsbStuff(); // I took this out because it was causing a crash on
delay(10);
// lastNetConfirm(0);
@ -138,7 +138,7 @@ int baudRate = 115200;
int restoredNodeFile = 0;
const char firmwareVersion[] = "1.3.8"; //// remember to update this
const char firmwareVersion[] = "1.3.9"; //// remember to update this
void loop()
{