07-16-2012 03:54 AM
Hello all,
I am using MCP42100 digi pot for my project. I have difficulty in programing spi in labview. I installed all required software and I am sure that all the devices working fine. Still I am unable to to communicate with the pot. The attachment has a Vi I am using, kindly go throuh it and let me know my mistakes please!
Thank you
Venki
Solved! Go to Solution.
07-18-2012 01:46 AM
I got it
07-18-2012 06:17 PM
You don't need to be so elaborate with building the array to send via SPI. You can simply do this as long as both values are U8's.
Why are you writing to that digital pin? The SPI command does that already within the code.
With my library (attached), you should be able to make your code as simple as this:
Try it out with my library and let me know if it works because I can't test it. If you test it and give me feedback, Thanks for you help!
07-22-2012 08:57 AM
NathanB, thanks for the vi's.great job, much cleaner!...will test it out at work. Uno is acting normal
07-23-2012 03:36 PM
I'm glad you like it. Let me know the results of your tests!
08-09-2012 02:28 PM
well, the chip select is not syncronized to the serial command and the pulse width (chip select) varies from 600 to 700 uSec, because of this...I cant clock 16 rises accurately...
08-09-2012 07:01 PM
I'm not sure I understand any of that. I'm using exactly the same method that Venki uses. Also, I'm using standardized SPI protocol so I'm not sure that that is the problem. If you are having issues with timing maybe you need to change the clock divider in the Init VI.
08-10-2012 09:00 AM
I am sure it must be my configuration(user error),it will do what it was commanded to do...., otherwise there would be more complaints on this.Thanks for your help!
01-25-2013 01:48 PM
thanks Nathan for the MCP41xx lib, I was able to get the digital pot working...
01-25-2013 03:50 PM
That's great to hear! Did you need to change anything in the library to get it to work? Anything I would need to change so that it will work for everybody?