Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: xtoff2 RF24Network mbed
Fork of xtoff3 by
LoadCell.h
00001 #ifndef LoadCell_h 00002 #define LoadCell_h 00003 00004 #include "mbed.h" 00005 #include "Maths.h" 00006 00007 class LoadCell 00008 { 00009 private: 00010 AnalogIn ain; 00011 int SAMPLE_AMOUNT; 00012 float CALIBRATION_MASS; 00013 float TARE_VALUE; 00014 float CALIBRATION_VALUE; 00015 float OFFSET; 00016 float DOWN_OFFSET; 00017 00018 00019 public: 00020 LoadCell(PinName pin); 00021 float analogRead(); 00022 float simpleAnalogRead(); 00023 float calculateMass(float value); 00024 float tare(); 00025 float tareDown(); 00026 float callibrate(); 00027 float mass(); 00028 float simpleMass(); 00029 void setCalibrationMass(int); 00030 void setSampleAmount(int); 00031 00032 }; 00033 00034 #endif 00035 00036 00037 00038 00039
Generated on Tue Jul 19 2022 01:01:54 by
