[go: up one dir, main page]

CN114443070A - Air conditioner and method for burning internal storage space of microcontroller of air conditioner - Google Patents

Air conditioner and method for burning internal storage space of microcontroller of air conditioner Download PDF

Info

Publication number
CN114443070A
CN114443070A CN202111672525.6A CN202111672525A CN114443070A CN 114443070 A CN114443070 A CN 114443070A CN 202111672525 A CN202111672525 A CN 202111672525A CN 114443070 A CN114443070 A CN 114443070A
Authority
CN
China
Prior art keywords
microcontroller
data
mcu
air conditioner
external
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111672525.6A
Other languages
Chinese (zh)
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.)
Hisense Shandong Air Conditioning Co Ltd
Original Assignee
Hisense Shandong Air Conditioning 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 Hisense Shandong Air Conditioning Co Ltd filed Critical Hisense Shandong Air Conditioning Co Ltd
Priority to CN202111672525.6A priority Critical patent/CN114443070A/en
Publication of CN114443070A publication Critical patent/CN114443070A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order
    • FMECHANICAL ENGINEERING; LIGHTING; HEATING; WEAPONS; BLASTING
    • F24HEATING; RANGES; VENTILATING
    • F24FAIR-CONDITIONING; AIR-HUMIDIFICATION; VENTILATION; USE OF AIR CURRENTS FOR SCREENING
    • F24F11/00Control or safety arrangements
    • F24F11/62Control or safety arrangements characterised by the type of control or by internal processing, e.g. using fuzzy logic, adaptive control or estimation of values
    • F24F11/63Electronic processing

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Fuzzy Systems (AREA)
  • Mathematical Physics (AREA)
  • Chemical & Material Sciences (AREA)
  • Combustion & Propulsion (AREA)
  • Mechanical Engineering (AREA)
  • Air Conditioning Control Device (AREA)

Abstract

The invention discloses an air conditioner and a burning method for an internal storage space of a microcontroller of the air conditioner, wherein the air conditioner comprises an external burner and the microcontroller, and the microcontroller is configured as follows: when the MCU receives a read command, returning data corresponding to the address to the external burner according to the address sent by the external burner; and when the MCU receives a write command, writing the data to be written into the corresponding area of the MCU according to the address sent by the external burner and the data to be written, thereby realizing the purposes of improving the universality of the MCU burning produced by various manufacturers and reducing the cost.

Description

一种空调器和空调器微控制器内部存储空间烧录方法An air conditioner and an air conditioner microcontroller internal storage space programming method

技术领域technical field

本申请涉及空调器技术领域,更具体地,涉及一种空调器和空调器微控制器内部存储空间烧录方法。The present application relates to the technical field of air conditioners, and more particularly, to an air conditioner and a method for burning the internal storage space of an air conditioner microcontroller.

背景技术Background technique

在空调行业中,通常采用外部存储介质存储部分数据,其存储的这部分数据可以包含运行信息、机型信息、保护状态数据等,MCU通过读取这些数据,搭配自身程序实现产品功能。之前行业中通常采用外部eeprom作为存储介质,因eeprom设计端采用IIC的通讯方式进行数据烧录和读取,因此控制器芯片(MCU等)和eeprom采用也采用此种方式进行数据交互。In the air-conditioning industry, an external storage medium is usually used to store part of the data. This part of the data stored can include operation information, model information, protection status data, etc. The MCU reads these data and implements product functions with its own program. In the past, the external eeprom was usually used as the storage medium. Because the eeprom design side uses the IIC communication method for data programming and reading, the controller chip (MCU, etc.) and the eeprom also use this method for data interaction.

但是随着MCU的发展,其内部增加了增加了内部存储空间的功能,可以替代空调器原有的eeprom,存储空调器需要的运行数据。这样做对空调器整机来说,不改变功能以及整体的软件实现形式,同时可以减少eeprom IC等元器件,降低产品成本。However, with the development of the MCU, the function of increasing the internal storage space has been added, which can replace the original eeprom of the air conditioner and store the operating data required by the air conditioner. This does not change the function and overall software implementation form of the whole air conditioner, at the same time, it can reduce components such as eeprom IC and reduce product cost.

MCU有自己独有烧写系统,包括烧录工具、烧写端口和烧写方式等,其相比于eeprom的IIC烧写方式比较复杂。MCU的烧写系统和之前的eeprom烧写系统是完全不一致的,即不能兼容目前的生产、售后等,兼容性差。采用MCU的烧写系统,可以实现其内部存储空间的读写,但是MCU的烧写系统通常比较复杂,成本也较高。同时每个MCU厂家的设计都由差异,其烧写系统也各不相同,难以兼容,即通用型很差。MCU has its own unique programming system, including programming tools, programming ports and programming methods, etc., which is more complicated than eeprom's IIC programming method. The MCU programming system is completely inconsistent with the previous eeprom programming system, that is, it is not compatible with the current production, after-sales, etc., and the compatibility is poor. Using the MCU programming system can realize the reading and writing of its internal storage space, but the MCU programming system is usually more complicated and the cost is higher. At the same time, the design of each MCU manufacturer is different, and its programming system is also different, which is difficult to be compatible, that is, the general-purpose type is very poor.

因此如何提供一种空调器及空调器微控制器内部存储空间烧录方法,用以提高MCU烧录的通用性,降低成本,是目前有待解决的技术问题。Therefore, how to provide an air conditioner and a method for programming the internal storage space of the microcontroller of the air conditioner to improve the versatility of MCU programming and reduce costs is a technical problem to be solved at present.

发明内容SUMMARY OF THE INVENTION

本发明提供一种空调器,用以解决现有技术中每个MCU厂家的设计都由差异,其烧写系统也各不相同,难以兼容,即通用型很差的技术问题。The invention provides an air conditioner, which is used to solve the technical problem that the design of each MCU manufacturer in the prior art is different, the programming systems thereof are also different, and compatibility is difficult, that is, the general type is poor.

该空调器包括:The air conditioner includes:

外部烧录器,与空调器MCU通过IIC进行数据交互;External programmer, to exchange data with the air conditioner MCU through IIC;

MCU微控制器,设置有DATAFLASH空间,所述空间用于参数存储;The MCU microcontroller is provided with a DATAFLASH space, and the space is used for parameter storage;

所述MCU,被配置为:The MCU, is configured to:

当所述MCU接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器;After the MCU receives the read command, it returns the data corresponding to the address to the external programmer according to the address sent by the external programmer;

当所述MCU接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述MCU的对应区域内。When the MCU receives the write command, the data to be written is written into the corresponding area of the MCU according to the address sent by the external programmer and the data to be written.

在本申请一些实施例中,所述微控制器与所述外部烧录器之间的数据协议和EEPROM的烧写协议一致。In some embodiments of the present application, the data protocol between the microcontroller and the external programmer is consistent with the programming protocol of the EEPROM.

在本申请一些实施例中,所述外部烧录器与所述微控制器的reset,以实现在所述烧录器工作时,拉低reset信号,使所述微控制器不工作。In some embodiments of the present application, the external programmer and the microcontroller are reset, so as to pull down the reset signal when the programmer is working, so that the microcontroller does not work.

在本申请一些实施例中,所述DATAFLASH空间为用于实现数据存储的区域。In some embodiments of the present application, the DATAFLASH space is an area for implementing data storage.

相应的,本发明还提出了一种空调器微控制器内部存储空间烧录方法,应用于包括外部烧录器及微控制器的空调器中,所述方法包括:Correspondingly, the present invention also proposes a method for programming the internal storage space of an air conditioner microcontroller, which is applied to an air conditioner including an external programmer and a microcontroller, and the method includes:

当所述微控制器接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器;After the microcontroller receives the read command, it returns the data corresponding to the address to the external programmer according to the address sent by the external programmer;

当所述微控制器接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述微控制器的对应区域内。When the microcontroller receives the write command, the data to be written is written into the corresponding area of the microcontroller according to the address sent by the external programmer and the data to be written.

在本申请一些实施例中,所述微控制器与所述外部烧录器之间的数据协议和EEPROM的烧写协议一致。In some embodiments of the present application, the data protocol between the microcontroller and the external programmer is consistent with the programming protocol of the EEPROM.

在本申请一些实施例中,所述外部烧录器与所述微控制器的reset,以实现在所述烧录器工作时,拉低reset信号,使所述微控制器不工作。In some embodiments of the present application, the external programmer and the microcontroller are reset, so as to pull down the reset signal when the programmer is working, so that the microcontroller does not work.

在本申请一些实施例中,所述DATAFLASH空间为用于实现数据存储的区域。In some embodiments of the present application, the DATAFLASH space is an area for implementing data storage.

通过应用以上技术方案,在包括外部烧录器及微控制器的空调器中,微控制器被配置为:当所述MCU接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器;当所述MCU接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述MCU的对应区域内,从而实现提高各厂商生产的MCU烧录的通用性,降低成本。By applying the above technical solutions, in an air conditioner including an external programmer and a microcontroller, the microcontroller is configured to: after the MCU receives the read command, according to the address sent by the external programmer, The data corresponding to the address is returned to the external programmer; when the MCU receives the write command, the data to be written is written into the data according to the address sent by the external programmer and the data to be written In the corresponding area of MCU, so as to improve the versatility of MCU programming produced by various manufacturers and reduce costs.

附图说明Description of drawings

为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions in the embodiments of the present application more clearly, the following briefly introduces the drawings that are used in the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those skilled in the art, other drawings can also be obtained from these drawings without creative effort.

图1示出了本发明实施例中外置eeprom的数据交互方式的示意图;1 shows a schematic diagram of a data interaction mode of an external eeprom in an embodiment of the present invention;

图2示出了本发明实施例中MCU内置存储空间的数据交互方式的示意图FIG. 2 is a schematic diagram showing a data interaction mode of a built-in storage space of an MCU in an embodiment of the present invention

图3示出了本发明实施例提出的一种空调器微控制器内部存储空间烧录方法的流程示意图。FIG. 3 shows a schematic flowchart of a method for programming an internal storage space of an air conditioner microcontroller according to an embodiment of the present invention.

具体实施方式Detailed ways

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.

术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括一个或者更多个该特征。在本申请的描述中,除非另有说明,“多个”的含义是两个或两个以上。The terms "first" and "second" are only used for descriptive purposes, and should not be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may expressly or implicitly include one or more of that feature. In the description of this application, unless stated otherwise, "plurality" means two or more.

本申请实施例提供一种空调器,包括:An embodiment of the present application provides an air conditioner, including:

外部烧录器,与空调器MCU通过IIC进行数据交互;External programmer, to exchange data with the air conditioner MCU through IIC;

MCU微控制器,设置有DATAFLASH空间,所述空间用于参数存储;The MCU microcontroller is provided with a DATAFLASH space, and the space is used for parameter storage;

所述MCU,被配置为:The MCU, is configured to:

当所述MCU接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器;After the MCU receives the read command, it returns the data corresponding to the address to the external programmer according to the address sent by the external programmer;

当所述MCU接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述MCU的对应区域内。When the MCU receives the write command, the data to be written is written into the corresponding area of the MCU according to the address sent by the external programmer and the data to be written.

本实施例中,如背景技术所述,在空调行业中,通常采用外部存储介质存储部分数据,其存储的这部分数据可以包含运行信息、机型信息、保护状态数据等,MCU通过读取这些数据,搭配自身程序实现产品功能。之前行业中通常采用外部eeprom作为存储介质,因eeprom设计端采用IIC的通讯方式进行数据烧录和读取,因此控制器芯片(MCU等)和eeprom采用也采用此种方式进行数据交互。In this embodiment, as described in the background art, in the air-conditioning industry, an external storage medium is usually used to store some data, and the stored data may include operation information, model information, protection status data, etc., and the MCU reads these data by reading these data. Data, with its own program to achieve product functions. In the past, the external eeprom was usually used as the storage medium. Because the eeprom design side uses the IIC communication method for data programming and reading, the controller chip (MCU, etc.) and the eeprom also use this method for data interaction.

但是随着MCU的发展,其内部增加了增加了内部存储空间的功能,可以替代空调器原有的eeprom,存储空调器需要的运行数据。这样做对空调器整机来说,不改变功能以及整体的软件实现形式,同时可以减少eeprom IC等元器件,降低产品成本。However, with the development of the MCU, the function of increasing the internal storage space has been added, which can replace the original eeprom of the air conditioner and store the operating data required by the air conditioner. This does not change the function and overall software implementation form of the whole air conditioner, at the same time, it can reduce components such as eeprom IC and reduce product cost.

MCU有自己独有烧写系统,包括烧录工具、烧写端口和烧写方式等,其相比于eeprom的IIC烧写方式比较复杂。MCU的烧写系统和之前的eeprom烧写系统是完全不一致的,即不能兼容目前的生产、售后等,兼容性差。采用MCU的烧写系统,可以实现其内部存储空间的读写,但是MCU的烧写系统通常比较复杂,成本也较高。同时每个MCU厂家的设计都由差异,其烧写系统也各不相同,难以兼容,即通用型很差。MCU has its own unique programming system, including programming tools, programming ports and programming methods, etc., which is more complicated than eeprom's IIC programming method. The MCU programming system is completely inconsistent with the previous eeprom programming system, that is, it is not compatible with the current production, after-sales, etc., and the compatibility is poor. Using the MCU programming system can realize the reading and writing of its internal storage space, but the MCU programming system is usually more complicated and the cost is higher. At the same time, the design of each MCU manufacturer is different, and its programming system is also different, which is difficult to be compatible, that is, the general-purpose type is very poor.

如图1所示,在之前使用外部eeprom作为存储单元情况下,外部烧写器可以通过烧写端子对eepprom进行数据读写操作,控制器在工作时直接读取eeprom内部的数据用于空调器的运行。烧写端子与EEPROM、以及EEPROM与MCU之间都是采用IIC的通信方式,而外部烧写器和MCU之间是没有进行数据交互的。本申请中在不改变原硬件电路的情况下,通过MCU的软件设计,实现了MCU和外部烧写器直接进行数据交互。如图2所示,MCU内部的DATAFLASH空间具有数据存储,可有替代外部的eeprom实现参数存储的功能,存储方式的变化带来的烧写方式的变化,硬件方面去掉eeprom芯片,采用MCU内部的DATAFLASH作为替代,但是eeprom周围电路不变。As shown in Figure 1, when the external eeprom was used as a storage unit before, the external writer can read and write data to the eeprom through the programming terminal, and the controller directly reads the data inside the eeprom for the air conditioner when it is working. operation. The IIC communication method is used between the programming terminal and the EEPROM, as well as between the EEPROM and the MCU, and there is no data exchange between the external programmer and the MCU. In this application, without changing the original hardware circuit, through the software design of the MCU, the direct data interaction between the MCU and the external programmer is realized. As shown in Figure 2, the DATAFLASH space inside the MCU has data storage, which can replace the external eeprom to realize the function of parameter storage. The change of the storage method brings about the change of the programming method. In terms of hardware, the eeprom chip is removed and the internal MCU is used. DATAFLASH as a replacement, but the circuit around the eeprom remains unchanged.

在外置eeprom方案时,MCU和外部烧写器都是主机,eeprom芯片是从机,主机发动读写指令,从机执行。在读数据时,主机将读命令以及地址发往从机,eeprom芯片作为从机将相应地址的数据返回主机。在写数据时,主机将写命令以及地址和对应地址的数据发往从机,eeprom根据指令,在内部指定地址区域写入对应数据,在内置DATAFLASH方案下,外部烧写器还是主机,但是MCU变为从机,MCU一直处在等待指令的状态。在读数据时,主机将读命令以及地址发往从机,MCU芯片在接收命令之后,根据地址映射,将相应地址的数据返回主机。在写数据时,主机将写命令以及地址和对应地址的数据发往从机,MCU芯片在接收命令之后,根据地址映射,在内部指定地址区域写入对应数据。In the external eeprom solution, both the MCU and the external programmer are the master, and the eeprom chip is the slave. The master initiates read and write commands, and the slave executes them. When reading data, the host sends the read command and address to the slave, and the eeprom chip returns the data of the corresponding address to the host as a slave. When writing data, the host sends the write command, the address and the data of the corresponding address to the slave, and the eeprom writes the corresponding data in the internal specified address area according to the command. Under the built-in DATAFLASH scheme, the external writer is still the host, but the MCU Become a slave, the MCU has been in a state of waiting for instructions. When reading data, the host sends the read command and address to the slave. After receiving the command, the MCU chip returns the data of the corresponding address to the host according to the address mapping. When writing data, the host sends the write command, the address and the data of the corresponding address to the slave. After the MCU chip receives the command, it writes the corresponding data in the internal specified address area according to the address mapping.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述微控制器与所述外部烧录器之间的数据协议和EEPROM的烧写协议一致。In order to implement programming to the internal storage space of the microcontroller, in some embodiments of the present application, the data protocol between the microcontroller and the external programmer is consistent with the programming protocol of the EEPROM.

本实施例中,MCU的端口该是采用IIC的通讯方式,直接与外部的烧写器进行数据交互,通讯协议完全和eeprom的烧写协议一致。In this embodiment, the port of the MCU should use the IIC communication mode to directly interact with the external programmer, and the communication protocol is completely consistent with the programming protocol of eeprom.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述外部烧录器与所述微控制器的reset,以实现在所述烧录器工作时,拉低reset信号,使所述微控制器不工作。In order to program the internal storage space of the microcontroller, in some embodiments of the present application, the external programmer and the microcontroller are reset, so as to pull down the reset when the programmer is working signal to disable the microcontroller.

本实施例中,Eeprom的有效电平范围比较宽,可以识别宽电压范围的电平,通常2V以上都可以。但是MCU对电压要求较为严苛,目前行业内的MCU芯片通常有两个电源规格3.3V和5V,通常其中5V芯片识别4V以上的,3.3V芯片只能识别2.7V~3.6V。两种芯片之间的电压不能通用,否则会在成不能识别正常信号,或者烧毁MCU芯片的风险。In this embodiment, the effective level range of the Eeprom is relatively wide, and the level of a wide voltage range can be identified, usually more than 2V. However, the MCU has strict voltage requirements. At present, MCU chips in the industry usually have two power supply specifications: 3.3V and 5V. Usually, the 5V chip recognizes more than 4V, and the 3.3V chip can only recognize 2.7V~3.6V. The voltage between the two chips cannot be universal, otherwise there will be a risk of not being able to recognize normal signals or burning the MCU chip.

在外部eeprom存储数据时,因为有烧写器和MCU两个主机,为了防止两个主机同时工作,一般做法是在烧写器硬件地上接入MCU reset端口,在烧写器工作时将reset信号拉低以使MCU不工作,使在任何情况下都只有一个主机在工作,保证对eeprom的通讯正常。When the external eeprom stores data, because there are two hosts, the programmer and the MCU, in order to prevent the two hosts from working at the same time, the general practice is to connect the MCU reset port on the hardware ground of the programmer, and send the reset signal when the programmer is working. Pull low to make the MCU not work, so that only one host is working in any case, to ensure normal communication to the eeprom.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述DATAFLASH空间为用于实现数据存储的区域。In order to realize programming the internal storage space of the microcontroller, in some embodiments of the present application, the DATAFLASH space is an area for realizing data storage.

本实施例中,上述所属DATAFLASH,是一种命名方式;可以是直接实现数据存储功能的区域,也可以是MCU内部的其它可以实现此功能的区域,可以是在空余的RAM或者ROM区间开辟的具有数据存储功能的区域。In this embodiment, the above-mentioned DATAFLASH is a naming method; it can be an area that directly implements the data storage function, or other areas inside the MCU that can implement this function, and can be opened up in the spare RAM or ROM interval An area with data storage capabilities.

通过应用以上技术方案,在包括外部烧录器及微控制器的空调器中,微控制器被配置为:当所述MCU接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器;当所述MCU接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述MCU的对应区域内,从而实现提高各厂商生产的MCU烧录的通用性,降低成本。By applying the above technical solutions, in an air conditioner including an external programmer and a microcontroller, the microcontroller is configured to: after the MCU receives the read command, according to the address sent by the external programmer, The data corresponding to the address is returned to the external programmer; when the MCU receives the write command, the data to be written is written into the data according to the address sent by the external programmer and the data to be written In the corresponding area of MCU, so as to improve the versatility of MCU programming produced by various manufacturers and reduce costs.

为了进一步阐述本发明的技术思想,现结合具体的应用场景,对本发明的技术方案进行说明。In order to further illustrate the technical idea of the present invention, the technical solutions of the present invention are now described with reference to specific application scenarios.

本申请实施例提供一种空调器微控制器内部存储空间烧录方法,应用于包括外部烧录器及微控制器的空调器中,如图3所示,所述方法包括:An embodiment of the present application provides a method for programming the internal storage space of an air conditioner microcontroller, which is applied to an air conditioner including an external programmer and a microcontroller. As shown in FIG. 3 , the method includes:

步骤S201,当所述微控制器接收到读命令后,根据所述外部烧录器发送的地址将所述地址对应的数据返回到所述外部烧录器。Step S201, after receiving the read command, the microcontroller returns the data corresponding to the address to the external programmer according to the address sent by the external programmer.

步骤S202,当所述微控制器接收到写命令时,根据所述外部烧录器发送的地址及待写入数据将所述待写入数据写入所述微控制器的对应区域内。Step S202, when the microcontroller receives a write command, the data to be written is written into a corresponding area of the microcontroller according to the address sent by the external programmer and the data to be written.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述微控制器与所述外部烧录器之间的数据协议和EEPROM的烧写协议一致。In order to implement programming to the internal storage space of the microcontroller, in some embodiments of the present application, the data protocol between the microcontroller and the external programmer is consistent with the programming protocol of the EEPROM.

本实施例中,MCU的端口该是采用IIC的通讯方式,直接与外部的烧写器进行数据交互,通讯协议完全和eeprom的烧写协议一致。In this embodiment, the port of the MCU should use the IIC communication mode to directly interact with the external programmer, and the communication protocol is completely consistent with the programming protocol of eeprom.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述外部烧录器与所述微控制器的reset,以实现在所述烧录器工作时,拉低reset信号,使所述微控制器不工作。In order to program the internal storage space of the microcontroller, in some embodiments of the present application, the external programmer and the microcontroller are reset, so as to pull down the reset when the programmer is working signal to disable the microcontroller.

本实施例中,Eeprom的有效电平范围比较宽,可以识别宽电压范围的电平,通常2V以上都可以。但是MCU对电压要求较为严苛,目前行业内的MCU芯片通常有两个电源规格3.3V和5V,通常其中5V芯片识别4V以上的,3.3V芯片只能识别2.7V~3.6V。两种芯片之间的电压不能通用,否则会在成不能识别正常信号,或者烧毁MCU芯片的风险。In this embodiment, the effective level range of the Eeprom is relatively wide, and the level of a wide voltage range can be identified, usually more than 2V. However, the MCU has strict voltage requirements. At present, MCU chips in the industry usually have two power supply specifications: 3.3V and 5V. Usually, the 5V chip recognizes more than 4V, and the 3.3V chip can only recognize 2.7V~3.6V. The voltage between the two chips cannot be universal, otherwise there will be a risk of not being able to recognize normal signals or burning the MCU chip.

在外部eeprom存储数据时,因为有烧写器和MCU两个主机,为了防止两个主机同时工作,一般做法是在烧写器硬件地上接入MCU reset端口,在烧写器工作时将reset信号拉低以使MCU不工作,使在任何情况下都只有一个主机在工作,保证对eeprom的通讯正常。When the external eeprom stores data, because there are two hosts, the programmer and the MCU, in order to prevent the two hosts from working at the same time, the general practice is to connect the MCU reset port on the hardware ground of the programmer, and send the reset signal when the programmer is working. Pull low to make the MCU not work, so that only one host is working in any case, to ensure normal communication to the eeprom.

为了实现对微控制器内部存储空间进行烧录,在本申请一些实施例中,所述DATAFLASH空间为用于实现数据存储的区域。In order to realize programming the internal storage space of the microcontroller, in some embodiments of the present application, the DATAFLASH space is an area for realizing data storage.

本实施例中,上述所属DATAFLASH,是一种命名方式;可以是直接实现数据存储功能的区域,也可以是MCU内部的其它可以实现此功能的区域,可以是在空余的RAM或者ROM区间开辟的具有数据存储功能的区域。In this embodiment, the above-mentioned DATAFLASH is a naming method; it can be an area that directly implements the data storage function, or other areas inside the MCU that can implement this function, and can be opened up in the spare RAM or ROM interval An area with data storage capabilities.

为了实现MCU内部空间替代外部的eeprom,本方案还开发了一种烧写工装,其主要特点是,可以调节电压,并可以调节reset端口的信号,通过拨码或者短接端子等实现。既可以保证外部eeprom的烧写,又可以实现MCU内部的存储区间的烧写,同时还能区分各芯片电压。In order to replace the external eeprom with the internal space of the MCU, a programming tool is also developed in this solution. Its main feature is that it can adjust the voltage and the signal of the reset port, which can be realized by dialing codes or shorting terminals. It can not only ensure the programming of the external eeprom, but also realize the programming of the internal storage area of the MCU, and at the same time, it can distinguish the voltage of each chip.

最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不驱使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand: it can still be Modifications are made to the technical solutions described in the foregoing embodiments, or some technical features thereof are equivalently replaced; and these modifications or replacements do not drive the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims (9)

1. An air conditioner, comprising:
the external recorder performs data interaction with the air conditioner MCU through the IIC;
the MCU microcontroller is provided with DATAFLASH space, and the space is used for storing parameters;
the MCU configured to:
when the MCU receives a read command, returning data corresponding to the address to the external burner according to the address sent by the external burner;
and when the MCU receives a write command, writing the data to be written into a corresponding area of the MCU according to the address sent by the external burner and the data to be written.
2. The air conditioner of claim 1, wherein a data protocol between the microcontroller and the external burner is consistent with a programming protocol of an EEPROM.
3. The air conditioner as claimed in claim 1, wherein the reset of the external burner and the microcontroller is performed to pull down the reset signal when the burner is operated, so that the microcontroller does not operate.
4. The air conditioner as claimed in claim 1, wherein said DATAFLASH space is an area for implementing data storage.
5. A method for burning an internal storage space of a microcontroller of an air conditioner is characterized by being applied to the air conditioner comprising an external burner and the microcontroller, and comprises the following steps:
when the microcontroller receives a read command, returning data corresponding to the address to the external burner according to the address sent by the external burner;
and when the microcontroller receives a write command, writing the data to be written into a corresponding area of the microcontroller according to the address sent by the external burner and the data to be written.
6. The method of claim 5, wherein a data protocol between the microcontroller and the external burner is consistent with a programming protocol of an EEPROM.
7. The method of claim 5, wherein the reset of the external burner and the microcontroller is performed to pull down the reset signal when the burner is operating, so that the microcontroller does not operate.
8. The method of claim 5, the DATAFLASH space being an area for implementing data storage.
9. A burning tool for an internal storage space of an air conditioner microcontroller is applied to the burning method for the internal storage space of the air conditioner microcontroller according to claims 5-8 and used for adjusting voltage and signals of a reset port.
CN202111672525.6A 2021-12-31 2021-12-31 Air conditioner and method for burning internal storage space of microcontroller of air conditioner Pending CN114443070A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111672525.6A CN114443070A (en) 2021-12-31 2021-12-31 Air conditioner and method for burning internal storage space of microcontroller of air conditioner

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111672525.6A CN114443070A (en) 2021-12-31 2021-12-31 Air conditioner and method for burning internal storage space of microcontroller of air conditioner

Publications (1)

Publication Number Publication Date
CN114443070A true CN114443070A (en) 2022-05-06

Family

ID=81366617

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111672525.6A Pending CN114443070A (en) 2021-12-31 2021-12-31 Air conditioner and method for burning internal storage space of microcontroller of air conditioner

Country Status (1)

Country Link
CN (1) CN114443070A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101950253A (en) * 2010-08-12 2011-01-19 深圳市共进电子有限公司 Method for upgrading optical module firmware in optical network unit by utilizing WEB webpage interface
CN103123579A (en) * 2011-09-08 2013-05-29 英飞凌科技股份有限公司 Standby operation with additional micro-controller
CN105022701A (en) * 2015-07-27 2015-11-04 四川长虹电器股份有限公司 Method for storing running state and parameters of air conditioner
CN109358887A (en) * 2018-12-17 2019-02-19 武汉精立电子技术有限公司 A kind of the online upgrading method, apparatus and system of SCM program
CN110569045A (en) * 2019-09-29 2019-12-13 上海菱沃铂智能技术有限公司 A programmer with controllable programming voltage and communication level and its control method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101950253A (en) * 2010-08-12 2011-01-19 深圳市共进电子有限公司 Method for upgrading optical module firmware in optical network unit by utilizing WEB webpage interface
CN103123579A (en) * 2011-09-08 2013-05-29 英飞凌科技股份有限公司 Standby operation with additional micro-controller
CN105022701A (en) * 2015-07-27 2015-11-04 四川长虹电器股份有限公司 Method for storing running state and parameters of air conditioner
CN109358887A (en) * 2018-12-17 2019-02-19 武汉精立电子技术有限公司 A kind of the online upgrading method, apparatus and system of SCM program
CN110569045A (en) * 2019-09-29 2019-12-13 上海菱沃铂智能技术有限公司 A programmer with controllable programming voltage and communication level and its control method

Similar Documents

Publication Publication Date Title
CN101454746B (en) Method for communication by using multifunctional memory card
US10976958B2 (en) Method for controlling storage device
US20080065788A1 (en) System and method for producing high volume flash memory cards
CN103914324B (en) A kind of method and its system of automatic programming embedded device firmware
JP5694101B2 (en) Memory device, host device
CN102915209B (en) Storage control chip, storage equipment and system data writing method
CN107273245B (en) Operation device and operation method
EP2058739B1 (en) Electronic device, information processing device, adapter device, and information exchange system
CN103593296B (en) Data storage method, memory controller and memory storage device
CN114296768A (en) Method, device, air conditioner and storage medium for updating parameters of air conditioner
CN101980159B (en) Updating device and updating method for firmware of U disk
CN114443070A (en) Air conditioner and method for burning internal storage space of microcontroller of air conditioner
CN115904415A (en) Burning device and burning method
CN111208757A (en) eMMC main controller based on FPGA
CN110908673B (en) Digital power supply chip burning method
CN216248810U (en) Board-level MCU data interaction storage system, controller and electrical equipment
CN104252631A (en) Electronic device and control method of the electronic device
CN114167840B (en) A wireless charging chip test system combined with peripheral MCU
CN115273944A (en) EEPROM data storage circuit, writing method and air conditioner
CN107402622B (en) Memory storage device and power management method thereof
CN208255870U (en) One kind can rebuild universal electronic disk
CN211149251U (en) Multi-channel data acquisition system
CN204270370U (en) J1939 Bus Data Logger
CN214202372U (en) Board carries off-line write device
CN219143810U (en) SPD (single-sided digital video recorder) burning device of DDR5 memory bank

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: No.1, Hisense Road, Nancun Town, Pingdu City, Qingdao City, Shandong Province 266700

Applicant after: Hisense Air Conditioning Co.,Ltd.

Address before: No.1, Hisense Road, Nancun Town, Pingdu City, Qingdao City, Shandong Province 266700

Applicant before: HISENSE (SHANDONG) AIR-CONDITIONING Co.,Ltd.