diff options
author | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-14 11:57:55 +0100 |
---|---|---|
committer | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-14 11:57:55 +0100 |
commit | 0e40d8791f5fa2081a76fa9a03bef6e189dbec0e (patch) | |
tree | ac4c079dd772ff4669562a6f6853bc5f4fda5391 /src/cameras | |
parent | b1b747d9f0f1065a6078dfc788fff60109fc007e (diff) | |
download | uca-0e40d8791f5fa2081a76fa9a03bef6e189dbec0e.tar.gz uca-0e40d8791f5fa2081a76fa9a03bef6e189dbec0e.tar.bz2 uca-0e40d8791f5fa2081a76fa9a03bef6e189dbec0e.tar.xz uca-0e40d8791f5fa2081a76fa9a03bef6e189dbec0e.zip |
Add gain modes
Diffstat (limited to 'src/cameras')
-rw-r--r-- | src/cameras/ipe.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/cameras/ipe.c b/src/cameras/ipe.c index a2308ad..193091a 100644 --- a/src/cameras/ipe.c +++ b/src/cameras/ipe.c @@ -46,6 +46,32 @@ static uint32_t uca_ipe_get_property(struct uca_camera_t *cam, enum uca_property set_void(data, uint32_t, (uint32_t) value); break; + case UCA_PROP_PGA_GAIN: + pcilib_read_register(handle, NULL, "pga", &value); + set_void(data, uint32_t, (uint32_t) value); + break; + + case UCA_PROP_PGA_GAIN_MIN: + set_void(data, uint32_t, 0); + break; + + case UCA_PROP_PGA_GAIN_MAX: + set_void(data, uint32_t, 3); + break; + + case UCA_PROP_ADC_GAIN: + pcilib_read_register(handle, NULL, "adc_gain", &value); + set_void(data, uint32_t, (uint32_t) value); + break; + + case UCA_PROP_ADC_GAIN_MIN: + set_void(data, uint32_t, 32); + break; + + case UCA_PROP_ADC_GAIN_MAX: + set_void(data, uint32_t, 55); + break; + default: return UCA_ERR_PROP_INVALID; } |