Skip to content

Commit cfa5c14

Browse files
authored
Merge pull request #517 from LeeLeahy2/ati50
Add the ATI50 command to test LoRaSerial to Host flow control
2 parents 2701e81 + 5f60568 commit cfa5c14

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

Firmware/LoRaSerial/Commands.ino

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -736,6 +736,29 @@ bool commandAT(const char * commandString)
736736
return true;
737737
}
738738
}
739+
if ((commandString[2] == 'I') && (commandString[3] == '5') && (commandLength == 5))
740+
{
741+
switch (commandString[4])
742+
{
743+
default:
744+
return false;
745+
746+
case ('0'): //ATI50 - Output 80000 bytes, stop when serial is full
747+
for (uint16_t line = 0; line < 1000; line++)
748+
{
749+
const char * text = "ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUV";
750+
751+
if (line < 100)
752+
systemWrite('0');
753+
if (line < 10)
754+
systemWrite('0');
755+
systemPrint(line);
756+
systemWrite(':');
757+
systemPrintln(text);
758+
}
759+
return true;
760+
}
761+
}
739762

740763
//Invalid command
741764
return false;

0 commit comments

Comments
 (0)