Made the sonaar reciever and transmitter and are working fine.
I need to calculate the distance so i need to interface the 8051microcontroller with Reciever and transmitter. i just dunt knw how to start up with the microcntroller part. then i need to display the distance calculated on a LCD screen or a 7 segment display.
CAn anyone help with the coding? and how to the interfacing? i need to complete the project as soon as possible
Well it looks like you have a digital output pin and a digital input pin. I don't know if there is any significance to the choice of pins on the Basic Stamp. Specifically if there is any usefull hardware associated with those pins. If not then you can pick any convenient pins of the 8051, connect them to the transmitter and the receiver and duplicate the Basic coding in assembly language.
hmmm....wat do u mean by duplicating the basic code? actuallly i dunt knw how to set the timmers of 8051 to calculate the time elapsed between transmission n reception of the pulse. Can u help me in that?
The Basic Stamp has a prgramming language that looks like Basic. Basic is a programming language developed at Dartmouth University in the early 1960's. AFAIK there is no widely available basic interpreter for a generic 8051 that is compatible with the Basic Stamp. The low cost alternative to Basic is assembly language. In order to program the timers you need to be able to follow the description of the hardware contained in the datasheet or the hardware description manual. Here are some links to some reference manuals for the Atmel line of 8051's
Hola P B,
I recall that all I did with the 8052 was in BASIC. More than 12 years ago.
Is it any possibility that it could be useful here? It was the BASIC supplied by Intel itself.
I am currently working in assembly (only) with PICs but recall that as being quite simple and easy. Got my first LCD up and running in hours with no previous experience at all!
As I recall Basic Stamp is a highly styleized version of Basic. There may be equivalent structures in some other Basic but I'm not familiar with the details. For what the OP wants to do I think assembly language is the only way to measure the return signal accurately. I could be wrong however -- it's happened before.