Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Using Serial Communication

Method Serial communication is used to transfer data between two devices.

Image RemovedImage Added


Serial Monitor & analogRead()

Image RemovedImage Added

Sending a Message

Code Block
languagecpp
themeConfluence
void setup()

...


{

...


  // initialize serial:

...


  Serial.begin(9600);

...



}

...



void loop ( )

...



{

...


  Serial.print(

...

"Hands on

...

") ; //does not insert a newline at the end; next message continues on the same line
  Serial.print(

...

"Learning ") ; //does not insert a newline at the end; next message continues on the same line
  Serial.println(

...

"is Fun!!!

...

") ; //inserts a newline at the end; next message is printed on a new line
}]] ></ac:plain-text-body></ac:structured-macro>