PDA

View Full Version : question regarding an external AD converter



dtoohey
- 14th March 2005, 00:47
I'm trying to interface a 12-bit AD converter(Gyropoint ASIC) with a PIC16F876, but I'm stuck.

The instructions for the AD converter call for a 4Mhz clock. Thinking I could use my PIC and its 4Mhz crystal to provide the clocking, I connected the PIC OSC2 pin to the MSTR_CLK pin of the AD converter.. Is this okay? I suspect it is not since i'm getting nothing but a "0" reading when I display the data. While it may be that other portions of my code are causing the problems, I figure it's most likely this clock issue.... I'm pretty new at this stuff, so any help will be most appreciated.
Thanks,
Damian

sonic
- 14th March 2005, 05:54
HI,D!
First of all, find a PDF file for your ADC and read it carefully.
Pay attention on timing diagrams!!!
Picture u have sent I suppose has wrong connection between PIC and ADC - Din (ADC) goes to Dout (MCU) and Din (MCU) goes to Dout (ADC).

dtoohey
- 15th March 2005, 05:50
Hi Sonic, thanks for the reply.
turns out i had an incorrect mode set for my shiftout statement. everything seems to work fine now. Looks like the clock pin for the ADC can be connected to the OSC2 pin of the PIC after all.