Beamline Instrument Software Support |
|
SPEC Macro documentation:
[ Macro Index |
BCU Home ]
|
ADC.MAC | ||||||
[ source code | installed at | configured at ] | ||||||
See other macros in category: Generic I/O | ||||||
Description:
| ||||||
Documentation:
This macro set provides an easier interface to work with the ADAS ADC card. You can configure the ADC as a counter or monitor and use the standard SPEC macros to work with this card. The new version of these macros will read the ADC during counting and calculate the average value during this time. You need to define a timer therefore (use the UNIX software timer if you don't have another one) EXAMPLE SETUP ATTENTION DEPENDENCIES | ||||||
Macros:
Usage: adcwatch [s]: Like adcmread but the results will be plotted adcread Usage: adcread [Channel] reads from Channel or DEFAULT channel given in adcsetup adcscale Usage: adcscale [scale] Defines a global scale factor, every adc has to be multiplied with Default is 1000 to give mV output adcsetup Usage: adcsetup [mne device channel] [mne device channel] ... The new version allows multiple devices to be used. The input format had to be changed therefore, but the macros still accept the old input format: [device name] [channel] [No. of channels] [gain] [No. reads] Parameters: device name : the name of your device (ex.: ID112Adc) channel : the channel to read from (0-n) No. of channels : number of channels to be read from the ADC card. gain : the gain is given in power of 2. If the range of your card is -10 to 10 V then: gain 0 : -10 -> 10 V gain 1 : -5 -> 5 V gain 2 : -2.5 -> 2.5 V gain 3 : -1.25 -> 1.25 V gain 4 : -0.63 -> 0.63 V Whatever gain you will set, the value you read are always in Volt No. reads : the number of reads for the multiple read commandThe questions asked if you do not supply input parameters on the command line : How many ADC pseudo counters do you want to define Counter mnemonic (the counter mnemonic) Device name for pseudo counter (the ESRF device server) Channel on this ADC card (channel starts with 0) adcoff Usage: adcoff Switches off all adc related in/output adcon Usage: adcon Switches on all adc related in/output (after adcoff) adcstart Usage: adcstart : starts the Adc for cont. reading adcstop Usage: adcstop : stops the Adc | ||||||
Internal Macros: | ||||||
Usage: adc_allprecount adc_precount Usage: adc_precount adc_allgetcounts Usage: adc_allgetcounts adc_getcounts Usage: adc_getcounts adc_mreadstart Usage: adc_mreadstart adc_mread Usage: adc_mread adc_init Usage: adc_init Sends the global values for adc min and max to the device. adcsetlast Usage: adcsetlast adcgain Usage: adcgain adcminmax Usage: adcminmax | ||||||
|