Ok this is what I have done:
It is exaclty the same other people have done but I do not know what I have done wrong:
Arduino UNO: TX--> RX of arduino micro
Arduino UNO: RX ---> TX of arduino micro.
common GND.
Code for arduino uno: (sender)
void setup()
{
Serial.begin(9600);
}
void loop() {
//--- display the character just sent on console ---
Serial.println( "Hello world" );
delay(1000);
}
Code for receiver (micro):
void setup()
{
Serial.begin(9600);
}
void loop() {
if (Serial.available() > 0) {
int temp=Serial.read();
Serial.println(temp);
} else {
Serial.println("Not available data");
}
delay(1000);
}
and I do see not available data.
What am I missing?