View previous topic :: View next topic |
Author |
Message |
jjacob
Joined: 08 Mar 2008 Posts: 54 Location: PORTUGAL (PORTO)
|
MCP41HV51 - Digital Potentiometer |
Posted: Wed Feb 15, 2017 6:28 am |
|
|
Hello everyone
I'm trying to do a digital potentiometer using MCP41HV51, and I want to control an VFD, from 0 to 10V.
Does someone have already a driver for this device?
Thanks for your help,
Best regards,
Jacob |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19552
|
|
Posted: Wed Feb 15, 2017 11:56 am |
|
|
Don't people look at the data sheet?.
Just like in this thread:
<http://www.ccsinfo.com/forum/viewtopic.php?t=55945>
It's another device that can be directly operated without a driver.
It needs SPI mode 3. When you want the value to actually update, raise and lower WLAT. You can if you want add this to the SPI setup (#use spi supports a latch bit), or if you want the update at a specific 'time' then operate this from a timer or something similar. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Wed Feb 15, 2017 1:05 pm |
|
|
According to the MCP41HV51 data sheet, it will also operate in SPI Mode 0:
Quote: | 6.2 The SPI Modes
The SPI module supports two (of the four) standard SPI
modes. These are Mode 0,0 and 1,1. The mode is
determined by the state of the SDI pin on the rising
edge of the first clock bit (of the 8-bit byte). |
http://ww1.microchip.com/downloads/en/DeviceDoc/20005207B.pdf |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19552
|
|
Posted: Wed Feb 15, 2017 1:19 pm |
|
|
Yes. A lot of things support both these modes. Their diagram shows the idle clock as high, so I felt it best to keep it simple and match the diagram. |
|
|
|