CN-122026947-A - Data transmission method, transmitting and receiving end controller and data transmission circuit
Abstract
The application discloses a data transmission method, a sending and receiving end controller and a data transmission circuit, wherein the data transmission method comprises the steps of obtaining a value to be transmitted; the method comprises the steps of obtaining a transmission pulse signal by carrying out operation processing on a value to be transmitted by adopting a preset mapping relation, obtaining a signal characteristic parameter, carrying out signal modulation by utilizing the signal characteristic parameter, and sending the transmission pulse signal to a receiving end controller so as to enable the receiving end controller to demodulate the transmission pulse signal to obtain the value to be transmitted. In the mode, the data transmission method of the application adopts the form of the digital pulse signal to transmit the value to be transmitted, thereby effectively improving the real-time performance of data transmission, meeting the requirements of two sets of controllers on the control algorithm, having simple logic and being easy for engineering realization.
Inventors
- GUO JIANXIN
- LIU XIAOGANG
Assignees
- 西安麦格米特电气有限公司
- 湖南麦格米特电气技术有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260414
Claims (16)
- 1. A data transmission method, the data transmission method comprising: Acquiring a value to be transmitted; Carrying out operation processing on the value to be transmitted by adopting a preset mapping relation to obtain a signal characteristic parameter; carrying out signal modulation by utilizing the signal characteristic parameters to obtain a transmission pulse signal; And sending the transmission pulse signal to a receiving end controller so that the receiving end controller demodulates the transmission pulse signal to obtain the value to be transmitted.
- 2. The method for transmitting data according to claim 1, wherein the values to be transmitted include a first transmission value and a second transmission value, the signal characteristic parameter includes a first signal period and a first positive duty cycle, and the step of performing an operation on the values to be transmitted using a preset mapping relationship to obtain the signal characteristic parameter includes: Adopting a first mapping function to perform operation processing on the first transmission value, the maximum transmission value, the minimum transmission value, the maximum signal period and the minimum signal period to obtain the first signal period; Performing operation processing on the second transmission value, the maximum transmission value, the minimum transmission value, the maximum positive duty cycle and the minimum positive duty cycle by adopting a second mapping function to obtain the first positive duty cycle; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: performing signal modulation by using the first signal period and the first positive duty cycle to obtain a first pulse signal; the step of sending the transmission pulse signal to a receiving end controller so that the receiving end controller demodulates the transmission pulse signal to obtain the value to be transmitted includes: And sending the first pulse signal to the receiving end controller so that the receiving end controller demodulates the first pulse signal to obtain the first transmission value and the second transmission value.
- 3. The data transmission method according to claim 1, wherein the step of performing an operation on the values to be transmitted using a predetermined mapping relationship to obtain signal characteristic parameters includes: when the value to be transmitted is not smaller than the minimum transmission value and smaller than the intermediate transmission value, a first mapping function is adopted to carry out operation processing on the value to be transmitted, the minimum transmission value, the intermediate transmission value, the maximum signal period and the minimum signal period to obtain a second signal period; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: performing signal modulation by adopting the second signal period and the minimum positive duty ratio to obtain the transmission pulse signal; and/or when the value to be transmitted is not smaller than the intermediate transmission value and not larger than the maximum transmission value, adopting a second mapping function to perform operation processing on the value to be transmitted, the intermediate transmission value, the maximum positive duty cycle and the minimum positive duty cycle to obtain a second positive duty cycle; And carrying out signal modulation by adopting the second positive duty ratio and the maximum signal period to obtain the transmission pulse signal.
- 4. The data transmission method according to claim 1, wherein the step of performing an operation on the values to be transmitted using a predetermined mapping relationship to obtain signal characteristic parameters includes: When the value to be transmitted is not smaller than the minimum transmission value and smaller than the intermediate transmission value, a second mapping function is adopted to carry out operation processing on the value to be transmitted, the minimum transmission value, the intermediate transmission value, the maximum positive duty cycle and the minimum positive duty cycle to obtain a third positive duty cycle; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: Performing signal modulation by adopting the third positive duty ratio and the minimum signal period to obtain the transmission pulse signal; And/or when the value to be transmitted is not smaller than the intermediate transmission value and not larger than the maximum transmission value, adopting a first mapping function to calculate and process the value to be transmitted, the intermediate transmission value, the maximum signal period and the minimum signal period to obtain a third signal period; And carrying out signal modulation by adopting the third signal period and the maximum positive duty ratio to obtain the transmission pulse signal.
- 5. The data transmission method according to claim 1, wherein the number of the values to be transmitted is 2*N, N is a positive integer greater than 1, the signal characteristic parameter includes N signal periods and N positive duty cycles, and the step of performing the operation on the values to be transmitted by using the preset mapping relationship to obtain the signal characteristic parameter includes: Respectively carrying out operation processing on any N values to be transmitted, a maximum transmission value, a minimum transmission value, a maximum signal period and a minimum signal period by adopting a first mapping function to obtain N signal periods; the operation formula of the first mapping function is as follows: (TN-Prdmax)/(Prdmin-Prdmax) = (DataN-Datamax)/(Datamin-Datamax), wherein TN is the nth signal period, prdmax is the maximum signal period, prdmin is the minimum signal period, dataN is the nth transmission value, datamax is the maximum transmission value, and Datamin is the minimum transmission value; Adopting a second mapping function to respectively calculate N other values to be transmitted, the maximum transmission value, the minimum transmission value, the maximum positive duty ratio and the minimum positive duty ratio to obtain N positive duty ratios; the operation formula of the second mapping function is as follows: (DutyN-Dutymax)/(Dutymin-Dutymax) = (DataN-Datamax)/(Datamin-Datamax), wherein DutyN is the nth positive duty cycle, dutymax is the maximum positive duty cycle, dutymin is the minimum positive duty cycle; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: Carrying out signal modulation by utilizing N signal periods and N positive duty ratios corresponding to the signal periods respectively to obtain N transmission pulse signals; the step of sending the transmission pulse signal to a receiving end controller so that the receiving end controller demodulates the transmission pulse signal to obtain the value to be transmitted includes: And respectively sending the N transmission pulse signals to the receiving end controller so that the receiving end controller respectively demodulates the N transmission pulse signals to obtain 2*N values to be transmitted.
- 6. The data transmission method according to claim 1, wherein the number of the values to be transmitted is 2*N, N is a positive integer greater than 1, the signal characteristic parameter includes N signal periods, N positive duty cycles and N-1 phase delay duty cycles, and the step of performing the operation on the values to be transmitted using the preset mapping relationship to obtain the signal characteristic parameter includes: Adopting a first mapping function to calculate any one of the to-be-transmitted numerical value, the maximum transmission value, the minimum transmission value, the maximum signal period and the minimum signal period to obtain the signal period; adopting a second mapping function to respectively calculate and process the other arbitrary N values to be transmitted, the maximum transmission value, the minimum transmission value, the maximum positive duty cycle and the minimum positive duty cycle to obtain N positive duty cycles; Calculating the remaining N-1 values to be transmitted, the maximum transmission value, the minimum transmission value, the maximum phase delay duty ratio and the minimum phase delay duty ratio by adopting a third mapping function to obtain N-1 phase delay duty ratios; the operation formula of the third mapping function is as follows: (Phase N-1 -Phasemax)/(Phasemin-Phasemax) = (DataN-Datamax)/(Datamin-Datamax), wherein Phase N-1 is the N-1 st Phase delay duty cycle, phasemax is the maximum Phase delay duty cycle, phasemin is the minimum Phase delay duty cycle, data is the nth transmission value, datamax is the maximum transmission value, and Datamin is the minimum transmission value; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: Respectively carrying out signal modulation by using the signal period and any positive duty ratio to obtain one of the transmission pulse signals; respectively carrying out signal modulation by using the N-1 positive duty ratios and the N-1 phase delay duty ratios corresponding to the positive duty ratios and the signal periods to obtain N-1 transmission pulse signals; the step of sending the transmission pulse signal to a receiving end controller so that the receiving end controller demodulates the transmission pulse signal to obtain the value to be transmitted includes: And respectively sending the N transmission pulse signals to the receiving end controller so that the receiving end controller respectively demodulates the N transmission pulse signals to obtain 2*N values to be transmitted.
- 7. The data transmission method according to claim 1, wherein the signal characteristic parameters include N signal periods and N positive duty cycles, N is a positive integer greater than 1, and the step of performing the operation on the values to be transmitted using a preset mapping relationship to obtain the signal characteristic parameters includes: Responding to the fact that the value to be transmitted is sequentially located in M+1 preset value intervals, sequentially carrying out operation processing on the value to be transmitted, a minimum transmission value, M intermediate transmission values, a maximum transmission value, a maximum signal period, a minimum signal period, a maximum positive duty cycle and a minimum positive duty cycle by adopting a preset mapping function to obtain any M parameters in the N signal periods and the N positive duty cycles, wherein M is a positive integer which is not larger than N, M+1 preset value intervals are continuous subintervals obtained by sequentially dividing data intervals with the minimum transmission value and the maximum transmission value as a lower limit value and an upper limit value by using M intermediate transmission values; the step of modulating the signal by using the signal characteristic parameters to obtain a transmission pulse signal comprises the following steps: Adopting any M parameters, minimum positive duty cycle and/or maximum signal cycle in N signal periods and N positive duty cycles to respectively and sequentially perform signal modulation to obtain M transmission pulse signals; or, sequentially performing signal modulation on any M parameters, minimum signal period and/or maximum positive duty ratio in the N signal periods and the N positive duty ratios to obtain M transmission pulse signals; And respectively sending the M transmission pulse signals to the receiving end controller so that the receiving end controller respectively demodulates the M transmission pulse signals to obtain the value to be transmitted.
- 8. The data transmission method according to any one of claims 1 to 7, wherein the step of performing signal modulation using the signal characteristic parameter to obtain a transmission pulse signal includes: obtaining a maximum count value and a comparison count value by utilizing the signal characteristic parameters; Setting a counter zero crossing event and a counter comparison event using the maximum count value and the comparison count value; and adjusting the level state of the output port in response to the counter zero crossing event and the counter comparison event to obtain the transmission pulse signal.
- 9. The data transmission method according to claim 8, wherein the signal characteristic parameter includes a signal period and a positive duty ratio, and the step of obtaining the maximum count value and the comparison count value using the signal characteristic parameter includes: Multiplying the signal period by a clock frequency to obtain the maximum count value; multiplying the maximum count value by the positive duty cycle to obtain the comparison count value.
- 10. The data transmission method according to any one of claims 1 to 7, wherein the step of performing signal modulation using the signal characteristic parameter to obtain a transmission pulse signal includes: obtaining a maximum count value, a comparison count value and a target count value by utilizing the signal characteristic parameters; Setting a first zero crossing event and a first comparison event using the maximum count value and the comparison count value; Adjusting the level state of a first output port in response to the first zero crossing event and the first comparison event to obtain a first pulse signal; setting a second zero crossing event and a phase delay event using the maximum count value and the target count value; And adjusting the level state of the second output port in response to the second zero crossing event and the phase delay event to obtain a second pulse signal.
- 11. The data transmission method according to claim 10, wherein the signal characteristic parameter includes a signal period, a positive duty cycle, and a phase delay duty cycle, and the step of obtaining the maximum count value, the comparison count value, and the target count value using the signal characteristic parameter includes: Multiplying the signal period by a clock frequency to obtain the maximum count value; Multiplying the maximum count value by the positive duty cycle to obtain the comparison count value; the target count value is obtained by multiplying the maximum count value by the product of the phase delay duty cycle subtracted from the maximum count value.
- 12. A transmitter controller, wherein the transmitter controller is coupled to a memory and a processor; the memory stores program data; the processor is configured to execute the program data to implement the data transmission method according to any one of claims 1 to 11.
- 13. A data transmission method, the data transmission method comprising: Acquiring a transmission pulse signal sent by a sending end controller; Demodulating the transmission pulse signal to obtain a signal characteristic parameter; and carrying out operation processing on the signal characteristic parameters by adopting a preset mapping relation to obtain a value to be transmitted.
- 14. The data transmission method according to claim 13, wherein the step of demodulating the transmission pulse signal to obtain the signal characteristic parameter comprises: acquiring each rising edge time and each falling edge time of the transmission pulse signal; And obtaining the signal characteristic parameters by using each rising edge moment, each falling edge moment and the clock frequency.
- 15. A receiver controller, wherein the receiver controller is coupled to a memory and a processor; the memory stores program data; the processor is configured to execute the program data to implement the data transmission method according to any one of claims 13 or 14.
- 16. The data transmission circuit is characterized by comprising a transmitting end controller, an isolation communication circuit and a receiving end controller, wherein the isolation communication circuit is coupled with the transmitting end controller and the receiving end controller; wherein the sender controller is the sender controller according to claim 12; the receiving end controller is as right the receiver controller of claim 15.
Description
Data transmission method, transmitting and receiving end controller and data transmission circuit Technical Field The present application relates to the field of circuit technologies, and in particular, to a data transmission method, a sending and receiving end controller, and a data transmission circuit. Background In recent years, along with the increasing abundance of various electronic products, power supply and signal control for realizing functions of various electronic products are more and more complex, and particularly, in a scene that two sets of controllers are used for respectively sampling and controlling an input end and an output end of a power supply, respective control algorithms of the two sets of controllers generally need to perform data interaction transmission with the other party to participate in control so as to meet the power supply requirement of loads. However, in the related art, the data is transmitted through the isolated communication interfaces of the two sets of controllers usually in units of frames, and protocol sets such as Modbus (a serial communication protocol), HDLC (High-LEVEL DATA LINK Control) and the like are used for framing, the time required for transmitting one frame of data is several ms (milliseconds) to several tens ms, and the delay requirement of the Control algorithm on sampling is several us (microseconds) to several tens us, so that the data transmitted through the isolated communication interfaces cannot meet the requirement of the Control algorithm on real-time performance. Disclosure of Invention The application mainly solves the technical problem of providing a data transmission method, a sending and receiving end controller and a data transmission circuit, and can solve the problem that the control algorithm of two sets of controllers cannot meet the real-time requirement due to overlong data transmission delay time of the two sets of controllers in the related technology. In order to solve the technical problems, the technical scheme adopted by the application is that a data transmission method is provided, wherein the data transmission method comprises the steps of obtaining a value to be transmitted, carrying out operation processing on the value to be transmitted by adopting a preset mapping relation to obtain a signal characteristic parameter, carrying out signal modulation on the signal characteristic parameter to obtain a transmission pulse signal, and sending the transmission pulse signal to a receiving end controller so that the receiving end controller demodulates the transmission pulse signal to obtain the value to be transmitted. The method comprises the steps of obtaining a first transmission value, obtaining a second transmission value, obtaining a first positive duty ratio by calculating a to-be-transmitted value through a first mapping function, obtaining a first transmission value, obtaining a second transmission value, obtaining a first positive duty ratio through a second mapping function, obtaining a first pulse signal through signal modulation through signal characteristic parameters, obtaining a first pulse signal through signal modulation through the first signal period and the first positive duty ratio, and sending the transmission pulse signal to a receiving end controller to enable the receiving end controller to demodulate the transmission pulse signal to obtain the to-be-transmitted value. The method comprises the steps of carrying out operation processing on a value to be transmitted by adopting a preset mapping relation to obtain a signal characteristic parameter, wherein when the value to be transmitted is not smaller than a minimum transmission value and smaller than an intermediate transmission value, carrying out operation processing on the value to be transmitted, the minimum transmission value, the intermediate transmission value, the maximum signal period and the minimum signal period by adopting a first mapping function to obtain a second signal period, carrying out signal modulation on the signal characteristic parameter to obtain a transmission pulse signal by adopting the second signal period and the minimum positive duty ratio, and/or carrying out signal modulation on the second signal period and the maximum signal period to obtain a transmission pulse signal by adopting the second mapping function when the value to be transmitted is not smaller than the intermediate transmission value and not larger than the maximum transmission value, carrying out operation processing on the value to be transmitted, the intermediate transmission value, the maximum positive duty ratio and the minimum positive duty ratio to obtain the second positive duty ratio. The method comprises the steps of carrying out operation processing on a value to be transmitted by adopting a preset mapping relation to obtain a signal characteristic parameter, carrying out operation processing on the value to be transmitted, the minimum transm