Microchip Technology MCP42XXEV User Manual

Page of 42
MCP42XXEV Evaluation Board User’s Guide
DS51898A-page 28
 2010 Microchip Technology Inc.
2.6
MCP4261 DEMO STEPS
This demo assumes that you know how to configure the PICkit Serial Analyzer for 
Master SPI operation. See Section 2.5 “Configuring The PICkit™ Serial Analyzer” 
or the “PICkit Serial Analyzer User’s Guide” (DS51647) for additional information.
1. Plug the PICkit serial device into the PC’s USB port.
2. Plug the MCP42XXEV board into the PICkit serial.
3. Add the User Scripts (see Example 2-1) to the CommScripts.TXT file.
4. Start the PICkit serial GUI.
5. Ensure the GUI is in Master SPI Communication mode (see Figure 2-5).
6. Ensure that the Master SPI configuration is appropriately configured (see 
7. Measure the Wiper 0 voltage on the MCP42XXEV board (see Figure 2-2) using 
an oscilloscope or digital multimeter. Measure voltage from the ground plane 
(GND) to the wiper (P12). The voltage on the wiper should be ~ V
DD
/2 (~2.5V).
8. Open the Script Builder window (see Figure 2-8).
9. Double click on the “WriteWiper0” script in the Example SPI Scripts column. This 
loads the Script Detail column (see Figure 2-10).
10. Click on the Execute Script button. This executes the script shown in the Script 
Detail column, which will update the wiper value to 3Fh. The wiper voltage will 
now be ~V
DD
/4 (~1.25V). The Transaction window (see Figure 2-13) will be 
updated to indicate the execution of the script.
11. Select the “ReadWiper0” script in the User SPI Scripts column. It should look like 
12. Click on the Execute Script button. This executes the script shown in the Script 
Detail column. The Transaction window (see Figure 2-13) will be updated to 
indicate the execution of the script. The data read is shown in the last line.
13. Double click on the “WriteWiper0” script in the Example SPI Scripts column. This 
loads the Script Detail column and modifies the Wiper 0 data to 1FFh (see 
Figure 2-12).
14. Click on the Execute Script button. This executes the script shown in the Script 
Detail column, which will update the wiper value to 1FFh. The wiper voltage will 
now be ~V
DD
 (~5V). The Transaction window (see Figure 2-13) will be updated 
to indicate the execution of the script.
15. Select the “ReadWiper0” script in the User SPI Scripts column. It should look like 
16. Click on the Execute Script button. This executes the script shown in the Script 
Detail column. The Transaction window (see Figure 2-13) will be updated to 
indicate the execution of the script. The data read is shown in the last line.
17. In the Transaction window, click the Clear button.
18. On the PICkit Serial Analyzer command bar, click the Reset button.
19. Select the “WriteWiper0” script in the User SPI Scripts column and then click on 
the Execute Script button.
20. Select the “ReadWiper0” script in the User SPI Scripts column and then click on 
the Execute Script button.