Cathode potential bias with respect of MCP.
(self)
| 169 | |
| 170 | @Feat(units='volt', limits=(-50, 50)) |
| 171 | def average_voltage(self): |
| 172 | """Cathode potential bias with respect of MCP. |
| 173 | """ |
| 174 | if self.revision >= 2.0: |
| 175 | ans = self.query_expect('AVE ?') |
| 176 | ans = between(ans, 'AVE ?', 'ok') |
| 177 | return float(ans.strip()) / 10. |
| 178 | else: |
| 179 | ans = self.query_expect('THRESHV @ .')[8:] |
| 180 | try: |
| 181 | pos = ans.index('.') |
| 182 | except ValueError: |
| 183 | raise InstrumentError('Unsupported operation.') |
| 184 | return float(ans[pos+2:pos+7]) / 10. |
| 185 | |
| 186 | @average_voltage.setter |
| 187 | def average_voltage(self, value): |
nothing calls this directly
no test coverage detected