user51466: I'm hoping to construct a feedback loop for a laser using an Chipkit UC32 and an analog-digitial converter ( the one of I have is an AD5780 evaluation board). I've been reading through Digilint's  SPI library but I admit I am pretty lost. 
( I believe this is on topic to Arduino because I am using an Arduino API. The micro-controller I use is basically an Arduino so I see no difference. ) 
I'd like to output something simple like a digital AC voltage to the DAC and have it convert it, but as I understand it from here, I am just using the digitalWritecommand which is basically binary. How do transfer something more complicated to have the DAC convert it? 
Likewise, how do I get the DAC to do the reverse, ADC, where it reads in a voltage and sends the Arduino a digital signal through SPI pins? 

user4143: 
I'd like to output something simple like a digital AC voltage to the DAC and have it convert it, but as I understand it from here, I am just using the digitalWritecommand which is basically binary. How do transfer something more complicated to have the DAC convert it?

SPI is a communication protocol.  It uses digital signals, coupled with time, to transfer information.
To use DSPI you need to first define an SPI object
DSPI0 SPI;

From then on it's the same as using the Arduino SPI library.
Start it
SPI.begin();

Then transfer the correct commands (found in the DAC datasheet) to set the voltage of the output
digitalWrite(10, LOW);
SPI.transfer(0x43);
SPI.transfer(0x1A);
digitalWrite(10, HIGH);

The values there are just examples. The 10 is the chip select pin for the DAC, and the values used in the transfers (however many are needed) need to be found in the datasheet.
If you only want to use the pins associated with DSPI0 you can use the SPI library instead (which only supports one SPI channel - the uC32 has two), in which case it is identical to working with the Arduino SPI library.

Likewise, how do I get the DAC to do the reverse, ADC, where it reads in a voltage and sends the Arduino a digital signal through SPI pins?

You don't. DACs are DACs and ADCs are ADCs. They aren't interchangeable. 
For ADC functionality just use any of pins A0 through A11 and the analogRead() function.

51466: <p>I'm hoping to construct a feedback loop for a laser using an Chipkit UC32 and an analog-digitial converter ( the one of I have is an AD5780 evaluation board). I've been reading through <a href="https://reference.digilentinc.com/learn/fundamentals/communication-protocols/spi/start" rel="nofollow noreferrer">Digilint's </a> SPI library but I admit I am pretty lost. </p>

<p>( I believe this is on topic to Arduino because I am using an Arduino API. The micro-controller I use is basically an Arduino so I see no difference. ) </p>

<p>I'd like to output something simple like a digital AC voltage to the DAC and have it convert it, but as I understand it from <a href="https://core-electronics.com.au/tutorials/spi-arduino-tutorial.html" rel="nofollow noreferrer">here</a>, I am just using the <code>digitalWrite</code>command which is basically binary. How do transfer something more complicated to have the DAC convert it? </p>

<p>Likewise, how do I get the DAC to do the reverse, ADC, where it reads in a voltage and sends the Arduino a digital signal through SPI pins? </p>
 4143: <blockquote>
  <p>I'd like to output something simple like a digital AC voltage to the DAC and have it convert it, but as I understand it from here, I am just using the digitalWritecommand which is basically binary. How do transfer something more complicated to have the DAC convert it?</p>
</blockquote>

<p>SPI is a communication <em>protocol</em>.  It uses digital signals, coupled with <em>time</em>, to transfer information.</p>

<p>To use DSPI you need to first define an SPI object</p>

<pre><code>DSPI0 SPI;
</code></pre>

<p>From then on it's the same as using the Arduino SPI library.</p>

<p>Start it</p>

<pre><code>SPI.begin();
</code></pre>

<p>Then transfer the correct commands (found in the DAC datasheet) to set the voltage of the output</p>

<pre><code>digitalWrite(10, LOW);
SPI.transfer(0x43);
SPI.transfer(0x1A);
digitalWrite(10, HIGH);
</code></pre>

<p>The values there are just examples. The 10 is the chip select pin for the DAC, and the values used in the transfers (however many are needed) need to be found in the datasheet.</p>

<p>If you only want to use the pins associated with DSPI0 you can use the SPI library instead (which only supports one SPI channel - the uC32 has two), in which case it is identical to working with the Arduino SPI library.</p>

<blockquote>
  <p>Likewise, how do I get the DAC to do the reverse, ADC, where it reads in a voltage and sends the Arduino a digital signal through SPI pins?</p>
</blockquote>

<p>You don't. DACs are DACs and ADCs are ADCs. They aren't interchangeable. </p>

<p>For ADC functionality just use any of pins A0 through A11 and the <code>analogRead()</code> function.</p>
