WO2024017337A1 - Fifo storage control circuit and method, chip, and electronic device - Google Patents

Fifo storage control circuit and method, chip, and electronic device Download PDF

Info

Publication number
WO2024017337A1
WO2024017337A1 PCT/CN2023/108417 CN2023108417W WO2024017337A1 WO 2024017337 A1 WO2024017337 A1 WO 2024017337A1 CN 2023108417 W CN2023108417 W CN 2023108417W WO 2024017337 A1 WO2024017337 A1 WO 2024017337A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
control circuit
read
switching signal
write
Prior art date
Application number
PCT/CN2023/108417
Other languages
French (fr)
Chinese (zh)
Inventor
秦晨钟
谢韶波
符土建
李晓
Original Assignee
芯海科技(深圳)股份有限公司
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 芯海科技(深圳)股份有限公司 filed Critical 芯海科技(深圳)股份有限公司
Publication of WO2024017337A1 publication Critical patent/WO2024017337A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F5/00Methods or arrangements for data conversion without changing the order or content of the data handled
    • G06F5/06Methods or arrangements for data conversion without changing the order or content of the data handled for changing the speed of data flow, i.e. speed regularising or timing, e.g. delay lines, FIFO buffers; over- or underrun control therefor
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C11/00Digital stores characterised by the use of particular electric or magnetic storage elements; Storage elements therefor
    • G11C11/21Digital stores characterised by the use of particular electric or magnetic storage elements; Storage elements therefor using electric elements
    • G11C11/34Digital stores characterised by the use of particular electric or magnetic storage elements; Storage elements therefor using electric elements using semiconductor devices
    • G11C11/40Digital stores characterised by the use of particular electric or magnetic storage elements; Storage elements therefor using electric elements using semiconductor devices using transistors
    • G11C11/41Digital stores characterised by the use of particular electric or magnetic storage elements; Storage elements therefor using electric elements using semiconductor devices using transistors forming static cells with positive feedback, i.e. cells not needing refreshing or charge regeneration, e.g. bistable multivibrator or Schmitt trigger
    • G11C11/413Auxiliary circuits, e.g. for addressing, decoding, driving, writing, sensing, timing or power reduction

Definitions

  • the present application relates to the field of data storage technology, and more specifically, to a FIFO storage control circuit, method, chip and electronic device.
  • FIFO First Input First Output
  • FIFO memory is a first-in first-out cache device.
  • FIFO memory is divided into synchronous FIFO and asynchronous FIFO.
  • Synchronous FIFO means that the read operation clock and write operation clock are synchronous clocks;
  • asynchronous FIFO means that the read operation clock and write operation clock are asynchronous clocks.
  • Related technologies cannot meet asynchronous FIFO requirements when using single-port static random access memory to implement full-speed FIFO memory.
  • This application proposes a FIFO storage control circuit, method, chip and electronic device to improve the above problems.
  • embodiments of the present application provide a FIFO storage control circuit, including: a single-port random data memory, a switching control circuit and a switching circuit.
  • the switching control circuit is used to generate a switching signal, the switching signal includes a reading switching signal or a writing switching signal; the switching circuit transmits an instruction corresponding to the switching signal to the single-port randomizer according to the switching signal.
  • data memory to randomize the single port
  • the machine data memory performs preset operations, wherein the instructions include read instructions or write instructions, and the preset operations include read operations or write operations.
  • embodiments of the present application provide a FIFO storage control method, including generating a switching signal according to a received communication instruction; the switching signal includes a read switching signal or a writing switching signal;
  • an instruction corresponding to the switching signal is transmitted to the single-port random access data memory to perform a preset operation on the single-port random access data memory, wherein the instruction includes a read instruction or a write instruction, and the Preset operations include read operations or write operations.
  • embodiments of the present application provide a chip including the above-mentioned FIFO storage control circuit.
  • embodiments of the present application provide an electronic device, including the above-mentioned FIFO storage control circuit or the above-mentioned chip.
  • Figure 1 shows a schematic structural block diagram 1 of a FIFO storage control circuit provided by this application
  • Figure 2 shows a schematic structural block diagram 2 of a FIFO storage control circuit provided by this application
  • Figure 3 shows an implementation block diagram of a read-priority FIFO storage control circuit provided by this application
  • Figure 4 shows an implementation block diagram of a write-priority FIFO storage control circuit provided by this application
  • Figure 5 shows a schematic flow chart 1 of a FIFO storage control method provided by this application
  • Figure 6 shows a schematic flow chart 2 of a FIFO storage control method provided by this application
  • Figure 7 shows a schematic flow chart 3 of a FIFO storage control method provided by this application.
  • Figure 8 shows a schematic flow chart 4 of a FIFO storage control method provided by this application.
  • Figure 9 shows a schematic flow chart 5 of a FIFO storage control method provided by this application.
  • Figure 10 shows a schematic structural diagram of a chip provided by this application.
  • Figure 11 shows a schematic structural diagram of an electronic device provided by this application.
  • 100-FIFO storage control circuit 110-single port random data memory; 120-switching control circuit; 130-switching circuit; 140-data buffer; 141-data write buffer; 142-data read buffer ; 151-data writing interface; 152-data reading interface; 160-data control circuit.
  • At least one refers to one or more; multiple refers to two or more.
  • words such as “first”, “second” and “third” are only used for the purpose of distinguishing the description, and cannot be understood as indicating or implying relative importance, nor can they be understood as indicating or implying. order.
  • connection in the embodiments of this application can be understood as electrical connection, and the connection between two electrical components can be a direct or indirect connection between two electrical components.
  • a and B may be connected directly, or A and B may be connected indirectly through one or more other electrical components.
  • FIFO memory is First In First Out memory, which is composed of several storage units. After data is written, it remains unchanged.
  • the FIFO function is implemented by automatically modifying the address pointer inside the chip.
  • FIFO is generally used for data transmission between different clock domains, and FIFO can be used as a data buffer between different clock domains.
  • the FIFO memory can pre-write the obtained data into the FIFO buffer, and then read out the data in the order of writing to the FIFO buffer first and then outputting it first.
  • the FIFO memory storage unit uses static random access memory (Static Random-Access Memory, SRAM).
  • Static random access memory is divided into single-port static random access memory, dual-port static random access memory and pseudo-dual-port static random access memory.
  • Single-port static random access memory means that the storage unit of static random access memory contains only one set of access interfaces
  • dual-port static random access memory means that the storage unit of static random access memory contains two sets of access interfaces, which can independently and simultaneously access static random access memory.
  • Random access memory data means that pseudo-dual-port static random access memory contains 2 sets of access interfaces, which can independently access static random access memory data, but cannot access it simultaneously.
  • Synchronous FIFO means that the read operation clock and write operation clock are synchronous clocks; asynchronous FIFO means that the read operation clock and write operation clock are asynchronous clocks.
  • asynchronous memory In current social life, the demand for asynchronous memory is also widespread, such as writing data from time to time in integrated circuits, reading data serially through communication interfaces such as SPI (Serial Peripheral Interface, Serial Peripheral Interface), or communicating with SPI etc.
  • SPI Serial Peripheral Interface
  • the interface serially writes data, the integrated circuit reads data from time to time, or the integrated circuit internally reads data from time to time, writes data from time to time, etc.
  • an asynchronous storage controller is required. Perform operations.
  • dual-port static random access memory is commonly used as the storage unit of FIFO memory.
  • the area of dual-port static random access memory is about twice the area of single-port static random access memory, which is not conducive to reducing the area of integrated circuits in practical applications. Limited practicality.
  • a FIFO storage control circuit which includes: a single-port random data memory, a switching control circuit and a switching circuit.
  • the switching control circuit is used to generate a switching signal, and the switching signal includes reading the switching signal or writing the switching signal; the switching circuit is used to receive the switching signal sent by the switching control circuit, and transmit the instructions corresponding to the switching signal to the single-port random data memory,
  • the single-port random access data memory is configured to perform a preset operation corresponding to the instruction according to the instruction, wherein the instruction includes a read instruction or a write instruction, and the preset operation includes a read operation or a write operation.
  • the switching control circuit By setting the single-port random data memory, the switching control circuit generates a switching signal, and the switching circuit performs preset operations on the single-port random data memory according to the instructions corresponding to the switching signal according to the switching signal sent by the switching control circuit. That is, when the switching control circuit outputs the write switching signal, the single-port random data memory can be written; only when the switching control circuit outputs the read switching signal, the single-port random data memory can be read.
  • Using a single-port random data memory can meet the asynchronous requirements of FIFO memory, effectively reducing the area of FIFO memory and reducing costs.
  • the FIFO storage control circuit is described in detail below. Please refer to Figure 1.
  • An embodiment of the present application provides a FIFO storage control circuit 100.
  • the FIFO storage control circuit 100 includes: a single-port random data memory 110, a switching control circuit 120 and Switching circuit 130.
  • the single-port random data memory 110 can be used to store data;
  • the switching control circuit 120 is used to generate switching signals, which include reading switching signals or writing switching signals;
  • the switching circuit 130 is connected to the switching control circuit 120 and the single-port random data respectively.
  • the memory 110 is used to transmit instructions corresponding to the switching signal to the single-port random access data memory 110 according to the switching signal, so as to perform preset operations on the single-port random access data memory 110, where the instructions include read instructions or write instructions, and the preset operations include Read operation or write operation.
  • the single-port random access data memory 110 means that the storage unit of the random access data memory only includes one set of access interfaces.
  • the single-port random access data memory 110 uses the same set of address lines when performing read or write operations.
  • the read instruction includes but is not limited to read enable information and read address
  • the write instruction includes but is not limited to write enable information and write address
  • the read operation may be to read the single-port random access data memory 110
  • the writing operation may be to write data to the single-port random access data memory 110 .
  • the FIFO storage control circuit also includes a data writing interface 151 and a data reading interface 152.
  • the switching circuit 130 is connected to the data writing interface 151 and the data reading interface 152 respectively, and is used to control data writing according to the switching signal.
  • the switching circuit 130 is configured to receive the read switching signal sent by the switching control circuit 120 and connect the data reading interface 152 to the single-port random access data memory 110 according to the reading switching signal.
  • the output read command executes reading on the single-port random access data memory 110
  • the fetch operation is to read the data stored in the single-port random access data memory 110.
  • the data reading interface 152 is connected to the single-port random access data memory 110, the data writing interface 151 and the single-port random access data memory 110 are in a non-conducting state.
  • the switching signal sent by the switching control circuit is a read switching signal, a read operation is performed on the single-port random access data memory 110. During this process, the write operation on the single-port random access data memory 110 is prohibited.
  • the switching circuit 130 is also used to receive the writing switching signal sent by the switching control circuit 120, and connect the data writing interface 151 to the single-port random data memory 110 according to the writing switching signal, so as to control the data writing according to the data writing.
  • the write command output by the interface 151 performs a write operation on the single-port random access data memory 110 , that is, writes the data to be stored into the single-port random access data memory 110 .
  • the data writing interface 151 is connected to the single-port random access data memory 110, the data reading interface 152 and the single-port random access data memory 110 are in a non-conducting state.
  • the switching signal sent by the switching control circuit is a write-to-write switching signal, a write operation is performed on the single-port random access data memory 110. During this process, the read operation on the single-port random access data memory 110 is prohibited.
  • the switching circuit 130 may include a multiplexer, or switches corresponding to the number of interfaces, etc., which are not limited here.
  • the switching circuit 130 is a multiplexer as an example.
  • the switching signal is a read
  • the multiplexer connects the data reading interface 152 to the single-port random data memory 110;
  • the switching signal is a write switching signal, the multiplexer connects the data writing interface 152 to the single-port random data memory 110.
  • the switching control circuit 120 may include a controller, which may include a first output terminal and a second output terminal, and the first output terminal and the second output terminal are respectively connected to the switching circuit 130; wherein, the first output terminal The output terminal is used to output the read switching signal to the switching circuit 130 , and the second output terminal is used to output the writing switching signal to the switching circuit 130 .
  • switching control circuit 120 may also include more or less components, which are not specifically limited here.
  • the switching signal output by the switching control circuit 120 when the switching signal output by the switching control circuit 120 is high level, it can be characterized as a read switching signal; when the switching signal output by the switching control circuit 120 is low level, it can be characterized as a writing switching signal.
  • switching signal output by the switching control circuit 120 when the switching signal output by the switching control circuit 120 is low level, it can be characterized as a read switching signal; when the switching signal output by the switching control circuit 120 is high level, it can be characterized as a writing switching signal. .
  • the embodiment of the present application receives the read switching signal sent by the switching control circuit 120 through the switching circuit 130, and switches the data reading interface 152 to be connected to the single-port random data memory 110 according to the reading switching signal, so as to output according to the data reading interface 152
  • the read instruction performs a read operation on the single-port random data memory 110; or the switching circuit 130 receives the write switching signal sent by the switching control circuit 120, and switches the data writing interface 151 to the single-port random data memory according to the write switching signal.
  • 110 is connected to perform a write operation on the single-port random access data memory 110 according to the write instruction output by the data write interface 151.
  • the switching control circuit 120 generates a switching signal, and then the switching circuit 130 responds to the switching signal to finally read or write data to the single-port random data memory 110, so that the FIFO storage control circuit 100 achieves asynchronous operation through a single-port random data memory.
  • the effect is to effectively reduce the area of FIFO memory and reduce the cost.
  • the FIFO storage control circuit 100 is also used to determine a preset operation according to the received communication instruction, so that the switching control circuit 120 generates a switching signal according to the preset operation.
  • prediction can be made through the communication instructions issued when the communication interface performs corresponding operations on the FIFO storage control circuit 100. For example, if the communication interface wants to perform a read operation on the FIFO storage control circuit 100, a read instruction will be issued. , through the read command, it can be predicted that the preset operation is a read operation. If the communication interface wants to perform a write operation on the FIFO storage control circuit 100, a write command will be issued. Through the write command, it can be predicted that the preset operation is writing operation, in this way, after predicting the preset operation, the switching control circuit 120 can determine the switching signal according to the preset operation. If the preset operation is a read operation, the corresponding switching signal is a read switching signal; if the preset operation is a write operation, the corresponding switching signal is a write switching signal.
  • the communication interface can be SPI (Serial Peripheral Interface, serial peripheral interface), I2C (Inter-Integrated Circuit, two-wire serial bus), or UART (Universal Asynchronous Receiver/Transmitter, Universal Asynchronous Receiver/Receiver) transmitter), there is no restriction here.
  • SPI Serial Peripheral Interface, serial peripheral interface
  • I2C Inter-Integrated Circuit, two-wire serial bus
  • UART Universal Asynchronous Receiver/Transmitter, Universal Asynchronous Receiver/Receiver
  • the FIFO storage control circuit 100 is also used to synchronize the switching signal to the corresponding clock domain; wherein, the clock domain includes Read operation clock domain or write operation clock domain.
  • the corresponding clock domain refers to the clock domain opposite to the current switching signal. For example, if the switching signal is a read switching signal, the clock domain opposite to the switching signal is the writing operation clock domain; if the switching signal is a writing switching signal, the clock domain opposite to the switching signal is the reading operation clock domain.
  • the switching signal corresponding to the preset operation needs to be synchronized to the clock domain opposite to the switching signal, because the current operation of the FIFO storage control circuit 100 is generally the same as the preset operation.
  • the clock connected is the clock opposite to the instruction corresponding to the preset operation, and the instruction corresponding to the preset operation is executed. Since the single-port random access data memory 110 has only one set of interfaces, in order to avoid passing through The sudden switching of the instructions transmitted to the single-port random data memory 110 by this set of interfaces will affect data reading or data writing.
  • the switching signal can be synchronized to
  • the FIFO stores the clock domain corresponding to the current operation of the control circuit 100, that is, the clock domain opposite to the switching signal, and reserves reaction time for the switching of instructions.
  • the FIFO storage control circuit 100 is used to synchronize the read switching signal to the write operation clock domain.
  • the switching signal is a read switching signal
  • the instruction corresponding to the read switching signal is a read instruction
  • the preset operation is a read operation
  • the current operation of the FIFO storage control circuit 100 is generally a write operation.
  • the switching signal can be synchronized to the write operation clock domain first, so that the write operation clock domain stops the write operation.
  • the switching circuit 130 then transmits the read command to the single-port random access data memory 110. This can avoid the impact of sudden switching of instructions on the single-port random access data memory 110 on the reading or writing of data.
  • the FIFO storage control circuit 100 is also used to synchronize the write switching signal to the read operation clock domain.
  • the switching signal is a write switching signal
  • the instruction corresponding to the write switching signal is a write instruction
  • the preset operation is a write operation
  • the current operation of the FIFO storage control circuit 100 is generally a read operation.
  • the switching signal can be synchronized to the read operation clock domain first, so that the read operation clock domain stops the read operation, and then the switching circuit 130 transmits the write command to the single-port randomizer.
  • the data memory 110 can avoid the sudden switching of instructions executed on the single-port random access data memory 110, which may affect the reading or writing of data.
  • the FIFO storage control circuit 100 also includes a data control circuit 160 and at least one data buffer 140.
  • the data control circuit 160 is connected to the switching control circuit 120 and the data buffer 140 respectively, and is connected to the single-port random data memory 110.
  • the data control circuit 160 is used to receive a request signal, and when the request signal is inconsistent with the switching signal, perform an operation corresponding to the request signal on the data buffer 140 according to the request signal; wherein the request signal includes a data read request or data Write request.
  • the data control circuit 160 is also connected to the switching circuit 130, and the data buffer 140 is also connected to the single-port random access data memory 110.
  • a request signal inconsistent with the switching signal may be received.
  • the preset operation is being performed on the single-port random access data memory 110 at this time, so the The switching signal corresponding to the preset operation is inconsistent with the request signal, so the corresponding operation cannot be performed on the single-port random data memory 110 according to the request signal.
  • a data control circuit 160 and at least one data cache are set in the FIFO storage control circuit 100
  • the processor 140 is configured to receive the request signal and perform operations corresponding to the request signal on the data buffer 140 .
  • the request signal is a data write request and the switching signal is a read switching signal
  • the data control circuit 160 writes the data to be written according to the data writing request. in the data buffer 140. Since the switching signal is a read switching signal, accordingly, a read operation is performed on the single-port random data memory 110, which is inconsistent with the request signal for a data write request. Therefore, the single-port random data memory 110 cannot execute a data write request. If the corresponding operation is performed, the operation corresponding to the data write request can be performed on the data buffer 140 , that is, the data to be written is first written into the data buffer 140 .
  • the request signal is a data read request and the switching signal is a write switching signal
  • the data control circuit 160 reads from the data buffer 140 according to the data read request. Get data. Since the switching signal is a write switching signal, accordingly, the single-port random access data memory 110 performs a write operation, which is inconsistent with the request signal for a data read request, and the single-port random access data memory 110 cannot perform the operation corresponding to the data read request. operation, you can pass the data
  • the buffer 140 is used to perform operations corresponding to the data read request, that is, data is first read from the data buffer 140 .
  • the data buffer 140 is equivalent to a register. When performing a read or write operation on the single-port random access data memory 110, another operation will be blocked. This problem can be solved through the data buffer.
  • the data buffer 140 may include a data write buffer 141, may include a data read buffer 142, and may further include a data write buffer 141 and a data read buffer 142.
  • the data control circuit 160 When the switching circuit 130 performs a read operation on the single-port random access data memory 110 according to the read command output by the data read interface, the data control circuit 160 writes the data to be written into the data write buffer 141 according to the write request.
  • the data write buffer 141 can be used first. The data to be written in the single-port random access data memory 110 is buffered into the data write buffer 141 according to the write request. After the read operation is completed on the single-port random access data memory 110 , the data in the data write buffer 141 is transferred to the single-port random access data memory 110 .
  • the data control circuit 160 reads data from the data read buffer 142 according to the data read request.
  • the request cannot be executed on the single-port random data memory 110.
  • You can read the data through The fetch buffer 141 will first read data from the data read buffer 141 according to the read request. In order to prevent the data read buffer 141 from being empty, some data can be transferred from the single port random access data memory 110 to the data read buffer 141 before performing a write operation on the single port random access data memory 110 .
  • the data control circuit 160 or the data buffer 140 can be controlled through an enable signal.
  • the enable signal types include read enable and write enable.
  • the enable information when the enable information is high level, it can be characterized as read enable, and the data read interface 152 (or an external device connected to the data read interface 152) can read data from the data read buffer 142. Read the stored data; when the enable information is low level, it can be characterized as write enable information, and the data write interface 151 (or an external device connected to the data write interface 151) can write data into the buffer 141 Write the data to be stored.
  • the data read interface 152 (or an external device connected to the data read interface 152) can read the data buffer 142 from the data read interface 152. Read the stored data; when the enable information is high level, it is characterized as write enable information, and the data write interface 151 (or an external device connected to the data write interface 151) writes to the data write buffer 141 Enter the data to be stored.
  • the data control circuit 160 is also connected to the single-port random access data memory 110 .
  • the switching circuit 130 executes the single-port random data memory 110 according to the instruction corresponding to the switching signal.
  • the data control circuit 160 is also used to write the data stored in the data buffer 140 into the single-port random data memory 110, or to write the data in the single-port random data memory 110 into the data buffer 140.
  • the default operation is a read operation.
  • the data control circuit 160 writes the data in the data buffer 140 to the single-port random data memory. 110.
  • the preset operation is a write operation
  • the data control circuit 160 controls the data buffer 140 to read the single-port random access data memory 110 after the switching circuit 130 completes the write operation on the single-port random access data memory 110 .
  • the switching control circuit is also used to switch the current switching signal after performing the preset operation on the single-port random data memory 110; and to control the single-port random data memory 110 to execute and switch according to the switched signal.
  • the signal corresponds to the preset operation. After performing the preset operation corresponding to the switching signal on the single-port random access data memory 110, as mentioned above, after performing the operation corresponding to the request signal on the data buffer 140 according to the request signal, the actual corresponding object of the request signal is the single-port random access signal.
  • the data memory 110 and the data buffer 140 play a transitional role when the operation corresponding to the request signal cannot be performed on the single-port random data memory 110.
  • the data buffer performs corresponding processing, so that the switching control signal 120 can switch the current switching signal to be consistent with the request signal, so that the single-port random data memory 110 can execute the switching information according to the switched signal.
  • the preset operation at this time corresponds to the request signal. For example, if the request signal is a write request, the corresponding preset operation is a write operation; if the request signal is a read request, the corresponding preset operation is a read operation.
  • the switching control circuit 120 switches the reading switching signal to a writing switching signal to perform a writing operation on the single-port random access data memory 110, thereby changing the data buffer
  • the data in 140 is written into the single-port random access data memory 110.
  • the read switching signal can be switched to the write switching signal through the switching control circuit 120, And synchronize the write switching signal to the write operation clock domain for subsequent write operations.
  • the data control circuit 160 includes a first inverter 161 , a second inverter 162 and a first logic gate 163 .
  • the first input end of the first logic gate 163 is connected to the switching control circuit 120
  • the output terminal and the second input terminal are connected to the output terminal of the first inverter 161, and the output terminal is respectively connected to the input terminal of the second inverter 162 and the input terminal of the data write register 141; the second inverter
  • the output terminal of 162 is connected to the WEN (write enable terminal) of the single-port random access data memory 110 .
  • the switching control circuit 120 switches the original read switching signal to output the write switching signal.
  • the switching circuit 130 switches the single-port random access data memory 110 according to the write switching signal.
  • the connected interface is switched, the CLK (clock port) is switched from the read clock to the write clock, and the ADR (address port) is switched from the read pointer to the write pointer.
  • Switch CEN (enable port) from read enable to read cache enable.
  • the write switching signal as a high level as an example, if the data in the data write buffer 141 is not empty at this time, the data can be read from the data write buffer 141, and there is currently no data written into the data.
  • the write register 141 that is, the write enable is low level
  • the write enable output is high level after passing through the first inverter 161, and is input to the second input terminal of the first logic gate 163,
  • the write switching information (high level) is input to the first input terminal of the first logic gate 163.
  • the output is high level, that is, the read cache enable is high level, resulting in a read data cache operation.
  • the CEN port of the single-port random data memory 110 is low level, and corresponding operations can be performed on the single-port random data memory 110; the high level output by the first logic gate 163 After passing through the second inverter 162, the output is low level, so that the WEN port that is finally input to the single-port random data memory 110 is low level, and a write operation can be performed on the single-port random data memory 110, and the data will be written into the buffer.
  • the data read in 141 is written into the address of the single-port random data memory 110 pointed to by the pointer of the single-port random data memory 110 through the DIN (data input port).
  • the switching control circuit 120 switches the writing switching signal to a reading switching signal to perform a reading operation on the single-port random access data memory 110 to control the data cache.
  • the processor 140 reads the data in the single-port random access data memory 110.
  • the write switching signal can be switched to the read switching signal through the switching control circuit 120, And synchronize the read switching signal to the read operation clock domain for subsequent read operations.
  • the data control circuit 160 includes a third inverter 164 , a fourth inverter 165 , a fifth inverter 167 and a second logic gate 166 , a first input of the second logic gate 166
  • the terminal is connected to the output terminal of the third inverter 164, the second input terminal is connected to the output terminal of the fourth inverter 165, and the output terminal is connected to the input terminal of the data read register 142;
  • the input terminal is connected to the output terminal of the switching control circuit 120 , and the output terminal of the fifth inverter 162 is connected to the WEN (write enable terminal) of the single-port random access data memory 110 .
  • the switching control circuit 120 switches the original write switching signal to output the read switching signal.
  • the switching circuit 130 switches the single-port random access data memory 110 according to the read switching signal. Switch the connected interface, switch the CLK (clock port) from the write clock to the read clock, switch the ADR (address port) from the write pointer to the read pointer, and switch the CEN (enable port) from the write enable Switch to write cache enable.
  • the read switching signal as a low level as an example, if the data read buffer 142 is not full, data can still be written to the data read buffer 142, and no data is currently read from the data read buffer 142.
  • the read enable is low level
  • the read enable output is high level after passing through the third inverter 164, and is input to the first input terminal of the second logic gate 166 to read the switching information ( low level) after passing through the second inverter 165, the output is high level, and is input to the second input terminal of the second logic gate 166, then the output of the second logic gate 166 is high level, that is, the write cache is enabled.
  • a write data cache operation is generated, and data can be written to the data read buffer 141.
  • the CEN port of the single-port random data memory 110 is low level, and the corresponding operation can be performed on the single-port random data memory 110;
  • the WEN port of the five-port inverter 167 input to the single-port random data memory 110 is at a high level, and the read operation can be performed on the single-port random data memory 110.
  • the data is read from the single-port random data memory 110 through DOUT (output data port) and Write to the data read buffer 142. In this way, the data of the single-port random access data memory 110 can be written into the data read buffer 142.
  • the data can be read from the cache memory 142.
  • the data is read from the data read buffer 142.
  • the following takes the communication interface as SPI, the write switching signal as high level, and the read switching signal as low level as an example to respectively conduct the pre-judgment of the read operation and the pre-judgment in this application.
  • the write operation is described below.
  • the SPI When the SPI performs a read operation on the FIFO storage control circuit 100, it can be predicted through the communication command that a read operation is to be performed, and the switching control circuit 120 selects to read the switching signal ( low level), and synchronizes the read switching signal to the write operation clock domain to prohibit the write operation, and then the switching circuit 130 switches the data reading interface 152 to the single-port random data memory when receiving the read switching signal. 110 connections.
  • the CLK (clock port) of the single-port random data memory 110 is switched to the read clock
  • the ADR address port
  • the CEN enable port
  • a read operation is performed on the single-port random access data memory 110, that is, the data stored in the single-port random access data memory 110 is read. During this process, the write operation on the single-port random access data memory 110 is prohibited. If there is a data write request during this process, the corresponding write enable of the data write buffer 141 is high, and the data to be written in the single-port random access data memory 110 can be cached into the data write buffer 141 .
  • the switching control circuit 120 When the read operation ends, the switching control circuit 120 re-enables the writing operation and synchronizes the writing switching signal to the writing operation clock domain. After receiving the writing switching signal sent by the switching control circuit 120, the switching circuit 130 The CLK (clock port) of the single-port random data memory 110 switches from the read clock to the write clock, the ADR (address port) switches from the read pointer to the write pointer, and the CEN (enable port) switches from the read enable Enable read caching. If the data write buffer 141 is not empty (the data write buffer 141 has data), and there is currently no write data cache operation (the write enable is low level), a read data cache operation is generated, and the data is read. Write the data cached in the buffer 141.
  • the CEN port of the single-port random data memory 110 is low level, indicating that the single-port random data memory 110 can be read or written.
  • the write switching signal is high level, the write enable is low level, and the data control
  • the circuit 160 is connected to the WEN port of the single-port random access data memory 110, and supplies the WEN port to the WEN port.
  • the port outputs a low level the write operation can be performed on the single-port random data memory 110, and the data read from the data write buffer 141 is written to the pointer of the single-port random data memory 110 through the DIN (data input port). The address pointed to by the single-port random access data memory 110.
  • the SPI When the SPI performs a write operation on the FIFO storage control circuit 100, it can be predicted through the communication command that a write operation is to be performed, and the switch control circuit 120 selects the write switch signal (high) according to the write operation. level), and synchronizes the write switching signal to the read operation clock domain to prohibit the read operation, and then the switching circuit 130 switches the data writing interface 152 to the single-port random data memory 110 when receiving the writing switching signal. connect.
  • the CLK (clock port) of the single-port random data memory 110 is switched to the write clock
  • the ADR address port
  • the CEN enable port
  • a write operation is performed on the single-port random access data memory 110, that is, data is written into the single-port random access data memory 110. During this process, the read operation on the single-port random access data memory 110 is prohibited. If there is a data reading request during this process, the corresponding read and write enable of the data reading buffer 142 is high, and the data can be read from the data reading buffer 142 .
  • the switching control circuit 120 When the write operation ends, the switching control circuit 120 re-enables the read operation and synchronizes the read switching signal to the read operation clock domain. After receiving the read switching signal sent by the switching control circuit 120, the switching circuit 130 The CLK (clock port) of the single-port random data memory 110 switches from the write clock to the read clock, the ADR (address port) switches from the write pointer to the read pointer, and the CEN (enable port) switches from write enable Enable write caching. If the data read buffer 141 is not full and there is currently no data read operation from the data read buffer 142 (the read enable is low level), a write data cache operation occurs, and the data read buffer 142 can be read. Write data in 141.
  • the CEN port of the single-port random data memory 110 is at a low level, indicating that the single-port random data memory 110 can be read or written.
  • the data control circuit 160 is connected to the WEN port of the single-port random data memory 110 and outputs a high level to the WEN port. level, the single-port random access data memory 110 can perform a read operation, read data from the single-port random access data memory 110 through DOUT (output data port) and write it into the data read buffer 142.
  • the switching circuit 130 can switch the connection between the data writing interface 151 and the single-port random data memory 110 in advance; when the writing clock stops, it means that the writing operation will not be performed temporarily, and the switching circuit 130 can switch in advance.
  • the circuit 130 can switch the data reading interface 151 to connect to the single-port random data memory 110 in advance; when both the reading and writing clocks are stopped, it means that the reading and writing operations will not be performed temporarily, the data reading interface 152 or the data writing interface 151 can maintain the specified state or restore the initial state.
  • This designated state means that the data reading interface 152 or the data writing interface 151 remains connected to the single-port random access data memory 110 at the end of the last work.
  • the above-mentioned application embodiment reads and writes data from time to time to the FIFO storage control circuit 100 through the communication interface, predicts the read operation or write operation, generates a switching signal in the switching control circuit 120, and the switching circuit 130 performs switching control according to the switching control circuit 120.
  • the read switching signal sent by the circuit 120 switches the data read interface 152 to be connected to the single-port random access data memory 110, so as to read according to the read signal output by the data read interface 152.
  • the instruction is to perform a read operation on the single-port random access data memory 110, or the switching circuit 130 switches the data writing interface 151 to be connected to the single-port random access data memory 110 according to the write switching signal sent by the switching control circuit 120, so that the data writing interface 151
  • the output write command performs a write operation on the single-port random data memory 110, in which the read operation clock and the write operation clock are independent. Only when the switching control circuit 120 outputs a write switching signal can the single-port random data memory 110 be written. A write operation is performed; only when the switching control circuit 120 outputs a read switching signal, the read operation can be performed on the single-port random access data memory 110 .
  • the above-mentioned FIFO storage control circuit 100 uses a single-chip single-port random data memory 110 as the storage unit, which meets the asynchronous requirements of the FIFO storage control device, effectively reduces the area of the FIFO memory, and reduces the cost.
  • FIG. 5 is a schematic flowchart of a FIFO storage control method provided by yet another embodiment of the present application.
  • the FIFO storage control method can be applied to the above-mentioned FIFO storage control circuit 100, and the method can include the following steps:
  • Step S210 Generate a switching signal according to the received communication command.
  • the switching signal includes a read switching signal or a writing switching signal.
  • Step S220 Transmit the instruction corresponding to the switching signal to the single-port random access data memory 110 according to the switching signal to perform a preset operation on the single-port random access data memory 110, where the instruction includes a read instruction or a write instruction, and the preset operation includes a read operation. or write operation.
  • step S220 the method also includes:
  • Step S230 Control the connection status of the data writing interface and the data reading interface to the single-port random access data memory 110 according to the switching signal.
  • step S230 please refer to the detailed description of the foregoing embodiments, and will not be described again here.
  • Step 210 Generate a switching signal according to the received communication command.
  • the switching signal includes a reading switching signal or a writing switching signal.
  • Step S240 Connect the data reading interface 152 to the single-port random access data memory 110 according to the read switching signal, so as to perform a read operation on the single-port random access data memory 110 according to the read command output by the data reading interface 152.
  • step S240 please refer to the detailed description of the foregoing embodiments, and will not be described again here.
  • This method may also include the following steps:
  • Step 210 Generate a switching signal according to the received communication command.
  • the switching signal includes a reading switching signal or a writing switching signal.
  • Step S250 Connect the data writing interface 151 to the single-port random data storage according to the writing switching signal.
  • the memory 110 is configured to perform a write operation on the single-port random access data memory 110 according to the write command output by the data write interface 151 .
  • step S250 please refer to the detailed description of the foregoing embodiments, and will not be described again here.
  • step S220 the method also includes:
  • Step S260 Synchronize the switching signal to the corresponding clock domain; where the clock domain includes a read operation clock domain or a write operation clock domain.
  • step S260 please refer to the detailed description of the foregoing embodiments, and will not be described again here.
  • FIG. 10 is a schematic structural diagram of a chip provided by this application. As shown in FIG. 10 , the chip 20 includes a FIFO storage control circuit 100 .
  • FIG. 11 is a schematic structural diagram of an electronic device provided by this application. As shown in FIG. 10 , the electronic device 30 includes a FIFO storage control circuit 100 or a chip 20 .
  • the electronic device 30 may be, but is not limited to, a weight scale, a body fat scale, a nutritional scale, an infrared electronic thermometer, a pulse oximeter, a body composition analyzer, a mobile power supply, a wireless charger, a fast charger, a vehicle mounted Chargers, adapters, monitors, USB (Universal Serial Bus, Universal Serial Bus) docking stations, stylus pens, true wireless headphones, car central control units, cars, smart wearable devices, mobile terminals, smart home devices.
  • Smart wearable devices include but are not limited to smart watches, smart bracelets, and cervical massagers.
  • Mobile terminals include but are not limited to smartphones, laptops, tablets, and POS (point of sales terminal) machines.
  • Smart home devices include but are not limited to smart sockets, smart rice cookers, smart sweepers, and smart lights.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Computer Hardware Design (AREA)
  • Communication Control (AREA)
  • Static Random-Access Memory (AREA)

Abstract

Disclosed in the present application are a FIFO storage control circuit and method, a chip, and an electronic device. The circuit comprises: a single-port random access memory, a switching control circuit and a switching circuit, wherein a switching signal is generated by means of the switching control circuit, and the switching signal comprises a reading switching signal or a writing switching signal; according to the switching signal, the switching circuit transmits to the single-port random data memory an instruction corresponding to the switching signal, so as to execute a preset operation on the single-port random data memory according to the instruction, the instruction comprising a reading instruction or a writing instruction, and the preset operation comprising a reading operation or a writing operation.

Description

一种FIFO存储控制电路、方法、芯片及电子设备A FIFO storage control circuit, method, chip and electronic device
相关申请的交叉引用Cross-references to related applications
本申请要求于2023年7月7日提交中国专利局、申请号为202310836566.7、发明名称为“一种FIFO存储控制电路、方法、芯片及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application requests the priority of the Chinese patent application submitted to the China Patent Office on July 7, 2023, with the application number 202310836566.7 and the invention name "A FIFO storage control circuit, method, chip and electronic device". All its contents are approved by This reference is incorporated into this application.
本申请要求于2022年7月22日提交中国专利局、申请号为202210871438.1、发明名称为“一种FIFO存储控制电路、方法、芯片及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application submitted to the China Patent Office on July 22, 2022, with the application number 202210871438.1 and the invention name "A FIFO storage control circuit, method, chip and electronic device". All its contents are approved by This reference is incorporated into this application.
技术领域Technical field
本申请涉及数据存储技术领域,更具体地,涉及一种FIFO存储控制电路、方法、芯片及电子设备。The present application relates to the field of data storage technology, and more specifically, to a FIFO storage control circuit, method, chip and electronic device.
背景技术Background technique
FIFO(First Input First Output,先进先出)存储器是一种先进先出缓存设备,一般的,FIFO存储器分为同步FIFO和异步FIFO。同步FIFO指读操作时钟和写操作时钟为同步时钟;异步FIFO指读操作时钟和写操作时钟为异步时钟。相关技术在利用单口静态随机存储器实现全速FIFO存储器时,不能满足异步FIFO需求。FIFO (First Input First Output) memory is a first-in first-out cache device. Generally, FIFO memory is divided into synchronous FIFO and asynchronous FIFO. Synchronous FIFO means that the read operation clock and write operation clock are synchronous clocks; asynchronous FIFO means that the read operation clock and write operation clock are asynchronous clocks. Related technologies cannot meet asynchronous FIFO requirements when using single-port static random access memory to implement full-speed FIFO memory.
发明内容Contents of the invention
本申请提出了一种FIFO存储控制电路、方法、芯片及电子设备,以改善上述问题。This application proposes a FIFO storage control circuit, method, chip and electronic device to improve the above problems.
第一方面,本申请实施例提供了一种FIFO存储控制电路,包括:单口随机数据存储器、切换控制电路以及切换电路。所述切换控制电路用于产生切换信号,所述切换信号包括读取切换信号或写入切换信号;所述切换电路据所述切换信号将与所述切换信号对应的指令传输至所述单口随机数据存储器,以对所述单口随 机数据存储器执行预设操作,其中,所述指令包括读指令或写指令,所述预设操作包括读取操作或写入操作。In the first aspect, embodiments of the present application provide a FIFO storage control circuit, including: a single-port random data memory, a switching control circuit and a switching circuit. The switching control circuit is used to generate a switching signal, the switching signal includes a reading switching signal or a writing switching signal; the switching circuit transmits an instruction corresponding to the switching signal to the single-port randomizer according to the switching signal. data memory to randomize the single port The machine data memory performs preset operations, wherein the instructions include read instructions or write instructions, and the preset operations include read operations or write operations.
第二方面,本申请实施例提供了一种FIFO存储控制方法,包括根据接收的通信指令产生切换信号;所述切换信号包括读取切换信号或写入切换信号;In the second aspect, embodiments of the present application provide a FIFO storage control method, including generating a switching signal according to a received communication instruction; the switching signal includes a read switching signal or a writing switching signal;
根据所述切换信号将与所述切换信号对应的指令传输至所述单口随机数据存储器,以对所述单口随机数据存储器执行预设操作,其中,所述指令包括读指令或写指令,所述预设操作包括读取操作或写入操作。According to the switching signal, an instruction corresponding to the switching signal is transmitted to the single-port random access data memory to perform a preset operation on the single-port random access data memory, wherein the instruction includes a read instruction or a write instruction, and the Preset operations include read operations or write operations.
第三方面,本申请实施例提供了一种芯片,包括上述的FIFO存储控制电路。In a third aspect, embodiments of the present application provide a chip including the above-mentioned FIFO storage control circuit.
第四方面,本申请实施例提供了一种电子设备,包括上述的FIFO存储控制电路或上述的芯片。In a fourth aspect, embodiments of the present application provide an electronic device, including the above-mentioned FIFO storage control circuit or the above-mentioned chip.
附图说明Description of drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments will be briefly introduced below. 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 based on these drawings without exerting creative efforts.
图1示出了本申请提供的一种FIFO存储控制电路的结构示意框图一;Figure 1 shows a schematic structural block diagram 1 of a FIFO storage control circuit provided by this application;
图2示出了本申请提供的一种FIFO存储控制电路的结构示意框图二;Figure 2 shows a schematic structural block diagram 2 of a FIFO storage control circuit provided by this application;
图3示出了本申请提供的一种读取优先的FIFO存储控制电路的实现框图;Figure 3 shows an implementation block diagram of a read-priority FIFO storage control circuit provided by this application;
图4示出了本申请提供的一种写入优先的FIFO存储控制电路的实现框图;Figure 4 shows an implementation block diagram of a write-priority FIFO storage control circuit provided by this application;
图5示出了本申请提供的一种FIFO存储控制方法的流程示意图一;Figure 5 shows a schematic flow chart 1 of a FIFO storage control method provided by this application;
图6示出了本申请提供的一种FIFO存储控制方法的流程示意图二;Figure 6 shows a schematic flow chart 2 of a FIFO storage control method provided by this application;
图7示出了本申请提供的一种FIFO存储控制方法的流程示意图三;Figure 7 shows a schematic flow chart 3 of a FIFO storage control method provided by this application;
图8示出了本申请提供的一种FIFO存储控制方法的流程示意图四;Figure 8 shows a schematic flow chart 4 of a FIFO storage control method provided by this application;
图9示出了本申请提供的一种FIFO存储控制方法的流程示意图五;Figure 9 shows a schematic flow chart 5 of a FIFO storage control method provided by this application;
图10示出了本申请提供的一种芯片的结构示意图;Figure 10 shows a schematic structural diagram of a chip provided by this application;
图11示出了本申请提供的一种电子设备的结构示意图。Figure 11 shows a schematic structural diagram of an electronic device provided by this application.
附图中:100-FIFO存储控制电路;110-单口随机数据存储器;120-切换控制电路;130-切换电路;140-数据缓存器;141-数据写入缓存器;142-数据读取缓存器;151-数据写入接口;152-数据读取接口;160-数据控制电路。In the attached figure: 100-FIFO storage control circuit; 110-single port random data memory; 120-switching control circuit; 130-switching circuit; 140-data buffer; 141-data write buffer; 142-data read buffer ; 151-data writing interface; 152-data reading interface; 160-data control circuit.
具体实施方式Detailed ways
下面详细描述本申请的实施方式,实施方式的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下 面通过参考附图描述的实施方式是示例性地,仅用于解释本申请,而不能理解为对本申请的限制。The embodiments of the present application are described in detail below. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements with the same or similar functions. Down The embodiments described above with reference to the accompanying drawings are exemplary and are only used to explain the present application and cannot be understood as limiting the present application.
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to enable those in the technical field to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only These are part of the embodiments of this application, but not all of them. 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.
本申请实施例中,至少一个是指一个或多个;多个,是指两个或两个以上。在本申请的描述中,“第一”、“第二”、“第三”等词汇,仅用于区分描述的目的,而不能理解为指示或暗示相对重要性,也不能理解为指示或暗示顺序。In the embodiments of this application, at least one refers to one or more; multiple refers to two or more. In the description of this application, words such as "first", "second" and "third" are only used for the purpose of distinguishing the description, and cannot be understood as indicating or implying relative importance, nor can they be understood as indicating or implying. order.
在本说明书中描述的参考“一种实施方式”或“一些实施方式”等意味着在本申请的一个或多个实施方式中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。Reference in this specification to "one embodiment" or "some embodiments" or the like means that a particular feature, structure or characteristic described in connection with the embodiment is included in one or more embodiments of the application. Therefore, in this specification, the terms "including", "includes", "having" and their variations all mean "including but not limited to" unless otherwise specifically emphasized.
需要指出的是,本申请实施例中“连接”可以理解为电连接,两个电学元件连接可以是两个电学元件之间的直接或间接连接。例如,A与B连接,既可以是A与B直接连接,也可以是A与B之间通过一个或多个其它电学元件间接连接。It should be noted that “connection” in the embodiments of this application can be understood as electrical connection, and the connection between two electrical components can be a direct or indirect connection between two electrical components. For example, A and B may be connected directly, or A and B may be connected indirectly through one or more other electrical components.
FIFO存储器即先进先出(First In First Out)存储器,是由若干存储单元构成的,数据写入之后就保持不动,FIFO功能是利用芯片内部的地址指针的自动修改来实现的。FIFO一般用于不同时钟域之间的数据传输,不同的时钟域间可以采用FIFO来作为数据缓冲。FIFO存储器可以将获得的数据预先写入FIFO缓存器,再按先写入FIFO缓存器就先输出的顺序将数据读出。一般FIFO存储器存储单元采用静态随机存取存储器(Static Random-Access Memory,SRAM)。FIFO memory is First In First Out memory, which is composed of several storage units. After data is written, it remains unchanged. The FIFO function is implemented by automatically modifying the address pointer inside the chip. FIFO is generally used for data transmission between different clock domains, and FIFO can be used as a data buffer between different clock domains. The FIFO memory can pre-write the obtained data into the FIFO buffer, and then read out the data in the order of writing to the FIFO buffer first and then outputting it first. Generally, the FIFO memory storage unit uses static random access memory (Static Random-Access Memory, SRAM).
静态随机存取存储器分为单口静态随机存取存储器、双口静态随机存取存储器和伪双口静态随机存取存储器。单口静态随机存储器是指静态随机存取存储器的存储单元仅包含1组访问接口;双口静态随机存取存储器是指静态随机存取存储器的存储单元包含2组访问接口,可独立、同时访问静态随机存取存储器数据;伪双口静态随机存取存储器是指静态随机存取存储器的存储单元包含2组访问接口,可独立访问静态随机存取存储器数据,但不能同时访问。Static random access memory is divided into single-port static random access memory, dual-port static random access memory and pseudo-dual-port static random access memory. Single-port static random access memory means that the storage unit of static random access memory contains only one set of access interfaces; dual-port static random access memory means that the storage unit of static random access memory contains two sets of access interfaces, which can independently and simultaneously access static random access memory. Random access memory data; pseudo-dual-port static random access memory means that the storage unit of static random access memory contains 2 sets of access interfaces, which can independently access static random access memory data, but cannot access it simultaneously.
目前,FIFO存储器分为同步FIFO和异步FIFO。同步FIFO指读操作时钟和写操作时钟为同步时钟;异步FIFO指读操作时钟和写操作时钟为异步时钟。Currently, FIFO memory is divided into synchronous FIFO and asynchronous FIFO. Synchronous FIFO means that the read operation clock and write operation clock are synchronous clocks; asynchronous FIFO means that the read operation clock and write operation clock are asynchronous clocks.
在目前的社会生活中,异步存储器的需求也比较广泛,例如在集成电路中不定时写数据、SPI((Serial Peripheral Interface,串行外设接口)等通信接口串行读数据,或SPI等通信接口串行写数据,集成电路中不定时读数据,或集成电路内部不定时读数据、不定时写数据等不是长时间连续进行读操作和写操作的应用场景下,就需要运用异步存储控制器进行操作。 In current social life, the demand for asynchronous memory is also widespread, such as writing data from time to time in integrated circuits, reading data serially through communication interfaces such as SPI (Serial Peripheral Interface, Serial Peripheral Interface), or communicating with SPI etc. The interface serially writes data, the integrated circuit reads data from time to time, or the integrated circuit internally reads data from time to time, writes data from time to time, etc. In application scenarios that do not continuously read and write operations for a long time, an asynchronous storage controller is required. Perform operations.
异步FIFO存储器设计中常用双口静态随机存储器做为FIFO存储器的存储单元,但是双口静态随机存储器的面积约为单口静态随机存储器面积的两倍,不利于实际应用时减小集成电路的面积,实用性受限。In the design of asynchronous FIFO memory, dual-port static random access memory is commonly used as the storage unit of FIFO memory. However, the area of dual-port static random access memory is about twice the area of single-port static random access memory, which is not conducive to reducing the area of integrated circuits in practical applications. Limited practicality.
为了解决上述存在的问题,本申请实施例提供了一种FIFO存储控制电路,该电路包括:单口随机数据存储器、切换控制电路以及切换电路。切换控制电路用于产生切换信号,切换信号包括读取切换信号或写入切换信号;切换电路用于接收切换控制电路发送的切换信号,并将与切换信号对应的指令传输至单口随机数据存储器,以对单口随机数据存储器根据指令执行与指令对应的预设操作,其中,指令包括读指令或写指令,预设操作包括读取操作或写入操作。In order to solve the above existing problems, embodiments of the present application provide a FIFO storage control circuit, which includes: a single-port random data memory, a switching control circuit and a switching circuit. The switching control circuit is used to generate a switching signal, and the switching signal includes reading the switching signal or writing the switching signal; the switching circuit is used to receive the switching signal sent by the switching control circuit, and transmit the instructions corresponding to the switching signal to the single-port random data memory, The single-port random access data memory is configured to perform a preset operation corresponding to the instruction according to the instruction, wherein the instruction includes a read instruction or a write instruction, and the preset operation includes a read operation or a write operation.
通过设置单口随机数据存储器,切换控制电路产生切换信号,切换电路根据切换控制电路发送的切换信号,以根据与切换信号对应的指令对单口随机数据存储器执行预设操作。即在切换控制电路输出写入切换信号时,才可对单口随机数据存储器进行写入操作;在切换控制电路输出读取切换信号时,才可对单口随机数据存储器进行读取操作。使用1片单口随机数据存储器,就可以满足FIFO存储器的异步需求,有效地减小了FIFO存储器的面积,降低了成本。By setting the single-port random data memory, the switching control circuit generates a switching signal, and the switching circuit performs preset operations on the single-port random data memory according to the instructions corresponding to the switching signal according to the switching signal sent by the switching control circuit. That is, when the switching control circuit outputs the write switching signal, the single-port random data memory can be written; only when the switching control circuit outputs the read switching signal, the single-port random data memory can be read. Using a single-port random data memory can meet the asynchronous requirements of FIFO memory, effectively reducing the area of FIFO memory and reducing costs.
下面对FIFO存储控制电路进行详细描述,请参阅图1,本申请一实施例提供了一种FIFO存储控制电路100,该FIFO存储控制电路100包括:单口随机数据存储器110、切换控制电路120和切换电路130。其中,单口随机数据存储器110可以用于存储数据;切换控制电路120用于产生切换信号,切换信号包括读取切换信号或写入切换信号;切换电路130分别连接于切换控制电路120和单口随机数据存储器110,用于根据切换信号将与切换信号对应的指令传输至单口随机数据存储器110,以对单口随机数据存储器110执行预设操作,其中,该指令包括读指令或写指令,预设操作包括读取操作或写入操作。The FIFO storage control circuit is described in detail below. Please refer to Figure 1. An embodiment of the present application provides a FIFO storage control circuit 100. The FIFO storage control circuit 100 includes: a single-port random data memory 110, a switching control circuit 120 and Switching circuit 130. Among them, the single-port random data memory 110 can be used to store data; the switching control circuit 120 is used to generate switching signals, which include reading switching signals or writing switching signals; the switching circuit 130 is connected to the switching control circuit 120 and the single-port random data respectively. The memory 110 is used to transmit instructions corresponding to the switching signal to the single-port random access data memory 110 according to the switching signal, so as to perform preset operations on the single-port random access data memory 110, where the instructions include read instructions or write instructions, and the preset operations include Read operation or write operation.
单口随机数据存储器110是指随机数据存储器的存储单元仅包含1组访问接口,其中,单口随机数据存储器110在进行读或写操作时使用的是同一套地址线。The single-port random access data memory 110 means that the storage unit of the random access data memory only includes one set of access interfaces. The single-port random access data memory 110 uses the same set of address lines when performing read or write operations.
本实施例中,读指令包括但不限于读取使能信息和读取地址,写指令包括但不限于写入使能信息和写入地址;读取操作可以是读取单口随机数据存储器110中的数据,写入操作可以是向单口随机数据存储器110写入数据。In this embodiment, the read instruction includes but is not limited to read enable information and read address, and the write instruction includes but is not limited to write enable information and write address; the read operation may be to read the single-port random access data memory 110 The writing operation may be to write data to the single-port random access data memory 110 .
在一些实施例中,FIFO存储控制电路还包括数据写入接口151和数据读取接口152,切换电路130与数据写入接口151和数据读取接口152分别连接,用于根据切换信号控制数据写入接口151和数据读取接口152与单口随机数据存储器110的连接状态。In some embodiments, the FIFO storage control circuit also includes a data writing interface 151 and a data reading interface 152. The switching circuit 130 is connected to the data writing interface 151 and the data reading interface 152 respectively, and is used to control data writing according to the switching signal. The connection status of the input interface 151 and the data reading interface 152 with the single-port random access data memory 110.
作为一种实施方式,切换电路130用于接收切换控制电路120发送的读取切换信号,并根据读取切换信号将数据读取接口152连接至单口随机数据存储器110,以根据数据读取接口152输出的读指令对单口随机数据存储器110执行读 取操作,即读取单口随机数据存储器110中存储的数据。在数据读取接口152连接至单口随机数据存储器110时,数据写入接口151与单口随机数据存储器110处于未导通的状态。在切换控制电路发送的切换信号为读取切换信号时,对单口随机数据存储器110执行的是读取操作,这个过程中,对单口随机数据存储器110的写入操作是禁止的。As an implementation manner, the switching circuit 130 is configured to receive the read switching signal sent by the switching control circuit 120 and connect the data reading interface 152 to the single-port random access data memory 110 according to the reading switching signal. The output read command executes reading on the single-port random access data memory 110 The fetch operation is to read the data stored in the single-port random access data memory 110. When the data reading interface 152 is connected to the single-port random access data memory 110, the data writing interface 151 and the single-port random access data memory 110 are in a non-conducting state. When the switching signal sent by the switching control circuit is a read switching signal, a read operation is performed on the single-port random access data memory 110. During this process, the write operation on the single-port random access data memory 110 is prohibited.
作为另一种实施方式,切换电路130还用于接收切换控制电路120发送的写入切换信号,并根据写入切换信号将数据写入接口151连接至单口随机数据存储器110,以根据数据写入接口151输出的写指令对单口随机数据存储器110执行写入操作,即向单口随机数据存储器110写入待存储的数据。在数据写入接口151连接至单口随机数据存储器110时,数据读取接口152与单口随机数据存储器110处于未导通的状态。在切换控制电路发送的切换信号为写入取切换信号时,对单口随机数据存储器110执行的是写入操作,这个过程中,对单口随机数据存储器110的读取操作是禁止的。As another implementation, the switching circuit 130 is also used to receive the writing switching signal sent by the switching control circuit 120, and connect the data writing interface 151 to the single-port random data memory 110 according to the writing switching signal, so as to control the data writing according to the data writing. The write command output by the interface 151 performs a write operation on the single-port random access data memory 110 , that is, writes the data to be stored into the single-port random access data memory 110 . When the data writing interface 151 is connected to the single-port random access data memory 110, the data reading interface 152 and the single-port random access data memory 110 are in a non-conducting state. When the switching signal sent by the switching control circuit is a write-to-write switching signal, a write operation is performed on the single-port random access data memory 110. During this process, the read operation on the single-port random access data memory 110 is prohibited.
在一些实施方式中,切换电路130可以包括多路选择器,或者与接口数量对应的开关等,在此不做限制,以切换电路130为多路选择器为例进行说明,当切换信号为读取切换信号时,多路选择器将数据读取接口152连接至单口随机数据存储器110;当切换信号为写入切换信号时,多路选择器将数据写入接口152连接至单口随机数据存储器110。In some embodiments, the switching circuit 130 may include a multiplexer, or switches corresponding to the number of interfaces, etc., which are not limited here. For illustration, the switching circuit 130 is a multiplexer as an example. When the switching signal is a read When the switching signal is obtained, the multiplexer connects the data reading interface 152 to the single-port random data memory 110; when the switching signal is a write switching signal, the multiplexer connects the data writing interface 152 to the single-port random data memory 110. .
在一些实施方式中,切换控制电路120可以包括控制器,该控制器可以包括第一输出端和第二输出端,第一输出端和第二输出端分别与切换电路130连接;其中,第一输出端用于向切换电路130输出读取切换信号,第二输出端用于向切换电路130输出写入切换信号。In some embodiments, the switching control circuit 120 may include a controller, which may include a first output terminal and a second output terminal, and the first output terminal and the second output terminal are respectively connected to the switching circuit 130; wherein, the first output terminal The output terminal is used to output the read switching signal to the switching circuit 130 , and the second output terminal is used to output the writing switching signal to the switching circuit 130 .
应当理解,切换控制电路120还可以包括更多或更少的组件,此处不作具体限定。It should be understood that the switching control circuit 120 may also include more or less components, which are not specifically limited here.
作为一种实施方式,当切换控制电路120输出的切换信号为高电平时,可以表征为读取切换信号;当切换控制电路120输出的切换信号为低电平时,可以表征为写入切换信号。As an implementation manner, when the switching signal output by the switching control circuit 120 is high level, it can be characterized as a read switching signal; when the switching signal output by the switching control circuit 120 is low level, it can be characterized as a writing switching signal.
作为另一种实施方式,当切换控制电路120输出的切换信号为低电平时,可以表征为读取切换信号;当切换控制电路120输出的切换信号为高电平时,可以表征为写入切换信号。As another implementation manner, when the switching signal output by the switching control circuit 120 is low level, it can be characterized as a read switching signal; when the switching signal output by the switching control circuit 120 is high level, it can be characterized as a writing switching signal. .
本申请实施例通过切换电路130接收切换控制电路120发送的读取切换信号,并根据读取切换信号将数据读取接口152切换至与单口随机数据存储器110连接,以根据数据读取接口152输出的读指令对单口随机数据存储器110执行读取操作;或者使切换电路130接收切换控制电路120发送的写入切换信号,并根据写入切换信号将数据写入接口151切换至与单口随机数据存储器110连接,以根据数据写入接口151输出的写指令对单口随机数据存储器110执行写入操作。 通过切换控制电路120产生切换信号,再通过切换电路130响应于切换信号最终对单口随机数据存储器110进行数据读取或者写入,使得FIFO存储控制电路100通过一片单口随机数据存储器就达到了异步的效果,有效地减小了FIFO存储器的面积,降低了成本。The embodiment of the present application receives the read switching signal sent by the switching control circuit 120 through the switching circuit 130, and switches the data reading interface 152 to be connected to the single-port random data memory 110 according to the reading switching signal, so as to output according to the data reading interface 152 The read instruction performs a read operation on the single-port random data memory 110; or the switching circuit 130 receives the write switching signal sent by the switching control circuit 120, and switches the data writing interface 151 to the single-port random data memory according to the write switching signal. 110 is connected to perform a write operation on the single-port random access data memory 110 according to the write instruction output by the data write interface 151. The switching control circuit 120 generates a switching signal, and then the switching circuit 130 responds to the switching signal to finally read or write data to the single-port random data memory 110, so that the FIFO storage control circuit 100 achieves asynchronous operation through a single-port random data memory. The effect is to effectively reduce the area of FIFO memory and reduce the cost.
在一些实施例中,FIFO存储控制电路100还用于根据接收的通信指令确定预设操作,以使切换控制电路120根据预设操作产生切换信号。In some embodiments, the FIFO storage control circuit 100 is also used to determine a preset operation according to the received communication instruction, so that the switching control circuit 120 generates a switching signal according to the preset operation.
在本实施例中,可以通过通信接口对FIFO存储控制电路100执行相应操作时发出的通信指令来进行预判,例如,通信接口要对FIFO存储控制电路100进行读取操作,则会发出读指令,通过读指令则可以预判出预设操作为读取操作,若通信接口要对FIFO存储控制电路100进行写入操作,则会发出写指令,通过写指令则可以预判出预设操作为写入操作,如此,在预判出预设操作后,切换控制电路120可以根据预设操作确定切换信号。若预设操作为读取操作,则对应的切换信号为读取切换信号;若预设操作为写入操作,则对应的切换信号为写入切换信号。In this embodiment, prediction can be made through the communication instructions issued when the communication interface performs corresponding operations on the FIFO storage control circuit 100. For example, if the communication interface wants to perform a read operation on the FIFO storage control circuit 100, a read instruction will be issued. , through the read command, it can be predicted that the preset operation is a read operation. If the communication interface wants to perform a write operation on the FIFO storage control circuit 100, a write command will be issued. Through the write command, it can be predicted that the preset operation is writing operation, in this way, after predicting the preset operation, the switching control circuit 120 can determine the switching signal according to the preset operation. If the preset operation is a read operation, the corresponding switching signal is a read switching signal; if the preset operation is a write operation, the corresponding switching signal is a write switching signal.
其中,通信接口可以是SPI(Serial Peripheral Interface,串行外设接口),可以是I2C(Inter-Integrated Circuit,两线式串行总线),还可以是UART(Universal Asynchronous Receiver/Transmitter,通用异步收发传输器),在此不做限制。Among them, the communication interface can be SPI (Serial Peripheral Interface, serial peripheral interface), I2C (Inter-Integrated Circuit, two-wire serial bus), or UART (Universal Asynchronous Receiver/Transmitter, Universal Asynchronous Receiver/Receiver) transmitter), there is no restriction here.
在一些实施例中,在切换电路130将与切换信号对应的指令传输至单口随机数据存储器110之前,FIFO存储控制电路100还用于将切换信号同步至相应的时钟域;其中,该时钟域包括读取操作时钟域或写入操作时钟域。在本实施例中,该相应的时钟域是指与当前的切换信号相反的时钟域。例如,切换信号为读取切换信号,则与该切换信号相反的时钟域为写入操作时钟域;切换信号为写入切换信号,则与该切换信号相反的时钟域为读取操作时钟域。在FIFO存储控制电路100预判出要执行的预设操作后,需要将预设操作对应的切换信号同步到与切换信号相反的时钟域,因为FIFO存储控制电路100当前进行的操作一般为与预设操作相反的操作,接入的时钟为与预设操作对应的指令相反的时钟,执行的是与预设操作对应的指令相反的指令,因单口随机数据存储器110只有一组接口,为避免通过这一组接口传输至单口随机数据存储器110的指令的突然切换,而给数据读取或数据写入造成影响,在改变传输至单口随机数据存储器110中的指令时,可以先将切换信号同步至FIFO存储控制电路100当前进行的操作对应的时钟域,即与切换信号相反的时钟域,给指令的切换预留出反应的时间。In some embodiments, before the switching circuit 130 transmits the instruction corresponding to the switching signal to the single-port random access data memory 110, the FIFO storage control circuit 100 is also used to synchronize the switching signal to the corresponding clock domain; wherein, the clock domain includes Read operation clock domain or write operation clock domain. In this embodiment, the corresponding clock domain refers to the clock domain opposite to the current switching signal. For example, if the switching signal is a read switching signal, the clock domain opposite to the switching signal is the writing operation clock domain; if the switching signal is a writing switching signal, the clock domain opposite to the switching signal is the reading operation clock domain. After the FIFO storage control circuit 100 predicts the preset operation to be performed, the switching signal corresponding to the preset operation needs to be synchronized to the clock domain opposite to the switching signal, because the current operation of the FIFO storage control circuit 100 is generally the same as the preset operation. Assuming the opposite operation, the clock connected is the clock opposite to the instruction corresponding to the preset operation, and the instruction corresponding to the preset operation is executed. Since the single-port random access data memory 110 has only one set of interfaces, in order to avoid passing through The sudden switching of the instructions transmitted to the single-port random data memory 110 by this set of interfaces will affect data reading or data writing. When changing the instructions transmitted to the single-port random data memory 110, the switching signal can be synchronized to The FIFO stores the clock domain corresponding to the current operation of the control circuit 100, that is, the clock domain opposite to the switching signal, and reserves reaction time for the switching of instructions.
作为一种实施方式,FIFO存储控制电路100用于将读取切换信号同步至写入操作时钟域。当切换信号为读取切换信号时,与读取切换信号对应的指令为读指令,预设操作为读取操作,则FIFO存储控制电路100当前进行的操作一般为写入操作,为了避免突然将接入FIFO存储控制电路100的时钟、指令等进行切换,可以将切换信号先同步至写入操作时钟域,使写入操作时钟域停止写操作, 然后切换电路130再将读指令传输至单口随机数据存储器110,如此可以避免对单口随机数据存储器110执行指令的突然切换而给数据的读取或写入造成的影响。As an implementation manner, the FIFO storage control circuit 100 is used to synchronize the read switching signal to the write operation clock domain. When the switching signal is a read switching signal, the instruction corresponding to the read switching signal is a read instruction, and the preset operation is a read operation, then the current operation of the FIFO storage control circuit 100 is generally a write operation. In order to avoid suddenly To switch the clock, instructions, etc. connected to the FIFO storage control circuit 100, the switching signal can be synchronized to the write operation clock domain first, so that the write operation clock domain stops the write operation. The switching circuit 130 then transmits the read command to the single-port random access data memory 110. This can avoid the impact of sudden switching of instructions on the single-port random access data memory 110 on the reading or writing of data.
作为另一种实施方式,FIFO存储控制电路100还用于将写入切换信号同步至读取操作时钟域。当切换信号为写入切换信号时,与写入切换信号对应的指令为写指令,预设操作为写入操作,则FIFO存储控制电路100当前进行的操作一般为读取操作,为了避免突然将接入FIFO存储控制电路100的时钟、指令等进行切换,可以将切换信号先同步至读取操作时钟域,使读取操作时钟域停止读操作,然后切换电路130再将写指令传输至单口随机数据存储器110,如此可以避免对单口随机数据存储器110执行指令的突然切换而给数据的读取或写入造成的影响。As another implementation manner, the FIFO storage control circuit 100 is also used to synchronize the write switching signal to the read operation clock domain. When the switching signal is a write switching signal, the instruction corresponding to the write switching signal is a write instruction, and the preset operation is a write operation, then the current operation of the FIFO storage control circuit 100 is generally a read operation. In order to avoid suddenly To switch the clock, instructions, etc. connected to the FIFO storage control circuit 100, the switching signal can be synchronized to the read operation clock domain first, so that the read operation clock domain stops the read operation, and then the switching circuit 130 transmits the write command to the single-port randomizer. The data memory 110 can avoid the sudden switching of instructions executed on the single-port random access data memory 110, which may affect the reading or writing of data.
在一些实施例中,FIFO存储控制电路100还包括数据控制电路160和至少一个数据缓存器140,该数据控制电路160分别连接于切换控制电路120和数据缓存器140,连接于单口随机数据存储器110,该数据控制电路160用于接收在请求信号,且在请求信号与切换信号不一致时,根据请求信号对数据缓存器140执行与请求信号对应的操作;其中,请求信号包括数据读取请求或数据写入请求。在本实施例中,数据控制电路160还连接于切换电路130,数据缓存器140还连接于单口随机数据存储器110。在根据与切换信号对应的指令对单口随机数据存储器110执行预设操作的期间,可能会接收到与切换信号不一致的请求信号,但是此时正在对单口随机数据存储器110执行预设操作,因该预设操作对应的切换信号与请求信号不一致,所以无法根据请求信号对单口随机数据存储器110执行对应的操作,为解决这个问题,在FIFO存储控制电路100中设置数据控制电路160和至少一个数据缓存器140,以接收请求信号,并对数据缓存器140来执行与请求信号对应的操作。In some embodiments, the FIFO storage control circuit 100 also includes a data control circuit 160 and at least one data buffer 140. The data control circuit 160 is connected to the switching control circuit 120 and the data buffer 140 respectively, and is connected to the single-port random data memory 110. , the data control circuit 160 is used to receive a request signal, and when the request signal is inconsistent with the switching signal, perform an operation corresponding to the request signal on the data buffer 140 according to the request signal; wherein the request signal includes a data read request or data Write request. In this embodiment, the data control circuit 160 is also connected to the switching circuit 130, and the data buffer 140 is also connected to the single-port random access data memory 110. During the period of performing the preset operation on the single-port random access data memory 110 according to the instruction corresponding to the switching signal, a request signal inconsistent with the switching signal may be received. However, the preset operation is being performed on the single-port random access data memory 110 at this time, so the The switching signal corresponding to the preset operation is inconsistent with the request signal, so the corresponding operation cannot be performed on the single-port random data memory 110 according to the request signal. To solve this problem, a data control circuit 160 and at least one data cache are set in the FIFO storage control circuit 100 The processor 140 is configured to receive the request signal and perform operations corresponding to the request signal on the data buffer 140 .
作为一种实施方式,当请求信号为数据写入请求,切换信号为读取切换信号时,则表示请求信号和切换信号不一致,则数据控制电路160根据数据写入请求将待写入数据写入数据缓存器140中。因切换信号为读取切换信号,所以相应地,对单口随机数据存储器110执行的是读取操作,与为数据写入请求的请求信号不一致,对单口随机数据存储器110无法执行与数据写入请求对应的操作,则可以对数据缓存器140来执行与数据写入请求对应的操作,即将待写入的数据先写入数据缓存器140中。As an implementation manner, when the request signal is a data write request and the switching signal is a read switching signal, it means that the request signal and the switching signal are inconsistent, and the data control circuit 160 writes the data to be written according to the data writing request. in the data buffer 140. Since the switching signal is a read switching signal, accordingly, a read operation is performed on the single-port random data memory 110, which is inconsistent with the request signal for a data write request. Therefore, the single-port random data memory 110 cannot execute a data write request. If the corresponding operation is performed, the operation corresponding to the data write request can be performed on the data buffer 140 , that is, the data to be written is first written into the data buffer 140 .
作为另一种实施方式,当请求信号为数据读取请求,切换信号为写入切换信号时,则表示请求信号和切换信号不一致,数据控制电路160根据数据读取请求从数据缓存器140中读取数据。因切换信号为写入切换信号,所以相应地,单口随机数据存储器110执行的是写入操作,与为数据读取请求的请求信号不一致,单口随机数据存储器110无法执行与数据读取请求对应的操作,则可以通过数据 缓存器140来执行与数据读取请求对应的操作,即先从数据缓存器140中读取数据。As another implementation manner, when the request signal is a data read request and the switching signal is a write switching signal, it means that the request signal and the switching signal are inconsistent, and the data control circuit 160 reads from the data buffer 140 according to the data read request. Get data. Since the switching signal is a write switching signal, accordingly, the single-port random access data memory 110 performs a write operation, which is inconsistent with the request signal for a data read request, and the single-port random access data memory 110 cannot perform the operation corresponding to the data read request. operation, you can pass the data The buffer 140 is used to perform operations corresponding to the data read request, that is, data is first read from the data buffer 140 .
在本实施例中,数据缓存器140相当于寄存器,在对单口随机数据存储器110执行读取或者写入操作时,会导致另一操作阻塞,则可通过数据缓存器解决这一问题。其中,数据缓存器140可以包括数据写入缓存器141,可以包括数据读取缓存器142,还可以包括数据写入缓存器141和数据读取缓存器142。In this embodiment, the data buffer 140 is equivalent to a register. When performing a read or write operation on the single-port random access data memory 110, another operation will be blocked. This problem can be solved through the data buffer. The data buffer 140 may include a data write buffer 141, may include a data read buffer 142, and may further include a data write buffer 141 and a data read buffer 142.
在切换电路130根据数据读取接口输出的读指令对单口随机数据存储器110执行读取操作时,数据控制电路160根据写入请求将待写入数据写入数据写入缓存器141中。在对单口随机数据存储器110执行读取操作时,因单口随机数据存储器110只有一组接口,在有另外的写入请求时,单口随机数据存储器110执行了,可以通过数据写入缓存器141先根据写入请求将待写入单口随机数据存储器110中的数据缓存至数据写入缓存器141中。待对单口随机数据存储器110执行完读取操作后,再将数据写入缓存器141中的数据搬运至单口随机数据存储器110。When the switching circuit 130 performs a read operation on the single-port random access data memory 110 according to the read command output by the data read interface, the data control circuit 160 writes the data to be written into the data write buffer 141 according to the write request. When performing a read operation on the single-port random access data memory 110, since the single-port random access data memory 110 has only one set of interfaces, when there is another write request and the single-port random access data memory 110 is executed, the data write buffer 141 can be used first. The data to be written in the single-port random access data memory 110 is buffered into the data write buffer 141 according to the write request. After the read operation is completed on the single-port random access data memory 110 , the data in the data write buffer 141 is transferred to the single-port random access data memory 110 .
在切换电路130根据数据写入接口输出的写指令对单口随机数据存储器110执行写入操作时,数据控制电路160根据数据读取请求从数据读取缓存器142中读取数据。在对单口随机数据存储器110执行写入操作时,因单口随机数据存储器110只有一组接口,在有另外的读取请求时,就无法对单口随机数据存储器110执行该请求了,可以通过数据读取缓存器141先根据读取请求将从数据读取缓存器141中读出数据。为了避免数据读取缓存器141为空,可以在对单口随机数据存储器110执行写入操作前,先从单口随机数据存储器110中搬运部分数据至数据读取缓存器141中。When the switching circuit 130 performs a write operation on the single-port random access data memory 110 according to the write command output by the data write interface, the data control circuit 160 reads data from the data read buffer 142 according to the data read request. When performing a write operation on the single-port random data memory 110, since the single-port random data memory 110 has only one set of interfaces, when there is another read request, the request cannot be executed on the single-port random data memory 110. You can read the data through The fetch buffer 141 will first read data from the data read buffer 141 according to the read request. In order to prevent the data read buffer 141 from being empty, some data can be transferred from the single port random access data memory 110 to the data read buffer 141 before performing a write operation on the single port random access data memory 110 .
在本申请实施例中,可以通过使能信号控制数据控制电路160或数据缓存器140,使能信号类型有读取使能和写入使能。In the embodiment of the present application, the data control circuit 160 or the data buffer 140 can be controlled through an enable signal. The enable signal types include read enable and write enable.
作为一种实施方式,当使能信息为高电平时,可以表征为读取使能,数据读取接口152(或者与数据读取接口152连接的外部设备)可以从数据读取缓存器142中读取存储数据;当使能信息为低电平时,可以表征为写入使能信息,数据写入接口151(或者与数据写入接口151连接的外部设备)可以向数据写入缓存器141中写入待存储数据。As an implementation manner, when the enable information is high level, it can be characterized as read enable, and the data read interface 152 (or an external device connected to the data read interface 152) can read data from the data read buffer 142. Read the stored data; when the enable information is low level, it can be characterized as write enable information, and the data write interface 151 (or an external device connected to the data write interface 151) can write data into the buffer 141 Write the data to be stored.
作为另一种实施方式,当使能信息为低电平时,表征为读取使能信息,数据读取接口152(或者与数据读取接口152连接的外部设备)可以从数据读取缓存器142中读取存储数据;当使能信息为高电平时,表征为写入使能信息,数据写入接口151(或者与数据写入接口151连接的外部设备)向数据写入缓存器141中写入待存储数据。As another implementation manner, when the enable information is low level, indicating that the enable information is read, the data read interface 152 (or an external device connected to the data read interface 152) can read the data buffer 142 from the data read interface 152. Read the stored data; when the enable information is high level, it is characterized as write enable information, and the data write interface 151 (or an external device connected to the data write interface 151) writes to the data write buffer 141 Enter the data to be stored.
在一些实施例中,数据控制电路160还连接于单口随机数据存储器110。其中,在切换电路130根据与切换信号对应的指令对单口随机数据存储器110执行 完预设操作后,数据控制电路160还用于把数据缓存器140中存储的数据写入单口随机数据存储器110,或者,将单口随机数据存储器110中的数据写入到数据缓存器140。In some embodiments, the data control circuit 160 is also connected to the single-port random access data memory 110 . Among them, the switching circuit 130 executes the single-port random data memory 110 according to the instruction corresponding to the switching signal. After completing the preset operation, the data control circuit 160 is also used to write the data stored in the data buffer 140 into the single-port random data memory 110, or to write the data in the single-port random data memory 110 into the data buffer 140.
作为一种实施方式,预设操作为读取操作,数据控制电路160在切换电路130对单口随机数据存储器110执行完读取操作后,将数据缓存器140中的数据写入至单口随机数据存储器110。As an implementation manner, the default operation is a read operation. After the switching circuit 130 completes the read operation on the single-port random data memory 110, the data control circuit 160 writes the data in the data buffer 140 to the single-port random data memory. 110.
作为另一种实施方式,预设操作为写入操作,数据控制电路160在切换电路130对单口随机数据存储器110执行完写入操作后,控制数据缓存器140读取单口随机数据存储器110。As another implementation manner, the preset operation is a write operation, and the data control circuit 160 controls the data buffer 140 to read the single-port random access data memory 110 after the switching circuit 130 completes the write operation on the single-port random access data memory 110 .
在一些实施例中,切换控制电路还用于在对单口随机数据存储器110执行完预设操作后,对当前的切换信号进行切换;以及根据切换后的信号控制单口随机数据存储器110执行与切换后的信号对应的预设操作。在对单口随机数据存储器110执行完与切换信号对应的预设操作后,如上述,在根据请求信号对数据缓存器140执行与请求信号对应的操作后,因请求信号实际对应的对象是单口随机数据存储器110,数据缓存器140是在无法对单口随机数据存储器110执行与请求信号对应的操作时起过渡的作用,所以在对单口随机数据存储器110执行预设操作后,需要根据请求信号来对数据缓存器进行相应的处理,则可以让切换控制信号120对当前的切换信号进行切换,将其切换至与请求信号一致,以根据切换后的信号对单口随机数据存储器110执行与切换后的信息对应的预设操作,这时的预设操作与请求信号是相对应的。例如,请求信号是写入请求,则对应的预设操作为写入操作;请求信号是读取请求,则对应的预设操作为读取操作。In some embodiments, the switching control circuit is also used to switch the current switching signal after performing the preset operation on the single-port random data memory 110; and to control the single-port random data memory 110 to execute and switch according to the switched signal. The signal corresponds to the preset operation. After performing the preset operation corresponding to the switching signal on the single-port random access data memory 110, as mentioned above, after performing the operation corresponding to the request signal on the data buffer 140 according to the request signal, the actual corresponding object of the request signal is the single-port random access signal. The data memory 110 and the data buffer 140 play a transitional role when the operation corresponding to the request signal cannot be performed on the single-port random data memory 110. Therefore, after performing the preset operation on the single-port random data memory 110, it is necessary to perform the operation according to the request signal. The data buffer performs corresponding processing, so that the switching control signal 120 can switch the current switching signal to be consistent with the request signal, so that the single-port random data memory 110 can execute the switching information according to the switched signal. Corresponding preset operation, the preset operation at this time corresponds to the request signal. For example, if the request signal is a write request, the corresponding preset operation is a write operation; if the request signal is a read request, the corresponding preset operation is a read operation.
作为一种实施方式,当前的切换信号为读取切换信号时,切换控制电路120将读取切换信号切换至写入切换信号,以对单口随机数据存储器110执行写入操作,从而将数据缓存器140中的数据写入至单口随机数据存储器110中。为了对单口随机数据存储器110执行与写入请求对应的写入操作,可以在对单口随机数据存储器110执行完读取操作后,通过切换控制电路120将读取切换信号切换至写入切换信号,并将写入切换信号同步至写操作时钟域,以便后续进行写入操作。As an implementation manner, when the current switching signal is a read switching signal, the switching control circuit 120 switches the reading switching signal to a writing switching signal to perform a writing operation on the single-port random access data memory 110, thereby changing the data buffer The data in 140 is written into the single-port random access data memory 110. In order to perform a write operation corresponding to the write request on the single-port random access data memory 110, after performing a read operation on the single-port random access data memory 110, the read switching signal can be switched to the write switching signal through the switching control circuit 120, And synchronize the write switching signal to the write operation clock domain for subsequent write operations.
示例性地,请参阅图3,数据控制电路160包括第一反相器161、第二反相器162和第一逻辑门163,第一逻辑门163的第一输入端连接于切换控制电路120的输出端、第二输入端连接于第一反相器161的输出端、输出端分别连接于第二反相器162的输入端和数据写入缓存器141的输入端;第二反相器162的输出端连接于单口随机数据存储器110的WEN(写使能端)。For example, please refer to FIG. 3 , the data control circuit 160 includes a first inverter 161 , a second inverter 162 and a first logic gate 163 . The first input end of the first logic gate 163 is connected to the switching control circuit 120 The output terminal and the second input terminal are connected to the output terminal of the first inverter 161, and the output terminal is respectively connected to the input terminal of the second inverter 162 and the input terminal of the data write register 141; the second inverter The output terminal of 162 is connected to the WEN (write enable terminal) of the single-port random access data memory 110 .
在对单口随机数据存储器110执行完读取操作后,切换控制电路120将原来的读取切换信号进行切换输出写入切换信号,则此时切换电路130根据写入切换信号对单口随机数据存储器110连接的接口进行切换,将CLK(时钟端口)从读取时钟切换为写入时钟,将ADR(地址端口)从读取指针切换为写入指针, 将CEN(使能端口)从读取使能切换为读缓存使能。After performing the read operation on the single-port random access data memory 110, the switching control circuit 120 switches the original read switching signal to output the write switching signal. At this time, the switching circuit 130 switches the single-port random access data memory 110 according to the write switching signal. The connected interface is switched, the CLK (clock port) is switched from the read clock to the write clock, and the ADR (address port) is switched from the read pointer to the write pointer. Switch CEN (enable port) from read enable to read cache enable.
以写入切换信号为高电平为例,若此时数据写入缓存器141中的数据为非空,即可以从数据写入缓存器141中读出数据,并且当前并没有数据写入数据写入缓存器141中,即写入使能为低电平,则写入使能经过第一反相器161后输出为高电平,并输入至第一逻辑门163的第二输入端,写入切换信息(高电平)输入至第一逻辑门163的第一输入端,经过第一逻辑门163后输出为高电平,即读缓存使能为高电平,产生读数据缓存操作,读取数据写入缓存器141缓存的数据,同时单口随机数据存储器110的CEN端口为低电平,可以对单口随机数据存储器110执行相应的操作;由第一逻辑门163输出的高电平再经过第二反相器162后输出为低电平,使得最后输入单口随机数据存储器110的WEN端口为低电平,可以对单口随机数据存储器110执行写入操作,将从数据写入缓存器141中读出的数据通过DIN(输入数据端口)写入至单口随机数据存储器110的指针所指向的单口随机数据存储器110的地址中。如此,可以在对单口随机数据存储器110执行读取操作时,因无法写入单口随机数据存储器110而缓存在数据写入缓存器141中数据,在对单口随机数据存储器110的读取操作执行结束后,再写入至单口随机数据存储器110。Taking the write switching signal as a high level as an example, if the data in the data write buffer 141 is not empty at this time, the data can be read from the data write buffer 141, and there is currently no data written into the data. In the write register 141, that is, the write enable is low level, the write enable output is high level after passing through the first inverter 161, and is input to the second input terminal of the first logic gate 163, The write switching information (high level) is input to the first input terminal of the first logic gate 163. After passing through the first logic gate 163, the output is high level, that is, the read cache enable is high level, resulting in a read data cache operation. , read data and write the data cached in the buffer 141, and at the same time, the CEN port of the single-port random data memory 110 is low level, and corresponding operations can be performed on the single-port random data memory 110; the high level output by the first logic gate 163 After passing through the second inverter 162, the output is low level, so that the WEN port that is finally input to the single-port random data memory 110 is low level, and a write operation can be performed on the single-port random data memory 110, and the data will be written into the buffer. The data read in 141 is written into the address of the single-port random data memory 110 pointed to by the pointer of the single-port random data memory 110 through the DIN (data input port). In this way, when a read operation is performed on the single-port random data memory 110, the data cannot be written to the single-port random data memory 110 and the data is cached in the data write buffer 141. After the read operation on the single-port random data memory 110 is completed, Then, it is written to the single-port random access data memory 110.
作为另一种实施方式,当前的切换信号为写入切换信号时,切换控制电路120将写入切换信号切换至读取切换信号,以对单口随机数据存储器110执行读取操作,从而控制数据缓存器140读取单口随机数据存储器110中的数据。为了对单口随机数据存储器110执行与读取请求对应的读取操作,可以在对单口随机数据存储器110执行完写入操作后,通过切换控制电路120将写入切换信号切换至读取切换信号,并将读取切换信号同步至读操作时钟域,以便后续进行读取操作。As another implementation manner, when the current switching signal is a writing switching signal, the switching control circuit 120 switches the writing switching signal to a reading switching signal to perform a reading operation on the single-port random access data memory 110 to control the data cache. The processor 140 reads the data in the single-port random access data memory 110. In order to perform a read operation corresponding to the read request on the single-port random access data memory 110, after performing a write operation on the single-port random access data memory 110, the write switching signal can be switched to the read switching signal through the switching control circuit 120, And synchronize the read switching signal to the read operation clock domain for subsequent read operations.
示例性地,请参阅图4,数据控制电路160包括第三反相器164、第四反相器165、第五反相器167和第二逻辑门166,第二逻辑门166的第一输入端连接于第三反相器164的输出端、第二输入端连接于第四反相器165的输出端,输出端连接于数据读取缓存器142的输入端;第四反相器165的输入端连接于切换控制电路120的输出端、第五反相器162的输出端连接于单口随机数据存储器110的WEN(写使能端)。Exemplarily, referring to FIG. 4 , the data control circuit 160 includes a third inverter 164 , a fourth inverter 165 , a fifth inverter 167 and a second logic gate 166 , a first input of the second logic gate 166 The terminal is connected to the output terminal of the third inverter 164, the second input terminal is connected to the output terminal of the fourth inverter 165, and the output terminal is connected to the input terminal of the data read register 142; The input terminal is connected to the output terminal of the switching control circuit 120 , and the output terminal of the fifth inverter 162 is connected to the WEN (write enable terminal) of the single-port random access data memory 110 .
在对单口随机数据存储器110执行完写入操作后,切换控制电路120将原来的写入切换信号进行切换输出读取切换信号,则此时切换电路130根据读取切换信号对单口随机数据存储器110连接的接口进行切换,将CLK(时钟端口)从写入时钟切换为读取时钟,将ADR(地址端口)从写入指针切换为读取指针,将CEN(使能端口)从写入使能切换为写缓存使能。After performing the write operation on the single-port random access data memory 110, the switching control circuit 120 switches the original write switching signal to output the read switching signal. At this time, the switching circuit 130 switches the single-port random access data memory 110 according to the read switching signal. Switch the connected interface, switch the CLK (clock port) from the write clock to the read clock, switch the ADR (address port) from the write pointer to the read pointer, and switch the CEN (enable port) from the write enable Switch to write cache enable.
以读取切换信号为低电平为例,若数据读取缓存器142非满,即还可以向数据读取缓存器142中写入数据,并且当前并没有从数据读取缓存器142中读取数 据,即读取使能为低电平,则读取使能经过第三反相器164后输出为高电平,并输入至第二逻辑门166的第一输入端,读取切换信息(低电平)经过第二反相器165后输出为高电平,并输入至第二逻辑门166的第二输入端,则第二逻辑门166输出为高电平,即写缓存使能为高电平,产生写数据缓存操作,可以向数据读取缓存器141中写入数据,同时单口随机数据存储器110的CEN端口为低电平,可以对单口随机数据存储器110执行相应的操作;第五反相器167输入至单口随机数据存储器110的WEN端口为高电平,可以对单口随机数据存储器110执行读取操作,通过DOUT(输出数据端口)从单口随机数据存储器110中读取数据并写入至数据读取缓存器142中。如此,可以将单口随机数据存储器110的数据写入数据读取缓存器142,在对单口随机数据存储器110执行写入操作时,因无法从单口随机数据存储器110读取数据,则可以从缓存有数据的数据读取缓存器142中读取。Taking the read switching signal as a low level as an example, if the data read buffer 142 is not full, data can still be written to the data read buffer 142, and no data is currently read from the data read buffer 142. Access According to the data, that is, the read enable is low level, the read enable output is high level after passing through the third inverter 164, and is input to the first input terminal of the second logic gate 166 to read the switching information ( low level) after passing through the second inverter 165, the output is high level, and is input to the second input terminal of the second logic gate 166, then the output of the second logic gate 166 is high level, that is, the write cache is enabled. High level, a write data cache operation is generated, and data can be written to the data read buffer 141. At the same time, the CEN port of the single-port random data memory 110 is low level, and the corresponding operation can be performed on the single-port random data memory 110; The WEN port of the five-port inverter 167 input to the single-port random data memory 110 is at a high level, and the read operation can be performed on the single-port random data memory 110. The data is read from the single-port random data memory 110 through DOUT (output data port) and Write to the data read buffer 142. In this way, the data of the single-port random access data memory 110 can be written into the data read buffer 142. When performing a write operation on the single-port random access data memory 110, since the data cannot be read from the single-port random access data memory 110, the data can be read from the cache memory 142. The data is read from the data read buffer 142.
为了更好的理解本申请,下面以通信接口为SPI,写入切换信号为高电平,读取切换信号为低电平为例分别对本申请中预判进行读取操作的情况和预判进行写入操作的情况进行说明。In order to better understand this application, the following takes the communication interface as SPI, the write switching signal as high level, and the read switching signal as low level as an example to respectively conduct the pre-judgment of the read operation and the pre-judgment in this application. The write operation is described below.
示例性的,请参见图3,SPI对FIFO存储控制电路100进行读取操作时,可通过通信指令预判出要进行读取操作,则切换控制电路120根据读取操作选择读取切换信号(低电平),并将该读取切换信号同步至写操作时钟域,以禁止写操作,然后切换电路130在接收到读取切换信号时,将数据读取接口152切换至与单口随机数据存储器110连接。单口随机数据存储器110的CLK(时钟端口)切换为读取时钟,ADR(地址端口)切换为读取指针,CEN(使能端口)为读取使能(高电平)。对单口随机数据存储器110执行读取操作,即读取单口随机数据存储器110中存储的数据,这个过程中,对单口随机数据存储器110的写入操作是禁止的。若此过程中,有数据写入请求,数据写入缓存器141对应的写入使能为高电平,可以将待写入单口随机数据存储器110中的数据缓存至数据写入缓存器141中。For example, please refer to Figure 3. When the SPI performs a read operation on the FIFO storage control circuit 100, it can be predicted through the communication command that a read operation is to be performed, and the switching control circuit 120 selects to read the switching signal ( low level), and synchronizes the read switching signal to the write operation clock domain to prohibit the write operation, and then the switching circuit 130 switches the data reading interface 152 to the single-port random data memory when receiving the read switching signal. 110 connections. The CLK (clock port) of the single-port random data memory 110 is switched to the read clock, the ADR (address port) is switched to the read pointer, and the CEN (enable port) is read enable (high level). A read operation is performed on the single-port random access data memory 110, that is, the data stored in the single-port random access data memory 110 is read. During this process, the write operation on the single-port random access data memory 110 is prohibited. If there is a data write request during this process, the corresponding write enable of the data write buffer 141 is high, and the data to be written in the single-port random access data memory 110 can be cached into the data write buffer 141 .
当读取操作结束时,切换控制电路120重新使能写入操作,并将写入切换信号同步至写操作时钟域,切换电路130在接收到切换控制电路120发送的写入切换信号后,将单口随机数据存储器110的CLK(时钟端口)从读取时钟切换为写入时钟,将ADR(地址端口)从读取指针切换为写入指针,将CEN(使能端口)从读取使能切换为读缓存使能。若数据写入缓存器141非空(数据写入缓存器141有数据),且当前无写入数据缓存操作(写入使能为低电平)时,则产生读数据缓存操作,读取数据写入缓存器141缓存的数据。When the read operation ends, the switching control circuit 120 re-enables the writing operation and synchronizes the writing switching signal to the writing operation clock domain. After receiving the writing switching signal sent by the switching control circuit 120, the switching circuit 130 The CLK (clock port) of the single-port random data memory 110 switches from the read clock to the write clock, the ADR (address port) switches from the read pointer to the write pointer, and the CEN (enable port) switches from the read enable Enable read caching. If the data write buffer 141 is not empty (the data write buffer 141 has data), and there is currently no write data cache operation (the write enable is low level), a read data cache operation is generated, and the data is read. Write the data cached in the buffer 141.
单口随机数据存储器110的CEN端口为低电平,表示可以对单口随机数据存储器110进行读取或者写入的操作,写入切换信号为高电平,写入使能为低电平,数据控制电路160与单口随机数据存储器110的WEN端口连接,向WEN 端口输出低电平,则对单口随机数据存储器110可执行写入操作,将从数据写入缓存器141中读出的数据通过DIN(输入数据端口)写入至单口随机数据存储器110的指针所指向的单口随机数据存储器110的地址中。The CEN port of the single-port random data memory 110 is low level, indicating that the single-port random data memory 110 can be read or written. The write switching signal is high level, the write enable is low level, and the data control The circuit 160 is connected to the WEN port of the single-port random access data memory 110, and supplies the WEN port to the WEN port. When the port outputs a low level, the write operation can be performed on the single-port random data memory 110, and the data read from the data write buffer 141 is written to the pointer of the single-port random data memory 110 through the DIN (data input port). The address pointed to by the single-port random access data memory 110.
类似地,请参见图4,SPI对FIFO存储控制电路100进行写入操作时,可通过通信指令预判出要进行写入操作,则切换控制电路120根据写入操作选择写入切换信号(高电平),并将该写入切换信号同步至读操作时钟域,以禁止读操作,然后切换电路130在接收到写入切换信号时,将数据写入接口152切换至与单口随机数据存储器110连接。单口随机数据存储器110的CLK(时钟端口)切换为写入时钟,ADR(地址端口)切换为写入指针,CEN(使能端口)为写入使能。对单口随机数据存储器110执行写入操作,即向单口随机数据存储器110中写入数据,这个过程中,对单口随机数据存储器110的读取操作是禁止的。若此过程中,有数据读取请求,数据读取缓存器142对应的读写使能为高电平,可以从数据读取缓存器142中读出数据。Similarly, please refer to Figure 4. When the SPI performs a write operation on the FIFO storage control circuit 100, it can be predicted through the communication command that a write operation is to be performed, and the switch control circuit 120 selects the write switch signal (high) according to the write operation. level), and synchronizes the write switching signal to the read operation clock domain to prohibit the read operation, and then the switching circuit 130 switches the data writing interface 152 to the single-port random data memory 110 when receiving the writing switching signal. connect. The CLK (clock port) of the single-port random data memory 110 is switched to the write clock, the ADR (address port) is switched to the write pointer, and the CEN (enable port) is the write enable. A write operation is performed on the single-port random access data memory 110, that is, data is written into the single-port random access data memory 110. During this process, the read operation on the single-port random access data memory 110 is prohibited. If there is a data reading request during this process, the corresponding read and write enable of the data reading buffer 142 is high, and the data can be read from the data reading buffer 142 .
当写入操作结束时,切换控制电路120重新使能读取操作,并将读取切换信号同步至读操作时钟域,切换电路130在接收到切换控制电路120发送的读取切换信号后,将单口随机数据存储器110的CLK(时钟端口)从写入时钟切换为读取时钟,将ADR(地址端口)从写入指针切换为读取指针,将CEN(使能端口)从写入使能切换为写缓存使能。若数据读取缓存器141非满,且当前无从数据读取缓存器142中读取数据操作(读取使能为低电平)时,则产生写数据缓存操作,可以向数据读取缓存器141中写入数据。When the write operation ends, the switching control circuit 120 re-enables the read operation and synchronizes the read switching signal to the read operation clock domain. After receiving the read switching signal sent by the switching control circuit 120, the switching circuit 130 The CLK (clock port) of the single-port random data memory 110 switches from the write clock to the read clock, the ADR (address port) switches from the write pointer to the read pointer, and the CEN (enable port) switches from write enable Enable write caching. If the data read buffer 141 is not full and there is currently no data read operation from the data read buffer 142 (the read enable is low level), a write data cache operation occurs, and the data read buffer 142 can be read. Write data in 141.
单口随机数据存储器110的CEN端口为低电平,表示可以对单口随机数据存储器110进行读取或者写入的操作,数据控制电路160与单口随机数据存储器110的WEN端口连接,向WEN端口输出高电平,则单口随机数据存储器110可执行读取操作,通过DOUT(输出数据端口)从单口随机数据存储器110中读取数据并写入至数据读取缓存器142中。The CEN port of the single-port random data memory 110 is at a low level, indicating that the single-port random data memory 110 can be read or written. The data control circuit 160 is connected to the WEN port of the single-port random data memory 110 and outputs a high level to the WEN port. level, the single-port random access data memory 110 can perform a read operation, read data from the single-port random access data memory 110 through DOUT (output data port) and write it into the data read buffer 142.
在读取时钟停止时,表示暂时不做读取操作,切换电路130可以提前切换数据写入接口151与单口随机数据存储器110连接;在写入时钟停止时,表示暂时不做写入操作,切换电路130可以提前切换数据读取接口151与单口随机数据存储器110连接;在读取和写入时钟均停止时,表示暂时不做读取和写入操作,数据读取接口152或者数据写入接口151可以保持指定状态或恢复初始状态。When the read clock stops, it means that the reading operation will not be performed temporarily, and the switching circuit 130 can switch the connection between the data writing interface 151 and the single-port random data memory 110 in advance; when the writing clock stops, it means that the writing operation will not be performed temporarily, and the switching circuit 130 can switch in advance. The circuit 130 can switch the data reading interface 151 to connect to the single-port random data memory 110 in advance; when both the reading and writing clocks are stopped, it means that the reading and writing operations will not be performed temporarily, the data reading interface 152 or the data writing interface 151 can maintain the specified state or restore the initial state.
该指定状态指数据读取接口152或者数据写入接口151保持上次工作结束时与单口随机数据存储器110连接的状态。This designated state means that the data reading interface 152 or the data writing interface 151 remains connected to the single-port random access data memory 110 at the end of the last work.
上述申请实施例通过通信接口对FIFO存储控制电路100不定时读取数据、写入数据,对读取操作或者写入操作进行预判,在切换控制电路120产生切换信号,切换电路130根据切换控制电路120发送的读取切换信号将数据读取接口152切换至与单口随机数据存储器110连接,以根据数据读取接口152输出的读 指令对单口随机数据存储器110执行读取操作,或者切换电路130根据切换控制电路120发送的写入切换信号将数据写入接口151切换至与单口随机数据存储器110连接,以根据数据写入接口151输出的写指令对单口随机数据存储器110执行写入操作,其中读取操作时钟和写入操作时钟都是独立的,在切换控制电路120输出写入切换信号时,才可对单口随机数据存储器110进行写入操作;在切换控制电路120输出读取切换信号时,才可对单口随机数据存储器110进行读取操作。上述FIFO存储控制电路100,使用单片单口随机数据存储器110作存储单元,满足了FIFO存储控制设备异步的需求,有效地减小了FIFO存储器的面积,降低了成本。The above-mentioned application embodiment reads and writes data from time to time to the FIFO storage control circuit 100 through the communication interface, predicts the read operation or write operation, generates a switching signal in the switching control circuit 120, and the switching circuit 130 performs switching control according to the switching control circuit 120. The read switching signal sent by the circuit 120 switches the data read interface 152 to be connected to the single-port random access data memory 110, so as to read according to the read signal output by the data read interface 152. The instruction is to perform a read operation on the single-port random access data memory 110, or the switching circuit 130 switches the data writing interface 151 to be connected to the single-port random access data memory 110 according to the write switching signal sent by the switching control circuit 120, so that the data writing interface 151 The output write command performs a write operation on the single-port random data memory 110, in which the read operation clock and the write operation clock are independent. Only when the switching control circuit 120 outputs a write switching signal can the single-port random data memory 110 be written. A write operation is performed; only when the switching control circuit 120 outputs a read switching signal, the read operation can be performed on the single-port random access data memory 110 . The above-mentioned FIFO storage control circuit 100 uses a single-chip single-port random data memory 110 as the storage unit, which meets the asynchronous requirements of the FIFO storage control device, effectively reduces the area of the FIFO memory, and reduces the cost.
请结合参阅图5,图5为本申请又一实施例提供的一种FIFO存储控制方法的流程示意图。FIFO存储控制方法可以应用与上述FIFO存储控制电路100,方法可以包括以下步骤:Please refer to FIG. 5 , which is a schematic flowchart of a FIFO storage control method provided by yet another embodiment of the present application. The FIFO storage control method can be applied to the above-mentioned FIFO storage control circuit 100, and the method can include the following steps:
步骤S210:根据接收的通信指令产生切换信号,切换信号包括读取切换信号或写入切换信号。Step S210: Generate a switching signal according to the received communication command. The switching signal includes a read switching signal or a writing switching signal.
步骤S220:根据切换信号将与切换信号对应的指令传输至单口随机数据存储器110,以对单口随机数据存储器110执行预设操作,其中,指令包括读指令或写指令,预设操作包括读取操作或写入操作。Step S220: Transmit the instruction corresponding to the switching signal to the single-port random access data memory 110 according to the switching signal to perform a preset operation on the single-port random access data memory 110, where the instruction includes a read instruction or a write instruction, and the preset operation includes a read operation. or write operation.
关于上述步骤S210-S220的具体描述可以参阅前述实施例的具体描述,在本实施例不作一一赘述。For the specific description of the above steps S210-S220, please refer to the specific description of the previous embodiment, and will not be described again in this embodiment.
请结合参阅图6,在步骤S220之前,该方法还包括:Please refer to Figure 6. Before step S220, the method also includes:
步骤S230:根据切换信号控制数据写入接口和数据读取接口与单口随机数据存储器110的连接状态。Step S230: Control the connection status of the data writing interface and the data reading interface to the single-port random access data memory 110 according to the switching signal.
关于上述步骤S230的具体描述可以参阅前述实施例的具体描述,在此处不作一一赘述。For the detailed description of the above step S230, please refer to the detailed description of the foregoing embodiments, and will not be described again here.
请结合参阅图7,该方法可以包括以下步骤:Please refer to Figure 7 in conjunction with this method, which may include the following steps:
步骤210:根据接收的通信指令产生切换信号,切换信号包括读取切换信号或写入切换信号。Step 210: Generate a switching signal according to the received communication command. The switching signal includes a reading switching signal or a writing switching signal.
步骤S240:根据读取切换信号将数据读取接口152连接至单口随机数据存储器110,以根据数据读取接口152输出的读指令对单口随机数据存储器110执行读取操作。Step S240: Connect the data reading interface 152 to the single-port random access data memory 110 according to the read switching signal, so as to perform a read operation on the single-port random access data memory 110 according to the read command output by the data reading interface 152.
关于上述步骤S240的具体描述可以参阅前述实施例的具体描述,在此处不作一一赘述。For the detailed description of the above step S240, please refer to the detailed description of the foregoing embodiments, and will not be described again here.
请结合参阅图8,该方法还可以包括以下步骤:Please refer to Figure 8 in conjunction with this method. This method may also include the following steps:
步骤210:根据接收的通信指令产生切换信号,切换信号包括读取切换信号或写入切换信号。Step 210: Generate a switching signal according to the received communication command. The switching signal includes a reading switching signal or a writing switching signal.
步骤S250:根据写入切换信号将数据写入接口151连接至单口随机数据存 储器110,以根据数据写入接口151输出的写指令对单口随机数据存储器110执行写入操作。Step S250: Connect the data writing interface 151 to the single-port random data storage according to the writing switching signal. The memory 110 is configured to perform a write operation on the single-port random access data memory 110 according to the write command output by the data write interface 151 .
关于上述步骤S250的具体描述可以参阅前述实施例的具体描述,在此处不作一一赘述。For the detailed description of the above step S250, please refer to the detailed description of the foregoing embodiments, and will not be described again here.
请结合参阅图9,在步骤S220之前,该方法还包括:Please refer to Figure 9 in conjunction. Before step S220, the method also includes:
步骤S260:将切换信号同步至相应的时钟域;其中,时钟域包括读取操作时钟域或写入操作时钟域。Step S260: Synchronize the switching signal to the corresponding clock domain; where the clock domain includes a read operation clock domain or a write operation clock domain.
关于上述步骤S260的具体描述可以参阅前述实施例的具体描述,在此处不作一一赘述。For the detailed description of the above step S260, please refer to the detailed description of the foregoing embodiments, and will not be described again here.
图10是本申请提供的一种芯片的结构示意图。如图10所示,该芯片20包括FIFO存储控制电路100。Figure 10 is a schematic structural diagram of a chip provided by this application. As shown in FIG. 10 , the chip 20 includes a FIFO storage control circuit 100 .
图11是本申请提供的一种电子设备的结构示意图。如图10所示,该电子设备30包括FIFO存储控制电路100或芯片20。Figure 11 is a schematic structural diagram of an electronic device provided by this application. As shown in FIG. 10 , the electronic device 30 includes a FIFO storage control circuit 100 or a chip 20 .
其中,该电子设备30电子设备可以是但不限于体重秤、体脂秤、营养秤、红外电子体温计、脉搏血氧仪、人体成分分析仪、移动电源、无线充电器、快充充电器、车载充电器、适配器、显示器、USB(Universal Serial Bus,通用串行总线)扩展坞、触控笔、真无线耳机、汽车中控屛、汽车、智能穿戴设备、移动终端、智能家居设备。智能穿戴设备包括但不限于智能手表、智能手环、颈椎按摩仪。移动终端包括但不限于智能手机、笔记本电脑、平板电脑、POS(point of sales terminal,销售点终端)机。智能家居设备包括但不限于智能插座、智能电饭煲、智能扫地机、智能灯。The electronic device 30 may be, but is not limited to, a weight scale, a body fat scale, a nutritional scale, an infrared electronic thermometer, a pulse oximeter, a body composition analyzer, a mobile power supply, a wireless charger, a fast charger, a vehicle mounted Chargers, adapters, monitors, USB (Universal Serial Bus, Universal Serial Bus) docking stations, stylus pens, true wireless headphones, car central control units, cars, smart wearable devices, mobile terminals, smart home devices. Smart wearable devices include but are not limited to smart watches, smart bracelets, and cervical massagers. Mobile terminals include but are not limited to smartphones, laptops, tablets, and POS (point of sales terminal) machines. Smart home devices include but are not limited to smart sockets, smart rice cookers, smart sweepers, and smart lights.
最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不驱使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。 Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present application, but not to limit it; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art will understand that: it can still Modifications are made to the technical solutions described in the foregoing embodiments, or equivalent substitutions are made to some of the technical features; however, these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions in the embodiments of the present application.

Claims (24)

  1. 一种FIFO存储控制电路,其特征在于,包括:A FIFO storage control circuit, which is characterized by including:
    单口随机数据存储器;Single port random access data memory;
    切换控制电路,用于产生切换信号,所述切换信号包括读取切换信号或写入切换信号;A switching control circuit for generating a switching signal, the switching signal including a read switching signal or a writing switching signal;
    切换电路,用于根据所述切换信号将与所述切换信号对应的指令传输至所述单口随机数据存储器,以对所述单口随机数据存储器执行预设操作,其中,所述指令包括读指令或写指令,所述预设操作包括读取操作或写入操作。A switching circuit configured to transmit an instruction corresponding to the switching signal to the single-port random access data memory according to the switching signal to perform a preset operation on the single-port random access data memory, wherein the instruction includes a read instruction or Write instructions, the preset operations include read operations or write operations.
  2. 根据权利要求1所述的FIFO存储控制电路,其特征在于,所述FIFO存储控制电路还包括数据写入接口和数据读取接口;The FIFO storage control circuit according to claim 1, characterized in that the FIFO storage control circuit further includes a data writing interface and a data reading interface;
    所述切换电路分别与所述数据写入接口和所述数据读取接口连接,用于根据所述切换信号控制所述数据写入接口和所述数据读取接口与所述单口随机数据存储器的连接状态。The switching circuit is respectively connected to the data writing interface and the data reading interface, and is used to control the connection between the data writing interface, the data reading interface and the single-port random data memory according to the switching signal. Connection Status.
  3. 根据权利要求2所述的FIFO存储控制电路,其特征在于,所述切换电路用于根据所述读取切换信号将所述数据读取接口连接至所述单口随机数据存储器,以根据所述数据读取接口输出的读指令对所述单口随机数据存储器执行读取操作。The FIFO storage control circuit according to claim 2, wherein the switching circuit is used to connect the data reading interface to the single-port random data memory according to the reading switching signal, so as to The read command output by the read interface performs a read operation on the single-port random access data memory.
  4. 根据权利要求2所述的FIFO存储控制电路,其特征在于,所述切换电路用于根据所述写入切换信号将所述数据写入接口连接至所述单口随机数据存储器,以根据所述数据写入接口输出的写指令对所述单口随机数据存储器执行写入操作。The FIFO storage control circuit according to claim 2, wherein the switching circuit is used to connect the data writing interface to the single-port random data memory according to the writing switching signal, so as to The write instruction output by the write interface performs a write operation on the single-port random data memory.
  5. 根据权利要求2所述的FIFO存储控制电路,其特征在于,在所述切换电路将与所述切换信号对应的指令传输至所述单口随机数据存储器之前,所述FIFO存储控制电路还用于将所述切换信号同步至相应的时钟域;其中,所述时钟域包括读取操作时钟域或写入操作时钟域。The FIFO storage control circuit according to claim 2, characterized in that, before the switching circuit transmits the instruction corresponding to the switching signal to the single-port random data memory, the FIFO storage control circuit is also used to The switching signal is synchronized to a corresponding clock domain; wherein the clock domain includes a read operation clock domain or a write operation clock domain.
  6. 根据权利要求5所述的FIFO存储控制电路,其特征在于,所述切换信号为读取切换信号,所述FIFO存储控制电路用于将所述读取切换信号同步至所述写入操作时钟域。The FIFO storage control circuit according to claim 5, wherein the switching signal is a read switching signal, and the FIFO storage control circuit is used to synchronize the read switching signal to the write operation clock domain. .
  7. 根据权利要求5所述的FIFO存储控制电路,其特征在于,所述切换信号为写入切换信号,所述FIFO存储控制电路用于将所述写入切换信号同步至所述读取操作时钟域。The FIFO storage control circuit according to claim 5, wherein the switching signal is a write switching signal, and the FIFO storage control circuit is used to synchronize the write switching signal to the read operation clock domain. .
  8. 根据权利要求5所述的FIFO存储控制电路,其特征在于,所述FIFO存储控制电路还包括数据控制电路和至少一个数据缓存器;The FIFO storage control circuit according to claim 5, characterized in that the FIFO storage control circuit further includes a data control circuit and at least one data buffer;
    所述数据控制电路分别连接于所述切换控制电路和所述数据缓存器;The data control circuit is respectively connected to the switching control circuit and the data buffer;
    所述数据控制电路用于接收请求信号,且在所述请求信号与所述切换信号不 一致时,根据所述请求信号对所述数据缓存器执行与所述请求信号对应的操作;其中,所述请求信号包括数据读取请求或数据写入请求。The data control circuit is used to receive a request signal, and when the request signal and the switching signal do not When consistent, perform an operation corresponding to the request signal on the data buffer according to the request signal; wherein the request signal includes a data read request or a data write request.
  9. 根据权利要求8所述的FIFO存储控制电路,其特征在于,所述请求信号为数据写入请求,所述切换信号为读取切换信号时,所述数据控制电路根据所述数据写入请求将待写入数据写入所述数据缓存器中。The FIFO storage control circuit according to claim 8, wherein the request signal is a data write request, and when the switching signal is a read switching signal, the data control circuit changes the data according to the data writing request. The data to be written is written into the data buffer.
  10. 根据权利要求9所述的FIFO存储控制电路,其特征在于,所述数据缓存器包括数据写入缓存器;The FIFO storage control circuit according to claim 9, wherein the data buffer includes a data write buffer;
    在所述切换电路根据所述数据读取接口输出的读指令对所述单口随机数据存储器执行读取操作时,所述数据控制电路根据所述写入请求将所述待写入数据写入所述数据写入缓存器中。When the switching circuit performs a read operation on the single-port random access data memory according to the read instruction output by the data read interface, the data control circuit writes the data to be written into the data memory according to the write request. The above data is written into the buffer.
  11. 根据权利要求8所述的FIFO存储控制电路,其特征在于,所述请求信号为数据读取请求,所述切换信号为写入切换信号时,所述数据控制电路根据所述数据读取请求从所述数据缓存器中读取数据。The FIFO storage control circuit according to claim 8, wherein the request signal is a data read request, and when the switching signal is a write switching signal, the data control circuit switches from Read data from the data buffer.
  12. 根据权利要求9所述的FIFO存储控制电路,其特征在于,所述数据缓存器包括数据读取缓存器;The FIFO storage control circuit according to claim 9, wherein the data buffer includes a data read buffer;
    在所述切换电路根据所述数据写入接口输出的写指令对所述单口随机数据存储器执行写入操作时,所述数据控制电路根据所述数据读取请求从所述数据读取缓存器中读取数据。When the switching circuit performs a write operation on the single-port random data memory according to the write instruction output by the data write interface, the data control circuit reads data from the data read buffer according to the data read request. Read data.
  13. 根据权利要求8所述的FIFO存储控制电路,其特征在于,所述数据控制电路还连接于所述单口随机数据存储器;The FIFO storage control circuit according to claim 8, characterized in that the data control circuit is also connected to the single-port random data memory;
    在所述切换电路对所述单口随机数据存储器执行完所述预设操作后,所述数据控制电路还用于把所述数据缓存器中存储的数据写入到所述单口随机数据存储器,或者,将所述单口随机数据存储器中的数据写入到所述数据缓存器。After the switching circuit performs the preset operation on the single-port random data memory, the data control circuit is also used to write the data stored in the data buffer to the single-port random data memory, or , writing the data in the single-port random access data memory to the data buffer.
  14. 根据权利要求13所述的FIFO存储控制电路,其特征在于,所述预设操作为读取操作;The FIFO storage control circuit according to claim 13, wherein the preset operation is a read operation;
    所述数据控制电路还用于在所述切换电路对所述单口随机数据存储器执行完所述读取操作后,将所述数据缓存器中的数据写入至所述单口随机数据存储器中。The data control circuit is also configured to write the data in the data buffer to the single-port random data memory after the switching circuit completes the read operation on the single-port random data memory.
  15. 根据权利要求13所述的FIFO存储控制电路,其特征在于,所述预设操作为写入操作;The FIFO storage control circuit according to claim 13, wherein the preset operation is a write operation;
    所述数据控制电路还用于在所述切换电路对所述单口随机数据存储器执行完所述写入操作后,控制所述数据缓存器读取所述单口随机数据存储器中的数据。The data control circuit is also used to control the data buffer to read the data in the single-port random data memory after the switching circuit completes the write operation on the single-port random data memory.
  16. 根据权利要求1-15任一项所述的FIFO存储控制电路,其特征在于,所述切换控制电路还用于:The FIFO storage control circuit according to any one of claims 1-15, characterized in that the switching control circuit is also used for:
    在对所述单口随机数据存储器执行完所述预设操作后,对当前的切换信号进 行切换;以及After performing the preset operation on the single-port random data memory, the current switching signal is row switching; and
    根据切换后的信号控制所述单口随机数据存储器执行与切换后的信号对应的所述预设操作。The single-port random access data memory is controlled according to the switched signal to perform the preset operation corresponding to the switched signal.
  17. 根据权利要求1-15任一项所述的FIFO存储控制电路,其特征在于,所述FIFO存储控制电路还用于根据接收的通信指令确定所述预设操作,以使所述切换控制电路根据所述预设操作产生所述切换信号。The FIFO storage control circuit according to any one of claims 1 to 15, characterized in that the FIFO storage control circuit is also used to determine the preset operation according to the received communication instruction, so that the switching control circuit is based on The preset operation generates the switching signal.
  18. 一种FIFO存储控制方法,其特征在于,应用于如权利要求1-17中任意一项所述的FIFO存储控制电路,所述方法包括:A FIFO storage control method, characterized in that it is applied to the FIFO storage control circuit according to any one of claims 1-17, and the method includes:
    根据接收的通信指令产生切换信号;所述切换信号包括读取切换信号或写入切换信号;Generate a switching signal according to the received communication command; the switching signal includes a read switching signal or a writing switching signal;
    根据所述切换信号将与所述切换信号对应的指令传输至所述单口随机数据存储器,以对所述单口随机数据存储器执行预设操作,其中,所述指令包括读指令或写指令,所述预设操作包括读取操作或写入操作。According to the switching signal, instructions corresponding to the switching signal are transmitted to the single-port random access data memory to perform preset operations on the single-port random access data memory, wherein the instructions include read instructions or write instructions, and the Preset operations include read operations or write operations.
  19. 根据权利要求18所述的方法,其特征在于,根据所述切换信号控制所述数据写入接口和所述数据读取接口与所述单口随机数据存储器的连接状态。The method according to claim 18, characterized in that the connection status of the data writing interface and the data reading interface and the single-port random access data memory is controlled according to the switching signal.
  20. 根据权利要求19所述的方法,其特征在于,根据所述读取切换信号将数据读取接口连接至所述单口随机数据存储器,以根据所述数据读取接口输出的读指令对所述单口随机数据存储器执行读取操作。The method according to claim 19, characterized in that a data reading interface is connected to the single-port random data memory according to the read switching signal, so that the single-port random data memory is read according to a read instruction output by the data reading interface. Random data memory performs read operations.
  21. 根据权利要求19所述的方法,其特征在于,根据所述写入切换信号将数据写入接口连接至所述单口随机数据存储器,以根据所述数据写入接口输出的写指令对所述单口随机数据存储器执行写入操作。The method according to claim 19, characterized in that a data writing interface is connected to the single-port random data memory according to the writing switching signal, so that the single-port random data memory is configured according to a write instruction output by the data writing interface. The random access data memory performs write operations.
  22. 根据权利要求18所述的方法,其特征在于,在所述切换电路将与所述切换信号对应的指令传输至所述单口随机数据存储器之前,将所述切换信号同步至相应的时钟域;其中,所述时钟域包括读取操作时钟域或写入操作时钟域。The method according to claim 18, characterized in that, before the switching circuit transmits the instruction corresponding to the switching signal to the single-port random data memory, the switching signal is synchronized to the corresponding clock domain; wherein , the clock domain includes a read operation clock domain or a write operation clock domain.
  23. 一种芯片,其特征在于,所述芯片包括至少如上述权利要求1-17任一项所述的FIFO存储控制电路。A chip, characterized in that the chip includes at least the FIFO storage control circuit as described in any one of the above claims 1-17.
  24. 一种电子设备,其特征在于,所述电子设备包括设备主体以及设置于所述设备主体内的如权利要求23所述的芯片或如权利要求1-17任一项所述的FIFO存储控制电路。 An electronic device, characterized in that the electronic device includes a device body and a chip according to claim 23 or a FIFO storage control circuit according to any one of claims 1 to 17 provided in the device body. .
PCT/CN2023/108417 2022-07-22 2023-07-20 Fifo storage control circuit and method, chip, and electronic device WO2024017337A1 (en)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN202210871438.1 2022-07-22
CN202210871438 2022-07-22
CN202310836566.7 2023-07-07
CN202310836566.7A CN117435158A (en) 2022-07-22 2023-07-07 FIFO storage control circuit, method, chip and electronic equipment

Publications (1)

Publication Number Publication Date
WO2024017337A1 true WO2024017337A1 (en) 2024-01-25

Family

ID=89557204

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/108417 WO2024017337A1 (en) 2022-07-22 2023-07-20 Fifo storage control circuit and method, chip, and electronic device

Country Status (2)

Country Link
CN (1) CN117435158A (en)
WO (1) WO2024017337A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103777894A (en) * 2012-10-25 2014-05-07 深圳市中兴微电子技术有限公司 Method and device for eliminating read-write conflict of memorizer
CN207718357U (en) * 2017-11-27 2018-08-10 航天信息股份有限公司 A kind of FIFO memory
CN111124961A (en) * 2019-12-30 2020-05-08 武汉先同科技有限公司 Method for realizing conversion from single-port RAM to pseudo-dual-port RAM in continuous read-write mode

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103777894A (en) * 2012-10-25 2014-05-07 深圳市中兴微电子技术有限公司 Method and device for eliminating read-write conflict of memorizer
CN207718357U (en) * 2017-11-27 2018-08-10 航天信息股份有限公司 A kind of FIFO memory
CN111124961A (en) * 2019-12-30 2020-05-08 武汉先同科技有限公司 Method for realizing conversion from single-port RAM to pseudo-dual-port RAM in continuous read-write mode

Also Published As

Publication number Publication date
CN117435158A (en) 2024-01-23

Similar Documents

Publication Publication Date Title
KR101442791B1 (en) Apparatus and methods employing variable clock gating hysteresis for a communications port
CN101329663A (en) Apparatus and method for implementing pin time-sharing multiplexing
EP2207101A1 (en) Method and device for parallel interfacing
US8433835B2 (en) Information processing system and control method thereof
CN112380157A (en) IIC bus communication device with FIFO cache and check function
CN101162448A (en) Hardware transmit method of USB high speed data tunnel
CN114490460A (en) FLASH controller for ASIC and control method thereof
JP4350808B2 (en) Data processing system having display controller with burst direct memory access and method for periodically supplying instructions in the system
US9015272B2 (en) Microcomputer
KR100476895B1 (en) Interface device having variable data transfer mode and operating method thereof
EP1478994B1 (en) Transferring data between differently clocked busses
WO2024017337A1 (en) Fifo storage control circuit and method, chip, and electronic device
US6584536B1 (en) Bus transaction accelerator for multi-clock systems
CN110827891B (en) Signal conversion unit, memory and driving method applied to memory
US20030217218A1 (en) Interface for devices having different data bus widths and data transfer method using the interface
CN114996184B (en) Compatible implementation SPI or I 2 Interface module of slave C and data transmission method
CN113590520B (en) Control method for automatically writing data in SPI system and SPI system
EP3819778A1 (en) Bus system and method for operating a bus system
JP5528939B2 (en) Microcomputer
JP2001167047A (en) Bridge device
WO2023240532A1 (en) Low-power island for display interface
CN114880270B (en) SPI device and data transmission method thereof
CN117312210B (en) Method for expanding performance of RISC-V processor
AU670507B2 (en) Method and system for providing data hold time by synchronous random access memory during write operations
JP2001051748A (en) Information processor

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23842399

Country of ref document: EP

Kind code of ref document: A1