07-17-2010 02:08 AM
I have interfaced an atmel 89c51 with ADC0808. Given the clock through uC. Vrf+ 5v.Vref- 0v.
I have also interfaced it with max232. Done the programming so that the ADC has three inputs and uC initiates the ADC0808 and sends the outputs to serial port. Input values are converted into Decimal and then ASCII (to display on hyperterminal). While I give 0 volts to all inputs.
The output is
000,000,000
When I give 5 volt to 1st input. The output appears as
255,000,000
But when i give input value between 0-5 volt.e.g 2.5 volt. the ouptut is still
000,000,000
I could not understand what could be the problem.
I have uploaded the proteus.simlulation file,c and hex code
07-18-2010 01:06 AM
I have interfaced an atmel 89c51 with ADC0808. Given the clock through uC. Vrf+ 5v.Vref- 0v. I have also interfaced it with max232. Done the programming so that the ADC has three inputs and uC initiates the ADC0808 and sends the outputs to serial port. Input values are converted into Decimal and then ASCII (to display on hyperterminal). While I give 0 volts to all inputs. The output is
000,000,000
When I give 5 volt to 1st input. If the output is 4 lines per second the output shows as
255,000,000 (correct value)
255,000,000 //
Some Random Value,000,000
255,000,000
Where the random values range from 000-255.
Also when i give input value between 0-5 volt.e.g 2.5 volt. the ouptut is still
000,000,000
I could not understand what could be the problem.
07-19-2010 10:10 AM
Hi 444444,
Thanks for posting to National Instruments forums. I wanted to check, after scanning your initial post, are you using any National Instruments software or hardware, perhaps something like the USB 8451? These forums are frequented by NI users and, subsequently, are a great place to speak with experts in the use of those products. Looking through your set up, I was unfamiliar with a lot of the hardware you mentioned, and as such I am not sure if this forum will be the best place to get the answers and expertise you are seeking. Perhaps the manufacturers of the 89c51 and ADC0808 have a support line where the expertise in your hardware is more readily available. I am sure that they would be a better resource as far a familiarity with programming and how data should be returned by that ADC.