Newbie vs. DS1868 Digital Pot
Greg Norton
Posts: 70
Hello All,
I'm attempting to interface my BS2 with a DS1868 digital pot. So far I'm not getting anywhere and I need some advice here. I wrote a quick program that should just ramp the voltage from 0-5 and back down. When I measure the output with my DVM, it just sits at around 0.14 volts and does nothing else. I have hooked things up as follows:
VCC to +5
GND to GND of power supply
H0 to +5v
L0 to GND
W0 to DVM positive input
/RST to pin 2 of BS2
CLK to pin 1 of BS2
DQ to pin 0 of BS2
So here are the questions:
What should be done with Vb pin on the 1868? If I leave it floating I get the 0.14 volts on the output. If I ground it, I get 0 volts on the output. I have no idea what this pin is for. The datasheet mentions -3.3V to GND voltage levels for this pin. I would really appreciate any enlightenment on this subject.
Another area I suspect is a problem is my code, I have read the datasheet to say that the first bit output should be the stack select bit, then MSB to LSB of the two values. Have I got the shiftout statement correct?
Is my output subroutine in general correct? I tried to implement the timing diagram shown but you never know.
I don't have a logic analyzer to view the activity on the serial interface and I haven't been too successful seeing anything with the USB oscilloscope.
Thanks.
Greg
Post Edited (Greg Norton) : 5/17/2007 4:07:54 AM GMT
I'm attempting to interface my BS2 with a DS1868 digital pot. So far I'm not getting anywhere and I need some advice here. I wrote a quick program that should just ramp the voltage from 0-5 and back down. When I measure the output with my DVM, it just sits at around 0.14 volts and does nothing else. I have hooked things up as follows:
VCC to +5
GND to GND of power supply
H0 to +5v
L0 to GND
W0 to DVM positive input
/RST to pin 2 of BS2
CLK to pin 1 of BS2
DQ to pin 0 of BS2
So here are the questions:
What should be done with Vb pin on the 1868? If I leave it floating I get the 0.14 volts on the output. If I ground it, I get 0 volts on the output. I have no idea what this pin is for. The datasheet mentions -3.3V to GND voltage levels for this pin. I would really appreciate any enlightenment on this subject.
Another area I suspect is a problem is my code, I have read the datasheet to say that the first bit output should be the stack select bit, then MSB to LSB of the two values. Have I got the shiftout statement correct?
Is my output subroutine in general correct? I tried to implement the timing diagram shown but you never know.
I don't have a logic analyzer to view the activity on the serial interface and I haven't been too successful seeing anything with the USB oscilloscope.
Thanks.
Greg
Post Edited (Greg Norton) : 5/17/2007 4:07:54 AM GMT
Comments
2) I think you have the bit order correct.