Skip to content

Commit

Permalink
Release 2.3.7
Browse files Browse the repository at this point in the history
Fix delay lengths, increase speed and reliability
  • Loading branch information
exploitagency committed Sep 7, 2017
1 parent 4d28c4a commit 15f9352
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
18 changes: 12 additions & 6 deletions source/ESP_Code/ESP_Code.ino
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,12 @@ void runpayload() {
int defaultdelay = DelayLength;
int settingsdefaultdelay = DelayLength;
int custom_delay;
delay(livepayloaddelay);
while(f.available()) {
// SOFTserial.println(line);
// Serial.println(line);
String line = f.readStringUntil('\n');
line.replace("&lt;", "<");
Serial.println(line);

String fullkeys = line;
int str_len = fullkeys.length()+1;
Expand All @@ -108,7 +108,7 @@ void runpayload() {

if(cmd == "Rem") {
cmdinput = String(strtok_r(NULL,":",&i));
DelayLength = 1500;
DelayLength = 0;
}

else if(cmd == "DefaultDelay") {
Expand All @@ -125,6 +125,9 @@ void runpayload() {
DelayLength = custom_delay;
// Serial.println(String()+"Custom delay set to:"+custom_delay);
}
else {
Serial.println(line);
}
// Serial.println(DelayLength);
delay(DelayLength); //delay between lines in payload, I found running it slower works best
DelayLength = defaultdelay;
Expand Down Expand Up @@ -206,7 +209,7 @@ void settingsPage()
"<hr>"
"<b>Payload Settings:</b><br><br>"
"Delay Between Sending Lines of Code in Payload:<br><input type=\"number\" name=\"DelayLength\" value=\""+DelayLength+"\" maxlength=\"31\" size=\"10\"> milliseconds (Default: 2000)<br><br>"
"Delay Before Starting a Live Payload:<br><input type=\"number\" name=\"LivePayloadDelay\" value=\""+livepayloaddelay+"\" maxlength=\"31\" size=\"10\"> milliseconds (Default: 3000)<br><br>"
"Delay Before Starting a Live or Auto Deploy Payload:<br><input type=\"number\" name=\"LivePayloadDelay\" value=\""+livepayloaddelay+"\" maxlength=\"31\" size=\"10\"> milliseconds (Default: 3000)<br><br>"
"<b>Automatically Deploy Payload Upon Insetion</b><br>"
"Yes <INPUT type=\"radio\" name=\"autopwn\" value=\"1\""+autopwnyes+"><br>"
"No <INPUT type=\"radio\" name=\"autopwn\" value=\"0\""+autopwnno+"><br><br>"
Expand Down Expand Up @@ -621,6 +624,7 @@ void setup(void)

if(cmd == "Rem") {
cmdinput = String(strtok_r(NULL,":",&i));
DelayLength = 0;
}

else if(cmd == "DefaultDelay") {
Expand All @@ -634,7 +638,7 @@ void setup(void)
cmdinput = String(strtok_r(NULL,":",&i));
String customdelay = cmdinput;
custom_delay = customdelay.toInt();
delay(custom_delay);
DelayLength = custom_delay;
// Serial.println(String()+"Custom delay set to:"+custom_delay);
}
// Serial.println(DelayLength);
Expand Down Expand Up @@ -725,7 +729,6 @@ void setup(void)
// Serial.println(line);
String line = f.readStringUntil('\n');
line.replace("&lt;", "<");
Serial.println(line);

String fullkeys = line;
int str_len = fullkeys.length()+1;
Expand All @@ -742,7 +745,7 @@ void setup(void)

if(cmd == "Rem") {
cmdinput = String(strtok_r(NULL,":",&i));
DelayLength = 1500;
DelayLength = 0;
}

else if(cmd == "DefaultDelay") {
Expand All @@ -759,6 +762,9 @@ void setup(void)
DelayLength = custom_delay;
// Serial.println(String()+"Custom delay set to:"+custom_delay);
}
else {
Serial.println(line);
}
// Serial.println(DelayLength);
delay(DelayLength); //delay between lines in payload, I found running it slower works best
DelayLength = defaultdelay;
Expand Down
Binary file modified source/ESP_Code/ESP_Code.ino.generic.bin
Binary file not shown.
2 changes: 1 addition & 1 deletion source/ESP_Code/version.h
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
String version = "2.3.6";
String version = "2.3.7";
String latestardversion = "2.1";

0 comments on commit 15f9352

Please sign in to comment.