Пример #1
0
		AutoDvmReader(double *voltage, const char* txt) :
			client_volts(voltage), client_txt(txt)
		{			
			if (!getVolts(v1)){
				err("failed to read volts, baling out");
				exit(-1);
			}			
		}
Пример #2
0
std::string AI16_DataPoint::toString() const {
	ostringstream out;
	out << "Channel " << dec << setw( 3 ) << setfill( ' ' ) << channel
		<< ", " << setw( 5 ) << counts << " A/D counts"
		<< ", " << setw( 11 ) << setprecision( 7 ) << getVolts() << 'V'
		<< ", " << getRangeText()
		<< ", " << ( differentialMode ? "differential" : "single-ended" );
	return out.str();
}
Пример #3
0
		virtual ~AutoDvmReader() {

			if (!getVolts(v2)){
				err("failed to read volts, baling out");
				exit(-1);	
			}
			*client_volts = (v1 + v2)/2;

			sanityCheck();
			dbg(2, "01 setting client to mean %.4f V", 
							*client_volts);
		}			
void getMD49data (void){
	getSpeed1();
	getSpeed2();
	readEncoderValues();
	getVolts();
	getCurrent1();
	getCurrent2();
	getError();
	getMode();
	getAcceleration();
	i2cdata[31]=statusRegulator;
	i2cdata[32]=statusTimeout;
}