I am trying to communicate through two, Arduino UNO and Nano. Looks like it is communicating not showing any error code even, but data showing in serial monitor is a set of codes inclusive of some simples like "??!!!A" randomly...
Have a look at the examples in Serial Input Basics - simple reliable ways to receive data. There is also a parse example to illustrate how to extract numbers from the received text.
The technique in the 3rd example will be the most reliable.
You can send data in a compatible format with code like this
1. Using hardware UART Port?
Figure-1: UNO and NANO connection using hardware UART Port (UART)
UNO NANO
TX RX
RX TX
GND GND
2. Using software UART Port (SUART)?
Figure-2: UNO and NANO connection using software UART Port (SUART) UNO NANO
STX (3) SRX (2)
SRX (2) STX (3)
GND GND
3. Using I2C Bus?
Figure-3: UNO and NANO connection using I2C Bus UNO NANO
SDA (A4) SDa (A4)
SCl (A5) SCL (A5)
GND GND
2.2k resistor from SDA pin to 5V
2.2k resistor from SCL line to 5V
4. USing SPI Port?
Figure-4: UNO and NANO connection using SPI Port UNO NANO
SS/ (10) D10
MOSI (11) D11
MISO (12) D12
SCK (13) D13
GND GND
5. Have you written some codes? Please post your codes.