1.Electronic scale information table

Host Model D1w
Measuring range 100g-15kg/30kg(Double range)
Certified division value 5g/10g
Safe overload (%FS) 120
Destroy overload (%FS) 150
Working temperature (℃) -10℃~40℃
Working humidity 10%~85% No condensation
Creep(%FS/30min) +-0.02
Equipment dealer / model 厦门佰伦斯电子 / W23
Porter rate 9600
Access mode Serial(/dev/ttyS4)

2. Measurement quantity related basic knowledge

Boot zero point/zero clearing
After the power on of the electronic scale weighing AD system, read the weight quantity signal and save it as the reference point of boot, namely the boot zero point.
Manual zero clearing
After the electronic scale has obtained the boot zero point, if an article with a range less than 2% of full range is placed on the scale pan, it can be cleared with a command, with a weight quantity of 0.
Tare weight
Tare weight is applied for goods with package. The weight quantity of the package should be excluded when calculating the price. At this time, you may first place the package onto the scale pan, conduct the tare removal operation. Then the weight quantity of the package is namely tare weight. You may also directly input the set package tare weight without weighing.
Weigh with tare removal
It is operated by weighing in and out. Packing the goods on the weighing plate, as a slave weight removed, the net weight should be 0, the slave weight should be the packing weight.
Digital tare removal
Tare removal operation with direct setting input without weighing

3.Electronic scale software development

3.1The method of application

Electronic scale sdk downloads
Binding the electronic scale service to obtain relevant data for the electronic scale
Initialization
Open the serial port and obtain the net weight and state of the electronic scale by means of an interface callback

                  Electronic mElectronic = new Electronic.Builder() //default path .setDevicePath(“/dev/ttyS4”) //default porter rate .setBaudrate(9600) .setReceiveCallback(new ElectronicCallback { @Override public void electronicStatus(String weight, String weightStatus) { //Callback in child thread ... }}) .builder()
Weight Unit:kg
electronic scale state 46:overweight, 53:Normal, 55:unstable, 56:Successful manual peeling, 57: Failure of manual peeling

Get the function of zero clearing and peeling of electronic scale by direct calling method

zero clearing

                  mElectronic.turnZero()

Weigh with tare removal

                  mElectronic.removePeel()

Manual peeling

                  mElectronic.manualPeel(int peelWeight)

Turn off the electronic scale

                  mElectronic.closeElectronic()