Changes between Version 1 and Version 2 of Docs/Prog/Manual/ApplicationLibraries/lib825ev/DAC/SetDACReg


Ignore:
Timestamp:
03/21/12 07:39:22 (13 years ago)
Author:
Don Wilson
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Docs/Prog/Manual/ApplicationLibraries/lib825ev/DAC/SetDACReg

    v1 v2  
    2424
    2525{{{
     26   int dac = 1; // number of dac card - not number of slot
     27   DACOutputRange outRange = dacOutput0to10V;
    2628
     29   // This sets the DAC output for manual control
     30   if(SetDACReg(dac, dacAD5422Control, 0x3FF0 | (uint16)outRange, WAIT_ACK) != OK)
     31   {
     32       DisplayText(0, 0, "SetDACReg Error");
     33   }
     34
     35   uint16 level = 0x7FFF; // Output at half
     36   if(SetDACReg(dac, dacAD5422Data, level, WAIT_ACK) != OK)
     37   {
     38       DisplayText(0, 0, "SetDACReg Set level error");
     39   }
     40   
    2741}}}
    2842