Changes between Version 38 and Version 39 of warpdac_ad9775.c


Ignore:
Timestamp:
Jan 26, 2006, 3:34:36 PM (18 years ago)
Author:
andreat
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • warpdac_ad9775.c

    v38 v39  
    1111== Functions ==
    1212
    13 For all functions the input variable ''baseaddr'' is the base address of the SPI Core.
     13For all functions the input variable ''baseaddr'' is the base address of the SPI Core.  The variable ''dacs'' is one hot encoded such that the eighth most significant bit refers to the fourth DAC, the seventh most significant to the third DAC, the sixth to the second DAC, and the fifth to the first.  For example 0x0080 would indicate the fourth DAC, 0x0010 the first, and 0x0050 the first and third together.
    1414
    1515'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L110 void WarpDac_InitializeSPI(unsigned int* baseaddr)]'''
     
    1717
    1818'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L120 void WarpDac_InitializeDAC(unsigned int* baseaddr, unsigned char dacs)]'''
    19 [[BR]]This function must be called at the beginning of the program to make necessary changes in some of the registers of the DAC.  Initializes the DACs specified in ''dacs'', the 8 bit value where the 4 least significant bits choose the DAC to initialize.
     19[[BR]]This function must be called at the beginning of the program to make necessary changes in some of the registers of the DAC.  Initializes the DACs specified in ''dacs'', the 8 bit value where the 4 most significant bits choose the DAC to initialize.
    2020
    2121'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L144 void WarpDac_Reset(unsigned int* baseaddr, unsigned char dacs)]'''
    22 [[BR]]Resets the DAC registers to their default values.  Calls WarpDac_InitializeDAC, so there is no need to repeat it in the code.  ''dacs'' is an 8 bit value where the 4 least significant bits choose the DAC to reset. 
     22[[BR]]Resets the DAC registers to their default values.  Calls WarpDac_InitializeDAC, so there is no need to repeat it in the code.  ''dacs'' is an 8 bit value where the 4 most significant bits choose the DAC to reset. 
    2323
    2424'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L158 int WarpDac_Sleep(unsigned int* baseaddr, char mode, unsigned char dacs)]'''
    25 [[BR]]Will take the specified DACs either in (''mode=1'') or out (''mode=0'') of sleep mode.  ''dacs'' is an 8 bit value where the 4 least significant bits choose the DAC to alter. 
     25[[BR]]Will take the specified DACs either in (''mode=1'') or out (''mode=0'') of sleep mode.  ''dacs'' is an 8 bit value where the 4 most significant bits choose the DAC to alter. 
    2626
    2727'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L206 int WarpDac_FineGainAdj(unsigned int* baseaddr, char chan, unsigned char value, unsigned char dacs)]'''
    28 [[BR]]Adjusts the fine gain of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value''.  ''dacs'' is an 8 bit value where the 4 least significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful.
     28[[BR]]Adjusts the fine gain of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value''.  ''dacs'' is an 8 bit value where the 4 most significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful.
    2929
    3030'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L256 int WarpDac_CoarseGainAdj(unsigned int* baseaddr, char chan, unsigned char value, unsigned char dacs)]'''
    31 [[BR]]Adjusts the coarse gain of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value'' which has a range from 0 to 15.  ''dacs'' is an 8 bit value where the 4 least significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful. 
     31[[BR]]Adjusts the coarse gain of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value'' which has a range from 0 to 15.  ''dacs'' is an 8 bit value where the 4 most significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful. 
    3232
    3333'''[source:/PlatformSupport/WARP_Libraries/warpdac_ad9775.c@latest#L306 int WarpDac_OffsetAdj(unsigned int* baseaddr, char chan, short value, unsigned char dacs)]'''
    34 [[BR]]Adjusts the DC offset of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value'' which has a range from -1024 to 1023.  ''dacs'' is an 8 bit value where the 4 least significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful. 
     34[[BR]]Adjusts the DC offset of either the I (''chan=ICHAN'') or the Q (''chan=QCHAN'') channel.  The magnitude of adjustment is specified in the variable ''value'' which has a range from -1024 to 1023.  ''dacs'' is an 8 bit value where the 4 most significant bits choose the DAC to alter.  Returns ''INVALID_MODE'' if the mode is incorrect. Returns ''WARP_SUCCESS'' if change is successful.