Basic class for reading SPTE 10 bar 0-5V analog pressure sensor made by Festo
Dependents: heros_leg_readout_torque_addition heros_leg_readout_torque_addition_V3 DROPSAWTestRigCode_V4
Revision 2:f31829b587b4, committed 2020-10-26
- Comitter:
- cnckiwi31
- Date:
- Mon Oct 26 08:31:29 2020 +0000
- Parent:
- 1:189d6f2b0612
- Commit message:
- Prepared for documentation with boilerplate added
Changed in this revision
SPTEPressureSensor.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r 189d6f2b0612 -r f31829b587b4 SPTEPressureSensor.h --- a/SPTEPressureSensor.h Fri Oct 12 12:10:26 2018 +0000 +++ b/SPTEPressureSensor.h Mon Oct 26 08:31:29 2020 +0000 @@ -1,18 +1,34 @@ +/* Copyright 2020 Allan Joshua Veale + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + #ifndef _SPTEPSensor_H_ #define _SPTEPSensor_H_ #include "mbed.h" /** * Reading and nulling the SPTE pressure sensor made by festo (analog input) + * Based on Martijn Grootens' LCM101 class */ class SPTEPressureSensor { public: /** - * @param pin_a_in PinName of analog input - * @param offset of analog value (calibration data) - * @param factor multiplication factor for analog value (calibration data) + * @param pin_a_in: PinName of analog input + * @param offset: of analog value read from the sensor(calibration data) + * @param factor: multiplication factor for analog value read from the sensor(calibration data) */ SPTEPressureSensor(PinName pin_a_in, float offset, float factor) : analog_in_(pin_a_in), @@ -47,7 +63,7 @@ } /** - * @return ffset of analog value + * @return offset of analog value */ float get_offset() { return kOffset_; }