AHaseeb:
The main Problem is that i want to take the average of both the ultrasonic readings i.e from 0 to 180 and from 180 to 0 ..... and send that average on the Serial port .. Can anyone help me with that ....
I don't understand this. Can you give an example. The average from 0 to 180 is 90 - but I suspect that is not what you want.
...R