Hi,
SHIFTIN/SHIFTOUT are bit-banged commands and does NOT use the SSP/MSSP module so you don't need to set that up. There are no "high level" PBP commands to do SPI (or I2C) with the SSP/MSSP module so you'll need to "drive it" manually - which isn't that hard. But again, since you're using SHIFTOUT it doesn't matter.
Right now you're sending MSB first - which is great. But the very first bit (Bit 15) you're sending is '1' which, if you look at the datasheet, means 'Ignore this command'. So, if everything else is alright, it should do exactly what you're seeing - nothing.
From the datasheet:Do you have a scope or logic analyzer you can use to verify that the pins are doing what they should?bit 15
0 = Write to DAC register
1 = Ignore this command
bit 14 BUF: VREF Input Buffer Control bit
1 = Buffered
0 = Unbuffered
bit 13 GA: Output Gain Selection bit
1 = 1x (VOUT = VREF * D/4096)
0 = 2x (VOUT = 2 * VREF * D/4096)
bit 12 SHDN: Output Shutdown Control bit
1 = Active mode operation. VOUT is available.
0 = Shutdown the device. Analog output is not available. VOUT pin is connected to 500 ktypical)
bit 11-0
D110: DAC Input Data bits. Bit x is ignored.
/Henrik.
Bookmarks