Skip to content

Commit

Permalink
#1 atualiza get_units()
Browse files Browse the repository at this point in the history
  • Loading branch information
ErickGiffoni committed May 22, 2019
1 parent a2d39df commit 7c6b8b9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions calibragem1.ino
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ void loop() {

void calibrar_balanca(HX711 balanca,float calibracao_fator){
balanca.set_scale(fator_de_calibracao);
aux = balanca.get_unit();
aux = balanca.get_units();
if(aux > peso){
do{
calibracao_fator++;
balanca.set_scale(calibracao_fator);
aux = balanca.get_unit();
aux = balanca.get_units();

}while(aux>peso)
serial.print(calibracao_fator);
Expand All @@ -42,7 +42,7 @@ void calibrar_balanca(HX711 balanca,float calibracao_fator){
do{
calibracao_fator--;
balanca.set_scale(calibracao_fator);
aux = balanca.get_unit();
aux = balanca.get_units();
}while(aux< peso)

serial.print(calibracao_fator);
Expand Down

0 comments on commit 7c6b8b9

Please sign in to comment.