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.
Dependents: torque_calibration_ywsim
Diff: HX711.cpp
- Revision:
- 4:d7a5cd03ed09
- Parent:
- 3:d246aa415f3a
- Child:
- 5:4f34d26cc9e7
--- a/HX711.cpp Tue Sep 12 15:33:33 2017 +0000
+++ b/HX711.cpp Wed Sep 13 09:11:22 2017 +0000
@@ -423,7 +423,8 @@
*
* @author Manuel Caballero
* @date 12/September/2017
- * @version 12/September/2017 The ORIGIN
+ * @version 13/September/2017 Adapt the scale was fixed, myFactor now works as expected.
+ * 12/September/2017 The ORIGIN
* @pre NaN.
* @warning NaN.
*/
@@ -433,7 +434,7 @@
float m, w_zs;
float c_zs, w_fs, c_fs, w_t;
float c = 0;
- float myFactor = 0;
+ float myFactor = 1.0;
Vector_mass_t w;
@@ -442,7 +443,7 @@
switch ( myScaleCalibratedMass ) {
default:
case HX711_SCALE_kg:
- myFactor = 1.0;
+ // myFactor = 1.0;
break;
case HX711_SCALE_g: