Universal serial communication device and microcontroller unit comprising the same

By combining register files and buffers, serial data transmission is achieved, solving the space limitations and reliability problems caused by excessive cables in integrated circuits, and improving scalability and long-distance transmission capabilities.

CN123157649APending Publication Date: 2026-11-24LX SEMICON CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610648512.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2025-05-22
Filing Date
2026-05-12
Publication Date
2026-11-24

AI Technical Summary

Technical Problem

In integrated circuits, the large number of cables in master and slave systems leads to space constraints and increased chip size. At the same time, existing technologies struggle to achieve serial data transmission, improve reliability and scalability, and are limited by network topology.

Method used

It adopts a combined structure of register file, buffer and control circuit, realizes serial data transmission through shift register and register file, reduces the number of cables, uses clock signal initialization to improve reliability, and supports various network topologies.

Benefits of technology

It reduces the number of cables required for data transmission, alleviates space constraints, reduces chip size, improves reliability and scalability, and supports long-distance data transmission and various network topologies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123157649A_ABST
    Figure CN123157649A_ABST
Patent Text Reader

Abstract

A universal serial communication device and a microcontroller unit comprising the same, wherein the universal serial communication device comprises: a register file configured to store a master output slave input (MOSI) transmitted from a master device; a buffer comprising a plurality of flip-flops, the plurality of flip-flops being responsive to a clock signal transmitted from the master device and performing a shift left operation on the MOSI; and a control circuit configured to, in a case where the MOSI comprises write data and a write address, cause the write data to be latched in a plurality of high-order flip-flops of the plurality of flip-flops and cause the write address to be latched in a plurality of low-order flip-flops of the plurality of flip-flops, and in a case where the MOSI comprises a read address, cause the read address to be latched in the plurality of low-order flip-flops of the plurality of flip-flops, and cause read data corresponding to the read address to be read from the register file and latched in the plurality of high-order flip-flops. Thus, the number of lines required for data transceiving in a master-slave framework can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present invention relates to a communication interface, and more particularly, to a universal serial communication device. BACKGROUND

[0002] In an Integrated Circuit (IC), the terms of Master and Slave are mainly used in synchronous circuit design.

[0003] The Master transmits a control signal to the Slave, and the Slave performs a job according to the control signal received from the Master. More specifically, if the Master transmits an instruction for performing a specific job to the Slave, the Slave performs an operation corresponding to the instruction according to the instruction received from the Master. At this time, the Master and the Slave can operate on the basis of a clock signal to achieve accurate synchronization. In the case of such an embodiment, the Slave performs according to the clock signal or the control signal transmitted from the Master, thereby playing a role of processing a designated job or processing data.

[0004] In a system (hereinafter, referred to as a "Master-Slave system") composed of the Master and the Slave as described above, since the Master controls the Slave according to the clock signal, the Master and the Slave operate in unison in the Master-Slave system. Thereby, the Master-Slave system processes transmission of data or a job in unison.

[0005] However, in the general Master-Slave system, a large number of cables for data transceiving are required, and thus an area for wiring cables increases, resulting in a problem of occurrence of space limitation or increase in chip size. SUMMARY

[0006] The present invention is to solve the above-described problems, and a technical problem thereof is to provide a universal serial communication device capable of reducing the number of lines required for data transceiving in a Master-Slave framework and a micro controller unit including the same.

[0007] In addition, another technical problem of the present invention is to provide a universal serial communication device capable of transmitting parallel data in a serial manner and a micro controller unit including the same.

[0008] In addition, still another technical problem of the present invention is to provide a universal serial communication device capable of improving reliability and a micro controller unit including the same.

[0009] In addition, still another technical problem of the present invention is to provide a universal serial communication device capable of being expanded to various network topologies and a micro controller unit including the same.

[0010] Another technical problem of the present invention is to provide a universal serial communication device and a microcontroller unit including the device, which can realize long-distance data transmission.

[0011] A general-purpose serial communication device for addressing the aforementioned technical problems is characterized by comprising: a register file storing a Master Output Slave Input (MOSI) transmitted from a master device; a buffer including a plurality of flip-flops, the plurality of flip-flops responding to a clock signal transmitted from the master device and performing a shift left operation on the master output slave input; and control circuitry that, when the master output slave input includes write data and a write address, latches the write data in a plurality of high-order flip-flops among the plurality of flip-flops and latches the write address in a plurality of low-order flip-flops among the plurality of flip-flops, and, when the master output slave input includes a read address, latches the read address in a plurality of low-order flip-flops among the plurality of flip-flops and reads read data corresponding to the read address from the register file and latches it in the plurality of high-order flip-flops.

[0012] Specifically, if the master device receives a first-level latch enable signal and a first-level write enable signal, the control circuit will latch the write data into a plurality of the high-order flip-flops according to the left shift operation, and latch the write address or the read address into a plurality of the low-order flip-flops; if the master device receives a second-level latch enable signal and a second-level write enable signal, the control circuit will write the write data in the region corresponding to the write address of the register file; if the master device receives a second-level latch enable signal and a first-level write enable signal, the control circuit will read the read data corresponding to the read address from the register file and latch it into a plurality of the high-order flip-flops.

[0013] A microcontroller unit of another aspect of the present invention for addressing the above-mentioned technical problems is characterized by comprising: a master device that generates and outputs a clock signal and a master output slave input; and at least one slave device that receives the master output slave input from the master device in response to the clock signal; the at least one slave device comprising: a register file that stores the master output slave input; a buffer comprising a plurality of flip-flops that perform a left shift operation on the master output slave input in response to the clock signal; and a control circuit that, when the master output slave input includes write data and a write address, latches the write data in a plurality of high-order flip-flops among the plurality of flip-flops and latches the write address in a plurality of low-order flip-flops among the plurality of flip-flops, and, when the master output slave input includes a read address, latches the read address in a plurality of low-order flip-flops among the plurality of flip-flops, and reads read data corresponding to the read address from the register file and latches it in the plurality of high-order flip-flops.

[0014] According to the present invention, as a structure that does not include a finite state machine (FSM) and a counter, the slave device is constructed using only a shift register, a register file, and control circuitry, thereby enabling the serial transmission of parallel data. This has the effect of reducing the number of lines required for data transmission and reception while improving reliability.

[0015] Furthermore, according to the present invention, since the number of lines required for data transmission and reception can be reduced, the area of ​​the wiring cables can be reduced, thereby alleviating space constraints or reducing chip size.

[0016] Furthermore, according to the present invention, since a locking function that prohibits data write operations can be implemented in the register file, it has the effect of improving reliability.

[0017] Furthermore, according to the present invention, since the slave device consists only of a shift register, a register file, and control circuitry, the data size and address size can be easily changed, thereby improving scalability.

[0018] Furthermore, according to the present invention, the shift register can be initialized using only a clock signal continuously supplied from the master device, thereby achieving the effects of easy initialization and improved reliability.

[0019] Furthermore, according to the present invention, since the number of lines required for data transmission and reception can be reduced, the network topology of the master-slave device framework can be implemented in various forms, thereby improving scalability.

[0020] Furthermore, according to the present invention, since the master device is able to determine the clock signal, it has the effect of enabling long-distance data transmission. Attached Figure Description

[0021] Figure 1 This is a block diagram of a microcontroller unit including a slave device according to an embodiment of the present invention.

[0022] Figure 2 It is used to explain its use. Figure 1 The diagram shows a conceptual block diagram of the write operation performed by the control circuit.

[0023] Figure 3 It is used for explanation Figure 1 The flowchart shown is for a write operation from the device.

[0024] Figure 4 It is used for explanation Figure 1 The diagram shows the timing of the write data and write address for the write operation from the slave device.

[0025] Figure 5 It is used to explain its use. Figure 1 The diagram shows a conceptual block diagram of the read operation performed by the control circuit.

[0026] Figure 6 It is included in Figure 2 or Figure 5 The circuit diagram of the data trigger control circuit shown is shown in the figure.

[0027] Figure 7 It is the truth table of the reset signal of the data trigger control circuit during the read operation.

[0028] Figure 8 It is the truth table of the set signal of the data trigger control circuit during the read operation.

[0029] Figure 9 It is used for explanation Figure 1 The flowchart shown is for the read operation from the device.

[0030] Figure 10 It is used for explanation Figure 1 The diagram shows the read address and timing diagram of the read operation from the device.

[0031] Figure 11 It includes Figure 1 An example of a network topology for master and slave devices is shown.

[0032] Figure 12 It includes Figure 1 Another embodiment of the network topology of master and slave devices is shown in the figure.

[0033] Figure 13 It includes Figure 1 This is yet another embodiment of the network topology of master and slave devices shown in the diagram.

[0034] Explanation of reference numerals in the attached figures: 100: Microcontroller Unit; 200: Main Device 300: Slave device 400: Buffer 500: Control circuit; 510: First trigger. 520: First inverter; 530: Second trigger. 540: Second inverter; 550: Data trigger control circuit 600: Register file; 610: Read / write control circuit 620: Address port; 630: Data input port 640: Register array; 650: Data output port. Detailed Implementation

[0035] Throughout this specification, the same reference numerals denote substantially the same constituent elements. In the following description, detailed descriptions of structures and functions known in the technical field of this invention may be omitted unless they are relevant to the core structure of the invention. The terms used in this specification should be understood as follows.

[0036] The advantages and features of the present invention, as well as the methods for achieving these advantages and features, will become apparent from the detailed embodiments described below with reference to the accompanying drawings. However, the present invention is not limited to the embodiments disclosed below and can be implemented in various different ways. These embodiments are only intended to complete the disclosure of the invention and to fully inform those skilled in the art of the scope of the invention, which is defined solely by the scope of the claims.

[0037] The shapes, dimensions, ratios, angles, quantities, etc., disclosed in the accompanying drawings used to illustrate embodiments of the present invention are exemplary, and therefore the present invention is not limited to the matters illustrated. Throughout the specification, the same reference numerals denote the same constituent elements. Furthermore, in the process of describing the present invention, detailed descriptions of well-known technologies related to the present invention are omitted when it is determined that such detailed descriptions would obscure the main points of the present invention.

[0038] When using terms such as "comprising," "having," or "consisting of" as mentioned in this specification, additional parts may be added unless "only" is used. Unless otherwise expressly stated, the use of the singular to express constituent elements includes the use of the plural.

[0039] When interpreting constituent elements, even without additional explicit documentation, it is interpreted as including a range of error.

[0040] When the positional relationship is described, for example, if the positional relationship between two parts is described as "on top of", "above", "below", "beside", etc., then unless "adjacent" or "direct" is used, there may be more than one other part between the two parts.

[0041] The terms "first," "second," etc., can be used to describe various constituent elements, but these constituent elements are not limited by these terms. These terms are only used to distinguish one constituent element from another. Therefore, the "first constituent element" mentioned below can also be a "second constituent element" within the technical concept of this invention.

[0042] The term "at least one" should be understood to include all combinations that can be derived from more than one related item. For example, "at least one of the first item, the second item, and the third item" can mean not only each of the first item, the second item, and the third item, but also all combinations of two or more of the first item, the second item, and the third item.

[0043] Each feature of the various embodiments of the present invention may be combined or integrated with each other in part or in whole, and may be linked and driven in various technical ways. Each embodiment may be implemented independently of each other or together in an associated relationship.

[0044] Hereinafter, embodiments of this specification will be described in detail with reference to the accompanying drawings.

[0045] Figure 1 This is a block diagram of a microcontroller unit of a slave device, including embodiments of the present invention.

[0046] Reference Figure 1 The microcontroller unit 100 (MCU) includes a master device 200 and a slave device 300. The master device 200 can also be called a transmitting device or master, and the slave device 300 can also be called a universal serial communication device, a receiving device, or a slave unit. Although Figure 1 The illustration shows a microcontroller unit 100 comprising only one master device 200 and one slave device 300. However, in another embodiment, the microcontroller unit 100 may include a plurality of slave devices, in which case the plurality of slave devices may each communicate with a master device 200.

[0047] In one embodiment, since the master device 200 of the microcontroller unit 100 of the present invention can determine the frequency of the clock signal CLK, therefore, Figure 1The microcontroller unit 100 shown in the figure is capable of long-distance data transmission.

[0048] The master device 200 can control the write and read operations of the slave device 300.

[0049] The slave device 300 can send and receive data with the master device 200 through a highly reliable universal serial communication interface. In one embodiment, the universal serial communication interface can be an internal serial bus (ISB). An internal serial bus is a serial data transmission method used within a computer system (e.g., an MCU) and is an interface designed for fast and efficient data communication between various hardware components.

[0050] The slave device 300, which communicates with the master device 200 via a general serial communication interface or an internal serial bus, includes a plurality of (e.g., five) pins P1 to P5, a buffer 400, control circuitry 500, and a register file 600. Pins P1 to P5 may also be referred to as ports.

[0051] In particular, to reduce the number of lines used for data transmission and reception while improving the reliability of the microcontroller unit 100, the slave device 300 of the present invention can be configured to exclude a finite state machine (FSM) and a counter. That is, the slave device 300 of the present invention may include a shift register and a register file 600 as embodiments of the buffer 400, thereby reducing the number of lines and improving reliability. In this embodiment, the slave device 300 can easily initialize the buffer 400 using only the clock signal CLK continuously supplied to the master device 200.

[0052] The following is an additional reference. Figures 2 to 7 The operation of the slave device 300 of the present invention will be further described in detail below.

[0053] First, refer to Figures 1 to 4 as well as Figure 6 This describes the write operation of the slave device 300 of the present invention. Figure 2 It is used to explain its use. Figure 1 The diagram shown is a conceptual block diagram of the write operation performed by the control circuit. Figure 3 It is used for explanation Figure 1 The flowchart shown in the figure illustrates the write operation from the device. Figure 4 It is used for explanation Figure 1The timing diagram shown below illustrates the write data and write address for a write operation from the device. Figure 6 It is included in Figure 2 or Figure 5 The circuit diagram of the data trigger control circuit shown is shown in the figure.

[0054] For write operations, slave device 300 receives a latch enable signal LE (low level, or data 0) from master device 200 via pin 1 P1, and a write enable signal WE (low level, or write signal L) from master device 200 via pin 5 P5. It also receives x bits of serial write data WDATA and y bits of serial write address (ADD=WADD) from master device 200 via pin 2 P2. Additionally, slave device 300 receives a clock signal CLK from master device 200 via pin 4 P4.

[0055] The Master Output Slave Input (MOSI), serially input via pin P2, includes x bits of serial write data (WDATA) and y bits of serial write address (ADD=WADD). Here, x and y are natural numbers greater than 2. For ease of explanation, we will assume x and y are both 8. That is, the Master Output Slave Input (MOSI) can include 8 bits of serial write address (ADD=WADD) and 8 bits of serial write data (WDATA).

[0056] In one embodiment, according to the present invention, since the master device 200 can change x and y respectively, the microcontroller unit 100 can have high scalability.

[0057] The shift register used as buffer 400 in an embodiment can be implemented as a left shift register, which receives the main output bit-by-bit from input MOSI and moves to the left in response to the rising edge (or falling edge, depending on the embodiment) of the clock signal CLK (or clock) received via pin 4 P4. Hereinafter, for ease of explanation, buffer 400 and left shift register 400 will be used interchangeably as synonyms.

[0058] For example, if the master device 200 detects an anomaly or error in the master input-slave output MISO transmitted from the slave device 300, the master device 200 can set the master output-slave input MOSI to data 0. Thus, based on the master output-slave input MOSI set to data 0 and the clock signal CLK, the left shift register 400 can be initialized.

[0059] The left shift register 400 includes a first block LBP (or low-order block) and a second block UBP (or high-order block). The first block LBP includes address flip-flops F1 to F8 (or low-order flip-flops), and the second block UBP includes data flip-flops F9 to F16 (or high-order flip-flops).

[0060] For example, during a write operation, the first block LBP performs the function of a serial-to-parallel converter that converts an 8-bit serial write address to an 8-bit parallel write address, and the second block UBP performs the function of a serial-to-parallel converter that converts 8-bit serial write data to 8-bit parallel write data.

[0061] On the other hand, during the read operation, the first block LBP performs the function of a serial-to-parallel converter that converts 8-bit serial read address bits into 8-bit parallel read address bits, and the second block UBP performs the function of a parallel-to-serial converter that converts 8-bit parallel read data into 8-bit serial read data.

[0062] like Figure 2 As shown, each of the address flip-flops F1 to F8 can be a first-type flip-flop, and each of the data flip-flops F9 to F16 can be a second-type flip-flop. In one embodiment, the first-type flip-flops F1 to F8 can be resettable flip-flops, and the second-type flip-flops F9 to F16 can be set-reset (SR) flip-flops. The clock signal CLK is input to the clock terminal CK of each flip-flop F1 to F16. In embodiments different from those described above, each flip-flop F1 to F16, including the reset terminal R containing a bubble, can perform a low-active or active-low reset operation.

[0063] The control circuit 500 includes a first flip-flop 510, a first inverter 520, a second flip-flop 530, a second inverter 540, and a data flip-flop control circuit 550. In the data flip-flop control circuit 550, the value of n can be 0, 1, 2, 3, 4, 5, 6, or 7.

[0064] The first flip-flop 510 can latch the latch enable signal LE and generate a first latch enable signal LEq in response to the rising edge of the clock signal CLK. The first flip-flop 510 can be a D flip-flop. The latch enable signal LE and the first latch enable signal LEq are the same signal.

[0065] The first inverter 520 can generate a second latch enable signal / LEq by inverting the first latch enable signal LEq. When the second latch enable signal / LEq, which is input to the reset terminal R of the address flip-flops F1 to F8, is low, the address flip-flops F1 to F8 are reset or initialized.

[0066] The second flip-flop 530 can latch the write enable signal WE and generate a first write enable signal WEq in response to the rising edge of the clock signal CLK. The second flip-flop 530 can be a D flip-flop. The write enable signal WE and the first write enable signal WEq are the same signal.

[0067] The second inverter 540 can generate the second write enable signal / WEq by inverting the first write enable signal WEq.

[0068] During a write operation, the data trigger control circuit 550 can control the operation of each of the data triggers F9 to F16 in response to the first latch enable signal LEq and the second write enable signal / WEq. Furthermore, during a read operation, the data trigger control circuit 550 can control the operation of each of the data triggers F9 to F16 in response to the first latch enable signal LEq, the second write enable signal / WEq, and x-bit parallel read data RDATA.

[0069] The register file 600 can write 8 bits of write data WDATA in the first storage area of ​​the register array 640 corresponding to the write address WADD based on the first latch enable signal LEq and the first write enable signal WEq, and read 8 bits of read data RDATA from the second storage area of ​​the register array 640 corresponding to the read address RADD and transmit it to the control circuit 500.

[0070] Additionally, register file 600 can provide locking functionality. For example, register file 600 determines whether the write address WADD is the same as the set write address. If the write address WADD is the same as the set write address, it generates an unlock signal or a lock signal. If an unlock signal is generated, register file 600 allows writing data to register array 640; if a lock signal is generated, register file 600 prohibits writing data to register array 640.

[0071] For example, the read / write control circuit 610 can determine whether the write address WADD is the same as the set write address, and can control the access operation (e.g., write operation or read operation) to the register array 640 based on the unlock signal or lock signal corresponding to the determination result.

[0072] The register file 600 includes a read / write control circuit 610, an address port 620, a data input port 630, a register array 640 including a plurality of registers, and a data output port 650.

[0073] When the latch enable signal LE is low and the write enable signal WE is low, the first inverter 520 outputs a second latch enable signal / LEq with a high level H. Therefore, the respective address flip-flops F1~F8 will not be reset and will operate normally, thereby performing a left shift operation.

[0074] Specifically, refer to Figure 6 When the latch enable signal LE is low and the write enable signal WE is low, since the first latch enable signal LEq is low and the second write enable signal WEq is high, the output signals of the respective AND gates 553_1 to 553_8 are low, and the output signals of the respective NAND gates 557_1 to 557_8 are high.

[0075] Therefore, regardless of the levels of their respective data D0′~D7′, the output signals S0~S7 of their respective AND gates 555_1~555_8 are low level L, and the output signals R0~R7 of their respective OR gates 559_1~559_8 are high level. Since high-level reset signals R0~R7 are output to the reset terminals R of their respective data flip-flops F9~F16, and low-level set signals S0~S7 are input to the set terminals S of their respective data flip-flops F9~F16, their respective data flip-flops F9~F16 will operate normally and perform a left shift operation.

[0076] Here, normal operation means that the 8-bit serial write data (WDATA=D7D6D5D4D3D2D1D0) and the 8-bit serial write address (ADD=WADD=A7A6A5A4A3A2A1A0) are shifted left bit by bit in response to the rising edge of the clock signal CLK through the operating flip-flops F1~F16 (Shift Left) (S110).

[0077] Therefore, the most significant bit (MSB) of the 8-bit serial write data (WDATA=D7D6D5D4D3D2D1D0) that is first input into the left shift register 400, compared to the 8-bit serial write address (ADD=WADD=A7A6A5A4A3A2A1A0), i.e., the least significant bit (MSB) of the 8-bit serial write data (WDATA=D7D6D5D4D3D2D1D0), is latched by D7 in the sixteenth flip-flop F16. Bit; LSB), that is, D0 is latched in the ninth flip-flop F9, the MSB of the 8-bit serial write address (ADD=WADD=A7A6A5A4A3A2A1A0), that is, A7 is latched in the eighth flip-flop F8, the LSB of the 8-bit serial write address (ADD=WADD=A7A6A5A4A3A2A1A0), that is, A0 is latched in the first flip-flop F1 (S110).

[0078] According to the above embodiment, the input terminal D of the first flip-flop F1 can be connected to the second pin P2, and the output terminal Q of the sixteenth flip-flop F16 can be connected to the third pin P3. In this case, the third pin P3 is used to transmit the main input from the output MISO to the master device 200. That is, the 16 flip-flops F1~F16 can be connected in series between the second pin P2 and the third pin P3.

[0079] In the above embodiment, buffer 400 is described as a left-shift register that shifts the main output bit by bit from the input MOSI to the left. However, this is just an example. Buffer 400 can also be implemented as a right-shift register that shifts the main output bit by bit from the input MOSI to the right. In this case, the third pin P3 can be the MISO pin, the second pin P2 can be the MOSI pin, the input terminal D of the first flip-flop F1 among the 16 flip-flops F1 to F16 can be connected to the third pin P3, and the output terminal Q of the last flip-flop F16 can be connected to the second pin P2.

[0080] Each of the signals LE, MOSI, CLK, and WE is transmitted from the master device 200 to the slave device 300 via a separate cable. The Master Input Slave Output (MISO) is transmitted from the slave device 300 to the master device 200 via a separate cable. Hereinafter, since the cable is used to transmit signals between the master device 200 and the slave device 300, the cable will be referred to as a signal transmission line.

[0081] The register file 600, for example, the read / write control circuit 610 contained in the register file 600, can determine whether the current operation is a write operation or a read operation based on the latch enable signal LE and the write enable signal WE, and more specifically, based on the first latch enable signal LEq and the first write enable signal WEq.

[0082] For example, when the latch enable signal LE is high (H) and the write enable signal WE is high (H), the read / write control circuit 610 of the register file 600 can determine that the current operation is a write operation. Conversely, when the latch enable signal LE is high (H) and the write enable signal WE is low (L), the read / write control circuit 610 of the register file 600 can determine that the current operation is a read operation.

[0083] When the latch enable signal LE is low and the write enable signal WE is low, the read / write control circuit 610 of register file 600 turns on address port 620, turns off data input port 630, and turns on data output port 650. Address port 620 remains on at all times to receive write address WADD or read address RADD.

[0084] Therefore, the 8-bit serial write address (ADD=WADD=A7A6A5A4A3A2A1A0) latched in address flip-flops F8~F1 can be input to the read / write control circuit 610 through the ON address port 620.

[0085] Based on the rising edge of the clock signal CLK, 8 bits of serial write data (WDATA=D7D6D5D4D3D2D1D0) and 8 bits of serial write address (WADD=A7A6A5A4A3A2A1A0) are sequentially latched into flip-flops F1~F16. The master device 200 then transmits a latch enable signal LE with a high level H to the first pin P1 and a write enable signal WE with a high level H to the fifth pin P5.

[0086] When the latch enable signal LE is high and the write enable signal WE is high (S120), the read / write control circuit 610 turns on the data input port 630.

[0087] Therefore, under the control of the read / write control circuit 610, the 8-bit parallel write data (WDATA=D7D6D5D4D3D2D1D0) is written to the first storage area (S130) of the register array 640 corresponding to the 8-bit write address (A7A6A5A4A3A2A1A0).

[0088] In addition, since the latch enable signal LE is high level H and the write enable signal WE is high level H (S120), the address flip-flops F1~F8 are reset in response to the second latch enable signal / LEq with low level L.

[0089] Additionally, since the latch enable signal LE is high (H) and the write enable signal WE is high (S120), therefore, Figure 6 As shown, the output signals of the respective AND gates 553_1~553_8 in the data flip-flop control circuit 550 are low level L, and the output signals of the respective NAND gates 557_1~557_8 are high level H, which are independent of the logic level of their respective data D0′~D7′. Since the output signals S0~S7 of the respective AND gates 555_1~555_8 are low level L and the output signals R0~R7 of the respective OR gates 559_1~559_8 are high level H, the respective data flip-flops F9~F16 will operate normally and perform left shift operation.

[0090] As address flip-flops F1 to F8 are initialized, the eighth flip-flop F8 outputs a signal with a low level L. Therefore, data flip-flops F9 to F16 respond to the rising edge of the clock signal CLK and are sequentially initialized to a low level L (S140). That is, after the write operation is completed, the buffer 400, including flip-flops F1 to F16, is initialized as the clock signal CLK toggles.

[0091] Figure 5 It is used to explain its use. Figure 1 The diagram shown is a conceptual block diagram of the read operation performed by the control circuit. Figure 7 It is the truth table of the reset signal of the data trigger control circuit during the read operation. Figure 8 It is the truth table of the set signals of the data trigger control circuit during the read operation. Figure 9 It is used for explanation Figure 1 The flowchart shown in the figure illustrates the read operation from the device. Figure 10 It is used for explanation Figure 1 The diagram shows the read address and timing diagram of the read operation from the device.

[0092] The following is for reference Figure 1 as well as Figures 5 to 10 This describes a read operation from device 300. Figure 8 and Figure 9 In this context, n can refer to any number from 0 to 7.

[0093] For the read operation, the slave device 300 receives a latch enable signal LE with a low level L from the master device 200 through the first pin P1, and a write enable signal WE with a low level L from the master device 200 through the fifth pin P5. It also receives a y-bit serial read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) from the master device 200 through the second pin P2, and a clock signal CLK from the master device 200 through the fourth pin P4.

[0094] During a read operation, the Master Output Slave Input (MOSI) input via the second pin P2 includes an 8-bit serial read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′).

[0095] Reference Figure 9 and Figure 10 When the latch enable signal LE is low and the write enable signal WE is low, since the first latch enable signal LEq is low and the second write enable signal / WEq is high, the respective address flip-flops F1~F8 respond to the second latch enable signal / LEq with high level H without being reset and operate normally, thereby performing a left shift operation.

[0096] Therefore, the MSB of the 8-bit serial read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) received through the second pin P2, i.e., A7′, is shifted left and latched into the eighth flip-flop F8 under the action of the clock signal CLK, and the LSB of the 8-bit serial read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′), i.e., A0′, is latched into the first flip-flop F1 (S210) under the action of the clock signal CLK.

[0097] In addition, when the latch enable signal LE is low and the write enable signal WE is low, the read / write control circuit 610 turns on the address port 620, turns off the data input port 630, and turns on the data output port 650.

[0098] Therefore, the 8-bit parallel read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) latched in address flip-flops F8~F1 can be input to the read / write control circuit 610 through the ON address port 620.

[0099] Based on the rising edge of the clock signal CLK, the 8-bit serial read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) is sequentially stored in eight address flip-flops F8~F10. The master device 200 then transmits the latch enable signal LE with a high level H to the first pin P1 and the write enable signal WE with a low level L to the fifth pin P5 (S220).

[0100] When the latch enable signal LE is high (H) and the write enable signal WE is low (S220), the read / write control circuit 610 reads the read data (RDATA=D7′D6′D5′D4′D3′A2′A1′A0′) from the second storage area of ​​the register array 640 corresponding to the 8-bit read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) and transmits it to the data trigger control circuit 550 (S230).

[0101] In addition, since the latch enable signal LE is high level H and the write enable signal WE is low level L (S220), after the address port 620 of the 8-bit parallel read address (ADD=RADD=A7′A6′A5′A4′A3′A2′A1′A0′) is turned on and transmitted to the read / write control circuit 610, the address flip-flops F1~F8 are reset in response to the second latch enable signal / LEq with low level L.

[0102] However, since the latch enable signal LE is high (H) and the second write enable signal / WEq is high (H), therefore, as Figure 6 As shown, the output signals of their respective AND gates 553_1~553_8 are high level, and the output signals of their respective NAND gates 557_1~557_8 are low level.

[0103] like Figure 7 As shown in the truth table, the output signals R0~R7 of each OR gate 559_1~559_8 determine whether they are high or low based on the level of their respective read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′), such as... Figure 8 As shown in the truth table, the output signals S0 to S7 of each AND gate 555_1 to 555_8 determine the high level H or low level L based on the level of their respective read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′).

[0104] For example, in the case where 8-bit parallel data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′) is 8b′01010101, such as Figure 6As shown, the output signals S0, S2, S4, and S6 of the respective AND gates 555_1, 555_3, 555_5, and 555_7 are high level H, the output signals S1, S3, S5, and S7 of the respective AND gates 555_2, 555_4, 555_6, and 555_8 are low level L, the output signals R0, R2, R4, and R6 of the respective OR gates 559_1, 559_3, 559_5, and 559_7 are high level H, and the output signals R1, R3, R5, and R7 of the respective OR gates 559_2, 559_4, 559_6, and 559_8 are low level L.

[0105] Therefore, their respective flip-flops F16, F14, F12, and F10 are reset and latched to 0, while their respective flip-flops F15, F13, F11, and F9 are set and latched to 1.

[0106] On the other hand, if the data trigger control circuit 550 receives 8-bit parallel read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′) from the register file 600 (S230), then the 8-bit parallel read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′) is recovered according to the first latch enable signal LEq with a high level H and the second write enable signal / WEq with a high level H and latched in the data triggers F16~F9.

[0107] Subsequently, the read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′) latched in data flip-flops F16~F9 is transmitted bit-by-bit serially to the master device 200 (S240) in response to the rising edge of the clock signal CLK and via the third pin P3. Thus, the master input-slave output MISO will include 8 bits of serial read data (RDATA=D7′D6′D5′D4′D3′D2′D1′D0′).

[0108] Figure 11 It includes Figure 1 An example of a network topology for master and slave devices is shown. Figure 11 The network topology 100_1 shown is a linear topology consisting of one master device 200 and m slave devices 300_A1~300_Am (m is a natural number greater than 2). The structure and operation method of each slave device 300_A1~300_Am are the same as those in the reference. Figures 1 to 10 The structure and operation method of the device 300 are the same as those described.

[0109] In each of the slave devices 300_A1 to 300_Am, the driver that drives the master input slave outputs MISO_1 to MISO_m can be in a high-impedance state (Hi-Z). The high-impedance state (Hi-Z) can be a state designed so that the driver does not output a signal or does not affect the circuit connected to the driver.

[0110] Figure 12 It includes Figure 1 Another embodiment of the network topology of master and slave devices is shown in the figure. Figure 12 The network topology 100_2 shown is a star topology including one master device 200 and n slave devices 300_B1~300_Bn (n is a natural number of 2 or more). The structure and operation method of each slave device 300_B1~300_Bn are the same as those in the reference. Figures 1 to 10 The structure and operation method of the device 300 are the same as those described.

[0111] According to this embodiment, the master device 200 can transmit enable signals CE_1 to CE_n to each slave device 300_B1 to 300_Bn. For example, the master device 200 can activate only one of the enable signals CE_1 to CE_n at a given time.

[0112] Figure 13 It includes Figure 1 This is yet another embodiment of the network topology of master and slave devices shown in the diagram. Figure 13 The network topology 100_3 shown can be a mixed topology including a plurality of master devices 200_1, 200_2 and a plurality of slave devices 300_C1~300_Cx, 300_D1~300_Dy (x and y are natural numbers greater than 2). The first master device 200_1 can send and receive data with each of the slave devices 300_C1~300_Cx in the first group, and the second master device 200_2 can send and receive data with each of the slave devices 300_D1~300_Dx in the second group. The structure and operation method of each slave device 300_C1~300_Cx, 300_D1~300_Dy are similar to those described in the reference. Figures 1 to 10 The structure and operation method of the device 300 are the same as those described.

[0113] In each slave device 300_C1~300_Cx of the first group, the driver that drives the master input slave output MISO1_1~MISO1_x is in high impedance state (Hi-Z), and in each slave device 300_D1~300_Dx of the second group, the driver that drives the master input slave output MISO2_1~MISO2_y is in high impedance state (Hi-Z).

[0114] Those skilled in the art to which this invention pertains should understand that this invention can be implemented in other specific ways without changing the technical concept or essential features of this invention.

[0115] Therefore, the embodiments described above should be understood as exemplary in all respects and not as limiting. The scope of the invention is not defined by the detailed description provided herein, but by the claims that follow, and the meaning and scope of the claims, as well as all modifications or variations derived from their equivalents, should be interpreted as encompassing the scope of the invention.

Claims

1. A universal serial communication device, wherein, include: Register file, storing master outputs and slave inputs transferred from the master device; The buffer includes a plurality of flip-flops, which, in response to a clock signal transmitted from the master device, perform a left shift operation on the master output from the input; as well as The control circuit, when the main output slave input includes write data and write address, latches the write data in a plurality of high-order flip-flops among a plurality of the flip-flops, and latches the write address in a plurality of low-order flip-flops among a plurality of the flip-flops; when the main output slave input includes read address, latches the read address in a plurality of low-order flip-flops among a plurality of the flip-flops, and reads read data corresponding to the read address from the register file and latches it in a plurality of high-order flip-flops.

2. The universal serial communication device according to claim 1, wherein, If a latch enable signal of the first level and a write enable signal of the first level are received from the master device, the control circuit will latch the write data into a plurality of the high-order flip-flops according to the left shift operation, and latch the write address or the read address into a plurality of the low-order flip-flops. If a second-level latch enable signal and a second-level write enable signal are received from the master device, the control circuit writes the write data in the region corresponding to the write address of the register file; If the master device receives a latch enable signal of the second level and a write enable signal of the first level, the control circuit reads the read data corresponding to the read address from the register file and latches it in a plurality of the high-order flip-flops.

3. The universal serial communication device according to claim 1, wherein, The control circuit responds to the clock signal and, according to the left shift operation, outputs the read data latched in the plurality of the high-order flip-flops to the master device via the master input-slave output.

4. The universal serial communication device according to claim 1, wherein, The register file includes: The address port is connected to the output terminals of the plurality of the low-order flip-flops; The data input port is connected to the output terminals of the plurality of the high-order flip-flops; A data output port is used to output the read data; and The read / write control circuit controls the on / off state of the address port, the data input port, and the data output port based on the latch enable signal and write enable signal received from the master device.

5. The universal serial communication device according to claim 4, wherein, The read / write control circuit determines whether the current operation is a write operation or a read operation based on the latch enable signal and the write enable signal. When the current operation is a write operation, the address port, the data input port, and the data output port are turned on; When the current operation is a read operation, the address port and the data output port are turned on, and the data input port is turned off.

6. The universal serial communication device according to claim 1, wherein, In the case that each of the plurality of the least-order flip-flops is a resettable flip-flop, the control circuit controls the reset of each of the plurality of the least-order flip-flops based on a latch enable signal received from the master device.

7. The universal serial communication device according to claim 1, wherein, In the case where each of the plurality of the high-order flip-flops is a reset-set flip-flop, the control circuit controls the reset and set of each of the plurality of the high-order flip-flops based on the write enable signal and latch enable signal received from the master device and the read data read from the register file, so that the read data is latched in the plurality of the high-order flip-flops.

8. The universal serial communication device according to claim 1, wherein, The control circuit includes: The first trigger, in response to the clock signal, latches the latch enable signal received from the master device; The first inverter inverts the output signal of the first flip-flop. The second trigger, in response to the clock signal, latches the write enable signal received from the master device; The second inverter inverts the output signal of the second flip-flop; and The data trigger control circuit controls the reset and set of each of the plurality of high-order triggers based on the output signal of the first trigger, the output signal of the second inverter, and the read data read from the register file, so that the read data is latched in the plurality of high-order triggers; The control circuit controls whether each low-order trigger is reset based on the output signal of the first inverter.

9. A microcontroller unit, wherein, include: The master device generates and outputs clock signals and master outputs to slave inputs; as well as At least one slave device receives the master output slave input from the master device in response to the clock signal; The at least one slave device includes: Register file, storing the master output and slave input; A buffer, comprising a plurality of flip-flops, wherein the plurality of flip-flops, in response to the clock signal, perform a left shift operation on the main output from the input; and The control circuit, when the main output slave input includes write data and write address, latches the write data in a plurality of high-order flip-flops among a plurality of the flip-flops, and latches the write address in a plurality of low-order flip-flops among a plurality of the flip-flops; when the main output slave input includes read address, latches the read address in a plurality of low-order flip-flops among a plurality of the flip-flops, and reads read data corresponding to the read address from the register file and latches it in a plurality of high-order flip-flops.

10. The microcontroller unit according to claim 9, wherein, The master device also generates and outputs latch enable signals and write enable signals. If a latch enable signal of the first level and a write enable signal of the first level are received from the master device, the control circuit will latch the write data into a plurality of the high-order flip-flops according to the left shift operation, and latch the write address or the read address into a plurality of the low-order flip-flops. If a second-level latch enable signal and a second-level write enable signal are received from the master device, the control circuit writes the write data in the region corresponding to the write address of the register file; If the master device receives a latch enable signal of the second level and a write enable signal of the first level, the control circuit reads the read data corresponding to the read address from the register file and latches it in a plurality of the high-order flip-flops.

11. The microcontroller unit according to claim 9, wherein, The control circuit responds to the clock signal and, according to the left shift operation, outputs the read data latched in the plurality of the high-order flip-flops to the master device via the master input-slave output.

12. The microcontroller unit according to claim 9, wherein, In the case that each of the plurality of the least-order flip-flops is a resettable flip-flop, the control circuit controls the reset of each of the plurality of the least-order flip-flops based on a latch enable signal received from the master device; In the case where each of the plurality of high-order flip-flops is a reset-set flip-flop, the control circuit controls the reset and set of each of the plurality of high-order flip-flops based on the write enable signal received from the master device, the latch enable signal, and the read data read from the register file, so that the read data is latched in the plurality of high-order flip-flops.