I am a beginner in arduino. I am controlling an arduino through i2c communication i.e when given command from the master the appropriate action is done by the slave.Now one of my command is to transmit data from the slave serially to the master which is connected to the pc and the received data is seen on the serial monitor.
The i2c commands works well but wen i connect the rx and tx of the arduino nothing works. and nothing comes on the serial monitor
Your diagram is not helpful - just like @PaulS you can have no idea how the OP has things connected.
The purpose of @PaulS's question is to get the OP to post a diagram showing how s/he has everything connected in the expectation that it will help with diagnosing the problem.
Answering questions that are addressed to newbies reduces their opportunity for learning.
Robin2:
Your diagram is not helpful - just like @PaulS you can have no idea how the OP has things connected.
The purpose of @PaulS's question is to get the OP to post a diagram showing how s/he has everything connected in the expectation that it will help with diagnosing the problem.
Answering questions that are addressed to newbies reduces their opportunity for learning.
The answer might help/inspire OP to draw his own diagram/schematic and thus may enhance the opportunity of learning.
Look at the codes that the OP has posted in Post#3. It is an I2C Bus oriented codes (direct copy of someone else's post of another thread) within which he has inserted this UART code: Serial.readBytes(data, 20). If the OP could realize that the codes could not be mixed just at will, he would not certainly do it. The diagram of Post#5 along with the given 3 statements might help him to understand that he has made mistakes.
GolamMostafa:
Whom have you addressed to post a schematic? Is is the OP or anyone who is a registered member of this Forum? I am a registered member of this Forum.
I think the fact that I quoted a portion of a previous thread, and made comments, strongly implies that the comments are address to the person that I'm quoting.
Just as you quoted part of what I wrote suggests that you are addressing your question to a specific forum member, not all forum members.
Your schematic might reflect how the OP should have connected stuff, but it does not tell us anything about how OP ACTUALLY connected stuff. Or meant to. It was, therefore, just noise, as you did not suggest, imply, or even hint at the fact that it might not actually reflect anything about OPs circuit.
PaulS:
I think the fact that I quoted a portion of a previous thread, and made comments, strongly implies that the comments are address to the person that I'm quoting.
When you say 'strongly implies', then there is a 'Schrödinger Tunnel' which I have simply utilized? I understand that there is a difference between the following two quotes when someone is strict/serious?
PaulS:
I think the fact that I quoted a portion of a previous thread, and made comments, strongly implies that the comments are address to the person that I'm quoting.
and
I think the fact that I quoted a portion of a previous thread, and made comments, strongly implies that the comments are address to the person that I'm quoting.
I think I should suggest to the Moderators to move everything starting with Reply #5 to a separate Thread so that @GolamMostafa can pursue his enquiries without mucking up the Thread that was started by @malamsthu.