syntax |
example |
output |
result = sampler(nsamples, freq, /dual) | v = sampler(4096, 1e6, /dual) | A one (or two) by nsamples array of voltages will be saved in v. |
parameters | definition | limits for required parameters, default behavior for optional keywords | ||||
nsamples (REQUIRED) | number of samples to record | Limits: 0 < n < 262144 | ||||
freq (REQUIRED) | sampling frequency |
|
||||
dual (optional) | to get two channels of data | one channel of data is saved |
syntax |
example |
output |
samptext, n, f, /dual, /lo, /integer, filename='samples.txt' | samptext, 128, 10e6, /dual, /lo, /integer, filename='samples.txt' | A text file will be saved with one or two columns of numbers that are the measured voltages. |
parameters | definition | limits for required parameters, default behavior for optional keywords | ||||
n (REQUIRED) | number of samples to record | Limits: 0 < n < 262144 | ||||
f (REQUIRED) | sampling frequency |
|
||||
dual (optional) | to get two channels of data | one channel of data is saved | ||||
lo (optional) |
"lo"="Low Voltage" - for
voltages within +/- 1 V
"lo" mode can increase the resolution when samping low voltages |
The sampler measures the range
+/- 5V |
||||
integer (optional) | "integer' mode is faster and
uses the following scale: (0 to 4095) = (-5V to 5V) or (0 to 4095) = (-1V to 1V) if the "lo" keyword is used |
Decimal
values are saved for voltages. (-5.0 to 5.0) with resolution = (10.0 V / 4096) or (-1.0 to 1.0) with resolution = (2.0 V / 4096) |
||||
filename (optional) | location of stored data | file saved as "data.txt" |