Browse Source

Update Spy tool

v_master
Volodymyr Shymanskyy 7 years ago
parent
commit
28cc44280d
1 changed files with 12 additions and 10 deletions
  1. +12
    -10
      tools/AT_Spy/AT_Spy.ino

+ 12
- 10
tools/AT_Spy/AT_Spy.ino View File

@ -1,7 +1,7 @@
/************************************************************** /**************************************************************
* *
* This script just listens in on the communication between an Arduino and the
* modem.
* This script just listens in on the communication
* between an Arduino and the modem.
* *
* TinyGSM Getting Started guide: * TinyGSM Getting Started guide:
* http://tiny.cc/tiny-gsm-readme * http://tiny.cc/tiny-gsm-readme
@ -28,18 +28,20 @@ AltSoftSerial BOARD_TX;
void setup() { void setup() {
// Set console baud rate // Set console baud rate
SPY.begin(57600);
SPY.begin(115200);
MODEM_TX.begin(BAUD_RATE); MODEM_TX.begin(BAUD_RATE);
BOARD_TX.begin(BAUD_RATE); BOARD_TX.begin(BAUD_RATE);
delay(5000);
delay(1000);
} }
void loop() void loop()
{ {
while (MODEM_TX.available()) {
SPY.write(MODEM_TX.read());
}
while (BOARD_TX.available()) {
SPY.write(BOARD_TX.read());
}
while (MODEM_TX.available()) {
SPY.write(MODEM_TX.read());
}
while (BOARD_TX.available()) {
SPY.write(BOARD_TX.read());
}
} }

Loading…
Cancel
Save