CN116049045B - Command sending method and electronic device - Google Patents
Command sending method and electronic device Download PDFInfo
- Publication number
- CN116049045B CN116049045B CN202210848089.1A CN202210848089A CN116049045B CN 116049045 B CN116049045 B CN 116049045B CN 202210848089 A CN202210848089 A CN 202210848089A CN 116049045 B CN116049045 B CN 116049045B
- Authority
- CN
- China
- Prior art keywords
- command
- kernel layer
- electronic device
- function
- sending
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 45
- 230000006870 function Effects 0.000 claims description 40
- 230000005540 biological transmission Effects 0.000 claims description 30
- 238000004590 computer program Methods 0.000 claims description 8
- 230000000873 masking effect Effects 0.000 claims 2
- 238000004806 packaging method and process Methods 0.000 claims 1
- 206010000210 abortion Diseases 0.000 abstract description 2
- 238000012545 processing Methods 0.000 description 15
- 238000004891 communication Methods 0.000 description 11
- 238000007726 management method Methods 0.000 description 8
- 238000010586 diagram Methods 0.000 description 6
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000013461 design Methods 0.000 description 3
- 230000004044 response Effects 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 230000036541 health Effects 0.000 description 2
- 238000013528 artificial neural network Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 125000004122 cyclic group Chemical group 0.000 description 1
- 230000004927 fusion Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000009877 rendering Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/14—Handling requests for interconnection or transfer
- G06F13/16—Handling requests for interconnection or transfer for access to memory bus
- G06F13/1668—Details of memory controller
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/10—Program control for peripheral devices
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
本申请提供了一种命令发送方法及电子设备。该方法包括:确定待发送给内核层的命令是否为第一命令,第一命令为与多块操作相关的命令,如果是,屏蔽内核层自动使能第二命令的功能,第二命令为能够中止或中断第一命令的命令,向内核层发送第一命令。这样,在已经屏蔽了内核层自动使能第二命令的功能之后,向内核层发送第一命令,由于自动使能第二命令的功能已经被屏蔽掉,内核层在解读第一命令时不再受到第二命令的干扰,从而能够将正确的第一命令发送给eMMC器件,从而避免了芯片在发送相关命令时因受到特殊命令设置的影响而出错。
This application provides a command sending method and electronic device. The method includes: determining whether the command to be sent to the kernel layer is a first command, and the first command is a command related to a multi-block operation. If so, shielding the kernel layer from automatically enabling the function of the second command, and the second command is capable of A command that aborts or interrupts the first command sends the first command to the kernel layer. In this way, after the function of automatically enabling the second command of the kernel layer has been blocked, the first command is sent to the kernel layer. Since the function of automatically enabling the second command has been blocked, the kernel layer no longer interprets the first command. Being interfered by the second command, the correct first command can be sent to the eMMC device, thereby avoiding the chip from making errors due to the influence of special command settings when sending related commands.
Description
技术领域Technical field
本申请涉及终端设备领域,尤其涉及一种命令发送方法及电子设备。The present application relates to the field of terminal equipment, and in particular, to a command sending method and electronic equipment.
背景技术Background technique
电子设备一般都包括主机和器件。主机可以通过主机与器件之间的通信连接,从器件中读取数据,或者向器件中写入数据。通常,作为电子设备主机的芯片会支持业内公认的协议,以及协议对应的所有命令集。Electronic equipment generally includes hosts and devices. The host can read data from the device or write data to the device through the communication connection between the host and the device. Usually, the chip that serves as the host of the electronic device will support industry-recognized protocols and all command sets corresponding to the protocols.
目前,一些芯片针对某个或某些命令进行了特殊设置,导致这些芯片作为电子设备主机时,在发送命令集中的某个或某些命令时出错。At present, some chips have special settings for one or some commands, causing these chips to make errors when sending one or some commands in the command set when serving as hosts for electronic devices.
发明内容Contents of the invention
为了解决上述技术问题,本申请提供一种命令发送方法及电子设备,针对进行了特殊命令设置的芯片,提供一种新的命令发送方法,避免芯片在发送相关命令时因受到特殊命令设置的影响而出错。In order to solve the above technical problems, this application provides a command sending method and electronic equipment. For chips with special command settings, a new command sending method is provided to avoid the chip being affected by the special command settings when sending related commands. And error.
第一方面,本申请提供一种命令发送方法。该方法应用于电子设备。该方法包括:确定待发送给内核层的命令是否为第一命令,第一命令为与多块操作相关的命令,如果是,屏蔽内核层自动使能第二命令的功能,第二命令为能够中止或中断第一命令的命令,向内核层发送第一命令。这样,在已经屏蔽了内核层自动使能第二命令的功能之后,向内核层发送第一命令,由于自动使能第二命令的功能已经被屏蔽掉,内核层在解读第一命令时不再受到第二命令的干扰,从而能够将正确的第一命令发送给eMMC器件,从而避免了芯片在发送相关命令时因受到特殊命令设置的影响而出错。In a first aspect, this application provides a command sending method. This method is applied to electronic devices. The method includes: determining whether the command to be sent to the kernel layer is a first command, and the first command is a command related to a multi-block operation. If so, shielding the kernel layer from automatically enabling the function of the second command, and the second command is capable of A command that aborts or interrupts the first command sends the first command to the kernel layer. In this way, after the function of automatically enabling the second command of the kernel layer has been blocked, the first command is sent to the kernel layer. Since the function of automatically enabling the second command has been blocked, the kernel layer no longer interprets the first command. Being interfered by the second command, the correct first command can be sent to the eMMC device, thereby avoiding the chip from making errors due to the influence of special command settings when sending related commands.
根据第一方面,屏蔽内核层自动使能第二命令的功能,包括:在内核层中设置第一传输模式和第二传输模式,其中,在第一传输模式下,内核层自动使能第二命令,不使能第三命令;在第二传输模式下,内核层自动使能第三命令,不使能第二命令;内核层在第一结构体为空的情况下采用第一传输模式,内核层在第一结构体不为空的情况下采用第二传输模式;将第三命令封装到第一结构体中,得到第一目标结构体;将第一目标结构体发送给内核层。这样,能够在向内核层发送第一命令之前,将内核层自动使能第二命令的功能成功地屏蔽掉。According to the first aspect, shielding the kernel layer from automatically enabling the second command function includes: setting a first transmission mode and a second transmission mode in the kernel layer, wherein in the first transmission mode, the kernel layer automatically enables the second command. command, the third command is not enabled; in the second transmission mode, the kernel layer automatically enables the third command and does not enable the second command; the kernel layer adopts the first transmission mode when the first structure is empty, The kernel layer adopts the second transmission mode when the first structure is not empty; encapsulates the third command into the first structure to obtain the first target structure; and sends the first target structure to the kernel layer. In this way, the function of the kernel layer automatically enabling the second command can be successfully blocked before sending the first command to the kernel layer.
根据第一方面,屏蔽内核层自动使能第二命令的功能,包括:向内核层发送关闭指令,关闭指令用于指示内核层关闭自动使能第二命令的功能。这样,能够在向内核层发送第一命令之前,将内核层自动使能第二命令的功能成功地屏蔽掉。According to the first aspect, shielding the kernel layer from automatically enabling the second command function includes: sending a shutdown instruction to the kernel layer, where the shutdown instruction is used to instruct the kernel layer to shut down the function of automatically enabling the second command. In this way, the function of the kernel layer automatically enabling the second command can be successfully blocked before sending the first command to the kernel layer.
根据第一方面,向内核层发送第一命令之后,还包括:判断内核层是否执行完第一命令;在内核层执行完第一命令之后,恢复内核层自动使能第二命令的功能。这样,可以避免影响芯片对其他命令的处理流程。According to the first aspect, after sending the first command to the kernel layer, the method further includes: determining whether the kernel layer has finished executing the first command; and after the kernel layer has finished executing the first command, restoring the function of the kernel layer to automatically enable the second command. In this way, it can avoid affecting the chip's processing flow of other commands.
根据第一方面,向内核层发送第一命令,包括:通过ioctl函数向内核层发送第一命令。According to the first aspect, sending the first command to the kernel layer includes: sending the first command to the kernel layer through an ioctl function.
根据第一方面,第一命令为多块读命令CMD18或多块写命令CMD25,第二命令为停止传输命令CMD12。According to the first aspect, the first command is a multi-block read command CMD18 or a multi-block write command CMD25, and the second command is a stop transmission command CMD12.
根据第一方面,第一命令为包括多块写命令CMD25和设置读写块数目的命令CMD23的组合命令,第二命令为停止传输命令CMD12。According to the first aspect, the first command is a combined command including a multi-block write command CMD25 and a command CMD23 for setting the number of read and write blocks, and the second command is a stop transmission command CMD12.
根据第一方面,第三命令为设置读写块数目的命令CMD23。According to the first aspect, the third command is a command CMD23 for setting the number of read and write blocks.
第二方面,本申请提供一种电子设备,包括:存储器和处理器,存储器与处理器耦合;存储器存储有程序指令,当程序指令由所述处理器执行时,使得电子设备执行第一方面任意一项的命令发送方法。In a second aspect, this application provides an electronic device, including: a memory and a processor. The memory is coupled to the processor; the memory stores program instructions. When the program instructions are executed by the processor, the electronic device causes the electronic device to execute any of the first aspects. A command sending method.
第三方面,本申请提供一种计算机可读存储介质,包括计算机程序,当计算机程序在电子设备上运行时,使得电子设备执行前述的第一方面任意一项的命令发送方法。In a third aspect, the present application provides a computer-readable storage medium, including a computer program. When the computer program is run on an electronic device, the electronic device causes the electronic device to execute any one of the command sending methods of the first aspect.
附图说明Description of the drawings
图1为示例性示出的电子设备100的结构示意图;FIG. 1 is a schematic structural diagram of an exemplary electronic device 100;
图2为示例性示出的本申请实施例的电子设备100的软件结构框图;Figure 2 is an exemplary software structure block diagram of the electronic device 100 according to the embodiment of the present application;
图3为示例性示出的电子设备中主机与eMMC器件的通信示意图;Figure 3 is a schematic diagram of communication between a host and an eMMC device in an electronic device;
图4为示例性示出的命令发送方法的一种流程示例图。FIG. 4 is an exemplary flowchart of a command sending method.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。The term "and/or" in this article is just an association relationship that describes related objects, indicating that three relationships can exist. For example, A and/or B can mean: A exists alone, A and B exist simultaneously, and they exist alone. B these three situations.
本申请实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一目标对象和第二目标对象等是用于区别不同的目标对象,而不是用于描述目标对象的特定顺序。The terms “first” and “second” in the description and claims of the embodiments of this application are used to distinguish different objects, rather than to describe a specific order of objects. For example, the first target object, the second target object, etc. are used to distinguish different target objects, rather than to describe a specific order of the target objects.
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of this application, words such as "exemplary" or "for example" are used to represent examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "such as" in the embodiments of the present application is not to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the words "exemplary" or "such as" is intended to present the concept in a concrete manner.
在本申请实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理单元是指两个或两个以上的处理单元;多个系统是指两个或两个以上的系统。In the description of the embodiments of this application, unless otherwise specified, the meaning of “plurality” refers to two or more. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.
电子设备的硬件通常包括主机(host)和器件(device)。其中,主机通常为一个芯片。器件例如可以是存储器。主机和器件之间可以通过通信接口进行通信连接。例如,该通信接口例如可以是eMMC总线。The hardware of electronic equipment usually includes host and device. Among them, the host is usually a chip. The device may be a memory, for example. The communication connection between the host and the device can be carried out through the communication interface. For example, the communication interface may be an eMMC bus.
其中,器件是支持eMMC(embedded MultiMedia Card,嵌入式多媒体卡)协议的器件。Among them, the device is a device that supports the eMMC (embedded MultiMedia Card, embedded multimedia card) protocol.
主机可以通过向器件发送符合eMMC协议的命令的方式,从器件中读取数据,或者向器件中写入数据。The host can read data from the device or write data to the device by sending commands that comply with the eMMC protocol to the device.
在相关技术中,一些芯片针对某个或某些命令进行了特殊设置,导致这些芯片作为电子设备主机时,在执行命令集中的某个或某些命令时出错。In the related art, some chips have special settings for one or some commands, which causes these chips to make errors when executing one or some commands in the command set when they serve as electronic device hosts.
例如,在一款芯片A上搭载eMMC存储器时,主机与eMMC存储器之间通过eMMC总线进行通信。芯片A向eMMC存储器发送CMD23+CMD25命令,以便获取eMMC存储器的健康信息。但是,芯片向eMMC存储器发送CMD23+CMD25命令后,芯片A收到了CRC(Cyclic RedundanceyCheck,循环冗余校验)报错,eMMC存储器并不向eMMC存储器返回健康信息。可见,芯片A在向eMMC存储器发送CMD23+CMD25命令时出了错。For example, when a chip A is equipped with an eMMC memory, the host and the eMMC memory communicate through the eMMC bus. Chip A sends the CMD23+CMD25 command to the eMMC memory to obtain the health information of the eMMC memory. However, after the chip sent the CMD23+CMD25 command to the eMMC memory, chip A received a CRC (Cyclic Redundance Check) error, and the eMMC memory did not return health information to the eMMC memory. It can be seen that chip A made an error when sending the CMD23+CMD25 command to the eMMC memory.
本申请实施例提供一种命令发送方法,针对进行了特殊命令设置的芯片,提供一种新的命令发送方法,避免芯片在发送相关命令时因受到特殊命令设置的影响而出错。Embodiments of the present application provide a command sending method, and provide a new command sending method for a chip with special command settings to avoid errors caused by the impact of special command settings when the chip sends related commands.
本申请实施例中的命令发送方法可以应用于电子设备,例如智能手机、平板等电子设备。该电子设备的结构可以如图1所示。The command sending method in the embodiment of the present application can be applied to electronic devices, such as smart phones, tablets and other electronic devices. The structure of the electronic device can be shown in Figure 1.
图1为示例性示出的电子设备100的结构示意图。应该理解的是,图1所示电子设备100仅是电子设备的一个范例,并且电子设备100可以具有比图中所示的更多的或者更少的部件,可以组合两个或多个的部件,或者可以具有不同的部件配置。图1中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。FIG. 1 is a schematic structural diagram of an exemplary electronic device 100 . It should be understood that the electronic device 100 shown in FIG. 1 is only an example of an electronic device, and the electronic device 100 may have more or fewer components than shown in the figure, and two or more components may be combined. , or can have different component configurations. The various components shown in Figure 1 may be implemented in hardware, software, or a combination of hardware and software including one or more signal processing and/or application specific integrated circuits.
请参见图1,电子设备100可以包括:处理器110,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,指示器192,摄像头193等。Referring to Figure 1, the electronic device 100 may include: a processor 110, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2. Mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone interface 170D, sensor module 180, indicator 192, camera 193, etc.
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processingunit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 110 may include one or more processing units. For example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processing unit (GPU), an image signal processor ( image signal processor (ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU), etc. . Among them, different processing units can be independent devices or integrated in one or more processors.
其中,控制器可以是电子设备100的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller may be the nerve center and command center of the electronic device 100 . The controller can generate operation control signals based on the instruction operation code and timing signals to complete the control of fetching and executing instructions.
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in processor 110 is cache memory.
其中,外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 . The external memory card communicates with the processor 110 through the external memory interface 120 to implement the data storage function. Such as saving music, videos, etc. files in external memory card.
内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器110通过运行存储在内部存储器121的指令,从而执行电子设备100的各种功能应用以及数据处理。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。Internal memory 121 may be used to store computer executable program code, which includes instructions. The processor 110 executes instructions stored in the internal memory 121 to execute various functional applications and data processing of the electronic device 100 . The internal memory 121 may include a program storage area and a data storage area. Among them, the stored program area can store an operating system, at least one application program required for a function (such as a sound playback function, an image playback function, etc.). The storage data area may store data created during use of the electronic device 100 (such as audio data, phone book, etc.). In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), etc.
其中,处理器110位于本申请实施例的芯片上,处理器110可以作为本申请实施例中的主机。eMMC存储器,可以通过eMMC总线与处理器110通信。The processor 110 is located on the chip of the embodiment of the present application, and the processor 110 may serve as the host in the embodiment of the present application. The eMMC memory can communicate with the processor 110 through the eMMC bus.
其中,电子设备100的软件系统可以采用分层架构、事件驱动架构、微核架构、微服务架构,或云架构。本申请实施例以分层架构的安卓(Android)系统为例,示例性说明电子设备100的软件结构。Among them, the software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. The embodiment of this application takes the Android system with a layered architecture as an example to illustrate the software structure of the electronic device 100 .
图2为示例性示出的本申请实施例的电子设备100的软件结构框图。FIG. 2 is an exemplary software structure block diagram of the electronic device 100 according to the embodiment of the present application.
电子设备100的分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,Android系统可以包括应用程序层、应用程序框架层、系统层以及内核层等。The layered architecture of the electronic device 100 divides the software into several layers, and each layer has clear roles and division of labor. The layers communicate through software interfaces. In some embodiments, the Android system may include an application layer, an application framework layer, a system layer, a kernel layer, etc.
应用程序层可以包括一系列应用程序包。The application layer can include a series of application packages.
如图2所示,应用程序包可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,音乐,视频,短信息等应用程序。As shown in Figure 2, the application package can include camera, gallery, calendar, calling, map, navigation, WLAN, Bluetooth, music, video, short message and other applications.
应用程序框架层为应用程序层的应用程序提供应用编程接口(applicationprogramming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。The application framework layer provides an application programming interface (API) and programming framework for applications in the application layer. The application framework layer includes some predefined functions.
如图2所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。As shown in Figure 2, the application framework layer can include a window manager, content provider, view system, phone manager, resource manager, notification manager, etc.
窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。A window manager is used to manage window programs. The window manager can obtain the display size, determine whether there is a status bar, lock the screen, capture the screen, etc.
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。Content providers are used to store and retrieve data and make this data accessible to applications. Said data can include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。The view system includes visual controls, such as controls that display text, controls that display pictures, etc. A view system can be used to build applications. The display interface can be composed of one or more views. For example, a display interface including a text message notification icon may include a view for displaying text and a view for displaying pictures.
电话管理器用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。The phone manager is used to provide communication functions of the electronic device 100 . For example, call status management (including connected, hung up, etc.).
资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。The resource manager provides various resources to applications, such as localized strings, icons, pictures, layout files, video files, etc.
通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。The notification manager allows applications to display notification information in the status bar, which can be used to convey notification-type messages and can automatically disappear after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be notifications that appear in the status bar at the top of the system in the form of charts or scroll bar text, such as notifications for applications running in the background, or notifications that appear on the screen in the form of conversation windows. For example, text information is prompted in the status bar, a beep sounds, the electronic device vibrates, the indicator light flashes, etc.
Android Runtime包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。Android Runtime includes core libraries and virtual machines. The Android runtime is responsible for the scheduling and management of the Android system.
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。The core library contains two parts: one is the functional functions that need to be called by the Java language, and the other is the core library of Android.
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The application layer and application framework layer run in virtual machines. The virtual machine executes the java files of the application layer and application framework layer into binary files. The virtual machine is used to perform object life cycle management, stack management, thread management, security and exception management, and garbage collection and other functions.
系统库可以包括多个功能模块。如图2所示,本申请实施例中,系统库中包括命令发送模块,该命令发送模块用于执行本申请实施例的命令发送方法。System libraries can include multiple functional modules. As shown in Figure 2, in the embodiment of the present application, the system library includes a command sending module, and the command sending module is used to execute the command sending method in the embodiment of the present application.
需要说明的是,尽管图2中没有示出,但是可以理解的是,系统库中还可以包括其他的功能模块,例如:表面管理器(surface manager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL)等。It should be noted that, although not shown in Figure 2, it can be understood that the system library can also include other functional modules, such as: surface manager (surface manager), media libraries (Media Libraries), three-dimensional graphics processing Library (for example: OpenGL ES), 2D graphics engine (for example: SGL), etc.
表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。The surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications.
媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, composition, and layer processing.
2D图形引擎是2D绘图的绘图引擎。内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。2D Graphics Engine is a drawing engine for 2D drawing. The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.
内核层是硬件和软件之间的层。The kernel layer is the layer between hardware and software.
如图2所示,内核层可以包括显示驱动、蓝牙驱动、音频驱动、Wi-Fi驱动、设备驱动等模块。As shown in Figure 2, the kernel layer can include modules such as display driver, Bluetooth driver, audio driver, Wi-Fi driver, and device driver.
其中,本申请实施例的命令发送方法中发送给内核层的命令,由设备驱动模块接收,然后设备驱动模块将该命令通过eMMC总线发送给eMMC器件,例如eMMC存储器。Among them, the command sent to the kernel layer in the command sending method of the embodiment of the present application is received by the device driver module, and then the device driver module sends the command to the eMMC device, such as an eMMC memory, through the eMMC bus.
可以理解的是,图2示出的软件结构中的层以及各层中包含的部件,并不构成对电子设备100的具体限定。在本申请另一些实施例中,电子设备100可以包括比图示更多或更少的层,以及每个层中可以包括更多或更少的部件,本申请不做限定。It can be understood that the layers in the software structure shown in FIG. 2 and the components included in each layer do not constitute specific limitations on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer layers than shown in the figures, and each layer may include more or fewer components, which is not limited by this application.
下面通过实施例,对本申请进行详细说明。The present application will be described in detail below through examples.
本申请实施例中,主机与eMMC器件进行通信,是通过主机内的eMMC主机控制器(eMMC Host Controller)与eMMC器件进行通信。eMMC主机控制器可以为图1中所示处理器110的一部分。In the embodiment of the present application, the host communicates with the eMMC device through the eMMC Host Controller (eMMC Host Controller) in the host. The eMMC host controller may be part of processor 110 shown in FIG. 1 .
图3为示例性示出的电子设备中主机与eMMC器件的通信示意图。请参见图3,主机中的eMMC主机控制器将命令(Command,简写为CMD)通过eMMC总线发送给eMMC器件,eMMC器件将对该命令的响应(response)信息通过eMMC总线返回给主机。FIG. 3 is a schematic diagram of communication between a host and an eMMC device in an electronic device. Please refer to Figure 3. The eMMC host controller in the host sends a command (Command, abbreviated as CMD) to the eMMC device through the eMMC bus, and the eMMC device returns the response (response) information to the command to the host through the eMMC bus.
图4为示例性示出的命令发送方法的一种流程示例图。本实施例中,命令发送方法应用于电子设备,该电子设备的内核层开启了自动使能第二命令的功能。FIG. 4 is an exemplary flowchart of a command sending method. In this embodiment, the command sending method is applied to an electronic device, and the kernel layer of the electronic device enables the function of automatically enabling the second command.
如图4所示,本实施例中,该方法可以包括如下步骤:As shown in Figure 4, in this embodiment, the method may include the following steps:
S401、判断待发送给内核层的命令是否为第一命令,如果是,执行步骤S402,否则执行步骤S403。其中,第一命令为与多块操作相关的命令。S401. Determine whether the command to be sent to the kernel layer is the first command. If so, execute step S402; otherwise, execute step S403. Among them, the first command is a command related to multi-block operations.
例如,在一个示例中,第一命令可以为多块读命令CMD18。在另一个示例中,第一命令可以为多块写命令CMD25。For example, in one example, the first command may be a multi-block read command CMD18. In another example, the first command may be a multi-block write command CMD25.
S402、屏蔽内核层自动使能第二命令的功能,其中,第二命令为能够中止或中断第一命令的命令。S402. Shield the kernel layer from automatically enabling the function of the second command, where the second command is a command capable of suspending or interrupting the first command.
例如,在第一命令为多块读命令CMD18或多块写命令CMD25的情况下,第二命令可以为停止传输命令CMD12。For example, in the case where the first command is the multi-block read command CMD18 or the multi-block write command CMD25, the second command may be the stop transmission command CMD12.
在相关技术中,芯片向eMMC存储器发送CMD23+CMD25命令时出错的原因是,该款芯片的内核层开启了自动使能CMD12的功能,这样在该芯片向eMMC存储器发送CMD23+CMD25命令的时候,该芯片的内核层的设备驱动实际上向eMMC存储器发送的是CMD23+CMD25+CMD12的组合命令。这样,由于eMMC协议中不存在这种命令组合,eMMC存储器不支持CMD23+CMD25+CMD12的组合命令,因此eMMC存储器在接收到主机发送的CMD23+CMD25+CMD12的组合命令后就会将CRC状态位置位,并通过响应(response)返回给主机。主机校验后给出CRC错误的校验结果,即校验未通过。In related technology, the reason for the error when the chip sends the CMD23+CMD25 command to the eMMC memory is that the kernel layer of the chip turns on the function of automatically enabling CMD12, so that when the chip sends the CMD23+CMD25 command to the eMMC memory, The chip's kernel layer device driver actually sends the combined command of CMD23+CMD25+CMD12 to the eMMC memory. In this way, since this command combination does not exist in the eMMC protocol, the eMMC memory does not support the combined command of CMD23+CMD25+CMD12. Therefore, the eMMC memory will change the CRC status position after receiving the combined command of CMD23+CMD25+CMD12 sent by the host. bit and returned to the host through a response. After verification, the host gives a CRC error verification result, that is, the verification fails.
本实施例中,通过屏蔽内核层自动使能第二命令的功能,使得内核层在接收到上层传送的第一命令后,第一命令不再受到自动使能的第二命令的干扰,从而内核层能够将正确的第一命令发送给eMMC器件。这样,eMMC器件就能够正确响应主机发送的第一命令,不再报错。In this embodiment, the function of automatically enabling the second command by the kernel layer is shielded, so that after the kernel layer receives the first command transmitted by the upper layer, the first command is no longer interfered by the automatically enabled second command, so that the kernel layer layer is able to send the correct first command to the eMMC device. In this way, the eMMC device can correctly respond to the first command sent by the host and no longer report errors.
S403、向内核层发送第一命令。S403. Send the first command to the kernel layer.
本步骤是在已经屏蔽了内核层自动使能第二命令的功能之后,向内核层发送第一命令的。此时,由于自动使能第二命令的功能已经被屏蔽掉,内核层在解读第一命令时不再受到第二命令的干扰,从而能够将正确的第一命令发送给eMMC器件。这样,就避免了芯片在发送相关命令时因受到特殊命令设置的影响而出错。This step is to send the first command to the kernel layer after the function of the kernel layer automatically enabling the second command has been blocked. At this time, since the function of automatically enabling the second command has been blocked, the kernel layer is no longer interfered by the second command when interpreting the first command, so that the correct first command can be sent to the eMMC device. In this way, errors caused by special command settings are avoided when the chip sends related commands.
在一个示例中,屏蔽内核层自动使能第二命令的功能,可以包括:In one example, shielding the kernel layer from automatically enabling the second command may include:
在内核层中设置第一传输模式和第二传输模式,其中,在所述第一传输模式下,内核层自动使能第二命令,不使能第三命令;在第二传输模式下,内核层自动使能第三命令,不使能第二命令;内核层在第一结构体为空的情况下采用第一传输模式,内核层在第一结构体不为空的情况下采用第二传输模式;A first transmission mode and a second transmission mode are set in the kernel layer, wherein, in the first transmission mode, the kernel layer automatically enables the second command and disables the third command; in the second transmission mode, the kernel layer The layer automatically enables the third command and disables the second command; the kernel layer adopts the first transmission mode when the first structure is empty, and the kernel layer adopts the second transmission mode when the first structure is not empty. model;
将第三命令封装到第一结构体中,得到第一目标结构体;Encapsulate the third command into the first structure to obtain the first target structure;
将第一目标结构体发送给内核层。Send the first target structure to the kernel layer.
例如,主机在每一次给器件发送命令时会设置传输模式,在设置传输模式里有两个分支:a分支和b分支。For example, the host will set the transmission mode every time it sends a command to the device. There are two branches in setting the transmission mode: branch a and branch b.
其中,a分支为:多块操作并且操作的块大于1,sbc(第一结构体)为空,主机使能SDHCI_AUTO_CMD12能力,会启用AUTO CMD12的传输模式。Among them, branch a is: multi-block operation and the operation block is greater than 1, sbc (first structure) is empty, the host enables SDHCI_AUTO_CMD12 capability, and the AUTO CMD12 transmission mode is enabled.
b分支为:sbc不为空,主机使能AUTO CMD23能力,启用AUTO CMD23的传输模式。Branch b is: sbc is not empty, the host enables the AUTO CMD23 capability, and enables the AUTO CMD23 transmission mode.
这样,在向内核层发送CMD25之前,将CMD23封装在sbc结构体中发送给内核层。内核层判断sbc结构体不为空,且封装有CMD23,就会执行b分支的传输模式,使能AUTO CMD23能力。从而,内核层接收到上层发送的CMD25之后,将CMD23+CMD25的组合命令发送给器件。In this way, before sending CMD25 to the kernel layer, CMD23 is encapsulated in the sbc structure and sent to the kernel layer. When the kernel layer determines that the sbc structure is not empty and contains CMD23, it will execute the transmission mode of branch b and enable the AUTO CMD23 capability. Therefore, after the kernel layer receives the CMD25 sent by the upper layer, it sends the combined command of CMD23+CMD25 to the device.
在另一个示例中,屏蔽内核层自动使能第二命令的功能,可以包括:In another example, shielding the kernel layer from automatically enabling the second command may include:
向内核层发送关闭指令,该关闭指令用于指示内核层关闭自动使能第二命令的功能。Send a shutdown instruction to the kernel layer, where the shutdown instruction is used to instruct the kernel layer to turn off the function of automatically enabling the second command.
例如,芯片A的上层(例如系统库)在向内核层发送CMD23+CMD25的组合命令之前,先向内核层发送上述关闭指令。内核层接收到关闭指令之后,关闭使能AUTO CMD12能力。这样,关闭内核层的使能AUTO CMD12能力后再向内核层发送CMD23+CMD25的组合命令,此时内核层不会受到CMD12的干扰,内核层将CMD23+CMD25的组合命令发送给器件。For example, the upper layer of chip A (such as the system library) first sends the above shutdown command to the kernel layer before sending the combined command of CMD23+CMD25 to the kernel layer. After the kernel layer receives the shutdown instruction, it turns off the AUTO CMD12 capability. In this way, after turning off the enable AUTO CMD12 capability of the kernel layer and then sending the combined command of CMD23+CMD25 to the kernel layer, the kernel layer will not be interfered by CMD12, and the kernel layer will send the combined command of CMD23+CMD25 to the device.
在一个示例中,向内核层发送所述第一命令之后,还可以包括:In one example, after sending the first command to the kernel layer, it may also include:
判断内核层是否执行完第一命令;Determine whether the kernel layer has completed executing the first command;
在内核层执行完第一命令之后,恢复内核层自动使能第二命令的功能。After the kernel layer executes the first command, the kernel layer's function of automatically enabling the second command is restored.
这样可以避免影响芯片对其他命令的处理流程。This can avoid affecting the chip's processing flow of other commands.
本申请实施例的命令发送方法,使得作了特殊命令设置的芯片也能够正常地从eMMC器件读取数据或写入数据,避免了因特殊命令设置导致芯片与eMMC器件不相兼容。The command sending method of the embodiment of the present application enables a chip with special command settings to normally read data from or write data to an eMMC device, thus avoiding incompatibility between the chip and the eMMC device due to special command settings.
本申请实施例还提供一种电子设备,该电子设备包括存储器和处理器,存储器与处理器耦合,存储器存储有程序指令,当程序指令由所述处理器执行时,使得电子设备前述电子设备所执行的命令发送方法。An embodiment of the present application also provides an electronic device. The electronic device includes a memory and a processor. The memory is coupled to the processor. The memory stores program instructions. When the program instructions are executed by the processor, the electronic device causes the electronic device to The command sending method to execute.
可以理解的是,电子设备为了实现上述功能,其包含了执行各个功能相应的硬件和/或软件模块。结合本文中所公开的实施例描述的各示例的算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以结合实施例对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。It can be understood that, in order to implement the above functions, the electronic device includes corresponding hardware and/or software modules that perform each function. In conjunction with the algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is performed by hardware or computer software driving the hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions in conjunction with the embodiments for each specific application, but such implementations should not be considered to be beyond the scope of this application.
本实施例还提供一种计算机存储介质,该计算机存储介质中存储有计算机指令,当该计算机指令在电子设备上运行时,使得电子设备执行上述相关方法步骤实现上述实施例中的命令发送方法。This embodiment also provides a computer storage medium that stores computer instructions. When the computer instructions are run on an electronic device, the electronic device causes the electronic device to execute the above related method steps to implement the command sending method in the above embodiment.
本实施例还提供了一种计算机程序产品,当该计算机程序产品在计算机上运行时,使得计算机执行上述相关步骤,以实现上述实施例中的命令发送方法。This embodiment also provides a computer program product. When the computer program product is run on a computer, it causes the computer to perform the above related steps to implement the command sending method in the above embodiment.
另外,本申请实施例还提供一种装置,这个装置具体可以是芯片,组件或模块,该装置可包括相连的处理器和存储器;其中,存储器用于存储计算机执行指令,当装置运行时,处理器可执行存储器存储的计算机执行指令,以使芯片执行上述各方法实施例中的命令发送方法。In addition, the embodiment of the present application also provides a device. This device may be a chip, a component or a module. The device may include a connected processor and a memory. The memory is used to store computer execution instructions. When the device is running, the processing The device can execute computer execution instructions stored in the memory, so that the chip executes the command sending method in each of the above method embodiments.
其中,本实施例提供的电子设备、计算机存储介质、计算机程序产品或芯片均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。Among them, the electronic equipment, computer storage media, computer program products or chips provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the corresponding methods provided above. The beneficial effects of the method will not be repeated here.
通过以上实施方式的描述,所属领域的技术人员可以了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。Through the description of the above embodiments, those skilled in the art can understand that for the convenience and simplicity of description, only the division of the above functional modules is used as an example. In practical applications, the above functions can be allocated to different modules according to needs. The functional module is completed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.
在本申请所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个装置,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods, for example, multiple units or components may be combined or can be integrated into another device, or some features can be ignored, or not implemented. On the other hand, the coupling or direct coupling or communication connection between each other shown or discussed may be through some interfaces, and the indirect coupling or communication connection of the devices or units may be in electrical, mechanical or other forms.
作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是一个物理单元或多个物理单元,即可以位于一个地方,或者也可以分布到多个不同地方。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。A unit described as a separate component may or may not be physically separate. A component shown as a unit may be one physical unit or multiple physical units, that is, it may be located in one place, or it may be distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application can be integrated into one processing unit, each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated units can be implemented in the form of hardware or software functional units.
本申请各个实施例的任意内容,以及同一实施例的任意内容,均可以自由组合。对上述内容的任意组合均在本申请的范围之内。Any contents of various embodiments of this application, as well as any contents of the same embodiment, can be freely combined. Any combination of the above is within the scope of this application.
集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该软件产品存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(read only memory,ROM)、随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。Integrated units may be stored in a readable storage medium if they are implemented in the form of software functional units and sold or used as independent products. Based on this understanding, the technical solutions of the embodiments of the present application are essentially or contribute to the existing technology, or all or part of the technical solution can be embodied in the form of a software product, and the software product is stored in a storage medium , including several instructions to cause a device (which can be a microcontroller, a chip, etc.) or a processor to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage media include: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), magnetic disk or optical disk and other media that can store program codes.
上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。The embodiments of the present application have been described above in conjunction with the accompanying drawings. However, the present application is not limited to the above-mentioned specific implementations. The above-mentioned specific implementations are only illustrative and not restrictive. Those of ordinary skill in the art will Inspired by this application, many forms can be made without departing from the purpose of this application and the scope protected by the claims, all of which fall within the protection of this application.
结合本申请实施例公开内容所描述的方法或者算法的步骤可以硬件的方式来实现,也可以是由处理器执行软件指令的方式来实现。软件指令可以由相应的软件模块组成,软件模块可以被存放于随机存取存储器(Random Access Memory,RAM)、闪存、只读存储器(Read Only Memory,ROM)、可擦除可编程只读存储器(Erasable Programmable ROM,EPROM)、电可擦可编程只读存储器(Electrically EPROM,EEPROM)、寄存器、硬盘、移动硬盘、只读光盘(CD-ROM)或者本领域熟知的任何其它形式的存储介质中。一种示例性的存储介质耦合至处理器,从而使处理器能够从该存储介质读取信息,且可向该存储介质写入信息。当然,存储介质也可以是处理器的组成部分。处理器和存储介质可以位于ASIC中。The steps of the methods or algorithms described in connection with the disclosure of the embodiments of this application can be implemented in hardware or by a processor executing software instructions. Software instructions can be composed of corresponding software modules. The software modules can be stored in random access memory (Random Access Memory, RAM), flash memory, read only memory (Read Only Memory, ROM), erasable programmable read only memory ( Erasable Programmable ROM (EPROM), Electrically Erasable Programmable Read-Only Memory (Electrically EPROM, EEPROM), register, hard disk, removable hard disk, CD-ROM or any other form of storage media well known in the art. An exemplary storage medium is coupled to the processor such that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be an integral part of the processor. The processor and storage media may be located in an ASIC.
本领域技术人员应该可以意识到,在上述一个或多个示例中,本申请实施例所描述的功能可以用硬件、软件、固件或它们的任意组合来实现。当使用软件实现时,可以将这些功能存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。Those skilled in the art should realize that in one or more of the above examples, the functions described in the embodiments of the present application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. Storage media can be any available media that can be accessed by a general purpose or special purpose computer.
上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。The embodiments of the present application have been described above in conjunction with the accompanying drawings. However, the present application is not limited to the above-mentioned specific implementations. The above-mentioned specific implementations are only illustrative and not restrictive. Those of ordinary skill in the art will Inspired by this application, many forms can be made without departing from the purpose of this application and the scope protected by the claims, all of which fall within the protection of this application.
Claims (8)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210848089.1A CN116049045B (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
CN202311631603.7A CN117827704A (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210848089.1A CN116049045B (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311631603.7A Division CN117827704A (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN116049045A CN116049045A (en) | 2023-05-02 |
CN116049045B true CN116049045B (en) | 2023-12-08 |
Family
ID=86122357
Family Applications (2)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210848089.1A Active CN116049045B (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
CN202311631603.7A Pending CN117827704A (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
Family Applications After (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311631603.7A Pending CN117827704A (en) | 2022-07-19 | 2022-07-19 | Command sending method and electronic device |
Country Status (1)
Country | Link |
---|---|
CN (2) | CN116049045B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2016026345A (en) * | 2015-09-03 | 2016-02-12 | マイクロン テクノロジー, インク. | Temporary stop of memory operation for shortening reading standby time in memory array |
CN105518640A (en) * | 2013-09-10 | 2016-04-20 | 高通股份有限公司 | Providing command queuing in embedded memories |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3389920B2 (en) * | 2000-07-10 | 2003-03-24 | 日本電気株式会社 | Disk array device and interrupt execution method for disk array device |
US9021146B2 (en) * | 2011-08-30 | 2015-04-28 | Apple Inc. | High priority command queue for peripheral component |
US11544185B2 (en) * | 2020-07-16 | 2023-01-03 | Silicon Motion, Inc. | Method and apparatus for data reads in host performance acceleration mode |
-
2022
- 2022-07-19 CN CN202210848089.1A patent/CN116049045B/en active Active
- 2022-07-19 CN CN202311631603.7A patent/CN117827704A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105518640A (en) * | 2013-09-10 | 2016-04-20 | 高通股份有限公司 | Providing command queuing in embedded memories |
JP2016026345A (en) * | 2015-09-03 | 2016-02-12 | マイクロン テクノロジー, インク. | Temporary stop of memory operation for shortening reading standby time in memory array |
Non-Patent Citations (1)
Title |
---|
"嵌入式Linux系统中MMC卡驱动管理技术研究";官成钢 等;《单片机与嵌入式系统应用》(2006年第08期);第24-26,39页 * |
Also Published As
Publication number | Publication date |
---|---|
CN116049045A (en) | 2023-05-02 |
CN117827704A (en) | 2024-04-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP2012529692A (en) | Pause memory operations to reduce read latency in memory arrays | |
CN103544994B (en) | Flash memory controller and flash memory debugging method | |
CN114995886B (en) | Memory card identification method and electronic equipment | |
WO2024078218A1 (en) | System booting method and electronic device | |
CN114020652B (en) | Application program management method and electronic equipment | |
CN116094083B (en) | Charging method, device and storage medium | |
CN114706633B (en) | Preloading method, electronic device and storage medium | |
CN115292199A (en) | A processing method and related device for video memory leakage | |
CN116049045B (en) | Command sending method and electronic device | |
CN113672445B (en) | Method for recording running state information of target program and electronic equipment | |
CN116541180B (en) | Memory allocation method, electronic equipment and storage medium | |
CN116700768B (en) | An applied processing method and related device | |
CN114490442B (en) | File fragment adjusting method and electronic equipment | |
CN116662270A (en) | File parsing method and related device | |
CN114879896B (en) | Frozen screen processing method, electronic equipment and storage medium | |
CN117687770B (en) | Memory application method and related device | |
JP2016026345A (en) | Temporary stop of memory operation for shortening reading standby time in memory array | |
CN117130627B (en) | Fitting upgrading method and electronic equipment | |
CN117369735B (en) | Data storage method, electronic device and storage medium | |
CN117093278B (en) | Kernel shutdown method, electronic equipment and storage media | |
WO2024082801A1 (en) | Reset method and electronic device | |
CN117707462A (en) | Audio data processing method, electronic equipment and medium | |
CN118467254A (en) | Method for restoring factory settings and electronic device | |
CN118626218A (en) | Resource scheduling method and electronic equipment | |
CN117724634A (en) | Process management method and device for application program |
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 | ||
CP03 | Change of name, title or address |
Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040 Patentee after: Honor Terminal Co.,Ltd. Country or region after: China Address before: 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong Patentee before: Honor Device Co.,Ltd. Country or region before: China |