copierter Code

This commit is contained in:
Manuel Weiser 2018-05-19 21:50:19 +02:00
parent 4f85897c01
commit be41a906bb

View File

@ -1,9 +1,16 @@
#include <Arduino.h> #include <Arduino.h>
#include <HX711.h>
// Scale Settings
const int SCALE_DOUT_PIN = D2;
const int SCALE_SCK_PIN = D3;
HX711 scale(SCALE_DOUT_PIN, SCALE_SCK_PIN);
void setup() { void setup() {
// put your setup code here, to run once: Serial.begin(115200);
scale.set_scale();// <- set here calibration factor!!!
scale.tare();
} }
void loop() { void loop() {
// put your main code here, to run repeatedly: float weight = scale.get_units(1);
Serial.println(String(weight, 2));
} }