add while(!Serial) to all examples
This commit is contained in:
6 files changed
+6
No files matched your search
@@ -24,6 +24,7 @@ const int baudrate = 115200;
|
||||
void setup()
|
||||
{
|
||||
Serial.begin (baudrate);
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
|
||||
Serial.println("Serial Echo demo");
|
||||
Serial.print("Badurate : ");
|
||||
|
||||
+1
@@ -23,6 +23,7 @@ int interruptPin = A0;
|
||||
void setup()
|
||||
{
|
||||
Serial.begin(115200);
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
|
||||
pinMode(interruptPin, INPUT_PULLUP);
|
||||
|
||||
|
||||
@@ -39,6 +39,7 @@ const int chipSelectPin = 7;
|
||||
|
||||
void setup() {
|
||||
Serial.begin(9600);
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
|
||||
// start the SPI library:
|
||||
SPI.begin();
|
||||
|
||||
@@ -16,6 +16,7 @@ void setup()
|
||||
{
|
||||
Wire.begin(); // join i2c bus (address optional for master)
|
||||
Serial.begin(9600); // start serial communication at 9600bps
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
}
|
||||
|
||||
int reading = 0;
|
||||
|
||||
@@ -16,6 +16,7 @@ void setup()
|
||||
{
|
||||
Wire.begin(); // join i2c bus (address optional for master)
|
||||
Serial.begin(9600); // start serial for output
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
}
|
||||
|
||||
void loop()
|
||||
|
||||
@@ -17,6 +17,7 @@ void setup()
|
||||
Wire.begin(4); // join i2c bus with address #4
|
||||
Wire.onReceive(receiveEvent); // register event
|
||||
Serial.begin(9600); // start serial for output
|
||||
while ( !Serial ) delay(10); // for nrf52840 with native usb
|
||||
}
|
||||
|
||||
void loop()
|
||||
|
||||
Reference in new issue
Block a user