CN114003394B - Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine - Google Patents

Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine Download PDF

Info

Publication number
CN114003394B
CN114003394B CN202111663452.4A CN202111663452A CN114003394B CN 114003394 B CN114003394 B CN 114003394B CN 202111663452 A CN202111663452 A CN 202111663452A CN 114003394 B CN114003394 B CN 114003394B
Authority
CN
China
Prior art keywords
flash
eeprom
idle
thermostat
value
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
CN202111663452.4A
Other languages
Chinese (zh)
Other versions
CN114003394A (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.)
Huato System Co ltd
Original Assignee
Huato System 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 Huato System Co ltd filed Critical Huato System Co ltd
Priority to CN202111663452.4A priority Critical patent/CN114003394B/en
Publication of CN114003394A publication Critical patent/CN114003394A/en
Application granted granted Critical
Publication of CN114003394B publication Critical patent/CN114003394B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5016Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3037Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a memory, e.g. virtual memory, cache
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3055Monitoring arrangements for monitoring the status of the computing system or of the computing system component, e.g. monitoring if the computing system is on, off, available, not available
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/508Monitor

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computing Systems (AREA)
  • Quality & Reliability (AREA)
  • Mathematical Physics (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The application relates to the technical field of Internet of things, and discloses a dynamic memory expansion method, device and thermostat for memory shortage of the thermostat, through obtaining the flash idle value of first equipment in wireless connection with the thermostat, the EEPROM idle value of second equipment and the idle occupation proportion of DDR memory of the thermostat, thus, when the memory of the thermostat is not enough, and when a task needs to be performed, the thread task can be sent to other equipment, thereby the flash idle operation of other equipment can be used, and the state record of completion of operation is saved in the EEPROM memory of other equipment, so that the situation that when the memory of the thermostat is not enough, the thermostat is jammed and slow in operation can be relieved.

Description

Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine
Technical Field
The application relates to the technical field of Internet of things, in particular to a dynamic memory expansion method and device for insufficient memory of a constant temperature machine and the constant temperature machine.
Background
With the continuous development of network technology, the internet of things is widely applied to various fields of life, such as smart home. A thermostat is a device in an intelligent home, and its memory is generally configured to a fixed capacity when it leaves the factory, and an expansion interface is not generally reserved for memory hardware expansion. However, the internet of things is a system platform with high expansibility, and household equipment can be flexibly increased and decreased according to the requirements of users. The thermostat is an important component of the internet of things, and in the operation process, because the thermostat often needs to communicate with various devices, such as a temperature sensor, a humidity sensor, a network terminal and the like, the number of interconnected devices connected to the thermostat is increased, and the memory of the thermostat cannot be improved in a hardware expansion mode, the thermostat often has the problem of insufficient memory in the operation process, and further the phenomenon of unsmooth and slow operation is shown.
Disclosure of Invention
The main purpose of the present application is to provide a dynamic memory expansion method for the shortage of the memory of the thermostat, and to solve the technical problem that the thermostat in the prior art is easy to operate slowly due to the shortage of the memory.
The application provides a dynamic memory expansion method for memory shortage of a constant temperature machine, which comprises the following steps:
acquiring a flash idle value of first equipment in wireless connection with a thermostat;
calculating a flash extensible byte of the thermostat according to the flash idle value, and judging a flash idle mode according to the flash extensible byte, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
acquiring an EEPROM idle value of second equipment wirelessly connected with the thermostat;
calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle value, and judging an EEPROM idle mode according to the EEPROM extensible bytes, wherein the EEPROM idle mode comprises an EEPROM high extensible mode and an EEPROM low extensible mode;
acquiring the idle occupation proportion of a DDR memory of the thermostat;
judging whether the idle occupation ratio is larger than a first preset value or not;
if the idle occupation ratio is larger than a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash high-extensibility mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after completion of operation to at least one second device corresponding to the EEPROM high-extensibility mode;
and if the idle occupation ratio is smaller than or equal to a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensible mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after the operation is completed to at least one second device corresponding to the EEPROM low-extensible mode.
Preferably, the step of acquiring a flash idle value of first equipment wirelessly connected with a thermostat, calculating a flash extensible byte of the thermostat according to the flash idle value, and judging a flash idle mode according to the flash extensible byte includes:
acquiring a first flash idle value of a screen display device in wireless connection with a thermostat;
acquiring a second flash idle value of the thermostat;
summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
acquiring an integral memory value of the thermostat;
subtracting the third flash idle value from the whole memory value to obtain a flash extensible byte of the thermostat;
judging whether the flash extensible byte is larger than a preset flash byte or not;
if the flash extensible byte is larger than the preset flash byte, judging that the flash idle mode is a flash high extensible mode;
acquiring a fourth flash idle value of the screen display-free equipment wirelessly connected with the thermostat;
calculating a difference value between the fourth flash idle value and the second flash idle value;
judging whether the difference value is larger than a preset difference value or not;
and if the difference is larger than the preset difference, judging that the flash idle mode is a flash low-extensible mode.
Preferably, the EEPROM idle value of the second device wirelessly connected with the thermostat is obtained; the steps of calculating the EEPROM extensible bytes of the thermostat according to the EEPROM idle value and judging the EEPROM idle mode according to the EEPROM extensible bytes comprise:
acquiring a first EEPROM idle value of second equipment wirelessly connected with a thermostat, wherein the second equipment comprises equipment with a memory function;
acquiring a second EEPROM idle value of the thermostat;
calculating an EEPROM difference value between the second EEPROM idle value and the first EEPROM idle value, wherein the difference value is an EEPROM extensible byte of the thermostat;
judging whether the EEPROM extensible bytes are larger than preset EEPROM bytes or not;
if the EEPROM extensible bytes are larger than the preset EEPROM bytes, judging that the current EEPROM idle mode is an EEPROM highly extensible mode;
and if the EEPROM extensible bytes are smaller than the preset EEPROM bytes, judging that the current EEPROM idle mode is an EEPROM low extensible mode.
Preferably, the step of obtaining the idle occupation ratio of the DDR memory of the thermostat includes, before the step of obtaining the idle occupation ratio of the DDR memory of the thermostat:
acquiring an idle memory of a DDR (double data rate) of the constant temperature machine;
acquiring the total available memory of the DDR of the constant temperature machine;
and calculating the ratio of the idle memory to the total available memory to obtain the idle memory occupation ratio of the DDR memory of the constant temperature machine.
Preferably, after the step of sending the thread task preset by the thermostat to the flash low-extensible mode, if the idle occupancy ratio is less than or equal to a first preset value, the method further includes:
acquiring dynamic memory expansion information;
and displaying the dynamic memory expansion information in a display screen, wherein the dynamic memory expansion information comprises flash memory expansion information, EEPROM memory expansion information and DDR memory expansion information of a thermostat.
The application also provides a dynamic memory extension device that is used for constant temperature machine memory not enough, includes:
the first acquisition module is used for acquiring a flash idle value of first equipment in wireless connection with the thermostat;
the first computing module is used for computing the flash extensible bytes of the thermostat according to the flash idle value and judging a flash idle mode according to the flash extensible bytes, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
the second acquisition module is used for acquiring an EEPROM idle value of second equipment wirelessly connected with the thermostat;
the second calculation module is used for calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle value and judging an EEPROM idle mode according to the EEPROM extensible bytes, wherein the EEPROM idle mode comprises an EEPROM high extensible mode and an EEPROM low extensible mode;
the third acquisition module is used for acquiring the idle occupation proportion of the DDR memory of the constant temperature machine;
the judging module is used for judging whether the idle occupation ratio is larger than a first preset value or not;
the first task scheduling module is used for sending a preset thread task of the thermostat to at least one first device corresponding to the flash highly-extensible mode if the idle occupation ratio is larger than a first preset value, calling a program of the first device to complete processing of the thread task, and storing a first state record after the operation is completed to at least one second device corresponding to the EEPROM highly-extensible mode;
and the second task scheduling module is used for sending a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensible mode if the idle occupation ratio is smaller than or equal to a first preset value, calling a program of the first device to complete processing of the thread task, and storing a first state record after the completion of operation in at least one second device corresponding to the EEPROM low-extensible mode.
Preferably, the first obtaining module includes:
the first acquisition unit is used for acquiring a first flash idle value of the screen display equipment in wireless connection with the thermostat;
the second acquisition unit is used for acquiring a second flash idle value of the thermostat;
the third acquisition unit is used for acquiring the integral memory value of the thermostat;
the fourth acquisition unit is used for acquiring a fourth flash idle value of the screen-free display device in wireless connection with the thermostat;
the first computing module includes:
the first computing unit is used for summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
the second computing unit is used for subtracting the third flash idle value from the whole memory value to obtain a flash extensible byte of the thermostat;
the first judging unit is used for judging whether the flash extensible bytes are larger than preset flash bytes or not;
the first judging unit is used for judging that the flash idle mode is a flash high-extensible mode if the flash extensible bytes are larger than preset flash bytes;
the third calculating unit is used for calculating the difference value between the fourth flash idle value and the second flash idle value;
the second judgment unit is used for judging whether the difference value is larger than a preset difference value or not;
and the second judgment unit is used for judging that the flash idle mode is a flash low extensible mode if the difference is larger than a preset difference.
Preferably, the second obtaining module includes:
the fifth acquisition unit is used for acquiring a first EEPROM idle value of second equipment wirelessly connected with the thermostat, wherein the second equipment comprises equipment with a memory function;
the sixth acquisition unit is used for acquiring a second EEPROM idle value of the thermostat;
the second calculation module includes:
a fourth calculating unit, configured to calculate an EEPROM difference between the second EEPROM idle value and the first EEPROM idle value, where the difference is an EEPROM scalable byte of the thermostat;
the third judging unit is used for judging whether the EEPROM extensible byte is larger than a preset EEPROM byte or not;
a third determination unit, configured to determine that the current EEPROM idle mode is an EEPROM highly scalable mode if the EEPROM scalable byte is larger than a preset EEPROM byte;
and the fourth judging unit is used for judging that the current EEPROM idle mode is the EEPROM low expandable mode if the EEPROM expandable byte is smaller than the preset EEPROM byte.
The application also provides a constant temperature machine, which comprises a storage and a processor, wherein the storage stores a computer program, and the processor executes the computer program to realize the steps of the dynamic memory expansion method for the insufficient memory of the constant temperature machine.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the above-described method for dynamic memory expansion for thermostat memory shortage.
The beneficial effect of this application does: by acquiring the flash idle value of the first device in wireless connection with the thermostat, the EEPROM idle value of the second device and the idle occupation proportion of the DDR memory of the thermostat, when the memory of the thermostat is insufficient and needs to perform task operation, the thread task can be sent to other devices, so that the thermostat can operate by means of the flash idle of other devices, and the state record of the operation completion is stored in the EEPROM memories of other devices, thereby relieving the condition that the thermostat is jammed and slow in operation when the memory of the thermostat is insufficient.
Drawings
Fig. 1 is a schematic flow chart of a dynamic memory expansion method for memory shortage of a thermostat according to an embodiment of the present application.
Fig. 2 is a schematic diagram illustrating a connection between a thermostat and first and second devices in a dynamic memory expansion method for a thermostat with insufficient memory according to an embodiment of the present application.
Fig. 3 is a schematic structural diagram of a dynamic memory expansion device for memory shortage of a thermostat according to an embodiment of the present application.
The implementation, functional features and advantages of the objectives of the present application will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
As shown in fig. 1 to fig. 3, the present application provides a dynamic memory expansion method for memory shortage of a thermostat, which includes:
s1, acquiring a flash idle value of first equipment in wireless connection with the thermostat;
s2, calculating a flash extensible byte of the thermostat according to the flash idle value, and judging a flash idle mode according to the flash extensible byte, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
s3, acquiring an EEPROM idle value of second equipment in wireless connection with the thermostat;
s4, calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle values, and judging EEPROM idle modes according to the EEPROM extensible bytes, wherein the EEPROM idle modes comprise an EEPROM high extensible mode and an EEPROM low extensible mode;
s5, acquiring the idle occupation proportion of the DDR memory of the thermostat;
s6, judging whether the idle occupation ratio is larger than a first preset value or not;
s7, if the idle occupation ratio is larger than a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash high-extensibility mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after operation completion to at least one second device corresponding to the EEPROM high-extensibility mode;
s8, if the idle occupation ratio is smaller than or equal to a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensibility mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after completion of running to at least one second device corresponding to the EEPROM low-extensibility mode.
As described in the above steps S1-S8, by obtaining the flash idle value of the first device, the EEPROM idle value of the second device, and the idle occupancy ratio of the DDR memory of the thermostat, which are wirelessly connected to the thermostat, when the memory of the thermostat is not sufficient and a task needs to be performed, the thread task can be sent to other devices, so that the thermostat can operate by using the flash idle of the other devices, and the state record of the completion of the operation is stored in the EEPROM memory of the other devices, which can alleviate the situation that the operation of the thermostat is stuck and slow when the memory of the thermostat is not sufficient. Specifically, when the EEPROM idle mode is the EEPROM highly extensible mode and the flash idle mode is the flash highly extensible mode, the devices wirelessly connected to the thermostat are usually a tablet computer, a mobile phone, a television, and the like with a screen display, so that a thread task requiring a large amount of memory for running can be sent to the flash highly extensible mode to help the task run by using the memories of the tablet computer, the mobile phone, and the television; when the EEPROM idle mode is the EEPROM low scalable mode and the flash idle mode is the flash low scalable mode, the devices wirelessly connected to the thermostat are generally devices without a screen display, such as a temperature sensor, a humidifier, a smart fan, and the like, and since the memory of these devices is relatively small, the devices are in the low scalable mode, and at this time, a small number of preset (with a small memory requirement) thread tasks may be sent to the temperature sensor, the humidifier, and the smart fan in the low scalable mode.
In one embodiment, the steps S1-S2 of obtaining a flash idle value of a first device wirelessly connected to a thermostat, calculating a flash extensible byte of the thermostat according to the flash idle value, and determining a flash idle mode according to the flash extensible byte include:
s11, acquiring a first flash idle value of a screen display device in wireless connection with the thermostat;
s12, acquiring a second flash idle value of the thermostat;
s21, summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
s13, acquiring the integral memory value of the thermostat;
s22, subtracting the third flash idle value from the whole memory value to obtain flash extensible bytes of the thermostat;
s23, judging whether the flash extensible byte is larger than a preset flash byte or not;
s24, if the flash extensible byte is larger than a preset flash byte, judging that the flash idle mode is a flash high extensible mode;
s14, acquiring a fourth flash idle value of the screen-free display device in wireless connection with the thermostat;
s25, calculating a difference value between the fourth flash idle value and the second flash idle value;
s26, judging whether the difference value is larger than a preset difference value or not;
and S27, if the difference is larger than the preset difference, determining that the flash idle mode is a flash low-extensible mode.
As described in the above steps S11-S27, by obtaining the first idle value, the second idle value, and the entire memory value of the thermostat, the flash extensible byte of the thermostat can be calculated, and if the flash extensible byte is larger than the preset flash byte, it represents that the screen display device currently connected to the thermostat has a large amount of flash memory for the thermostat to operate; in addition, a fourth flash idle value of the non-screen display device wirelessly connected with the thermostat can be obtained, and a difference value between the fourth flash idle value and the second flash idle value is calculated, if the difference value is greater than a preset difference value, it represents that the non-screen display device currently connected with the thermostat also has a flash memory for the thermostat to run, the on-screen display device is generally a device with a larger memory, such as a tablet computer, and the non-screen display device is generally a device with a smaller memory, such as a humidifier.
In one embodiment, the obtaining of the EEPROM idle value of the second device wirelessly connected to the thermostat; steps S3-S4 of calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle values and judging an EEPROM idle mode according to the EEPROM extensible bytes, including:
s31, acquiring a first EEPROM idle value of second equipment in wireless connection with the thermostat, wherein the second equipment comprises equipment with a memory function;
s32, acquiring a second EEPROM idle value of the thermostat;
s41, calculating an EEPROM difference value between the second EEPROM idle value and the first EEPROM idle value, wherein the difference value is an EEPROM expandable byte of the thermostat;
s42, judging whether the EEPROM extensible byte is larger than a preset EEPROM byte or not;
s43, if the EEPROM extensible bytes are larger than the preset EEPROM bytes, judging that the current EEPROM idle mode is an EEPROM highly extensible mode;
and S44, if the EEPROM extensible byte is smaller than the preset EEPROM byte, determining that the current EEPROM idle mode is the EEPROM low extensible mode.
As described in the above steps S31-S44, when obtaining the memory function, the thermostat first detects each device connected to the thermostat, whether the device has an EEPROM memory, if the device has the EEPROM memory, the device is marked as a device with the memory function, and then obtains a first EEPROM idle value of the device with the memory function and a second EEPROM idle value of the thermostat, so as to calculate an EEPROM extensible byte of the thermostat according to a difference between the two values, if the EEPROM extensible byte is greater than the preset EEPROM byte, the device is currently in an EEPROM highly extensible mode, the device with the memory function in this mode is generally a television, a computer, or the like, if the EEPROM extensible byte is less than or equal to the preset EEPROM byte, the device with the memory function in this mode is generally in an EEPROM low extensible mode, and the device with the memory function in this mode is generally a temperature sensor, an intelligent humidifier, an intelligent fan, or the like.
In one embodiment, the step of obtaining the idle occupancy ratio of the DDR memory of the thermostat before S5 includes:
s51, acquiring an idle memory of a DDR (double data rate) of the thermostat;
s52, acquiring the total available memory of the DDR of the thermostat;
and S53, calculating the ratio of the free memory to the total available memory to obtain the occupation ratio of the free memory of the DDR memory of the thermostat.
As described in the above steps S51-S53, by obtaining the idle memory of the DDR of the thermostat and the total available memory of the DDR, the idle memory occupancy ratio of the DDR memory of the thermostat can be calculated, and thus, the thread task can be selectively sent to the flash high expandable mode or the flash low expandable mode according to the idle memory occupancy ratio, and the thermostat can be prevented from operating in a stuck and slow manner.
In an embodiment, if the idle occupancy ratio is less than or equal to the first preset value, S8 after the step of sending the thread task preset by the thermostat to the flash low extensible mode further includes:
s81, acquiring dynamic memory expansion information;
s82, displaying the dynamic memory expansion information in a display screen, wherein the dynamic memory expansion information comprises flash memory expansion information, EEPROM memory expansion information and DDR memory expansion information of a thermostat.
As described in the above steps S81-S82, after the thermostat performs task operation by using the devices wirelessly connected to the thermostat, the operating memory and the memory result of each device can be obtained, and the result is displayed on the display screen, so that the specific information of the memory extended operation can be more intuitively understood.
The application also provides a dynamic memory extension device for the memory shortage of the constant temperature machine, which comprises:
the first acquisition module 1 is used for acquiring a flash idle value of first equipment in wireless connection with the thermostat;
the first computing module 2 is used for computing the flash extensible bytes of the thermostat according to the flash idle values and judging a flash idle mode according to the flash extensible bytes, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
the second acquisition module 3 is used for acquiring an EEPROM idle value of second equipment wirelessly connected with the thermostat;
the second calculation module 4 is used for calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle value and judging an EEPROM idle mode according to the EEPROM extensible bytes, wherein the EEPROM idle mode comprises an EEPROM high extensible mode and an EEPROM low extensible mode;
the third acquisition module 5 is used for acquiring the idle occupation proportion of the DDR memory of the constant temperature machine;
the judging module 6 is used for judging whether the idle occupation ratio is larger than a first preset value or not;
the first task scheduling module 7 is configured to send a preset thread task of the thermostat to at least one first device corresponding to the flash highly extensible mode if the idle occupancy ratio is greater than a first preset value, call a program of the first device to complete processing of the thread task, and store a first state record after completion of operation in at least one second device corresponding to the EEPROM highly extensible mode;
and the second task scheduling module 8 is configured to send a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensibility mode if the idle occupancy ratio is less than or equal to a first preset value, call a program of the first device to complete processing of the thread task, and store a first state record after completion of operation in at least one second device corresponding to the EEPROM low-extensibility mode.
In one embodiment, the first obtaining module comprises:
the first acquisition unit is used for acquiring a first flash idle value of the screen display equipment in wireless connection with the thermostat;
the second acquisition unit is used for acquiring a second flash idle value of the thermostat;
the third acquisition unit is used for acquiring the integral memory value of the thermostat;
the fourth acquisition unit is used for acquiring a fourth flash idle value of the screen-free display device in wireless connection with the thermostat;
the first computing module includes:
the first computing unit is used for summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
the second computing unit is used for subtracting the third flash idle value from the whole memory value to obtain a flash extensible byte of the thermostat;
the first judging unit is used for judging whether the flash extensible bytes are larger than preset flash bytes or not;
the first judging unit is used for judging that the flash idle mode is a flash high-extensible mode if the flash extensible bytes are larger than preset flash bytes;
the third calculating unit is used for calculating the difference value between the fourth flash idle value and the second flash idle value;
the second judgment unit is used for judging whether the difference value is larger than a preset difference value or not;
and the second judgment unit is used for judging that the flash idle mode is a flash low extensible mode if the difference is larger than a preset difference.
In one embodiment, the second obtaining module includes:
the fifth acquisition unit is used for acquiring a first EEPROM idle value of second equipment wirelessly connected with the thermostat, wherein the second equipment comprises equipment with a memory function;
the sixth acquisition unit is used for acquiring a second EEPROM idle value of the thermostat;
the second calculation module includes:
a fourth calculating unit, configured to calculate an EEPROM difference between the second EEPROM idle value and the first EEPROM idle value, where the difference is an EEPROM scalable byte of the thermostat;
the third judging unit is used for judging whether the EEPROM extensible byte is larger than a preset EEPROM byte or not;
a third determination unit, configured to determine that the current EEPROM idle mode is an EEPROM highly scalable mode if the EEPROM scalable byte is larger than a preset EEPROM byte;
and the fourth judging unit is used for judging that the current EEPROM idle mode is the EEPROM low expandable mode if the EEPROM expandable byte is smaller than the preset EEPROM byte.
In one embodiment, the dynamic memory expansion device for the memory shortage of the constant temperature machine further comprises:
the fourth acquisition module is used for acquiring the idle memory of the DDR of the constant temperature machine;
the fifth acquisition module is used for acquiring the total available memory of the DDR of the constant temperature machine;
and the third calculation module is used for calculating the ratio of the idle memory to the total available memory to obtain the idle memory occupation ratio of the DDR memory of the thermostat.
In one embodiment, the dynamic memory expansion device for the memory shortage of the constant temperature machine further comprises:
a sixth obtaining module, configured to obtain dynamic memory extension information;
and the display module is used for displaying the dynamic memory expansion information in a display screen, wherein the dynamic memory expansion information comprises flash memory expansion information, EEPROM memory expansion information and DDR memory expansion information of the thermostat.
As shown in fig. 3, the present application also provides a thermostat machine, the internal structure of which may be as shown in fig. 3. The thermostat includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the thermostat design is configured to provide computing and control capabilities. The storage of the thermostat comprises a nonvolatile storage medium and an internal storage. The non-volatile storage medium stores an operating system, a computer program, and a database. The memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the thermostat machine is used for storing all data required by the process of the dynamic memory expansion method for the shortage of the memory of the thermostat machine. The network interface of the thermostat is used for connecting and communicating with an external terminal through a network. The computer program is executed by a processor to implement a dynamic memory expansion method for thermostat memory shortage.
Those skilled in the art will appreciate that the architecture shown in fig. 3 is only a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects may be applied.
An embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the method for dynamic memory expansion for memory shortage of a thermostat is implemented.
It will be understood by those skilled in the art that all or part of the processes of the methods of the above embodiments may be implemented by hardware associated with instructions of a computer program, which may be stored on a non-volatile computer-readable storage medium, and when executed, may include processes of the above embodiments of the methods. Any reference to memory, storage, database, or other medium provided herein and used in the examples may include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), double-rate SDRAM (SSRSDRAM), Enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, apparatus, article, or method. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, apparatus, article, or method that includes the element.
The above description is only a preferred embodiment of the present application, and not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application, or which are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (9)

1. A dynamic memory expansion method for memory shortage of a constant temperature machine is characterized by comprising the following steps:
acquiring a flash idle value of first equipment in wireless connection with a thermostat;
calculating a flash extensible byte of the thermostat according to the flash idle value, and judging a flash idle mode according to the flash extensible byte, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
acquiring an EEPROM idle value of second equipment wirelessly connected with the thermostat;
calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle value, and judging an EEPROM idle mode according to the EEPROM extensible bytes, wherein the EEPROM idle mode comprises an EEPROM high extensible mode and an EEPROM low extensible mode;
acquiring the idle occupation proportion of a DDR memory of the thermostat;
judging whether the idle occupation ratio is larger than a first preset value or not;
if the idle occupation ratio is larger than a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash high-extensibility mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after completion of operation to at least one second device corresponding to the EEPROM high-extensibility mode;
and if the idle occupation ratio is smaller than or equal to a first preset value, sending a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensible mode, calling a program of the first device to complete processing of the thread task, and storing a first state record after the operation is completed to at least one second device corresponding to the EEPROM low-extensible mode.
2. The dynamic memory expansion method for the shortage of the memory of the thermostat according to claim 1, wherein the step of obtaining a flash idle value of a first device wirelessly connected to the thermostat, calculating a flash expandable byte of the thermostat according to the flash idle value, and determining a flash idle mode according to the flash expandable byte comprises:
acquiring a first flash idle value of a screen display device in wireless connection with a thermostat;
acquiring a second flash idle value of the thermostat;
summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
acquiring an integral memory value of the thermostat;
subtracting the third flash idle value from the whole memory value to obtain a flash extensible byte of the thermostat;
judging whether the flash extensible byte is larger than a preset flash byte or not;
if the flash extensible byte is larger than the preset flash byte, judging that the flash idle mode is a flash high extensible mode;
acquiring a fourth flash idle value of the screen display-free equipment wirelessly connected with the thermostat;
calculating a difference value between the fourth flash idle value and the second flash idle value;
judging whether the difference value is larger than a preset difference value or not;
and if the difference is larger than the preset difference, judging that the flash idle mode is a flash low-extensible mode.
3. The dynamic memory expansion method for the shortage of the memory of the thermostat machine according to claim 1, wherein the EEPROM idle value of the second device wirelessly connected to the thermostat machine is obtained; the steps of calculating the EEPROM extensible bytes of the thermostat according to the EEPROM idle value and judging the EEPROM idle mode according to the EEPROM extensible bytes comprise:
acquiring a first EEPROM idle value of second equipment wirelessly connected with a thermostat, wherein the second equipment comprises equipment with a memory function;
acquiring a second EEPROM idle value of the thermostat;
calculating an EEPROM difference value between the second EEPROM idle value and the first EEPROM idle value, wherein the difference value is an EEPROM extensible byte of the thermostat;
judging whether the EEPROM extensible bytes are larger than preset EEPROM bytes or not;
if the EEPROM extensible bytes are larger than the preset EEPROM bytes, judging that the current EEPROM idle mode is an EEPROM highly extensible mode;
and if the EEPROM extensible bytes are smaller than the preset EEPROM bytes, judging that the current EEPROM idle mode is an EEPROM low extensible mode.
4. The dynamic memory expansion method for the shortage of the memory of the thermostat according to claim 1, wherein before the step of obtaining the idle occupation ratio of the DDR memory of the thermostat, the method comprises:
acquiring an idle memory of a DDR (double data rate) of the constant temperature machine;
acquiring the total available memory of the DDR of the constant temperature machine;
and calculating the ratio of the idle memory to the total available memory to obtain the idle memory occupation ratio of the DDR memory of the constant temperature machine.
5. The dynamic memory expansion method for the shortage of the memory of the constant temperature machine according to claim 1, wherein after the step of sending the thread task preset by the constant temperature machine to the at least one first device corresponding to the flash low expandable mode if the idle occupancy ratio is less than or equal to the first preset value, the method further comprises:
acquiring dynamic memory expansion information;
and displaying the dynamic memory expansion information in a display screen, wherein the dynamic memory expansion information comprises flash memory expansion information, EEPROM memory expansion information and DDR memory expansion information of a thermostat.
6. A dynamic memory expansion device for memory shortage of a constant temperature machine is characterized by comprising:
the first acquisition module is used for acquiring a flash idle value of first equipment in wireless connection with the thermostat;
the first computing module is used for computing the flash extensible bytes of the thermostat according to the flash idle value and judging a flash idle mode according to the flash extensible bytes, wherein the flash idle mode comprises a flash high extensible mode and a flash low extensible mode;
the second acquisition module is used for acquiring an EEPROM idle value of second equipment wirelessly connected with the thermostat;
the second calculation module is used for calculating EEPROM extensible bytes of the thermostat according to the EEPROM idle value and judging an EEPROM idle mode according to the EEPROM extensible bytes, wherein the EEPROM idle mode comprises an EEPROM high extensible mode and an EEPROM low extensible mode;
the third acquisition module is used for acquiring the idle occupation proportion of the DDR memory of the constant temperature machine;
the judging module is used for judging whether the idle occupation ratio is larger than a first preset value or not;
the first task scheduling module is used for sending a preset thread task of the thermostat to at least one first device corresponding to the flash highly-extensible mode if the idle occupation ratio is larger than a first preset value, calling a program of the first device to complete processing of the thread task, and storing a first state record after the operation is completed to at least one second device corresponding to the EEPROM highly-extensible mode;
and the second task scheduling module is used for sending a preset thread task of the thermostat to at least one first device corresponding to the flash low-extensible mode if the idle occupation ratio is smaller than or equal to a first preset value, calling a program of the first device to complete processing of the thread task, and storing a first state record after the completion of operation in at least one second device corresponding to the EEPROM low-extensible mode.
7. The dynamic memory expansion device for the memory shortage of the constant temperature machine according to claim 6, wherein the first obtaining module comprises:
the first acquisition unit is used for acquiring a first flash idle value of the screen display equipment in wireless connection with the thermostat;
the second acquisition unit is used for acquiring a second flash idle value of the thermostat;
the third acquisition unit is used for acquiring the integral memory value of the thermostat;
the fourth acquisition unit is used for acquiring a fourth flash idle value of the screen-free display device in wireless connection with the thermostat;
the first computing module includes:
the first computing unit is used for summing the first flash idle value and the second flash idle value to obtain a third flash idle value;
the second computing unit is used for subtracting the third flash idle value from the whole memory value to obtain a flash extensible byte of the thermostat;
the first judging unit is used for judging whether the flash extensible bytes are larger than preset flash bytes or not;
the first judging unit is used for judging that the flash idle mode is a flash high-extensible mode if the flash extensible bytes are larger than preset flash bytes;
the third calculating unit is used for calculating the difference value between the fourth flash idle value and the second flash idle value;
the second judgment unit is used for judging whether the difference value is larger than a preset difference value or not;
and the second judgment unit is used for judging that the flash idle mode is a flash low extensible mode if the difference is larger than a preset difference.
8. The dynamic memory expansion device for the memory shortage of the constant temperature machine according to claim 6, wherein the second obtaining module comprises:
the fifth acquisition unit is used for acquiring a first EEPROM idle value of second equipment wirelessly connected with the thermostat, wherein the second equipment comprises equipment with a memory function;
the sixth acquisition unit is used for acquiring a second EEPROM idle value of the thermostat;
the second calculation module includes:
a fourth calculating unit, configured to calculate an EEPROM difference between the second EEPROM idle value and the first EEPROM idle value, where the difference is an EEPROM scalable byte of the thermostat;
the third judging unit is used for judging whether the EEPROM extensible byte is larger than a preset EEPROM byte or not;
a third determination unit, configured to determine that the current EEPROM idle mode is an EEPROM highly scalable mode if the EEPROM scalable byte is larger than a preset EEPROM byte;
and the fourth judging unit is used for judging that the current EEPROM idle mode is the EEPROM low expandable mode if the EEPROM expandable byte is smaller than the preset EEPROM byte.
9. A thermostat comprising a memory and a processor, the memory storing a computer program, characterized in that the processor, when executing the computer program, implements the steps of the method for dynamic memory expansion for thermostat memory shortage of any one of claims 1 to 5.
CN202111663452.4A 2021-12-31 2021-12-31 Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine Active CN114003394B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111663452.4A CN114003394B (en) 2021-12-31 2021-12-31 Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111663452.4A CN114003394B (en) 2021-12-31 2021-12-31 Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine

Publications (2)

Publication Number Publication Date
CN114003394A CN114003394A (en) 2022-02-01
CN114003394B true CN114003394B (en) 2022-03-29

Family

ID=79932470

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111663452.4A Active CN114003394B (en) 2021-12-31 2021-12-31 Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine

Country Status (1)

Country Link
CN (1) CN114003394B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102209103A (en) * 2010-03-29 2011-10-05 英特尔公司 Multicasting write requests to multiple storage controllers
CN103150132A (en) * 2013-02-21 2013-06-12 海信集团有限公司 Screen transmission method and electronic equipment
CN104170309A (en) * 2014-02-27 2014-11-26 华为技术有限公司 Resource management method and resource management device
CN106959893A (en) * 2017-03-31 2017-07-18 联想(北京)有限公司 Accelerator, EMS memory management process and data handling system for accelerator
CN112905598A (en) * 2021-03-15 2021-06-04 上海交通大学 Interface-based graph task intermediate result storage method and system for realizing separation

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9471369B2 (en) * 2014-04-01 2016-10-18 Xerox Corporation Methods and systems for sharing computational resources

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102209103A (en) * 2010-03-29 2011-10-05 英特尔公司 Multicasting write requests to multiple storage controllers
CN103150132A (en) * 2013-02-21 2013-06-12 海信集团有限公司 Screen transmission method and electronic equipment
CN104170309A (en) * 2014-02-27 2014-11-26 华为技术有限公司 Resource management method and resource management device
CN106959893A (en) * 2017-03-31 2017-07-18 联想(北京)有限公司 Accelerator, EMS memory management process and data handling system for accelerator
CN112905598A (en) * 2021-03-15 2021-06-04 上海交通大学 Interface-based graph task intermediate result storage method and system for realizing separation

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Evaluating the Benefits of An Extended Memory Hierarchy for Parallel Streamline Algorithms;David Camp et.al;《IEEE Symposium on Large Data Analysis and Visualization》;20111024;第57-64页 *
面向大数据处理的基于Spark的异质内存编程框架;王晨曦 等;《计算机研究与发展》;20181231;第246-264页 *

Also Published As

Publication number Publication date
CN114003394A (en) 2022-02-01

Similar Documents

Publication Publication Date Title
AU2021107642A4 (en) Method, device, computer device and storage medium for detecting abnormal state of energy consumption
CN110187753B (en) Application program control method, device, terminal and computer readable storage medium
CN108848142B (en) Message pushing method and device, computer equipment and storage medium
CN105204871A (en) Plug-in type development method and device
CN110826978A (en) Unified backlog processing method and device based on enterprise browser
CN105630531A (en) Display method and device of application operating state of mobile terminal
CN114003394B (en) Dynamic memory expansion method and device for memory shortage of constant temperature machine and constant temperature machine
CN108241516B (en) Embedded system program loading method and device, computer equipment and storage medium
CN115406063A (en) Method, device, terminal and storage medium for automatically controlling terminal equipment
CN107341007B (en) Display terminal, timing starting method thereof and computer readable storage medium
CN110074596B (en) Electric bed resetting method and device, computer equipment and storage medium
CN109857344B (en) Heartbeat state judgment method and device based on shared memory and computer equipment
CN110134475B (en) Method and device for displaying interface parameter configuration, computer equipment and storage medium
CN114517971A (en) Air conditioner constant temperature control method and system, related equipment and air conditioner
CN111148054B (en) Traffic switching use method, device and storage medium
CN114928538A (en) Equipment configuration processing method and device, computer equipment and storage medium
CN110889524B (en) Power failure reservation application processing method and device, computer equipment and medium
CN114079588B (en) Equipment control method, device, server and storage medium
CN112969166A (en) Mobile terminal Bluetooth upgrading processing method and device, terminal equipment and medium
CN109582680B (en) Business processing method based on new product development, electronic device and readable storage medium
CN114281445A (en) Page display method and device, electronic equipment and storage medium
CN111158819A (en) Interface state determination method, device, equipment and storage medium
CN108834087B (en) Short message sending method and device, computer equipment and storage medium
CN112148191A (en) Test image uploading method, device, equipment and storage medium based on browser
CN111177603A (en) Traffic-saving management and control method, system, computer equipment and storage medium

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