CN113190259B - Data programming method and device, internet module and storage medium - Google Patents

Data programming method and device, internet module and storage medium Download PDF

Info

Publication number
CN113190259B
CN113190259B CN202110540825.2A CN202110540825A CN113190259B CN 113190259 B CN113190259 B CN 113190259B CN 202110540825 A CN202110540825 A CN 202110540825A CN 113190259 B CN113190259 B CN 113190259B
Authority
CN
China
Prior art keywords
data
programmed
programming
terminal
internet
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.)
Active
Application number
CN202110540825.2A
Other languages
Chinese (zh)
Other versions
CN113190259A (en
Inventor
李光
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Aux Air Conditioning Co Ltd
Ningbo Aux Electric Co Ltd
Original Assignee
Aux Air Conditioning Co Ltd
Ningbo Aux Electric Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Aux Air Conditioning Co Ltd, Ningbo Aux Electric Co Ltd filed Critical Aux Air Conditioning Co Ltd
Priority to CN202110540825.2A priority Critical patent/CN113190259B/en
Publication of CN113190259A publication Critical patent/CN113190259A/en
Application granted granted Critical
Publication of CN113190259B publication Critical patent/CN113190259B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/654Updates using techniques specially adapted for alterable solid state memories, e.g. for EEPROM or flash memories
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1004Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's to protect a block of data words, e.g. CRC or checksum
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/70Services for machine-to-machine communication [M2M] or machine type communication [MTC]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Quality & Reliability (AREA)
  • Selective Calling Equipment (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention relates to the technical field of air conditioners, and provides a data programming method, a device, an internet module and a storage medium, wherein the method comprises the following steps: when the internet of things module powers off and then powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, verifying the data to be programmed; and if the data to be programmed passes the verification, re-programming the data to be programmed to the air conditioner. Compared with the prior art, when the Internet of things module is powered off and powered on again in the process of writing data, the Internet of things module can read out the data to be written from the Flash memory and verify the data based on the received writing inquiry command sent by the terminal without intervention of maintenance personnel, so that the re-writing of the data to be written is realized, and the writing efficiency in the scene is improved.

Description

Data programming method and device, internet module and storage medium
Technical Field
The invention relates to the technical field of air conditioners, in particular to a data programming method and device, an internet module and a storage medium.
Background
When a maintainer repairs the air conditioner, the parameter data in the air conditioner is usually required to be reset, in the prior art, the maintainer needs to carry tens of memories with stored data, and select a proper memory from the memories to be connected to a controller of an external machine of the air conditioner, so that great inconvenience is brought to the maintenance work.
In another implementation scheme, the parameter in the air conditioner is rewritten by means of the debugger, so that the purpose of resetting is achieved, but in the process of rewriting, if the air conditioner is powered on again after being suddenly powered off, maintenance personnel are required to reset the debugger and then restart the writing again, and the writing efficiency is low.
Disclosure of Invention
The invention solves the problem of improving the programming efficiency under the condition that the air conditioner is powered on again after being suddenly powered off in the programming process.
In order to solve the above problems, the present invention provides a data programming method, which is applied to an internet of things module in an air conditioner, wherein the internet of things module comprises a Flash memory, the Flash memory stores data to be programmed, and the air conditioner is also in communication with a terminal through the internet of things module, and the method comprises: when the internet of things module powers off and then powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, verifying the data to be programmed; and if the data to be programmed passes the verification, re-programming the data to be programmed to the air conditioner.
Compared with the prior art, the data programming method has the following advantages: the internet of things module in the air conditioner comprises a Flash memory, the Flash memory stores data to be programmed, the air conditioner is also communicated with the terminal through the internet of things module, when the internet of things module is powered off and powered on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, the data to be programmed is verified, if the data to be programmed passes the verification, the data to be programmed is rewritten to the air conditioner, therefore, the intervention of maintenance personnel is not needed when the internet of things module is powered off and powered on again in the process of programming the data, the internet of things module can read the data to be programmed from the Flash memory and verify based on the received programming inquiry command sent by the terminal, and therefore the re-programming of the data to be programmed is realized, and the programming efficiency in the scene is improved.
Further, the step of re-writing the data to be programmed to the air conditioner includes:
if the data to be programmed is successfully programmed, feeding back a programming result of the successful programming to the terminal;
if the data to be programmed fails to be programmed, re-programming the data to be programmed;
if the programming times reach the preset times and programming fails each time, feeding back the programming result of the programming failure to the terminal.
Further, the method further comprises:
receiving a data transmission instruction sent by the terminal, wherein the data transmission instruction is used for starting a flow for transmitting the data to be programmed;
receiving the data to be programmed sent by the terminal based on the data sending instruction;
after the data to be programmed is received, checking the data to be programmed;
if the data to be programmed passes the verification, storing the data to be programmed into the Flash memory and feeding back a verification completion message to the terminal;
and if the data to be programmed does not pass the verification, feeding back a message of verification failure to the terminal.
Further, if the data to be programmed passes the verification, the step of storing the data to be programmed into the Flash memory and feeding back the verification completion message to the terminal further includes:
receiving a data programming instruction sent by the terminal, wherein the data programming instruction is sent by the terminal after receiving a verification completion message fed back by the internet of things module;
and writing the data to be programmed into the air conditioner based on the data writing instruction.
Further, the terminal is also communicatively connected to a database server, and the method further comprises:
receiving a query message sent by the terminal and used for querying the connection state of the internet of things module;
if the internet of things module is locally connected with the terminal, feeding back the connection state of the internet of things module to the terminal based on the query message as a local connection state, so that the terminal acquires the data to be programmed from the database server based on the local connection state;
if the internet of things module is remotely connected with the database server, feeding back the connection state of the internet of things module to the terminal based on the query message to enable the terminal to instruct the database server to send the data to be programmed to the internet of things module based on the remote connection state.
Further, the data to be programmed includes internal machine data, the air conditioner includes an internal machine, and if the data to be programmed passes the verification, the step of re-programming the data to be programmed to the air conditioner further includes:
and if the internal machine data passes the verification, re-programming the internal machine data to the internal machine of the air conditioner.
Further, the to-be-programmed data further includes external machine data, the air conditioner further includes an external machine, the external machine communicates with the internal machine through an internal machine communication line, and if the to-be-programmed data passes the verification, the step of re-programming the to-be-programmed data to the air conditioner further includes:
and if the external machine data passes the verification, re-writing the external machine data to the external machine of the air conditioner through the internal and external machine communication line.
The invention also provides a data programming device, which is applied to an internet of things module in an air conditioner, wherein the internet of things module comprises a Flash memory, the Flash memory stores data to be programmed, the air conditioner is also communicated with a terminal through the internet of things module, and the device comprises:
the receiving module is used for checking the data to be programmed if a programming inquiry command sent by the terminal is received when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner;
and the programming module is used for re-programming the data to be programmed to the air conditioner if the data to be programmed passes the verification.
The invention also provides an internet of things module, which comprises a memory and a processor, wherein the memory comprises a Flash memory, the memory stores a computer program, and the processor realizes the data programming method when executing the computer program.
The present invention also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements a data burning method as described above.
Drawings
Fig. 1 is an exemplary diagram of an application scenario provided by the present invention.
Fig. 2 is a schematic block diagram of an internet of things module according to the present invention.
Fig. 3 is a flowchart of a data writing method provided by the present invention.
Fig. 4 is a flowchart of another data writing method provided by the present invention.
Fig. 5 is a flowchart of another data writing method provided by the present invention.
Fig. 6 is a flowchart of another data writing method provided by the present invention.
Fig. 7 is a flowchart of another data writing method provided by the present invention.
Fig. 8 is a flowchart of another data writing method provided by the present invention.
Fig. 9 is a flowchart of another data writing method provided by the present invention.
Fig. 10 is a block diagram of a data writing device according to the present invention.
Reference numerals illustrate:
10-an internet of things module; 11-a processor; 12-memory; 13-bus; 14-a communication interface; 20-terminal; 30-an air conditioner; 40-a database server; 100-a data programming device; 110-a receiving module; 120-programming module; 130-a query module.
Detailed Description
In order that the above objects, features and advantages of the invention will be readily understood, a more particular description of the invention will be rendered by reference to specific embodiments thereof which are illustrated in the appended drawings.
Referring to fig. 1, fig. 1 is an exemplary diagram of an application scenario provided in the present invention. In fig. 1, an internet of things module 10 is installed in an air conditioner 30, and a terminal 20 and the internet of things module 10 can be connected locally, for example, by a bluetooth technology, or can be connected remotely with a database server, for example, by a wireless network, and the internet of things module 10 can also have both local connection and remote connection. The terminal 20 registers and binds the internet of things module 10 in advance, and the terminal 20 is in communication connection with the database server 40.
As a specific embodiment, when the internet of things module 10 and the terminal 20 are locally connected, if the data needs to be written into the air conditioner 30, the terminal 20 first obtains the data to be written from the database server 40, and sends the data to be written into the internet of things module 10, after the internet of things module 10 receives the data to be written, the data to be written is verified, after the verification is passed, the data to be written into the Flash memory is stored, and a verification completion message is returned to the terminal 20, after the terminal 20 receives the verification completion message, a data writing instruction is sent to the internet of things module 10, and the internet of things module 10 writes the data to be written into the air conditioner 30 based on the data writing instruction.
As another specific embodiment, when the internet of things module 10 and the terminal 20 are connected remotely, if the data needs to be programmed into the air conditioner 30, the terminal 20 sends the model information of the air conditioner to the database server 40, the database server 40 sends the data to be programmed corresponding to the model information to the internet of things module 10, the internet of things module 10 receives, verifies, stores and writes the data the same as the local connection, and finally the data to be programmed is programmed into the air conditioner 30.
As another specific embodiment, when the internet of things module 10 supports both local connection and remote connection, if data needs to be programmed into the air conditioner 30, the internet of things module 10 preferably selects a local connection mode to obtain the data to be programmed, and performs subsequent programming of the data to be programmed.
In the process of programming, the terminal 20 periodically sends a programming query command to the internet of things module 10 to determine whether the internet of things module 10 is programming data, if no response information fed back by the internet of things module 10 is received within a preset time period and the number of queries exceeds a preset number of times, it is determined that programming fails, the preset number of queries herein may be set according to the needs of the actual scene, for example, the preset number of queries may be set to 5.
If the internet of things module 10 is powered off and is consistent with the power-on state, the terminal 20 will finally determine the programming failure. Otherwise, when the internet of things module 10 is powered on again, the internet of things module 10 receives the programming query command sent by the terminal 20, and based on the programming query command, the internet of things module 10 can determine that data programming is being performed before power failure, so that the data to be programmed can be automatically retrieved from the Flash memory, and the data to be programmed can be programmed to the air conditioner 30 again.
The internet of things module 10 can support communication modes such as bluetooth and WIFI, so as to realize communication connection with the terminal 20 or the database server 40.
The terminal 20 may be a mobile terminal such as a cell phone, tablet, notebook, etc.
A programming bus exists between the air conditioner 30 and the internet of things module 10, the programming bus can be an L2C bus, and the internet of things module 10 writes programming data to the air conditioner 30 through the programming bus. The air conditioner 30 may include an inner unit and an outer unit, an inner unit and outer unit communication line exists between the inner unit and the outer unit, the data to be programmed may include inner unit data and outer unit data, the internet of things module 10 writes the inner unit data to the inner unit of the air conditioner 30 through a programming bus, and the internet of things module 10 writes the writing data to the outer unit of the air conditioner 30 through the inner unit and the outer unit communication line.
The database server 40 may be a physical computer or a virtual machine that performs the same function as the physical computer, and the database server 40 may be one computer or a cluster composed of a plurality of computers. The database server 40 stores the programming data of different models of air conditioners.
On the basis of fig. 1, the embodiment of the present invention further provides a block schematic diagram of the internet of things module 10 in fig. 1, referring to fig. 2, fig. 2 is a block schematic diagram of the internet of things module 10 provided by the present invention, and the internet of things module 10 includes a processor 11, a memory 12, a bus 13 and a communication interface 14, where the processor 11, the memory 12 and the communication interface 14 are connected through the bus 13.
The processor 11 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the air conditioning parameter processing method may be completed by an integrated logic circuit of hardware in the processor 11 or an instruction in a software form. The processor 11 may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU for short), a network processor (Network Processor, NP for short), and the like; but may also be a Digital Signal Processor (DSP), application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components.
The memory 12 is used for storing programs, such as the data writing device described above. The data writing device includes at least one software function module which can be stored in the memory 12 in the form of software or firmware (firmware) or solidified in the internet of things module 10. After receiving the execution instruction, the processor 11 executes the program to implement the data programming method disclosed in the following embodiments.
The memory 12 further includes a Flash memory for storing data to be programmed, and because the Flash memory has the characteristic that the data is not lost after power failure, the data to be programmed can still be read from the Flash memory if the internet of things module 10 is powered up again after unexpected power failure in the data programming process.
The communication interfaces 14 may be multiple, and the internet of things module 10 may communicate with other devices such as the air conditioner 30 and the database server 40 through different communication interfaces 14.
On the basis of fig. 1 and 2, an embodiment of the present invention provides a data writing method, which is applied to an internet of things module 10 in fig. 1 and 2, please refer to fig. 3, fig. 3 is a flow chart of the data writing method provided by the present invention, the method includes the following steps:
step S100, when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, the data to be programmed is checked.
In this embodiment, the writing query command may be a query command for knowing whether the data writing is normally performed, which is periodically sent by the terminal 20 to the internet of things module 10 after the internet of things module 10 starts the data writing, where the writing query command can avoid abnormal interruption or abnormal termination of the writing caused by power failure of the internet of things module 10 in the writing process, and the terminal 20 cannot know that the writing is abnormal in time, so that the user cannot be given feedback of the abnormal writing condition in time, and on the other hand, when the internet of things module 10 is powered on again, the writing can be restarted automatically based on the searched writing query command, so that the manual intervention of a maintainer is avoided, and the re-writing efficiency is improved.
As a specific embodiment, after the internet of things module 10 starts data writing for a preset time period (the preset time period may be set according to needs, for example, the preset time period is 30 seconds), if the writing state information returned by the internet of things module 10 is not received, the terminal 20 periodically sends a writing query command to the internet of things module, the query period may be set according to needs, for example, the query period is set to be 5s for one query, if the number of times of query reaches the preset number of times, and if the writing state information fed back by the internet of things module 10 is not received yet, the terminal 20 determines that writing fails here, the preset number of times may be set according to needs, for example, the preset number of times may be set to be 5.
In this embodiment, since the internet of things module 10 is powered off in the programming process, in order to ensure the correctness of the programming data after the internet of things module 10 is powered on again, the data to be programmed in the Flash memory of the internet of things module 10 is checked before the data is re-programmed, so as to avoid that the wrong data to be programmed is programmed to the air conditioner 30, and the data update of the air conditioner 30 fails. As a specific implementation manner, the verification may include an integrity verification of the data to be programmed, and the verification method may be a CRC verification.
Step S110, if the data to be programmed passes the verification, re-programming the data to be programmed to the air conditioner.
In this embodiment, as a specific implementation manner, the writing is performed entirely when the data to be written is re-written after the power-up, regardless of the writing progress during the power-down.
In this embodiment, the internet of things module 10 writes the data to be written into the air conditioner 30 through the writing bus, and in general, the air conditioner includes an EEPROM (Electrically Erasable Programmable read only memory, i.e. an electrically erasable programmable read only memory) memory, which generally stores configuration information related to the air conditioner, such as model parameters stored in an air conditioner internal unit, compressor parameters stored in an air conditioner external unit, and the like. The data to be programmed is programmed into the air conditioner 30, which generally means that the data to be programmed is programmed into the EEPROM memory of the air conditioner 30.
According to the method provided by the embodiment of the invention, when the Internet of things module is powered off and powered on again in the process of writing data, the Internet of things module can read out the data to be written from the Flash memory and check the data based on the received writing inquiry command sent by the terminal without intervention of maintenance personnel, so that the re-writing of the data to be written is realized, and the writing efficiency in the scene is improved.
In this embodiment, in order to make the terminal 20 know the writing result in time, and to improve the success rate of writing by retry after the writing failure, and avoid unnecessary processing of the writing failure, the embodiment of the present invention further provides an implementation manner of feeding back the writing result and processing the writing result after step S110 on the basis of fig. 3, please refer to fig. 4, fig. 4 is a flowchart of another data writing method provided by the present invention, and step S110 further includes the following steps:
in step S120, if the data to be programmed is successfully programmed, a successful programming result is fed back to the terminal.
In step S130, if the writing of the data to be written fails, the data to be written is rewritten.
In step S140, if the number of writing times reaches the preset number of times and each writing fails, the writing result of the writing failure is fed back to the terminal.
In this embodiment, the preset times may be set according to the needs of the actual scenario, for example, the preset times are set to 5 times, if the number of times of programming reaches 2 times and the programming fails for 2 times, the internet of things module 10 stops retrying, does not continue to re-program the data to be programmed, and feeds back the programming result of the programming failure to the terminal 20, so as to avoid untimely feedback of the programming result caused by invalid retrying.
According to the method provided by the embodiment of the invention, when the programming is successful, the programming result of the programming is fed back to the terminal 20 in time, and when the programming is failed, the retry of the preset times is usually performed, so that the success rate of the programming is improved, and unnecessary processing of the programming failure is avoided.
In this embodiment, in order to correctly obtain the data to be programmed before programming the data to be programmed and to ensure the reliability of the data to be programmed, the embodiment of the present invention further provides an implementation manner for obtaining the data to be programmed, please refer to fig. 5, fig. 5 is a flowchart of another data programming method provided by the present invention, the method includes the following steps:
step 200, receiving a data transmission instruction sent by the terminal, wherein the data transmission instruction is used for starting a flow for transmitting data to be programmed.
In this embodiment, the data sending instruction is used to instruct the internet of things module 10 to enter a data receiving state in preparation for receiving the data to be programmed.
Step 210, receiving data to be programmed sent by the terminal based on the data sending instruction.
Step 220, after the data to be programmed is received, checking the data to be programmed.
In this embodiment, the checking of the data to be programmed includes performing integrity checking of the data to be programmed, and the checking mode includes CRC checking.
And 230, if the data to be programmed passes the verification, storing the data to be programmed into a Flash memory and feeding back a verification completion message to the terminal.
In this embodiment, the checked data to be programmed is stored in the Flash memory, and the Flash memory has the characteristic that the data is not lost after power failure, so that the data to be programmed can still be automatically read from the Flash memory for re-programming after the internet of things module is powered up again after abnormal power failure in the programming process.
And step 240, if the data to be programmed fails to pass the verification, feeding back a message of failure verification to the terminal.
On the basis of fig. 5, the embodiment of the present invention further provides a specific implementation manner of writing the verified data to be written into the air conditioner 30, referring to fig. 6, fig. 6 is a flowchart of another data writing method provided by the present invention, and the method further includes the following steps:
step 250, a data programming instruction sent by the terminal is received, wherein the data programming instruction is sent by the terminal after receiving a message of checking completion fed back by the internet of things module.
In this embodiment, after receiving the verification completion message fed back by the internet of things module 10, the terminal 20 sends a data programming instruction to the internet of things module 10 to instruct the internet of things module 10 to start data programming.
Step 260, based on the data writing instruction, writing the data to be written into the air conditioner.
According to the method provided by the embodiment of the invention, the user can automatically write the data through the terminal 20 and the Internet of things module 10, the data can be completed without a third-party tool, the operation is convenient and quick for the user or a maintainer, the simple operation of fault maintenance and data writing can be even completed by the user, and the maintenance efficiency of the air conditioner 30 is greatly improved.
In this embodiment, the connection state of the internet of things module 10 may be local connection or remote connection, or may be both local connection and remote connection, so as to obtain data to be programmed according to different connection states in different manners, and the embodiment of the present invention further provides a specific implementation manner of obtaining the data to be programmed, referring to fig. 7, fig. 7 is a flowchart of another data programming method provided by the present invention, where the method includes the following steps:
step 300, receiving a query message sent by a terminal and used for querying the connection state of the internet of things module.
In this embodiment, the internet of things module may be a WiFi module, a bluetooth module, or a dual mode combination module of a WiFi module and a bluetooth module.
In this embodiment, the connection state of the internet of things module includes a local connection state and a remote connection state, in the local connection state, the internet of things module 10 and the terminal 20 can not communicate with the database server, and in the remote connection state, the internet of things module 10 can communicate with the terminal 20 or the database server.
In step 310, if the internet of things module is locally connected to the terminal, the connection state of the internet of things module is fed back to the terminal as the local connection state based on the query message, so that the terminal obtains the data to be programmed from the database server based on the local connection state.
In this embodiment, the terminal 20 and the internet of things module 10 are registered and bound in advance, the terminal 20 may obtain configuration information of the air conditioner 30, where the configuration information includes a model number, network information, and the like of the air conditioner 30, and a configuration information obtaining manner may be input by a user at the terminal 20, may be obtained by scanning a two-dimensional code of the air conditioner 30, or may be obtained by querying a controller of the air conditioner 30 through the internet of things module 10.
It should be noted that, one terminal 20 may be bound with one internet of things module 10, or may be bound with a plurality of internet of things modules 10, and when bound with a plurality of internet of things modules 10, a plurality of users may actually log in the terminal 20, and each user is bound with one internet of things module 10.
In this embodiment, the internet of things module 10 feeds back to the terminal 20 that the connection state of the internet of things module 10 is a local connection state, after the terminal 20 obtains the local connection state of the internet of things module 10, the terminal sends the model information of the air conditioner 30 to the database server 40, the database server 40 obtains the data to be programmed matched with the model information according to the model information, and returns the data to the terminal 20, and the terminal 20 sends the data to be programmed to the internet of things module 10 to instruct the internet of things module 10 to perform subsequent verification, storage and programming on the data to be programmed.
Step 320, if the internet of things module is remotely connected to the database server, feeding back the connection state of the internet of things module to the terminal based on the query message to be the remote connection state, so that the terminal instructs the database server to send the data to be programmed to the internet of things module based on the remote connection state.
In this embodiment, after the terminal 20 obtains the remote connection state of the internet of things module 10, it sends the model information of the air conditioner 30 to the database server 40, and instructs the database server 40 to send the data to be programmed, which matches the model information, to the internet of things module 10 bound with the terminal 20.
It should be noted that, if the internet of things module 10 supports both local connection and remote connection, the data to be programmed is preferentially obtained by adopting the local connection mode.
In this embodiment, the air conditioner 30 includes an internal unit, and the embodiment of the invention further provides a method for writing data to the internal unit, referring to fig. 8, fig. 8 is a flowchart of another method for writing data provided by the invention, the method includes the following steps:
step S400, if the internal machine data passes the verification, the internal machine data is re-written into the internal machine of the air conditioner.
In this embodiment, the internal machine data includes, but is not limited to, coil temperature, etc.
In this embodiment, the air conditioner 30 includes an external unit, and the embodiment of the invention further provides a method for writing data to the external unit, please refer to fig. 9, fig. 9 is a flowchart of another method for writing data provided by the invention, the method includes the following steps:
and step S500, if the external machine data passes the verification, re-writing the external machine data to the external machine of the air conditioner through the internal and external machine communication line.
In this embodiment, the external machine data includes, but is not limited to, compressor parameters and the like.
In order to perform the above embodiments and the corresponding steps in each possible implementation, an implementation of data writing is given below. Referring to fig. 10, fig. 10 is a schematic diagram of functional modules of a data writing device 100 according to the present invention. It should be noted that, in the data writing device 100 according to the embodiment of the present invention, the basic principle and the technical effects thereof are the same as those of the foregoing method embodiment, and for brevity, reference may be made to the corresponding content of the foregoing method embodiment for the description of the present invention. The data writing device 100 will be described with reference to fig. 3 to 9, and the data writing device 100 includes: the device comprises a receiving module 110, a programming module 120 and a query module 130.
The receiving module 110 is configured to verify the data to be programmed if a programming query command sent by the terminal is received when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner.
As a specific implementation manner, the receiving module 110 is further configured to receive a data sending instruction sent by the terminal, where the data sending instruction is used to start a process of sending the data to be programmed.
As a specific implementation manner, the receiving module 110 is further configured to receive a query message sent by the terminal for querying a connection state of the internet of things module.
The writing module 120 is configured to re-write the data to be written to the air conditioner if the data to be written passes the verification.
As a specific embodiment, the programming module 120 is further configured to: if the data to be programmed is successfully programmed, feeding back a programming result of the successful programming to the terminal; if the data to be programmed fails to be programmed, re-programming the data to be programmed; if the programming times reach the preset times and programming fails each time, feeding back the programming result of the programming failure to the terminal.
As a specific embodiment, the programming module 120 is further configured to: receiving data to be programmed sent by a terminal based on a data sending instruction; after the data to be programmed is received, checking the data to be programmed; if the data to be programmed passes the verification, storing the data to be programmed into a Flash memory and feeding back a verification completion message to the terminal; if the data to be programmed does not pass the verification, a message of verification failure is fed back to the terminal.
As a specific embodiment, after the writing module 120 is configured to store the data to be written to the Flash memory and feed back the verification completion message to the terminal if the data to be written passes the verification, the writing module is further configured to: receiving a data programming instruction sent by a terminal, wherein the data programming instruction is sent by the terminal after receiving a verification completion message fed back by an internet of things module; and writing the data to be programmed into the air conditioner based on the data writing instruction.
As a specific embodiment, the data to be programmed includes the internal unit data, the air conditioner includes the internal unit, and the programming module 120 is specifically configured to re-program the internal unit data to the internal unit of the air conditioner if the internal unit data passes the verification.
As a specific embodiment, the data to be programmed further includes external machine data, the air conditioner further includes an external machine, the external machine and the internal machine communicate through an internal machine communication line, and the programming module 120 is specifically configured to re-program the external machine data to the external machine of the air conditioner through the internal machine communication line if the external machine data passes the verification.
A query module 130, configured to: if the internet of things module is locally connected with the terminal, feeding back the connection state of the internet of things module to the terminal based on the query message as a local connection state, so that the terminal obtains data to be programmed from the database server based on the local connection state; if the internet of things module is remotely connected with the database server, the connection state of the internet of things module is fed back to the terminal based on the query message to be the remote connection state, so that the terminal instructs the database server to send the data to be programmed to the internet of things module based on the remote connection state.
The embodiment of the invention also provides a computer readable storage medium, on which a computer program is stored, which when executed by a processor, implements the data programming method as described above.
In summary, the invention provides a data programming method, a device, an internet module and a storage medium, which are applied to an internet of things module in an air conditioner, wherein the internet of things module comprises a Flash memory, the Flash memory stores data to be programmed, and the air conditioner is also communicated with a terminal through the internet of things module, and the method comprises the following steps: when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, verifying the data to be programmed; and if the data to be programmed passes the verification, re-programming the data to be programmed to the air conditioner. Compared with the prior art, in the embodiment of the invention, the internet of things module in the air conditioner comprises the Flash memory, the Flash memory stores the data to be programmed, the air conditioner is also communicated with the terminal through the internet of things module, when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, the data to be programmed is checked, if the data to be programmed passes the check, the data to be programmed is rewritten to the air conditioner, so that the intervention of maintenance personnel is not needed when the internet of things module powers off and powers on again in the process of programming the data, the internet of things module can read the data to be programmed from the Flash memory and check based on the received programming inquiry command sent by the terminal, thereby realizing the rewriting of the data to be programmed and improving the programming efficiency in the scene.
Although the present invention is disclosed above, the present invention is not limited thereto. Various changes and modifications may be made by one skilled in the art without departing from the spirit and scope of the invention, and the scope of the invention should be assessed accordingly to that of the appended claims.

Claims (7)

1. The utility model provides a data programming method which characterized in that is applied to the thing networking module among the air conditioner, thing networking module includes Flash memory, the Flash memory stores the data of waiting to write in, the air conditioner still communicates with the terminal through thing networking module, the method includes:
when the internet of things module powers off and then powers on again in the process of programming the data to be programmed to the air conditioner, if a programming inquiry command sent by the terminal is received, verifying the data to be programmed;
if the data to be programmed passes the verification, re-programming the data to be programmed to the air conditioner;
the step of re-writing the data to be programmed to the air conditioner comprises the following steps:
if the data to be programmed is successfully programmed, feeding back a programming result of the successful programming to the terminal;
if the data to be programmed fails to be programmed, re-programming the data to be programmed;
if the programming times reach the preset times and programming fails each time, feeding back a programming result of the programming failure to the terminal;
the method further comprises the steps of:
receiving a data transmission instruction sent by the terminal, wherein the data transmission instruction is used for starting a flow for transmitting the data to be programmed;
receiving the data to be programmed sent by the terminal based on the data sending instruction;
after the data to be programmed is received, checking the data to be programmed;
if the data to be programmed passes the verification, storing the data to be programmed into the Flash memory and feeding back a verification completion message to the terminal;
if the data to be programmed does not pass the verification, feeding back a message of verification failure to the terminal;
if the data to be programmed passes the verification, the steps of storing the data to be programmed into the Flash memory and feeding back the verification completion message to the terminal further comprise:
receiving a data programming instruction sent by the terminal, wherein the data programming instruction is sent by the terminal after receiving a verification completion message fed back by the internet of things module;
and writing the data to be programmed into the air conditioner based on the data writing instruction.
2. The data writing method according to claim 1, wherein the terminal is further communicatively connected to a database server, the method further comprising:
receiving a query message sent by the terminal and used for querying the connection state of the internet of things module;
if the internet of things module is locally connected with the terminal, feeding back the connection state of the internet of things module to the terminal based on the query message as a local connection state, so that the terminal acquires the data to be programmed from the database server based on the local connection state;
if the internet of things module is remotely connected with the database server, feeding back the connection state of the internet of things module to the terminal based on the query message to enable the terminal to instruct the database server to send the data to be programmed to the internet of things module based on the remote connection state.
3. The method for writing data according to claim 1, wherein the data to be written includes internal machine data, the air conditioner includes an internal machine, and the step of re-writing the data to be written to the air conditioner if the data to be written passes the verification further includes:
and if the internal machine data passes the verification, re-programming the internal machine data to the internal machine of the air conditioner.
4. The method for writing data according to claim 3, wherein the data to be written further comprises external machine data, the air conditioner further comprises an external machine, the external machine and the internal machine communicate through an internal machine and external machine communication line, and the step of re-writing the data to be written to the air conditioner if the data to be written passes the verification further comprises:
and if the external machine data passes the verification, re-writing the external machine data to the external machine of the air conditioner through the internal and external machine communication line.
5. The utility model provides a data write device, its characterized in that is applied to the thing networking module among the air conditioner, thing networking module includes Flash memory, flash memory stores the data of waiting to write in, the air conditioner is still through thing networking module communicates with the terminal, the device includes:
the receiving module is used for checking the data to be programmed if a programming inquiry command sent by the terminal is received when the internet of things module powers off and powers on again in the process of programming the data to be programmed to the air conditioner;
the programming module is used for re-programming the data to be programmed to the air conditioner if the data to be programmed passes the verification;
the receiving module is further configured to receive a data sending instruction sent by the terminal, where the data sending instruction is used to start a process of sending the data to be programmed;
the receiving module is further configured to receive a data programming instruction sent by the terminal, where the data programming instruction is sent by the terminal after receiving a message that verification fed back by the internet of things module is completed;
the programming module is further configured to: if the data to be programmed is successfully programmed, feeding back a programming result of the successful programming to the terminal; if the data to be programmed fails to be programmed, re-programming the data to be programmed; if the programming times reach the preset times and programming fails each time, feeding back a programming result of the programming failure to the terminal;
the programming module is further configured to: receiving the data to be programmed sent by the terminal based on the data sending instruction; after the data to be programmed is received, checking the data to be programmed; if the data to be programmed passes the verification, storing the data to be programmed into the Flash memory and feeding back a verification completion message to the terminal; if the data to be programmed does not pass the verification, feeding back a message of verification failure to the terminal;
the programming module is further configured to: and writing the data to be programmed into the air conditioner based on the data writing instruction.
6. An internet of things module comprising a memory and a processor, wherein the memory comprises a Flash memory, the memory stores a computer program, and the processor implements the data programming method according to any one of claims 1-4 when executing the computer program.
7. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the data burning method according to any of claims 1-4.
CN202110540825.2A 2021-05-18 2021-05-18 Data programming method and device, internet module and storage medium Active CN113190259B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110540825.2A CN113190259B (en) 2021-05-18 2021-05-18 Data programming method and device, internet module and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110540825.2A CN113190259B (en) 2021-05-18 2021-05-18 Data programming method and device, internet module and storage medium

Publications (2)

Publication Number Publication Date
CN113190259A CN113190259A (en) 2021-07-30
CN113190259B true CN113190259B (en) 2024-04-16

Family

ID=76982396

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110540825.2A Active CN113190259B (en) 2021-05-18 2021-05-18 Data programming method and device, internet module and storage medium

Country Status (1)

Country Link
CN (1) CN113190259B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116150818B (en) * 2023-04-17 2023-07-25 杭州利尔达展芯科技有限公司 Method for realizing safety of micro-controller chip writer

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013053262A1 (en) * 2011-10-14 2013-04-18 烽火通信科技股份有限公司 Method for automatically burning flash in batches
CN103679230A (en) * 2013-12-04 2014-03-26 西安诺瓦电子科技有限公司 Device, method and system for programming product sequence codes
WO2015165305A1 (en) * 2014-04-30 2015-11-05 深圳市九洲电器有限公司 Set-top box programming method and system
CN106775880A (en) * 2016-12-22 2017-05-31 海信(山东)空调有限公司 The programming device and method of a kind of EEPROM data
CN107678753A (en) * 2017-06-15 2018-02-09 卡姆福(北京)能源服务有限公司 A kind of program burn writing method, apparatus and electronic equipment
WO2018120213A1 (en) * 2016-12-30 2018-07-05 深圳配天智能技术研究院有限公司 Firmware updating method and controller
CN110879717A (en) * 2019-11-27 2020-03-13 四川虹美智能科技有限公司 EEPROM parameter programming device and method
CN111142886A (en) * 2019-12-25 2020-05-12 宁波奥克斯电气股份有限公司 Data programming method and related device
CN111880817A (en) * 2020-07-27 2020-11-03 北京环境特性研究所 Remote programming method for photoelectric monitoring system
CN112181444A (en) * 2020-08-25 2021-01-05 北京航天时代激光导航技术有限责任公司 DSP multi-core data programming method based on 1553B bus

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013053262A1 (en) * 2011-10-14 2013-04-18 烽火通信科技股份有限公司 Method for automatically burning flash in batches
CN103679230A (en) * 2013-12-04 2014-03-26 西安诺瓦电子科技有限公司 Device, method and system for programming product sequence codes
WO2015165305A1 (en) * 2014-04-30 2015-11-05 深圳市九洲电器有限公司 Set-top box programming method and system
CN106775880A (en) * 2016-12-22 2017-05-31 海信(山东)空调有限公司 The programming device and method of a kind of EEPROM data
WO2018120213A1 (en) * 2016-12-30 2018-07-05 深圳配天智能技术研究院有限公司 Firmware updating method and controller
CN107678753A (en) * 2017-06-15 2018-02-09 卡姆福(北京)能源服务有限公司 A kind of program burn writing method, apparatus and electronic equipment
CN110879717A (en) * 2019-11-27 2020-03-13 四川虹美智能科技有限公司 EEPROM parameter programming device and method
CN111142886A (en) * 2019-12-25 2020-05-12 宁波奥克斯电气股份有限公司 Data programming method and related device
CN111880817A (en) * 2020-07-27 2020-11-03 北京环境特性研究所 Remote programming method for photoelectric monitoring system
CN112181444A (en) * 2020-08-25 2021-01-05 北京航天时代激光导航技术有限责任公司 DSP multi-core data programming method based on 1553B bus

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
基于STM32的高可靠IAP在线烧写设计;李光学;郭燕红;李超;岳宗帅;宋茜;;电子测量技术(17);全文 *
基于串行总线和FPGA的FLASH烧写方法研究与实现;丁宁;樊宏伦;;电子世界(13);全文 *

Also Published As

Publication number Publication date
CN113190259A (en) 2021-07-30

Similar Documents

Publication Publication Date Title
CN107179909B (en) Software upgrading method and device and computer readable storage medium
US7200845B2 (en) System and method for high availability firmware load
CN110096294B (en) Method for wirelessly upgrading MCU application program at any breakpoint
US9268318B2 (en) Air conditioner, method for controlling outdoor units thereof, and central control system having the same
CN114281394A (en) Method, system, equipment and medium for fast on-line upgrading program
WO2019227619A1 (en) Hardware controller for nand apparatus, control method, and liquid crystal display
CN111813428A (en) Method and device for upgrading terminal firmware, electronic equipment and storage medium
CN113190259B (en) Data programming method and device, internet module and storage medium
US20030106052A1 (en) System and method for high availability firmware load
CN101778378A (en) Firmware node updating method, device and system
CN111142886A (en) Data programming method and related device
CN112684982B (en) Data migration method, system, equipment and computer readable storage medium
TW202207021A (en) Method for upgrade, computer system and remote upgrade equipment
CN113094072A (en) Vehicle upgrading method and device, electronic device and storage medium
CN110569053A (en) method for upgrading application chip in electronic equipment and electronic equipment
CN114489732A (en) Method and device for updating FPGA (field programmable Gate array) firmware of equipment and electronic equipment
CN113703803A (en) Remote upgrading system, method and medium based on FPGA
CN111026417A (en) Embedded equipment upgrading method and embedded equipment
CN108153548A (en) A kind of EMMC firmware upgrade methods and device
CN112181455B (en) Online upgrading method of microcontroller, microcontroller and storage medium
CN113138788A (en) Air conditioner program upgrading method and air conditioner system
CN110134423B (en) Firmware updating method and device and computer readable storage medium
CN109933479B (en) Fault simulation and emulation method and related equipment
CN112445508B (en) ARM application program online upgrading method based on CAN bus
CN109901117B (en) Radar restarting method and device

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
GR01 Patent grant
GR01 Patent grant