CN108469935A - A kind of method, apparatus and computer readable storage medium of configuration truck scale - Google Patents
A kind of method, apparatus and computer readable storage medium of configuration truck scale Download PDFInfo
- Publication number
- CN108469935A CN108469935A CN201810251699.7A CN201810251699A CN108469935A CN 108469935 A CN108469935 A CN 108469935A CN 201810251699 A CN201810251699 A CN 201810251699A CN 108469935 A CN108469935 A CN 108469935A
- Authority
- CN
- China
- Prior art keywords
- truck scale
- weight data
- configuration
- protocol analysis
- interface
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0484—Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
- G06F3/04847—Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01G—WEIGHING
- G01G19/00—Weighing apparatus or methods adapted for special purposes not provided for in the preceding groups
- G01G19/02—Weighing apparatus or methods adapted for special purposes not provided for in the preceding groups for weighing wheeled or rolling bodies, e.g. vehicles
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Human Computer Interaction (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
The invention discloses a kind of methods of configuration truck scale, including:The truck scale serial port setting that user inputs at serial communication interface is received, according to the serial ports parameter of the truck scale serial port setting truck scale;The truck scale protocol analysis formula that the user inputs at protocol analysis interface is received, the weight data of the truck scale output is parsed according to the truck scale protocol analysis formula.The method of configuration truck scale provided by the invention, the interface at the interface and input truck scale protocol analysis formula of input truck scale serial port setting is provided to Field Force, Field Force is allow to be done directly the configuration to truck scale by the explanation on truck scale specification, without by operation maintenance personnel write special driver debugged, more new system, it is equivalent to the operation and maintenance independently of entire management system by the configuration of truck scale, to reduce the difficulty of configuration truck scale, time and the manpower of configuration truck scale is greatly saved.
Description
Technical field
The present invention relates to metrical instrument fields, can more particularly to the method, apparatus and computer of a kind of configuration truck scale
Read storage medium.
Background technology
Truck scale is also referred to as weighbridge, is the main weighing-appliance that factories and miness, businessman etc. are used for bulk supply tariff metering.Truck scale
Configuration be totally divided into two steps:It selects suitable interface to connect according to the interface type of truck scale, parses truck scale output data
Used agreement is converted to the weight information for being easy to read to write program by the data that truck scale exports.Due to factory
Family is different, production batch is different, and there are many type of truck scale, and the agreement of the weight data of the output of each truck scale is different,
So that needing the department of multiple truck scales for warehouse etc., often increase a new truck scale, is required for collecting truck scale output
Data, analyze data meaning, write special driver, and driver is written in the management system of warehouse entirety,
This is equivalent to the version updating of primary system.
But the process of version updating is very cumbersome, such as intelligent grain depot system generally has hundreds thousand of line codes, updates intelligence
The version of energy grain depot system not only needs the version post staff of profession to participate in, it is also necessary to coordinate various changes, the modification of BUG,
Test in place, can just issue new version, this needs to involve many resources.In addition, after new version publication, using the institute of the system
There is grain depot to be required for more new version, even more involves the consumption of a large amount of external resource.
Therefore, the difficulty of truck scale configuration how is reduced, the efficiency of truck scale configuration is improved, being those skilled in the art needs
Technical problems to be solved.
Invention content
The object of the present invention is to provide a kind of method, apparatus and computer readable storage medium of configuration truck scale, are used for
The difficulty of truck scale configuration is reduced, the efficiency of truck scale configuration is improved.
In order to solve the above technical problems, the present invention provides a kind of method of configuration truck scale, including:
The truck scale serial port setting that user inputs at serial communication interface is received, according to the truck scale serial port setting automobile
The serial ports parameter of weighing apparatus;
The truck scale protocol analysis formula that the user inputs at protocol analysis interface is received, according to the truck scale agreement solution
Analysis formula parses the weight data of the truck scale output.
Optionally, the truck scale protocol analysis formula specifically includes weight data condition for validity expression formula and weight data table
Up to formula.
Optionally, the protocol analysis interface specifically includes:
Weight data condition for validity expression formula input frame, weight data expression formula input frame, operator column and instruction column.
Optionally, further include:
When the weight data is unsatisfactory for the weight data condition for validity, weight is popped up in weight data display interface
The prompt of data invalid.
Optionally, further include:
Convert the weight data expression formula to inverse Polan expression.
Optionally, after described according to the serial ports parameter of the truck scale serial port setting truck scale, further include:
Judge whether that the weight data can be received;
If it is not, then the prompt of pop-up serial ports parameter error.
Optionally, the truck scale serial port setting specifically includes Configuration of baud rate, data bit is arranged, stop position is arranged and strange
Even parity bit is arranged.
In order to solve the above technical problems, the present invention also provides a kind of devices of configuration truck scale, including:
Memory, for storing instruction, described instruction include the step for the method that truck scale is configured described in above-mentioned any one
Suddenly;
Processor, for executing described instruction.
In order to solve the above technical problems, the present invention also provides a kind of computer readable storage medium, it is stored thereon with calculating
Machine program realizes the step for the method that truck scale is configured as described in above-mentioned any one when the computer program is executed by processor
Suddenly.
The method of configuration truck scale provided by the present invention, including:Receive the automobile that user inputs at serial communication interface
Weigh serial port setting, according to the serial ports parameter of the truck scale serial port setting truck scale;The user is received at protocol analysis interface
The truck scale protocol analysis formula of input parses the weight data of the truck scale output according to the truck scale protocol analysis formula.
The method of configuration truck scale provided by the invention provides interface and the input vapour of input truck scale serial port setting to Field Force
The interface of vehicle weighing apparatus protocol analysis formula so that Field Force can be done directly by the explanation on truck scale specification to truck scale
Configuration, without by operation maintenance personnel write special driver debugged, more new system, be equivalent to the configuration of truck scale
Configuration truck scale is greatly saved to reduce the difficulty of configuration truck scale in operation and maintenance independently of entire management system
Time and manpower.The present invention also provides a kind of devices and computer readable storage medium of configuration truck scale, have with above-mentioned
Beneficial effect, details are not described herein.
Description of the drawings
It, below will be to embodiment or existing for the clearer technical solution for illustrating the embodiment of the present invention or the prior art
Attached drawing is briefly described needed in technology description, it should be apparent that, the accompanying drawings in the following description is only this hair
Some bright embodiments for those of ordinary skill in the art without creative efforts, can be with root
Other attached drawings are obtained according to these attached drawings.
Fig. 1 is a kind of flow chart of the method for configuration truck scale provided by the invention;
Fig. 2 is the flow chart of another method for configuring truck scale provided by the invention;
Fig. 3 is a kind of structural schematic diagram of the device of configuration truck scale provided in an embodiment of the present invention.
Specific implementation mode
Core of the invention is to provide a kind of method, apparatus and computer readable storage medium of configuration truck scale, is used for
The difficulty of truck scale configuration is reduced, the efficiency of truck scale configuration is improved.
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation describes, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on
Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other
Embodiment shall fall within the protection scope of the present invention.
Fig. 1 is a kind of flow chart of the method for configuration truck scale provided by the invention.As shown in Figure 1, configuration truck scale
Method includes:
S10:The truck scale serial ports parameter setting that user inputs at serial communication interface is received, according to truck scale serial ports parameter
The serial ports parameter of truck scale is set.
In specific implementation, on serial communication interface, it may provide the user with Configuration of baud rate, data bit setting, stop
Stop bit is arranged and the setting options such as parity check bit setting, and provides initial value, and user is facilitated to debug.
Field Force can select general interface to complete the hardware configuration to truck scale, and according on truck scale specification
Dated serial ports parameter inputs corresponding truck scale serial ports parameter setting or is debugged according to initial value.
After Field Force completes the setting to truck scale serial ports parameter, if setting is correct, it can be shown on interface
Show the weight data received.A kind of format such as following table for the weight data being made of 12 groups of data per frame:
S11:The truck scale protocol analysis formula that user inputs at protocol analysis interface is received, according to truck scale protocol analysis formula
Parse the weight data of the truck scale output.
In specific implementation, truck scale protocol analysis formula can specifically include weight data condition for validity expression formula and weight
Date expression.On protocol analysis interface, weight data condition for validity expression formula input frame, weight number may provide the user with
According to expression formula input frame, operator column and instruction column, input prompt can also be provided.
After Field Force enters protocol analysis interface, relevant vapour can be inputted according to the format of the data frame received
Vehicle weighing apparatus protocol analysis formula.For upper table, corresponding expression formula is:
Weight data condition for validity expression formula:
Weight data expression formula=(DByte [3] * 100000)+(DByte [4] * 10000)+(DByte [5] * 1000)+
(DByte[6]*100)+(DByte[7]*10)+DByte[8]
After personnel input above formula at protocol analysis interface at the scene, above formula is preserved and in the course of work of truck scale later
In, judge whether weight data is effective according to weight data condition for validity expression formula, is then calculated according to weight data expression formula
Weight data, and the weight data obtained after the display of weight data display interface calculates.
Further, when parsing weight data, if the weight data in data frame is unsatisfactory for weight data condition for validity,
The invalid prompt of weight data can be popped up on weight data display interface, so that user checks.
Optionally, judge and calculate in order to facilitate computer, weight data expression formula can be converted to the expression of head sea orchid
Formula is stored in systems in the form of inverse Polan expression.It is as follows that above-mentioned weight data expression formula is converted to inverse Polan expression:
DByte[3]100000*DByte[4]10000*+DByte[5]1000*+DByte[6]100*+DByte[7]10*+
DByte[8]+
The method of configuration truck scale provided by the invention provides input truck scale serial ports parameter setting to Field Force
The interface at interface and input truck scale protocol analysis formula so that Field Force can be direct by the explanation on truck scale specification
Complete configuration to truck scale, without by operation maintenance personnel write special driver debugged, more new system, be equivalent to by
The configuration of truck scale is greatlyd save independently of the operation and maintenance of entire management system to reduce the difficulty of configuration truck scale
The time of configuration truck scale and manpower.
Fig. 2 is the flow chart of another method for configuring truck scale provided by the invention.As shown in Fig. 2, in above-mentioned implementation
On the basis of example, in another embodiment, further include after step slo:
S20:Judge whether that weight data can be received;If it is, entering step S11;If it is not, then entering step S21.
S21:Pop up the prompt of serial ports parameter error.
In view of the explanation about serial ports parameter on the specification of truck scale is unclear, Field Force is merely able to pass through debugging
The case where serial ports parameter is arranged, in order to give the intuitive information of Field Force, reduces the judgement work of Field Force, can be by calculating
Machine illustrates serial ports parameter setting mistake to determine whether weight data can be received if being not received by.
The corresponding each embodiment of method of configuration truck scale as detailed above, on this basis, the invention also discloses
The device of configuration truck scale corresponding with the above method.
Fig. 3 is a kind of structural schematic diagram of the device of configuration truck scale provided in an embodiment of the present invention.As shown in figure 3, should
Bigger difference can be generated because configuration or performance are different by configuring the device of truck scale, may include at one or more
Device (central processing units, CPU) 310 (for example, one or more processors) and memory 320 is managed,
The storage medium 330 of one or more storage application programs 333 or data 332 (such as deposit by one or more magnanimity
Store up equipment).Wherein, memory 320 and storage medium 330 can be of short duration storage or persistent storage.It is stored in storage medium 330
Program may include one or more modules (diagram does not mark), each module may include to one in computing device
Series of instructions operates.Further, processor 310 could be provided as communicating with storage medium 330, in the dress of configuration truck scale
Set the series of instructions operation executed on 300 in storage medium 330.
The device 300 for configuring truck scale can also include one or more power supplys 340, one or more are wired
Or radio network interface 350, one or more input/output interfaces 330, and/or, one or more operating systems
331, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM etc..
Step in software performance testing method described in above-mentioned Fig. 1 to Fig. 2 is based on by the device of configuration truck scale should
Structure shown in Fig. 3 is realized.
It is apparent to those skilled in the art that for convenience and simplicity of description, the configuration of foregoing description
The device of truck scale and the specific work process of computer readable storage medium can refer to the correspondence in preceding method embodiment
Process, details are not described herein.
In several embodiments provided herein, it should be understood that disclosed method, apparatus and computer-readable
Storage medium may be implemented in other ways.For example, the apparatus embodiments described above are merely exemplary, example
Such as, the division of module, only a kind of division of logic function, formula that in actual implementation, there may be another division manner, for example (,) it is multiple
Module or component can be combined or can be integrated into another system, or some features can be ignored or not executed.It is another
Point, shown or discussed mutual coupling, direct-coupling or communication connection can be by some interfaces, device or
The INDIRECT COUPLING of module or communication connection can be electrical, machinery or other forms.The module illustrated as separating component can
It is physically separated with being or may not be, the component shown as module may or may not be physics mould
Block, you can be located at a place, or may be distributed on multiple network modules.It can be selected according to the actual needs
In some or all of module achieve the purpose of the solution of this embodiment.
In addition, each function module in each embodiment of the application can be integrated in a processing module, it can also
That modules physically exist alone, can also two or more modules be integrated in a module.Above-mentioned integrated mould
The form that hardware had both may be used in block is realized, can also be realized in the form of software function module.
If integrated module is realized and when sold or used as an independent product in the form of software function module, can
To be stored in a computer read/write memory medium.Based on this understanding, the technical solution of the application substantially or
Say that all or part of the part that contributes to existing technology or the technical solution can embody in the form of software products
Out, which is stored in a storage medium, including some instructions are used so that a computer equipment
(can be personal computer, funcall device or the network equipment etc.) executes the whole of each embodiment method of the application
Or part steps.And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (Read-Only Memory,
ROM), random access memory (Random Access Memory, RAM), magnetic disc or CD etc. are various can store program
The medium of code.
Above to it is provided by the present invention it is a kind of configuration truck scale method, apparatus and computer readable storage medium carry out
It is discussed in detail.Each embodiment is described by the way of progressive in specification, the highlights of each of the examples are with its
The difference of his embodiment, just to refer each other for identical similar portion between each embodiment.For being filled disclosed in embodiment
For setting, since it is corresponded to the methods disclosed in the examples, so description is fairly simple, related place is referring to method part
Explanation.It should be pointed out that for those skilled in the art, in the premise for not departing from the principle of the invention
Under, it can be with several improvements and modifications are made to the present invention, these improvement and modification also fall into the protection of the claims in the present invention
In range.
It should also be noted that, in the present specification, relational terms such as first and second and the like be used merely to by
One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation
Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning
Covering non-exclusive inclusion, so that the process, method, article or equipment including a series of elements includes not only that
A little elements, but also include other elements that are not explicitly listed, or further include for this process, method, article or
The intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence "including a ...", is not arranged
Except there is also other identical elements in the process, method, article or apparatus that includes the element.
Claims (9)
1. a kind of method of configuration truck scale, which is characterized in that including:
The truck scale serial port setting that user inputs at serial communication interface is received, according to the truck scale serial port setting truck scale
Serial ports parameter;
The truck scale protocol analysis formula that the user inputs at protocol analysis interface is received, according to the truck scale protocol analysis formula
Parse the weight data of the truck scale output.
2. according to the method described in claim 1, it is characterized in that, the truck scale protocol analysis formula specifically includes weight data
Condition for validity expression formula and weight data expression formula.
3. according to the method described in claim 2, it is characterized in that, the protocol analysis interface specifically includes:
Weight data condition for validity expression formula input frame, weight data expression formula input frame, operator column and instruction column.
4. according to the method described in claim 2, it is characterized in that, further including:
When the weight data is unsatisfactory for the weight data condition for validity, weight data is popped up in weight data display interface
Invalid prompt.
5. according to the method described in claim 2, it is characterized in that, further including:
Convert the weight data expression formula to inverse Polan expression.
6. according to the method described in claim 1, it is characterized in that, described according to the truck scale serial port setting truck scale
After serial ports parameter, further include:
Judge whether that the weight data can be received;
If it is not, then the prompt of pop-up serial ports parameter error.
7. according to the method described in claim 1, it is characterized in that, the truck scale serial port setting specifically includes baud rate and sets
It sets, data bit setting, stop position is arranged and parity check bit setting.
8. a kind of device of configuration truck scale, which is characterized in that including:
Memory, for storing instruction, described instruction include the method that truck scale is configured described in claim 1 to 7 any one
The step of;
Processor, for executing described instruction.
9. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the computer program quilt
The step of method that truck scale is configured as described in claim 1 to 7 any one is realized when processor executes.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810251699.7A CN108469935A (en) | 2018-03-26 | 2018-03-26 | A kind of method, apparatus and computer readable storage medium of configuration truck scale |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810251699.7A CN108469935A (en) | 2018-03-26 | 2018-03-26 | A kind of method, apparatus and computer readable storage medium of configuration truck scale |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108469935A true CN108469935A (en) | 2018-08-31 |
Family
ID=63265749
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810251699.7A Pending CN108469935A (en) | 2018-03-26 | 2018-03-26 | A kind of method, apparatus and computer readable storage medium of configuration truck scale |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108469935A (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102148825A (en) * | 2011-01-28 | 2011-08-10 | 清华大学 | Method and device for configuring and analysing dynamic protocol |
CN102930706A (en) * | 2012-11-12 | 2013-02-13 | 武钢集团昆明钢铁股份有限公司 | Remote concentration measurement multi-protocol data acquisition system and method |
CN105867940A (en) * | 2016-04-19 | 2016-08-17 | 浪潮通用软件有限公司 | Method for reading wagon balance weighing displayer based on java |
CN106878798A (en) * | 2017-01-18 | 2017-06-20 | 环球智达科技(北京)有限公司 | A kind of scheme of the dynamic interface allocation of intelligent television |
CN107643932A (en) * | 2017-08-31 | 2018-01-30 | 深圳天珑无线科技有限公司 | A kind of collecting method, harvester and storage device |
-
2018
- 2018-03-26 CN CN201810251699.7A patent/CN108469935A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102148825A (en) * | 2011-01-28 | 2011-08-10 | 清华大学 | Method and device for configuring and analysing dynamic protocol |
CN102930706A (en) * | 2012-11-12 | 2013-02-13 | 武钢集团昆明钢铁股份有限公司 | Remote concentration measurement multi-protocol data acquisition system and method |
CN105867940A (en) * | 2016-04-19 | 2016-08-17 | 浪潮通用软件有限公司 | Method for reading wagon balance weighing displayer based on java |
CN106878798A (en) * | 2017-01-18 | 2017-06-20 | 环球智达科技(北京)有限公司 | A kind of scheme of the dynamic interface allocation of intelligent television |
CN107643932A (en) * | 2017-08-31 | 2018-01-30 | 深圳天珑无线科技有限公司 | A kind of collecting method, harvester and storage device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107861713A (en) | Data calling method, device and computer-readable recording medium | |
CN108073688B (en) | Data migration method and device | |
CN107992403B (en) | IO performance test method, device, equipment and computer readable storage medium | |
CN108170425B (en) | Program code modification method and device and terminal equipment | |
CN109871368B (en) | Database detection method, database detection device, computer device and storage medium | |
CN107094086A (en) | A kind of information acquisition method and device | |
CN116502273B (en) | Dynamic data desensitization method, device and equipment based on data blood edges | |
CN105302730A (en) | Calculation model detection method, testing server and service platform | |
CN101984415A (en) | Method and device for setting monitoring index threshold | |
CN109800022A (en) | A kind of method, system, terminal and the storage medium of automation comparison BIOS information difference | |
CN106293687A (en) | The control method of a kind of flow process of packing, and device | |
CN110032513B (en) | Data verification method and device and electronic equipment | |
CN104636529A (en) | Circuit design simulation system of printed circuit board and circuit design method thereof | |
CN108469935A (en) | A kind of method, apparatus and computer readable storage medium of configuration truck scale | |
CN112027111A (en) | Real-time acquisition and display method and system for aircraft bus data | |
CN107346255A (en) | A kind of electric energy meter system upgrade method and electric energy meter system | |
CN107844490A (en) | A kind of database divides storehouse method and device | |
CN107704362A (en) | A kind of method and device based on Ambari monitoring big data components | |
CN109657317A (en) | A kind of method, system and the equipment of CPLD pin assignments | |
CN110737707A (en) | Multi-system log searching method and device and computer readable storage medium | |
CN115437663A (en) | Upgrade strategy updating method and device, electronic equipment, storage medium and vehicle | |
CN109408577A (en) | ORACLE database JSON analytic method, system, device and can storage medium | |
CN110895460A (en) | Jenkins-based robot system integration method and device and terminal equipment | |
CN107239359A (en) | A kind of method that server master board internal memory signal quality is checked by BMC | |
CN109144624A (en) | Method, storage medium, equipment and the system of not contour list are shown in IOS |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180831 |
|
RJ01 | Rejection of invention patent application after publication |