I have the following test setup:
1) a board with a serial output
2) a Teensy 3.5, RX1 connected to the serial output
Every 8 seconds the board is sending a string and after each fourth string it sends immediately a further string.
The tests are performed on Arduino IDE with Teensyduino and the following sketch on the Teensy3.5:
On the Serial Monitor I expected to see the received strings line by line.
What I see is one, sometimes two or three, strings. Then the screen is cleared, then again one to three strings, screen cleared, and so on.
When the screen is cleared the head line of the Serial Monitor shows: (offline) Teensy
Obviously the link from Teensy3.5 to my PC breaks down for a short moment and then comes up again. I don't understand why this happens.
In the Tools menue (USB Type: "serial") is selected.
What can be the reason for the link breaking down?
1) a board with a serial output
2) a Teensy 3.5, RX1 connected to the serial output
Every 8 seconds the board is sending a string and after each fourth string it sends immediately a further string.
The tests are performed on Arduino IDE with Teensyduino and the following sketch on the Teensy3.5:
Code:
#define RFrec Serial1
void setup() { // ----------------------------------------------
// Initialize serial port for communication with receiver.
RFrec.begin(19200); // from RF receiver
// Initialize serial port for communication with IDE.
Serial.begin(38400); // for Serial Monitor
delay(1000);
while (1) {
char c;
if (RFrec.available()) {
c=RFrec.read();
if ( (c==13) || (c==10) || ((c>31) && (c<91)) ) {
Serial.print(c);
}
else {
Serial.print((uint8_t)c);
Serial.print(" ");
}
}
}
}
void loop() {
}
What I see is one, sometimes two or three, strings. Then the screen is cleared, then again one to three strings, screen cleared, and so on.
When the screen is cleared the head line of the Serial Monitor shows: (offline) Teensy
Obviously the link from Teensy3.5 to my PC breaks down for a short moment and then comes up again. I don't understand why this happens.
In the Tools menue (USB Type: "serial") is selected.
What can be the reason for the link breaking down?