Communication module and atmosphere lamp control system
By designing a communication module for MCU, the direct communication between the MCU and the ambient light control chip is achieved, and the problem of increasing software load when the MCU controls the chip through the SPI interface is solved, and the control efficiency is improved.
Patent Information
- Application Number
- CN202510447155.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-10
- Publication Date
- 2025-05-06
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The MCU simulates data extension through the SPI interface, resulting in an increase in software computing load, making it difficult to control the atmosphere light control chip in a timely and effective manner.
Design a communication module, including SIO interface, transceiver control circuit, transceiver FIFO circuit, register and controller, to realize direct communication between the MCU and the atmosphere lamp control chip.
Through direct communication, the software load of the MCU is reduced and the control efficiency of the ambient light control chip is improved.
Smart Images

Figure CN119937440A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of atmosphere lamp control, and in particular to a communication module and an atmosphere lamp control system. Background Art
[0002] At present, the interaction mechanism between MCU and atmosphere light control chip is mainly used. For example, MCU controls the atmosphere light control chip by using SPI analog communication interface, and simulates the communication protocol of the atmosphere light control chip through software, thereby realizing the lighting and control of RGB atmosphere light.
[0003] However, the problem with the related technology is that the MCU uses the SPI interface to simulate the transmission and reception of data, which greatly increases the software computing load, and the software computing speed is slow, making it difficult to control the atmosphere light control chip in a timely and effective manner. Summary of the invention
[0004] The present invention aims to solve one of the technical problems in the related art to at least a certain extent. To this end, one purpose of the present invention is to provide a communication module that can realize direct communication between the MCU and the atmosphere light control chip, thereby facilitating the MCU to control the atmosphere light control chip in a timely and effective manner and effectively reducing the MCU software load.
[0005] Another object of the present invention is to provide an ambient light control system.
[0006] To achieve the above-mentioned purpose, the communication module proposed in the embodiment of the first aspect of the present invention includes: an SIO interface, wherein the SIO interface includes a data signal interface and a clock signal interface; a transceiver control circuit, wherein the transceiver control circuit controls the SIO interface to exchange data with the atmosphere light control chip; a transceiver FIFO circuit, wherein the transceiver FIFO circuit exchanges data with the transceiver control circuit, and the transceiver FIFO circuit is used to cache the data to be sent and the received data; a register, which is used to store the data to be sent and the received data; a controller, wherein the controller exchanges data with the transceiver FIFO circuit and the register respectively, and the controller is used to transfer the data to be sent to the transceiver FIFO circuit for caching and transfer the received data to the register for storage.
[0007] According to the communication module of the embodiment of the present invention, the transceiver control circuit controls the SIO interface to exchange data with the atmosphere light control chip, and the transceiver FIFO circuit exchanges data with the transceiver control circuit to cache the data to be sent and the received data, and the register stores the data to be sent and the received data, and then the controller exchanges data with the transceiver FIFO circuit and the register respectively to transfer the data to be sent to the transceiver FIFO circuit for caching and the received data to the register for storage. Thus, direct communication between the MCU and the atmosphere light control chip is realized through the communication module, which is conducive to the MCU to control the atmosphere light control chip in a timely and effective manner and effectively reduces the MCU software load.
[0008] In addition, the communication module according to the above embodiment of the present invention may also have the following additional technical features: According to one embodiment of the present invention, the frame structure of the data to be sent and the received data includes: a preamble field, an address field, a PSI field, a command field, a valid information field and a CRC field.
[0009] According to one embodiment of the present invention, the transceiver control circuit includes: a sending control circuit, which controls the data signal interface to perform data interaction with the atmosphere light control chip, and the sending control circuit is used to send the data to be sent, wherein the data to be sent includes a data signal in Manchester encoding form; a receiving control circuit, which controls the data signal interface and the clock signal interface to perform data interaction with the atmosphere light control chip respectively, and the receiving control circuit is used to receive the received data, wherein the received data includes a data signal and a clock signal in non-return-to-zero encoding form.
[0010] According to one embodiment of the present invention, the transceiver FIFO circuit includes: a transmitting FIFO circuit, which exchanges data with the transmitting control circuit, and the transmitting FIFO circuit is used to cache the data to be sent; and a receiving FIFO circuit, which exchanges data with the receiving control circuit, and the receiving FIFO circuit is used to cache the received data.
[0011] According to one embodiment of the present invention, the controller is used to trigger an interrupt request when the send FIFO queue of the send FIFO circuit meets the interrupt trigger condition, and trigger a DMA request when the send FIFO queue of the send FIFO circuit meets the DMA trigger condition, wherein the interrupt trigger condition includes that the send FIFO queue is empty, and the DMA trigger condition includes that the total amount of data in the send FIFO queue is less than or equal to a preset send threshold.
[0012] According to one embodiment of the present invention, the controller is used to trigger an interrupt request when the receive FIFO queue of the receive FIFO circuit meets the interrupt trigger condition, and trigger a DMA request when the receive FIFO queue of the receive FIFO circuit meets the DMA trigger condition, wherein the interrupt trigger condition includes at least one of the receive FIFO queue being empty, the receive FIFO queue being full, and the receive FIFO queue overflowing, and the DMA trigger condition includes the total amount of data in the receive FIFO queue being greater than or equal to a preset receive threshold.
[0013] According to an embodiment of the present invention, the register is also used to configure the working parameters of the communication module and read the status parameters of the communication module.
[0014] According to one embodiment of the present invention, the communication module further includes: a CRC check comparison circuit, and the CRC check comparison circuit is used to perform a CRC check on the data to be sent and the received data.
[0015] According to one embodiment of the present invention, the CRC check comparison circuit is also used to transmit the CRC check result of the data to be sent to the controller, and transmit the comparison result between the CRC check result of the received data and the received CRC check result to the register.
[0016] To achieve the above-mentioned purpose, the atmosphere light control system proposed in the second aspect of the embodiment of the present invention includes: a communication module according to the above-mentioned embodiment of the present invention; an atmosphere light control chip, the atmosphere light control chip interacts with the communication module through the SIO interface to realize atmosphere light control; a power management module, which is used to provide working voltage for the communication module and the atmosphere light control chip.
[0017] According to the atmosphere light control system of the embodiment of the present invention, by adopting the aforementioned communication module, direct communication between the MCU and the atmosphere light control chip can be achieved, thereby facilitating the MCU to control the atmosphere light control chip in a timely and effective manner and effectively reducing the MCU software load.
[0018] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 is a block diagram of a communication module according to an embodiment of the present invention; Figure 2 is a schematic diagram of a transmission data frame structure of a communication module according to an embodiment of the present invention; Figure 3is a schematic diagram of the structure of a communication module according to an embodiment of the present invention; Figure 4 is a schematic diagram of waveforms when an MCU sends data according to an embodiment of the present invention; Figure 5 is a waveform diagram of an MCU receiving data according to an embodiment of the present invention; Figure 6 is a block diagram of a communication module according to an embodiment of the present invention; Figure 7 is a block diagram of an ambient light control system according to an embodiment of the present invention.
[0020] Description of reference numerals: Communication module 100, SIO interface 10, transceiver control circuit 20, transmission control circuit 201, reception control circuit 202, transceiver FIFO circuit 30, transmission FIFO circuit 301, reception FIFO circuit 302, register 40, controller 50, CRC check comparison circuit 60, atmosphere light control system 1000, atmosphere light control chip 200, power management module 300. DETAILED DESCRIPTION
[0021] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.
[0022] The communication module and the ambient light control system according to the embodiments of the present invention will be described below with reference to the accompanying drawings.
[0023] Figure 1 is a block diagram of a communication module according to an embodiment of the present invention.
[0024] Specifically, in some embodiments of the present invention, Figure 1 As shown, the communication module 100 includes: an SIO interface 10 , a transceiver control circuit 20 , a transceiver FIFO circuit 30 , a register 40 and a controller 50 .
[0025] Among them, the SIO interface 10 includes a data signal interface SIO_P and a clock signal interface SIO_N; the transceiver control circuit 20 controls the SIO interface 10 to exchange data with the atmosphere light control chip; the transceiver FIFO circuit 30 exchanges data with the transceiver control circuit 20, and the transceiver FIFO circuit 30 is used to cache the data to be sent and the received data; the register 40 is used to store the data to be sent and the received data; the controller 50 exchanges data with the transceiver FIFO circuit 30 and the register 40 respectively, and the controller 50 is used to transfer the data to be sent to the transceiver FIFO circuit 30 for caching and transfer the received data to the register 40 for storage.
[0026] It can be understood that in this embodiment of the present invention, the MCU (Microcontroller Unit) uses the transceiver control circuit 20 in the communication module 100 to control the SIO interface 10 (i.e., the data signal interface SIO_P and the clock signal interface SIO_N) to interact with the atmosphere light control chip for data, and uses the transceiver FIFO circuit 30 to interact with the transceiver control circuit 20 to cache the data to be sent and the received data. At the same time, the register 40 is used to store the data to be sent and the received data. Then, the controller 50 is used to interact with the transceiver FIFO circuit 30 and the register 40 respectively to transmit the data to be sent to the transceiver FIFO circuit 30 for caching and to transmit the received data to the register 40 for storage.
[0027] Therefore, the communication module 100 based on the above-mentioned embodiment of the present invention can realize direct communication between the MCU and the atmosphere light control chip, thereby facilitating the MCU to control the atmosphere light control chip in a timely and effective manner and effectively reducing the MCU software load.
[0028] Optionally, in the above embodiment of the present invention, the atmosphere light control chip is an E3731i chip.
[0029] Furthermore, in some embodiments of the present invention, the frame structure of the data to be sent and the received data includes: a preamble field, an address field, a PSI field, a command field, a valid information field and a CRC field.
[0030] Specifically, in this embodiment of the present invention, according to the frame structure based on the SIO interface defined by the atmosphere light control chip (taking the E3731i chip as an example), such as Figure 2 As shown, the frame structure of the data to be sent and the received data includes: Preamble (i.e. preamble field): 4 bits, fixed to 0b1010.
[0031] Address (i.e. address field): 10 bits, with a value range of 0x000 (broadcast) and 0x001 to 0x3EF (single node address). Upstream messages always contain the address of the sending device in the address field.
[0032] PSI (PSI field): 3 bits, indicating the length of the payload in bytes. Its value must match the expected value of each command. The PSI field values are as follows:
[0033] The total length of a frame of data should be the effective information length + 4 bytes.
[0034] Command (command field): 7 bits, indicating the command sent by the host.
[0035] Payload (valid information field): 0~64 bits, the transmitted data, the length must match the value in the PSI field. The valid information can be information sent by the host MCU or feedback information from the slave E3731i chip.
[0036] CRC (CRC field): 8 bits, checks the entire frame except the CRC field, where the polynomial takes the value 0x2F, the initial value takes the value 0x00, the result XOR value takes the value 0x00, and the CRC function of each ambient light control chip can be configured to enable or disable, but even if disabled, the CRC field still exists.
[0037] It can be understood that in the above embodiment of the present invention, register 40 is used to configure the frame content of the data to be sent, such as address, PSI, command and valid information, and is also used to store the frame content of the received data, such as valid information.
[0038] Further, in some embodiments of the present invention, Figure 3 As shown, the transceiver control circuit 20 includes: a transmission control circuit 201 and a reception control circuit 202 .
[0039] Among them, the sending control circuit 201 controls the data signal interface SIO_P to interact with the atmosphere light control chip, and the sending control circuit 201 is used to send the data to be sent, wherein the data to be sent includes a data signal in Manchester encoding form; the receiving control circuit 202 controls the data signal interface SIO_P and the clock signal interface SIO_N to interact with the atmosphere light control chip respectively, and the receiving control circuit 202 is used to receive the received data, wherein the received data includes a data signal and a clock signal in non-return-to-zero encoding form.
[0040] It can be understood that in this embodiment of the present invention, the MCU uses the sending control circuit 201 to control the data signal interface SIO_P to interact with the atmosphere light control chip so as to transmit the data to be sent (i.e., the data signal in Manchester encoding form) to the atmosphere light control chip, and uses the receiving control circuit 202 to respectively control the data signal interface SIO_P and the clock signal interface SIO_N to interact with the atmosphere light control chip so as to receive the received data (i.e., the data signal and clock signal in non-return-to-zero encoding form) fed back by the atmosphere light control chip.
[0041] Specifically, in the above-mentioned embodiment of the present invention, the MCU and the ambient light control chip (taking the E3731i chip as an example) use the SIO interface 10 to send and receive data to realize different communication modes: 1) MCU sends data: Manchester encoding is used. Within one clock, the level jumps from low to high to indicate logic 1, and jumps from high to low to indicate logic 0. The high level range is VDD~VDD-0.7V, the low level range is 0~0.7V, and the VDD range is 4.5~5.5V. Specifically, when MCU sends data, only the data signal interface SIO_P is used to transmit data. There is no data transmitted on the clock signal interface SIO_N. The baud rate of the transmitted data is fixed at 2.4Mbps. The waveform of the transmitted data is as follows: Figure 4 As shown in the figure, in order to clearly and concisely illustrate the waveform diagram of the transmitted data, Figure 4 In the figure, other groups of transmission data not shown are represented by thick solid lines.
[0042] 2) MCU sends data: non-return-to-zero encoding (NRZ) is used. In one clock, a high level indicates logic 1, and a low level indicates logic 0. The high level range is VDD~VDD-0.7V, the low level range is 0~0.7V, and the VDD range is 4.5~5.5V. Specifically, when the MCU receives data, the data signal interface SIO_P transmits data, and the clock signal interface SIO_N transmits clock. The clock polarity is configurable. The waveform of the transmitted data is shown in the figure below. Figure 5 As shown in the figure, in order to clearly and concisely illustrate the waveform diagram of the transmitted data, Figure 5 In the figure, other groups of transmission data not shown are represented by thick solid lines.
[0043] Further, in some embodiments of the present invention, Figure 3 As shown, the transceiver FIFO circuit 30 includes: a transmit FIFO circuit 301 and a receive FIFO circuit 302 .
[0044] The transmission FIFO circuit 301 exchanges data with the transmission control circuit 201, and the transmission FIFO circuit 301 is used to cache the data to be transmitted; the reception FIFO circuit 302 exchanges data with the reception control circuit 202, and the reception FIFO circuit 302 is used to cache the received data.
[0045] It can be understood that in this embodiment of the present invention, the MCU uses the sending FIFO circuit 301 to interact with the sending control circuit 201 for data, for example, the sending control circuit 201 captures the data to be sent from the sending FIFO circuit 301, and the sending FIFO circuit 301 sends the data to be sent to the sending control circuit 201, and the MCU uses the receiving FIFO circuit 302 to interact with the receiving control circuit 202 for data, for example, the receiving control circuit 202 captures the received data from the receiving FIFO circuit 302, and the receiving FIFO circuit 302 sends the received data to the receiving control circuit 202.
[0046] Further, in some embodiments of the present invention, the controller 50 is used to trigger an interrupt request when the send FIFO queue of the send FIFO circuit 301 meets the interrupt trigger condition, and trigger a DMA request when the send FIFO queue of the send FIFO circuit 301 meets the DMA trigger condition, wherein the interrupt trigger condition includes that the send FIFO queue is empty, and the DMA trigger condition includes that the total amount of data in the send FIFO queue is less than or equal to a preset send threshold.
[0047] It can be understood that in this embodiment of the present invention, when the sending FIFO queue of the sending FIFO circuit 301 meets the interrupt triggering condition (that is, when the sending FIFO queue of the sending FIFO circuit 301 is empty), the MCU uses the controller 50 to trigger the interrupt request. At this time, the control circuit 201 is controlled to transmit the data to be sent to the atmosphere light control chip, and when the sending FIFO queue of the sending FIFO circuit 301 meets the DMA triggering condition (that is, when the total amount of data in the sending FIFO queue is less than or equal to the preset sending threshold), the MCU uses the controller 50 to trigger the DMA request. At this time, the control register 40 transmits the data to be sent to the sending FIFO circuit 301 for caching. In this way, the MCU can send data to the atmosphere light control chip.
[0048] Optionally, in the above embodiment of the present invention, the threshold corresponding to the empty sending FIFO queue and the preset sending threshold can be configured in the register 40 respectively.
[0049] Furthermore, in some embodiments of the present invention, the controller 50 is used to trigger an interrupt request when the receive FIFO queue of the receive FIFO circuit 302 meets the interrupt trigger condition, and trigger a DMA request when the receive FIFO queue of the receive FIFO circuit 302 meets the DMA trigger condition, wherein the interrupt trigger condition includes at least one of the receive FIFO queue being empty, the receive FIFO queue being full, and the receive FIFO queue overflowing, and the DMA trigger condition includes the total amount of data in the receive FIFO queue being greater than or equal to a preset receive threshold.
[0050] It can be understood that in this embodiment of the present invention, when the receiving FIFO queue of the receiving FIFO circuit 302 meets the interrupt triggering condition (i.e., the receiving FIFO queue of the receiving FIFO circuit 302 is empty, or the receiving FIFO queue of the receiving FIFO circuit 302 is fully loaded, or the receiving FIFO queue of the receiving FIFO circuit 302 overflows), the MCU uses the controller 50 to trigger an interrupt request, at which time, the receiving control circuit 202 is controlled to transmit the received data to the receiving FIFO circuit 302, or the receiving control circuit 202 is controlled to suspend the transmission of the received data to the receiving FIFO circuit 302, and when the receiving FIFO queue of the receiving FIFO circuit 302 meets the DMA triggering condition (i.e., the total amount of data in the receiving FIFO queue is greater than or equal to the preset receiving threshold), the MCU uses the controller 50 to trigger a DMA request, at which time, the receiving FIFO circuit 302 is controlled to transmit the cached received data to the register 40 for storage. In this way, the MCU receives data from the atmosphere light control chip.
[0051] Optionally, in the above embodiment of the present invention, the threshold corresponding to the empty receiving FIFO queue, the threshold corresponding to the full receiving FIFO queue, the threshold corresponding to the overflow receiving FIFO queue and the preset receiving threshold can be configured in the register 40 respectively.
[0052] Furthermore, in some embodiments of the present invention, the register 40 is also used to configure the working parameters of the communication module and read the status parameters of the communication module.
[0053] It can be understood that in this embodiment of the present invention, the register 40 can configure the working parameters of the communication module according to user needs, for example, configure the communication module enable, interrupt request enable, interrupt flag clear, DMA request enable, CRC field enable, valid information length of the sent data, the address of the sent data, the PSI of the sent data, the command to send data, the valid information of the sent data, etc. In addition, the register 40 can also read the status parameters of the communication module, such as reading the valid information of the received data, the module interrupt flag, whether the module is busy, whether the send and receive FIFOs are full / empty, whether the CRC check is incorrect, whether an error occurs in the module, etc.
[0054] Further, in some embodiments of the present invention, Figure 6 As shown, the communication module 100 further includes: a CRC check comparison circuit 60, wherein the CRC check comparison circuit 60 is used to perform CRC check on the data to be sent and the received data.
[0055] It can be understood that in this embodiment of the present invention, the MCU can also use the CRC check comparison circuit 60 to perform CRC check on the data to be sent and the received data. Specifically, the MCU can use the controller 50 to control the CRC check comparison circuit 60 to perform CRC check on the data to be sent, and can also use the controller 50 to control the CRC check comparison circuit 60 to perform CRC check on the received data.
[0056] Furthermore, in some embodiments of the present invention, the CRC check comparison circuit 60 is also used to transmit the CRC check result of the data to be sent to the controller 50, and transmit the comparison result between the CRC check result of the received data and the received CRC check result to the register 40.
[0057] It can be understood that in this embodiment of the present invention, after the CRC check comparison circuit 60 completes the CRC check of the data to be sent, the CRC check result of the data to be sent can also be transmitted to the controller 50, so that the controller 50 sends the CRC check result of the data to be sent together with the data to be sent to the sending FIFO circuit 301, and, after the CRC check comparison circuit 60 completes the CRC check of the received data, the comparison result between the CRC check result of the received data and the received CRC check result can also be transmitted to the register 40, so that the register 40 stores the comparison result of the CRC check of the received data together with the received data, and, it is convenient for the controller 50 to judge and control the module to enter the interrupt according to the user configuration and the comparison result of the CRC check.
[0058] Specifically, in the above-mentioned embodiment of the present invention, the CRC field of the data to be sent is calculated by the CRC check comparison circuit 60 itself, and the CRC field of the received data is compared by the CRC check comparison circuit 60 itself, and the comparison result is reflected in the register 40.
[0059] In summary, according to the communication module of the embodiment of the present invention, the transceiver control circuit controls the SIO interface to perform data interaction with the atmosphere light control chip, and the transceiver FIFO circuit performs data interaction with the transceiver control circuit to cache the data to be sent and the received data, and the register stores the data to be sent and the received data, and then, the controller performs data interaction with the transceiver FIFO circuit and the register respectively to transfer the data to be sent to the transceiver FIFO circuit for caching and transfer the received data to the register for storage. Thus, direct communication between the MCU and the atmosphere light control chip is realized through the communication module, which is conducive to the MCU to control the atmosphere light control chip in a timely and effective manner, and effectively reduces the MCU software load.
[0060] Figure 7 is a block diagram of an ambient light control system according to an embodiment of the present invention.
[0061] Specifically, in some embodiments of the present invention, Figure 7 As shown, the ambient light control system 1000 includes: a communication module 100 , an ambient light control chip 200 and a power management module 300 .
[0062] The ambient light control chip 200 exchanges data with the communication module 100 via the SIO interface to achieve ambient light control; the power management module 300 is used to provide operating voltage for the communication module 100 and the ambient light control chip 200.
[0063] It can be understood that in this embodiment of the present invention, the atmosphere light control system 1000 provides working voltage to the communication module 100 and the atmosphere light control chip 200 through the power management module 300, and realizes data interaction between the MCU and the atmosphere light control chip 200 through the communication module 100 to realize atmosphere light control.
[0064] Optionally, in the above-mentioned embodiment of the present invention, the number of the atmosphere light control chips 200 may be one or more, wherein, when the number of the atmosphere light control chips 200 is more than one, the upstream atmosphere light control chip communicates with the downstream atmosphere light control chip via a daisy chain structure.
[0065] It should be understood that the specific implementation of the atmosphere light control system 1000 of the embodiment of the present invention can refer to the specific implementation of the communication module 100 of the aforementioned embodiment of the present invention, and will not be described again here to reduce redundancy.
[0066] In summary, according to the ambient light control system of the embodiment of the present invention, by adopting the aforementioned communication module, direct communication between the MCU and the ambient light control chip can be achieved, thereby facilitating the MCU to control the ambient light control chip in a timely and effective manner and effectively reducing the MCU software load.
[0067] It should be noted that the logic and / or steps represented in the flowchart or described in other ways herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or equipment (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or equipment and execute instructions), or in combination with these instruction execution systems, devices or equipment. For the purpose of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or equipment, or in combination with these instruction execution systems, devices or equipment. More specific examples (non-exhaustive list) of computer-readable media include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and editable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.
[0068] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0069] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0070] In the description of the present invention, it is to be understood that the terms “center”, “longitudinal”, “lateral”, “length”, “width”, “thickness”, “up”, “down”, “front”, “back”, “left”, “right”, “vertical”, “horizontal”, “top”, “bottom”, “inside”, “outside”, “clockwise”, “counterclockwise”, “axial”, “radial”, “circumferential”, etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.
[0071] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0072] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0073] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0074] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.
Claims
1. A communication module, characterized in that: The communication module comprises: SIO interface, wherein the SIO interface includes a data signal interface and a clock signal interface; A transceiver control circuit, wherein the transceiver control circuit controls the SIO interface to perform data exchange with the atmosphere light control chip; A transceiver FIFO circuit, wherein the transceiver FIFO circuit performs data exchange with the transceiver control circuit, and the transceiver FIFO circuit is used to buffer data to be sent and received data; A register, used for storing the data to be sent and the received data; A controller is provided, wherein the controller exchanges data with the transceiver FIFO circuit and the register respectively, and the controller is used to transfer the data to be sent to the transceiver FIFO circuit for buffering and to transfer the received data to the register for storage.
2. The communication module according to claim 1, characterized in that: The frame structure of the data to be sent and the received data includes: a preamble field, an address field, a PSI field, a command field, a valid information field and a CRC field.
3. The communication module according to claim 2, characterized in that: The transceiver control circuit comprises: A sending control circuit, wherein the sending control circuit controls the data signal interface to perform data exchange with the atmosphere light control chip, and the sending control circuit is used to send the data to be sent, wherein the data to be sent includes a data signal in a Manchester encoding form; A receiving control circuit, wherein the receiving control circuit controls the data signal interface and the clock signal interface to perform data interaction with the atmosphere light control chip respectively, and the receiving control circuit is used to receive the received data, wherein the received data includes a data signal and a clock signal in a non-return-to-zero encoding form.
4. The communication module according to claim 3, characterized in that: The transceiver FIFO circuit comprises: A sending FIFO circuit, wherein the sending FIFO circuit performs data exchange with the sending control circuit, and the sending FIFO circuit is used to buffer the data to be sent; A receiving FIFO circuit, wherein the receiving FIFO circuit performs data exchange with the receiving control circuit, and the receiving FIFO circuit is used to buffer the received data.
5. The communication module according to claim 4, characterized in that: The controller is used to trigger an interrupt request when a send FIFO queue of the send FIFO circuit meets an interrupt trigger condition, and to trigger a DMA request when a send FIFO queue of the send FIFO circuit meets a DMA trigger condition, wherein the interrupt trigger condition includes that the send FIFO queue is empty, and the DMA trigger condition includes that the total amount of data in the send FIFO queue is less than or equal to a preset send threshold.
6. The communication module according to claim 4, characterized in that: The controller is used to trigger an interrupt request when a receive FIFO queue of the receive FIFO circuit meets an interrupt trigger condition, and to trigger a DMA request when the receive FIFO queue of the receive FIFO circuit meets a DMA trigger condition, wherein the interrupt trigger condition includes at least one of the receive FIFO queue being empty, the receive FIFO queue being full, and the receive FIFO queue overflowing, and the DMA trigger condition includes the total amount of data in the receive FIFO queue being greater than or equal to a preset receive threshold.
7. The communication module according to claim 4, characterized in that: The register is also used to configure the working parameters of the communication module and read the status parameters of the communication module.
8. The communication module according to claim 1, characterized in that: The communication module also includes: A CRC check comparison circuit is used to perform CRC check on the data to be sent and the received data.
9. The communication module according to claim 8, characterized in that: The CRC check comparison circuit is also used to transmit the CRC check result of the data to be sent to the controller, and transmit the comparison result between the CRC check result of the received data and the received CRC check result to the register.
10. An atmosphere light control system, characterized in that: The atmosphere light control system comprises: The communication module according to any one of claims 1 to 9; An atmosphere light control chip, wherein the atmosphere light control chip exchanges data with the communication module through an SIO interface to realize atmosphere light control; The power management module is used to provide working voltage for the communication module and the atmosphere light control chip.
Citation Information
Patent Citations
Safe and reusable single program initiation (SPI) peripheral interface circuit
CN102231143A
Multi-wire SPI-Flash controller used for automatic handling and adapted to device
CN106874224A
High-speed data transmission method for serial port equipment under embedded operating system
CN112231265A
Atmosphere lamp control method, controller, electronic equipment and storage medium
CN115568055A
SPI bus controller circuit with transmitting and receiving FIFO
CN115712591A