sergiotucano / digital_scale

Repository of Digital Scale flutter package
GNU General Public License v3.0
6 stars 2 forks source link

Close door after getWeight #3

Open Guimarte opened 7 months ago

Guimarte commented 7 months ago

Hi, im tryng make this package work in my software, but i need close the door after read, and after re-open, how can i make this ?

sergiotucano commented 2 months ago

Hi! When the package reads the weight the door is closed:


wait Future.any([
        completer.future,
        Future.delayed(Duration(milliseconds: digitalScaleTimeout))
      ]);

      serialPort.close();

      return 1.0 * weight;