CN106445578B - Remote hardware upgrading method and device and wireless temperature and humidity monitor - Google Patents

Remote hardware upgrading method and device and wireless temperature and humidity monitor Download PDF

Info

Publication number
CN106445578B
CN106445578B CN201610575521.9A CN201610575521A CN106445578B CN 106445578 B CN106445578 B CN 106445578B CN 201610575521 A CN201610575521 A CN 201610575521A CN 106445578 B CN106445578 B CN 106445578B
Authority
CN
China
Prior art keywords
hardware
program
upgraded
command
upgrading
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
CN201610575521.9A
Other languages
Chinese (zh)
Other versions
CN106445578A (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.)
Beijing Huahailong Technology Co ltd
Original Assignee
Beijing Huahailong Technology 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 Beijing Huahailong Technology Co ltd filed Critical Beijing Huahailong Technology Co ltd
Priority to CN201610575521.9A priority Critical patent/CN106445578B/en
Publication of CN106445578A publication Critical patent/CN106445578A/en
Application granted granted Critical
Publication of CN106445578B publication Critical patent/CN106445578B/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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]

Abstract

The invention discloses a remote hardware upgrading method and device and a wireless temperature and humidity monitor, wherein a source program is stored in a first code storage area of hardware to be upgraded, then an upgrading program is downloaded from a remote server or the upgrading degree which is not transmitted before continuous transmission is stored in a temporary code storage area of the hardware to be upgraded, when the hardware to be upgraded is started, whether the complete upgrading program is stored in the temporary code storage area is checked, if the complete upgrading program is stored, the upgrading program is copied to a second code storage area, then the starting of the hardware to be upgraded is carried out according to the upgrading program stored in the second code storage area, the upgrading operation of the hardware to be upgraded is completed, and if the complete upgrading program is not stored, the starting of the hardware to be upgraded is carried out according to the source program stored in the first code storage area. According to the scheme, the hardware temperature and humidity monitor to be upgraded can be remotely and online upgraded, manpower and material resources are saved, resource waste is avoided, and hardware upgrading cost is saved.

Description

Remote hardware upgrading method and device and wireless temperature and humidity monitor
Technical Field
The invention relates to the field of hardware upgrading and temperature and humidity monitoring, in particular to a remote hardware upgrading method and device and a wireless temperature and humidity monitor.
Background
Food, milk ware, vegetables etc. need the low temperature to preserve transportation in the transportation, especially blood products, bacterin etc. in the medicine clearly prescribe to need the low temperature to preserve in the transportation, and new edition medicine GSP clearly prescribes in the medicine cold chain medicine transportation, must carry out whole monitoring to the temperature and the humidity in the medical kit. At present, certain achievements are achieved on temperature and humidity monitoring in the cold chain transportation process, but the existing detection equipment is designed in advance according to the needs, and can only monitor according to a preset scheme according to a preset monitoring method, and along with different transportation products or changing of temperature and humidity requirements, the prior temperature and humidity monitoring device can not better meet the existing monitoring requirements, so that a monitoring instrument needs to be replaced, resource waste is caused, and cost is increased. Even if the existing temperature and humidity monitoring instrument is not replaced, the existing temperature and humidity monitoring instrument is updated in a mode that the temperature and humidity monitoring instrument is required to be disassembled and transported to a specific place, and the temperature and humidity monitoring instrument is updated by special technicians, so that the cost is increased and the working efficiency is reduced to a certain extent. In a word, the existing temperature and humidity monitoring instrument cannot realize remote hardware upgrading, and even if the remote hardware upgrading can be realized, an additional memory is required to be added, so that the cost of temperature and humidity monitoring is increased to a certain extent.
Disclosure of Invention
The invention solves the technical problem of realizing the hardware remote upgrade of the temperature and humidity monitoring instrument in the temperature and humidity monitoring process.
In order to solve the technical problems, the invention provides a remote hardware upgrading method, which comprises the following steps:
s1, downloading a source program by hardware to be upgraded through a USB, and storing the downloaded source program in a first code area of the hardware to be upgraded.
S2, the hardware to be upgraded downloads an upgrade program from a server through remote communication, and the upgrade program is stored in a temporary code storage area of the hardware to be upgraded;
S3, when the hardware to be upgraded is started, the hardware to be upgraded detects whether the temporary code storage area stores a complete upgrading program, if the temporary code storage area stores the complete upgrading program, the hardware to be upgraded copies the upgrading program to a second code storage area, and starts the hardware to be upgraded according to the upgrading program; and if the temporary code storage area does not have the finished upgrading program, starting the hardware to be upgraded according to the source program stored in the first code storage area by the hardware to be upgraded.
Preferably, the method further comprises the steps of:
S4, judging whether the hardware to be upgraded is successfully started according to the upgrading program, and if not, starting the hardware to be upgraded according to the source program stored in the first code storage area.
Preferably, the step S2 specifically includes the following steps:
S20, the server and the hardware to be upgraded are communicated through a remote hardware upgrading device protocol.
The server issues an application data communication command to the hardware with upgrade; and the hardware to be upgraded returns an OK command, and the server and the equipment start to communicate.
S21, the server transmits a downloading program inquiry command to the hardware to be upgraded; the hardware to be upgraded receives the downloading program inquiry command and feeds back to the server to request downloading of the upgrading program command or request to continue downloading of the upgrading program command before;
S22, the server sends a command for confirming downloading of the upgrade program to the hardware to be upgraded according to the command for requesting downloading of the upgrade program or the command for requesting the upgrade program before continuous downloading; the hardware to be upgraded feeds back to the server to confirm the downloading command according to the confirmed downloading upgrading program command;
S23, the server sends an upgrading program to the hardware to be upgraded according to the confirmed downloading command, and the hardware to be upgraded receives the upgrading program and feeds back a confirmation command to the server;
s24, after the upgrade program is sent, the server sends an output completion command to the hardware to be upgraded, and the hardware to be upgraded feeds back a downloading completion command to the server after receiving the upgrade program according to the output completion command;
S25, storing the upgrading program in a temporary code storage area of the hardware to be upgraded.
A remote hardware upgrade apparatus, the apparatus comprising hardware to be upgraded and a server; the hardware control module and the communication module to be upgraded. The control module storage unit comprises a downloading unit, an initializing unit, a first code storage area, a second code storage area and a temporary code storage area;
the hardware to be upgraded is downloaded BOOT LOADER via USB and stored in BOOT LOADER code area. After BOOT LOADER programs are downloaded, the source programs are downloaded through the USB, and the downloaded source programs are stored in the first code storage area of the hardware to be upgraded.
The downloading unit is also used for downloading an upgrade program from a server through remote communication and storing the upgrade program in the temporary code storage area;
The initialization unit is used for detecting whether the temporary code storage area stores a complete upgrading program or not when the hardware to be upgraded is started, and if the temporary code storage area stores the complete upgrading program, the initialization unit copies the upgrading program to a second code storage area and starts the hardware to be upgraded according to the upgrading program; and if the temporary code storage area does not contain the completed upgrading program, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area.
Preferably, the initialization unit is further configured to determine whether the hardware to be upgraded is successfully started according to the upgrade program, and if not, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area.
Preferably, the downloading unit includes a receiving program subunit, a first command generating subunit, a second command generating subunit, and a third command generating subunit;
The first command generating subunit is configured to receive a downloading program query command issued by the server to the hardware to be upgraded, and feed back to the server to request downloading of the upgrading program command or to request the upgrading program command before continuing downloading;
the second command generating subunit is configured to feed back a confirmed download command to the server according to a confirmed download upgrade program command issued by the server, where the confirmed download upgrade program command is generated by the server according to the upgrade program command requested to be downloaded or an upgrade program command before the server continues to download;
The receiving program subunit is used for receiving the upgrade program sent by the server and feeding back a receiving confirmation command to the server; the server sends the upgrading program to the hardware to be upgraded according to the confirmed downloading command;
The third command generating subunit is used for feeding back a downloading completion command to the server after receiving the upgrading program according to the output completion command sent by the server; and after the upgrade program is sent, the server sends the output completion command to the hardware to be upgraded.
The wireless temperature and humidity monitor comprises the remote hardware upgrading device, and the temperature and humidity monitor utilizes the remote hardware upgrading device to conduct remote hardware upgrading of hardware to be upgraded, wherein the wireless temperature and humidity monitor comprises the hardware to be upgraded.
Preferably, the system further comprises a Bluetooth key pairing module;
The Bluetooth key pairing module is used for receiving an encryption key sent by external equipment and decrypting the encryption key, and pairing the decrypted key with a key set by the Bluetooth module, and if pairing is successful, the Bluetooth module is used as a slave to establish Bluetooth communication connection between the Bluetooth module and the external equipment;
The Bluetooth key pairing module is also used for sending an encryption key to the external equipment, decrypting the encryption key by the external equipment, pairing the decrypted key with a key set by the external equipment, and if pairing is successful, the Bluetooth module is used as a host to establish Bluetooth communication connection between the Bluetooth module and the external equipment.
Preferably, the hardware control module to be upgraded is a single chip microcomputer.
Preferably, the temperature and humidity sensor also comprises a temperature and humidity probe, a display, an alarm, a sensor interface and a memory, wherein the temperature and humidity probe, the display, the alarm, the sensor interface and the memory are connected with the singlechip;
The temperature and humidity probe is used for monitoring the temperature and humidity in the environment and transmitting the temperature and humidity obtained by monitoring to the singlechip;
the display is used for displaying the temperature and the humidity received by the singlechip;
The alarm is used for alarming when the temperature or/and the humidity exceeds a preset threshold value;
the sensor interface is used for connecting an extended sensor;
the memory is used for storing the temperature and the humidity obtained by the monitoring of the temperature and humidity probe.
The invention provides a remote hardware upgrading method and a remote hardware upgrading device, wherein a source program downloaded for the first time is stored in a first code storage area of hardware to be upgraded, then the hardware to be upgraded downloads the upgrading program from a remote server or the upgrading degree which is not transmitted before continuous transmission is stored in a temporary code storage area of the hardware to be upgraded, when the hardware to be upgraded is started, firstly, whether a complete upgrading program is stored in the temporary code storage area is checked, if the complete upgrading program is stored in the temporary code storage area, the complete upgrading program is copied to a second code storage area, the initializing unit starts the hardware to be upgraded according to the upgrading program stored in the second code storage area, the upgrading operation of the hardware to be upgraded is completed, and if the complete upgrading program is not stored in the temporary code storage area, the initializing unit starts the hardware to be upgraded according to the source program stored in the first code storage area. According to the scheme, remote upgrading of the hardware to be upgraded can be realized without replacing new hardware, disassembly and transportation of the hardware to be upgraded are not needed, upgrading operation is performed by professional technicians, manpower and material resources are saved, waste of resources is avoided, hardware upgrading cost is saved, and hardware upgrading efficiency is improved. Meanwhile, the scheme does not need to additionally add a memory, and the hardware upgrading cost is saved to a certain extent. Meanwhile, the technical scheme can realize breakpoint continuous transmission, and the flexibility of upgrading program transmission is improved.
In addition, the invention also discloses a wireless temperature and humidity monitor comprising the remote hardware upgrading device, and the wireless temperature and humidity monitor can utilize the technical scheme to carry out remote hardware upgrading, so that the wireless temperature and humidity monitor can carry out hardware upgrading according to real-time temperature and humidity monitoring requirements without replacing a new temperature and humidity monitor, and the old temperature and humidity monitor does not need to be subjected to periodic disassembly and assembly, transportation and upgrading by professional staff, thereby saving the cost of hardware upgrading of the temperature and humidity monitor and avoiding the waste of resources. In addition, the wireless temperature and humidity monitor is further provided with a Bluetooth module and a key pairing module, the key pairing module is used for carrying out key pairing on the Bluetooth module and external equipment, and Bluetooth communication connection between the Bluetooth module and the external equipment is established after the key pairing is successful, wherein the external equipment can be a mobile device or a Bluetooth printer, so that the wireless temperature and humidity monitor can carry out printing and data transmission in a Bluetooth mode.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a remote hardware upgrade method of the present invention;
FIG. 2A is an upgrade flow chart of a remote hardware upgrade apparatus of the present invention;
FIG. 2B is a schematic diagram of a partition of a remote hardware upgrade apparatus of the present invention;
FIG. 3 is a flowchart of the Bluetooth module and key pairing module of the wireless temperature and humidity monitor of the present invention;
fig. 4 is a schematic structural diagram of the wireless temperature and humidity monitor according to the present invention.
Detailed Description
The invention is described in further detail below with reference to the drawings and examples. The following examples are illustrative of the invention but are not intended to limit the scope of the invention.
A method of remote hardware upgrade, as shown in fig. 1, the method comprising the steps of:
S1, downloading a source program by hardware to be upgraded through a USB, and storing the downloaded source program in a first code storage area of the hardware to be upgraded.
The hardware to be upgraded downloads the source program through the USB, and before downloading the source program, the hardware to be upgraded can firstly download the initialization program BOOT LOADER through the USB;
S2, after the source program is downloaded, the hardware to be upgraded downloads an upgrade program from a server through remote communication, and the upgrade program is stored in a temporary code storage area of the hardware to be upgraded;
S3, when the hardware to be upgraded is started, the hardware to be upgraded detects whether the temporary code storage area stores a complete upgrading program, if the temporary code storage area stores the complete upgrading program, the hardware to be upgraded copies the upgrading program to a second code storage area, and starts the hardware to be upgraded according to the upgrading program; and if the temporary code storage area does not have the finished upgrading program, starting the hardware to be upgraded according to the source program stored in the first code storage area by the hardware to be upgraded.
The method can realize remote online upgrade of the hardware to be upgraded, does not need to replace new hardware, does not need to disassemble and transport the hardware to be upgraded and upgrade the hardware by professional technicians, saves manpower and material resources, avoids resource waste, saves hardware upgrade cost, and improves hardware upgrade efficiency. Meanwhile, the scheme does not need to additionally add a memory, and the hardware upgrading cost is saved to a certain extent. Meanwhile, the technical scheme can realize breakpoint continuous transmission, and the flexibility of upgrading program transmission is improved.
Further, the method may further include the following steps after step S3:
S4, judging whether the hardware to be upgraded is successfully started according to the upgrading program, and if not, starting the hardware to be upgraded according to the source program stored in the first code storage area. In the step, after the hardware starting is not realized by using the new upgrading program, the hardware starting is performed by using the source program downloaded for the first time, so that the hardware damage caused by the problem of the upgrading program is avoided, the use of the hardware is influenced, and the normal use of the hardware is ensured to the greatest extent.
Further, the step S2 of downloading the upgrade program by remote communication specifically includes the following steps:
S21, the server transmits a downloading program inquiry command to the hardware to be upgraded; the hardware to be upgraded receives the downloading program inquiry command and feeds back to the server to request downloading of the upgrading program command or request to continue downloading of the upgrading program command before; preferably, before the server issues a downloading program inquiry command to the hardware to be upgraded, the hardware to be upgraded firstly sends an application data communication command to the server, and the server issues the downloading program inquiry command to the hardware to be upgraded after receiving the application data communication command;
S22, the server sends a command for confirming downloading of the upgrade program to the hardware to be upgraded according to the command for requesting downloading of the upgrade program or the command for requesting the upgrade program before continuous downloading; the hardware to be upgraded feeds back to the server to confirm the downloading command according to the confirmed downloading upgrading program command;
S23, the server sends an upgrading program to the hardware to be upgraded according to the confirmed downloading command, and the hardware to be upgraded receives the upgrading program and feeds back a confirmation command to the server;
in the step, a communication module is utilized to realize program transmission between a server and hardware to be upgraded;
s24, after the upgrade program is sent, the server sends an output completion command to the hardware to be upgraded, and the hardware to be upgraded feeds back a downloading completion command to the server after receiving the upgrade program according to the output completion command;
S25, after the downloading is finished, CRC check is firstly carried out on the currently downloaded upgrading program, and after the CRC passes, the upgrading program is stored in a temporary code storage area of the hardware to be upgraded.
By utilizing the method, the remote on-line upgrading of the hardware can be realized, the efficiency of the hardware upgrading is improved, and the waste of manpower and material resources is avoided.
The invention also discloses a remote hardware upgrading device, which comprises hardware to be upgraded and a server; the hardware to be upgraded comprises a control module and a communication module. The control module storage unit comprises a downloading unit, an initializing unit, a first code storage area, a second code storage area and a temporary code storage area;
the hardware to be upgraded downloads a source program through the USB, and stores the downloaded source program in a first code storage area of the hardware to be upgraded.
The downloading unit is also used for downloading an upgrade program from a server through remote communication and storing the upgrade program in the temporary code storage area;
The initialization unit is used for detecting whether the temporary code storage area stores a complete upgrading program or not when the hardware to be upgraded is started, and if the temporary code storage area stores the complete upgrading program, the initialization unit copies the upgrading program to a second code storage area and starts the hardware to be upgraded according to the upgrading program; and if the temporary code storage area does not contain the completed upgrading program, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area.
The device can realize remote online upgrade of hardware, and the processing steps of the device are in one-to-one correspondence with the steps of the method, so repeated contents are not repeated here.
Further, the initialization unit is further configured to determine whether the hardware to be upgraded is successfully started according to the upgrade program, and if not, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area.
Further, the downloading unit comprises a receiving program subunit, a first command generating subunit, a second command generating subunit and a third command generating subunit;
The first command generating subunit is configured to receive a downloading program query command issued by the server to the hardware to be upgraded, and feed back to the server to request downloading of the upgrading program command or to request the upgrading program command before continuing downloading;
the second command generating subunit is configured to feed back a confirmed download command to the server according to a confirmed download upgrade program command issued by the server, where the confirmed download upgrade program command is generated by the server according to the upgrade program command requested to be downloaded or an upgrade program command before the server continues to download;
The receiving program subunit is used for receiving the upgrade program sent by the server and feeding back a receiving confirmation command to the server; the server sends the upgrading program to the hardware to be upgraded according to the confirmed downloading command;
The third command generating subunit is used for feeding back a downloading completion command to the server after receiving the upgrading program according to the output completion command sent by the server; and after the upgrade program is sent, the server sends the output completion command to the hardware to be upgraded.
The remote hardware upgrade apparatus described above is described in detail below with respect to one embodiment.
In this embodiment, the hardware control module to be upgraded is a single-chip microcomputer. As shown in fig. 2B, the internal memory area of the single chip microcomputer is a BOOT LOADER area, a CODE0 area (i.e., the above first CODE memory area), a CODE1 area (i.e., the above second CODE memory area), and a CODE BAK area (i.e., the above temporary CODE memory area), respectively. The singlechip downloads BOOT LOADER through USB first, and then downloads the source program. The source program downloaded for the first time is placed in the CODE0 area by default, then the singlechip downloads the upgrade program from the server, and the singlechip communicates with the server according to a remote upgrade device protocol.
As shown in fig. 2A, the source program downloaded for the first time is placed in the CODE0 area. And after the check is finished, putting data in a CODE BAK area of the singlechip, detecting whether the CODE BAK has an updated downloaded program or not before starting up each time in a BOOT LORDE area, if so, copying the new program to a CODE1 area, and starting an upgrading program stored in the CODE1 area. If there is no new upgrade program or the new upgrade program is not successfully started, the source program stored in the CODE0 area is started. Therefore, the equipment can be prevented from being failed and not started normally, and a guarantee is provided for the normal starting of the equipment. The new program in the CODE BAK area may be also downloaded by self-judging whether the program is downloaded completely or not and whether to continue the program file downloaded before the device is started normally.
The invention also discloses a wireless temperature and humidity monitor, which comprises the remote hardware upgrading device, and the temperature and humidity monitor utilizes the remote hardware upgrading device to upgrade the remote hardware of the hardware to be upgraded, wherein the wireless temperature and humidity monitor comprises the hardware to be upgraded. This wireless temperature and humidity monitor can carry out the long-range hardware upgrade of self to make this wireless temperature and humidity monitor carry out the hardware upgrade according to real-time temperature and humidity monitoring requirement, need not change new temperature and humidity monitor, and need not carry out the upgrade to old temperature and humidity monitor hard dismouting, transportation and by professional staff, improved hardware upgrade efficiency, saved the cost of temperature and humidity monitor hardware upgrade, avoid the waste of resource.
Further, the wireless temperature and humidity monitor further comprises a Bluetooth key pairing module;
The Bluetooth key pairing module is used for receiving an encryption key sent by external equipment and decrypting the encryption key, and pairing the decrypted key with a key set by the Bluetooth module, and if pairing is successful, the Bluetooth module is used as a slave to establish Bluetooth communication connection between the Bluetooth module and the external equipment;
The Bluetooth key pairing module is also used for sending an encryption key to the external equipment, decrypting the encryption key by the external equipment, pairing the decrypted key with a key set by the external equipment, and if pairing is successful, the Bluetooth module is used as a host to establish Bluetooth communication connection between the Bluetooth module and the external equipment.
The external device may be a mobile device or a mobile device, or may be a bluetooth printer, as shown in fig. 3, after the key decryption and the key pairing are successful, the key connection is successful, the mobile device and the bluetooth module communicate in a bluetooth manner, and the data transmitted between the two are encrypted by AES. After the key connection is successful, the mobile device can download data from the server for printing, and can also receive data from the Bluetooth module for Bluetooth printing. When the Bluetooth module receives the secret key sent by the mobile device, the Bluetooth module works in a slave mode, and otherwise, the Bluetooth module works in a host mode. When the Bluetooth module is beside the Bluetooth printer, the Bluetooth module can also be connected with the Bluetooth printer to print data. The Bluetooth module is arranged, so that the wireless temperature and humidity monitor can print and transmit data in a Bluetooth mode.
Further, as shown in fig. 4, the wireless temperature and humidity monitor further comprises a singlechip, a temperature and humidity probe, a display, an alarm, a sensor interface and a memory, which are connected with the singlechip, and a communication module GPRS, wherein the singlechip is used as hardware to be upgraded to carry out hardware upgrading. The temperature and humidity probe is used for monitoring the temperature and humidity in the environment and transmitting the temperature and humidity obtained by monitoring to the singlechip; the display is used for displaying the temperature and the humidity received by the singlechip; the alarm is used for alarming when the temperature or/and the humidity exceeds a preset threshold value or other anomalies occur in the running process; the sensor interface is used for connecting an extended sensor; the memory is used for storing the temperature and the humidity obtained by the monitoring of the temperature and humidity probe. The communication module GPRS is used for communicating between the equipment and the upper computer server and uploading and downloading data.
As shown in fig. 4, the wireless temperature and humidity monitor may also use a built-in lithium battery with a charging function.
As shown in fig. 4, the wireless temperature and humidity monitor may further be provided with a film button to realize opening, closing, function selection, and the like.
As shown in fig. 4, the temperature and humidity probe preferably includes a temperature sensor DS18B20 and a temperature and humidity sensor MVH3004D, and the temperature monitoring range is as follows: -30 ℃ to +70 ℃, humidity monitoring range: 0-95% RH, accuracy/resolution of temperature + -0.5 ℃ humidity + -3.8% RH, recording period adjustable for 1 min-60 min.
The display preferably uses 12864 liquid crystals and a white backlight display.
The memory is used for automatically storing the data which is not uploaded, and can conduct data export through a USB port, such as export to a PC. The server can also be uploaded through GPRS, and the PC can derive historical data from the server. Historical data may also be derived via USB.
The alarm can adopt sound and light alarm or short message alarm and the like.
According to the design requirements, the SCM adopts an ARM 32-bit Crotex M SCM 32F103RET6 to support Debug and USB boot.
The wireless temperature and humidity monitor has the following functions: storing 8000 pieces of data at most; historical data can be exported through a GPRS uploading server or through USB; the historical data can be printed by Bluetooth; a base station positioning function; a remote short message control wireless function; an audible and visual alarm and a short message alarm function; the device parameter setting function can set device unlocking, device ID and working parameter setting through the upper computer management software or the server management software, wherein the working parameter setting comprises recording interval, temperature and humidity alarm, early warning upper and lower limits, temperature and humidity alarm function enabling, attendant mobile phone number, recording storage mode (cycle storage and single storage) and RTC time setting reading; the number of keys is 3: switches, functions, select keys; liquid crystal display function: the device operating state, the wireless connection state, the battery power and the battery charging indication; displaying the real-time temperature and humidity; the stored record number and the unedited record number; alarm information or status; a device ID; system time. Temperature acquisition, storage and display functions; a GPRS wireless uploading function of temperature data; temperature recording interval, wireless transmission period and alarm threshold configuration function (by external configuration software); default factory configuration: collecting for 5 minutes, and uploading for 5 minutes in a wireless way; automatically synchronizing network time; and in combination with Herol medical cold chain real-time monitoring and tracing system, temperature data, equipment hierarchical management, hierarchical alarm, historical data inquiry, calling, report form and the like are displayed in real time. Most importantly, in practical application, a customer requires hardware upgrade, if the factory is returned, time, energy and manpower are wasted, the wireless temperature and humidity monitor realizes remote online hardware upgrade, unnecessary resource waste is saved while hardware upgrade is improved, and safety of medicines, vaccines, biological agents, foods and medicines in the transportation process can be fully ensured.
The wireless temperature and humidity monitor can be placed in equipment needing to monitor temperature, such as a refrigerator, a freezer, the inside of the freezer and the like, and can be used for temperature monitoring (humidity monitoring of 0-100% RH) at-40-85 ℃. A SIM card of standard phone card size for a built-in ordinary cell phone may be used. Through relevant configuration, the wireless temperature and humidity monitor can send temperature alarm information to the appointed mobile phone number, and intelligent remote monitoring can be achieved. The rechargeable lithium battery is used for supplying power to ensure that the equipment normally operates for more than 48 hours.
The remote hardware upgrade device protocol is as follows:
Application data communication command
(1) Device transmissions as in table 1:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte 1+n*2byte 2bytes
Data 0xAA 0x01 ID CRC results
The data content is as follows:
(2) The server returns:
The data content is as follows:
(3) The device returns:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte 2byte 2byte
Data 0xAA 0x01 ID “OK” CRC results
And after receiving an ED sent by the server, the device returns a command and enters wireless dormancy.
Remote upgrade apparatus program (Command word: 0x 22)
(1) Initiating a download program
① The server sends a downloading program information inquiry command:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte 4byte 2bytes
Data 0xA5 0x22 ID “ASK” CRC results
② The device returns: program file to be downloaded before requesting to download program or continuous transmission
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte bytes 2bytes
Data 0xAA 0x01 ID CRC results
The data content is as follows:
(2) Download program information validation
① The server sends a download program information command:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte byte 2bytes
Data 0xA5 0x22 ID CRC results
The data content is as follows:
note that: the last three bytes of the file name must be either "_r0" or "_r1".
② The device returns: downloading a program information confirmation frame:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte bytes 2bytes
Data 0xAA 0x02 ID CRC results
The data content is as follows:
(3) Transmitting files
In the file transmission command, the server transmits each packet of data, and the next packet cannot be transmitted until the device returns an acknowledgement.
① The server sends a file transfer command:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte byte 2bytes
Data 0xA5 0x22 ID CRC results
The data content is as follows:
② The device returns: file receipt acknowledgement:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte byte 2byte
Data 0xAA 0x02 ID CRC results
The data content is as follows:
(4) Transmission of file completion acknowledgements
① The server sends a file transfer completion command:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte byte 2byte
Data 0xA5 0x12 ID CRC results
The data content is as follows:
/>
② The device returns: file transfer completion acknowledgement:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte byte 2byte
Data 0xAA 0x12 ID CRC results
The data content is as follows:
Invalidation commands
(1) And (3) the server sends:
(2) Device return
Communication cycle end command (command word: 0x 33)
(1) And (3) the server sends:
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte 0byte 2byte
Data 0xA5 0x33 ID CRC results
(2) Device return
Parameters (parameters) Frame header Frame length Command word Device ID Data content CRC
Length of 1byte 2byte 1byte 4byte 0byte 2byte
Data 0xAA 0x33 ID CRC results
The device receives the command or receives the command of the server overtime, and the communication is ended and enters a dormant state.
The above embodiments are only for illustrating the present invention, and are not limiting of the present invention. While the invention has been described in detail with reference to the embodiments, those skilled in the art will appreciate that various combinations, modifications, and substitutions can be made thereto without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (6)

1. A method of remote hardware upgrade, the method comprising the steps of:
s1, downloading BOOT LOADER a program through a USB (universal serial bus), storing the program in a BOOT LOADER code area, downloading a source program through the USB after downloading BOOT LOADER program, and storing the downloaded source program in a first code storage area of the hardware to be upgraded;
S2, the hardware to be upgraded downloads an upgrade program from a server through remote communication, the upgrade program downloaded from the server passes CRC check, and after the check is finished, the upgrade program is stored in a temporary code storage area of the hardware to be upgraded, and the method comprises the following steps:
The server and the hardware to be upgraded are communicated through a remote hardware upgrading device protocol;
the server issues an application data communication command to the hardware to be upgraded; the hardware to be upgraded returns an OK command, and the server and the equipment start to communicate;
the server transmits a downloading program inquiry command to the hardware to be upgraded; the hardware to be upgraded receives the downloading program inquiry command and feeds back to the server to request downloading of the upgrading program command or request to continue downloading of the upgrading program command before;
The server sends a command for confirming downloading of the upgrade program to the hardware to be upgraded according to the command for requesting downloading of the upgrade program or the command for requesting the upgrade program before continuous downloading; the hardware to be upgraded feeds back to the server to confirm the downloading command according to the confirmed downloading upgrading program command;
The server sends an upgrading program to the hardware to be upgraded according to the confirmed downloading command, and the hardware to be upgraded receives the upgrading program and feeds back a confirmed command to the server;
after the upgrade program is sent, the server sends an output completion command to the hardware to be upgraded, and the hardware to be upgraded feeds back a downloading completion command to the server after receiving the upgrade program according to the output completion command;
storing the upgrade program in a temporary code storage area of the hardware to be upgraded;
s3, when the hardware to be upgraded is started, the hardware to be upgraded detects whether the temporary code storage area stores a complete upgrading program, if the temporary code storage area stores the complete upgrading program, the hardware to be upgraded copies the upgrading program to a second code storage area, and starts the hardware to be upgraded according to the upgrading program; if the temporary code storage area does not have the finished upgrading program, the hardware to be upgraded starts the hardware to be upgraded according to the source program stored in the first code storage area;
S4, judging whether the hardware to be upgraded is successfully started according to the upgrading program, and if not, starting the hardware to be upgraded according to the source program stored in the first code storage area.
2. A remote hardware upgrade apparatus, wherein the apparatus comprises hardware to be upgraded; the hardware to be upgraded comprises a control module and a communication module; the control module comprises a downloading unit, an initializing unit, a first code storage area, a second code storage area and a temporary code storage area;
downloading BOOT LOADER a program by the hardware to be upgraded through a USB, and storing the program in a BOOT LOADER code area; after BOOT LOADER programs are downloaded, downloading source programs through a USB, and storing the downloaded source programs in a first code storage area of the hardware to be upgraded;
The downloading unit is also used for downloading an upgrade program from a server through remote communication and storing the upgrade program in the temporary code storage area; the downloading unit comprises a receiving program subunit, a first command generating subunit, a second command generating subunit and a third command generating subunit;
The first command generating subunit is configured to receive a downloading program query command issued by the server to the hardware to be upgraded, and feed back to the server to request downloading of the upgrading program command or to request the upgrading program command before continuing downloading;
the second command generating subunit is configured to feed back a confirmed download command to the server according to a confirmed download upgrade program command issued by the server, where the confirmed download upgrade program command is generated by the server according to the upgrade program command requested to be downloaded or an upgrade program command before the server continues to download;
The receiving program subunit is used for receiving the upgrade program sent by the server and feeding back a receiving confirmation command to the server; the server sends the upgrading program to the hardware to be upgraded according to the confirmed downloading command;
the third command generating subunit is used for feeding back a downloading completion command to the server after receiving the upgrading program according to the output completion command sent by the server; after the upgrade program is sent, the server sends the output completion command to the hardware to be upgraded;
the initialization unit is used for detecting whether the temporary code storage area stores a complete upgrading program or not when the hardware to be upgraded is started, and if the temporary code storage area stores the complete upgrading program, the initialization unit stores the upgrading program into a second code storage area and starts the hardware to be upgraded according to the upgrading program; if the temporary code storage area does not contain the finished upgrading program, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area;
The initialization unit is further configured to determine whether the hardware to be upgraded is successfully started according to the upgrade program, and if not, the initialization unit starts the hardware to be upgraded according to the source program stored in the first code storage area.
3. The wireless temperature and humidity monitor is characterized by comprising the remote hardware upgrading device of claim 2, and the temperature and humidity monitor utilizes the remote hardware upgrading device to conduct remote hardware upgrading of hardware to be upgraded, wherein the wireless temperature and humidity monitor comprises the hardware to be upgraded.
4. The wireless temperature and humidity monitor of claim 3 further comprising a bluetooth module and a bluetooth key pairing module;
The Bluetooth key pairing module is used for receiving an encryption key sent by external equipment and decrypting the encryption key, and pairing the decrypted key with a key set by the Bluetooth module, and if pairing is successful, the Bluetooth module is used as a slave to establish Bluetooth communication connection between the Bluetooth module and the external equipment; or alternatively
The Bluetooth key pairing module is also used for sending an encryption key to the external equipment, decrypting the encryption key by the external equipment, pairing the decrypted key with a key set by the external equipment, and if pairing is successful, the Bluetooth module is used as a host to establish Bluetooth communication connection between the Bluetooth module and the external equipment.
5. The wireless temperature and humidity monitor according to claim 4, wherein the control module is a single-chip microcomputer; the external device is an external mobile device or a Bluetooth printer.
6. The wireless temperature and humidity monitor according to claim 5, further comprising a temperature and humidity probe, a display, an alarm, a sensor interface and a memory connected with the single-chip microcomputer;
The temperature and humidity probe is used for monitoring the temperature and humidity in the environment and transmitting the temperature and humidity obtained by monitoring to the singlechip;
the display is used for displaying the temperature and the humidity received by the singlechip;
the alarm is used for alarming when the temperature or/and the humidity exceeds a preset threshold value;
the sensor interface is used for connecting an extended sensor;
the memory is used for storing the temperature and the humidity obtained by the monitoring of the temperature and humidity probe.
CN201610575521.9A 2016-07-19 2016-07-19 Remote hardware upgrading method and device and wireless temperature and humidity monitor Active CN106445578B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610575521.9A CN106445578B (en) 2016-07-19 2016-07-19 Remote hardware upgrading method and device and wireless temperature and humidity monitor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610575521.9A CN106445578B (en) 2016-07-19 2016-07-19 Remote hardware upgrading method and device and wireless temperature and humidity monitor

Publications (2)

Publication Number Publication Date
CN106445578A CN106445578A (en) 2017-02-22
CN106445578B true CN106445578B (en) 2024-05-03

Family

ID=58184106

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610575521.9A Active CN106445578B (en) 2016-07-19 2016-07-19 Remote hardware upgrading method and device and wireless temperature and humidity monitor

Country Status (1)

Country Link
CN (1) CN106445578B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7027809B2 (en) * 2017-10-31 2022-03-02 京セラドキュメントソリューションズ株式会社 Update system
CN109358865A (en) * 2018-12-20 2019-02-19 合肥协力仪表控制技术股份有限公司 A kind of industrial vehicle car networking instrument and upgrade method with remote upgrade function
CN113495729A (en) * 2020-03-20 2021-10-12 株洲中车时代电气股份有限公司 Software upgrading method and device
CN113219872A (en) * 2021-05-10 2021-08-06 安徽大学 Remote upgrading method of monitoring system of refrigerator car based on real-time perception
CN113312648B (en) * 2021-06-23 2023-10-31 国网黑龙江省电力有限公司绥化供电公司 Communication module and communication method based on data encryption
CN113568646B (en) * 2021-09-24 2021-12-28 常州星宇车灯股份有限公司 Novel portable program upgrading method
CN116455884B (en) * 2023-04-04 2023-12-29 河南驰诚电气股份有限公司 Remote debugging and upgrading method in wireless cascading mode

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1991761A (en) * 2005-12-30 2007-07-04 北京华旗资讯数码科技有限公司 Firmware program on-line upgrading method and hardware equipment
CN101419557A (en) * 2008-07-29 2009-04-29 航天信息股份有限公司 Program downloading control method
CN101826026A (en) * 2010-04-12 2010-09-08 中兴通讯股份有限公司 Embedded equipment and on-line updating system and method of firmware in embedded equipment
CN104331312A (en) * 2014-11-24 2015-02-04 东软熙康健康科技有限公司 Firmware updating method and embedded device
CN105740000A (en) * 2014-12-09 2016-07-06 航天信息股份有限公司 Intelligent alarm upgrading method, device and system
CN105740025A (en) * 2016-02-04 2016-07-06 深圳创达云睿智能科技有限公司 Bluetooth based firmware program upgrading method and apparatus

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1991761A (en) * 2005-12-30 2007-07-04 北京华旗资讯数码科技有限公司 Firmware program on-line upgrading method and hardware equipment
CN101419557A (en) * 2008-07-29 2009-04-29 航天信息股份有限公司 Program downloading control method
CN101826026A (en) * 2010-04-12 2010-09-08 中兴通讯股份有限公司 Embedded equipment and on-line updating system and method of firmware in embedded equipment
CN104331312A (en) * 2014-11-24 2015-02-04 东软熙康健康科技有限公司 Firmware updating method and embedded device
CN105740000A (en) * 2014-12-09 2016-07-06 航天信息股份有限公司 Intelligent alarm upgrading method, device and system
CN105740025A (en) * 2016-02-04 2016-07-06 深圳创达云睿智能科技有限公司 Bluetooth based firmware program upgrading method and apparatus

Also Published As

Publication number Publication date
CN106445578A (en) 2017-02-22

Similar Documents

Publication Publication Date Title
CN106445578B (en) Remote hardware upgrading method and device and wireless temperature and humidity monitor
CN105573810A (en) Remote upgrade method and remote upgrade device for wireless sensor network node
CN106020066A (en) Animal body temperature concentrated monitoring device and system
CN103868551A (en) Real-time temperature and humidity data collection system and method for in-transit incubator of cold-chain logistics
CN104321775A (en) Device for collecting information for display and HMI system
RU2008146087A (en) CONTINUOUS TRANSFER DURING CHANGE ENCRYPTION CONFIGURATION
CN201345041Y (en) Field data acquisition terminal capable of upgrading programs remotely
CN107346244B (en) A kind of automobile EPS director demon automation download system and method
CN104345147A (en) Portable medical blood glucose detecting system with code scanner
CN104361730A (en) Data transferring system and data transferring method of intelligent metering device
CN103092648B (en) A kind of image upgrade method, system and subscriber equipment and personal computer
CN206075050U (en) Animal heat Centralizing inspection device and its system
CN201092778Y (en) Low-power consumption electronic lock pipe control circuit and key circuit
CN201533846U (en) Urinary disorder detecting system
CN112074796A (en) Device with a removable smart card
CN107481496A (en) A kind of field inspection data remote transmission system based on GPRS network and cloud platform
CN111624543B (en) Method and system for identifying gateway electric energy meter based on electronic ink label
CN104346590A (en) Screen control system and method
CN202458378U (en) Device for wirelessly transmitting data of glucose meter
CN207458309U (en) A kind of field inspection data remote transmission system based on GPRS network and cloud platform
CN111487901A (en) Remote control system and control method for ocean data buoy power supply
CN207234981U (en) It is a kind of can portable adjusting wireless video transmission system
JP2003309494A (en) Monitor, monitoring method, state display device and state displaying method
CN104579435A (en) Multiple-master-with-multiple-slave Bluetooth communication method for portable health examination box
CN116095624B (en) Heart monitor data acquisition system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant