Changes between Version 7 and Version 8 of Docs/Prog/Manual/ApplicationLibraries/lib825ev/DAC


Ignore:
Timestamp:
09/20/18 12:39:22 (6 years ago)
Author:
Don Wilson
Comment:

--

Legend:

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

    v7 v8  
    2727{
    2828   // The DAC output is controlled by a 16 bit register so we multiple the maximum 16-bit value 0xFFFF times output percentage/100 desired.
    29    // For example maxium 10 V would be 0xFFFF * (10.0 / 10.0) = 0xFFFF * 1.0 = 0xFFFF, 5V would be 0xFFFF * (5.0 / 10.0) = 0xFFFF * 0.5 = 0x8000
     29   // For example maximum 10 V would be 0xFFFF * (10.0 / 10.0) = 0xFFFF * 1.0 = 0xFFFF, 5V would be 0xFFFF * (5.0 / 10.0) = 0xFFFF * 0.5 = 0x8000
    3030     uint16 value = (uint16)(0xFFFF * (voltage / 10.0));
    3131     SetDACReg(nDAC, dacAD5422Data, value, WAIT_ACK);
    3232}
    3333
    34 
    35 
    3634}}}