CN110688339B - Data transmission method and device, mobile terminal and storage medium - Google Patents

Data transmission method and device, mobile terminal and storage medium Download PDF

Info

Publication number
CN110688339B
CN110688339B CN201910895339.5A CN201910895339A CN110688339B CN 110688339 B CN110688339 B CN 110688339B CN 201910895339 A CN201910895339 A CN 201910895339A CN 110688339 B CN110688339 B CN 110688339B
Authority
CN
China
Prior art keywords
level
transmission speed
interval
integrated circuit
subintervals
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910895339.5A
Other languages
Chinese (zh)
Other versions
CN110688339A (en
Inventor
俞斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xi'an Zhengdatong Information Technology Co.,Ltd.
Original Assignee
TCL Mobile Communication Technology Ningbo Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by TCL Mobile Communication Technology Ningbo Ltd filed Critical TCL Mobile Communication Technology Ningbo Ltd
Priority to CN201910895339.5A priority Critical patent/CN110688339B/en
Publication of CN110688339A publication Critical patent/CN110688339A/en
Application granted granted Critical
Publication of CN110688339B publication Critical patent/CN110688339B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus

Abstract

The embodiment of the application discloses a data transmission method, a data transmission device, a mobile terminal and a storage medium, and can detect the transmission speed of an integrated circuit bus when transmitting data; acquiring a level interval corresponding to the transmission speed to obtain a target level interval; detecting the level of the integrated circuit bus when transmitting data to obtain the current level; and if the current level is not in the target level interval, controlling the current level to be in the target level interval. The scheme can control the level of the integrated circuit bus to be maintained in the level interval, so that the level change of the integrated circuit bus is stable, the integrated circuit bus can normally transmit data, and the level interference resistance and the data transmission efficiency of the integrated circuit bus are improved.

Description

Data transmission method and device, mobile terminal and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a data transmission method, an apparatus, a mobile terminal, and a storage medium.
Background
An Inter-Integrated Circuit (IIC) is a simple, bidirectional, synchronous serial bus, which can conveniently implement a multi-computer system and a peripheral expansion system, but when the number of peripheral devices configured on the IIC bus is large, the IIC bus is prone to have a level interference problem, resulting in abnormal data transmission.
Based on the problem, in the conventional method for resisting level interference, when data transmission is abnormal, level interference occurs, and at this time, a pulse signal is sent from the host device to reset software of the IIC bus, so that the level of the IIC bus is restored to an initial state, and data transmission is performed again. The existing method has a rough processing mode for resisting level interference, and directly resetting to restore the level to the initial state not only easily causes data transmission errors, but also has low data transmission efficiency.
Disclosure of Invention
The embodiment of the application provides a data transmission method, a data transmission device, a mobile terminal and a storage medium, which can improve the anti-level interference capability and the data transmission efficiency.
In a first aspect, an embodiment of the present application provides a data transmission method, including:
detecting the transmission speed of the integrated circuit bus when transmitting data;
acquiring a level interval corresponding to the transmission speed to obtain a target level interval;
detecting the level of the integrated circuit bus when transmitting data to obtain the current level;
and if the current level is not in the target level interval, controlling the current level to be in the target level interval.
In some embodiments, before obtaining the level interval corresponding to the transmission speed, before obtaining the target level interval, the method further includes:
acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data;
dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals;
establishing a corresponding relation between each level subinterval and each transmission speed subinterval;
the obtaining of the level interval corresponding to the transmission speed and obtaining of the target level interval includes:
determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed;
and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
In some embodiments, the dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals and the dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals includes:
dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and a plurality of level subintervals are obtained;
and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
In some embodiments, the detecting a transmission speed of the integrated circuit bus when transmitting data includes:
detecting a starting time of a first rising edge on a clock line of an integrated circuit bus;
detecting a start time of a second rising edge on a clock line of an integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge;
and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
In some embodiments, if the current level is not in the target level interval, controlling the current level to be after the target level interval further includes:
and if the current level is within the target level interval, maintaining the current level so that the integrated circuit bus normally transmits data.
In some embodiments, the detecting the level when the integrated circuit bus transmits data, and obtaining the current level includes:
collecting analog signals when the integrated circuit bus transmits data;
converting the analog signal into a digital signal by an analog-to-digital converter;
and converting the digital signal into a level to obtain the current level.
In a second aspect, an embodiment of the present application further provides a data transmission apparatus, including:
the first detection module is used for detecting the transmission speed of the integrated circuit bus when transmitting data;
the first acquisition module is used for acquiring a level interval corresponding to the transmission speed to obtain a target level interval;
the second detection module is used for detecting the level of the integrated circuit bus when transmitting data to obtain the current level;
and the control module is used for controlling the current level to be positioned in the target level interval if the current level is not positioned in the target level interval.
In some embodiments, the data transmission device further comprises:
the second acquisition module is used for acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data;
the dividing module is used for dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals;
the establishing module is used for establishing a corresponding relation between each level subinterval and each transmission speed subinterval;
the first obtaining module is specifically configured to:
determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed;
and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
In some embodiments, the partitioning module is specifically configured to:
dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and a plurality of level subintervals are obtained;
and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
In some embodiments, the first detection module is specifically configured to:
detecting a starting time of a first rising edge on a clock line of an integrated circuit bus;
detecting a start time of a second rising edge on a clock line of an integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge;
and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
In some embodiments, the data transmission device further comprises:
and the maintaining module is used for maintaining the current level if the current level is positioned in the target level interval so that the integrated circuit bus can normally transmit data.
In some embodiments, the second detection module is specifically configured to
Collecting analog signals when the integrated circuit bus transmits data;
converting the analog signal into a digital signal by an analog-to-digital converter;
and converting the digital signal into a level to obtain the current level.
In a third aspect, an embodiment of the present application further provides a mobile terminal, including a memory and a processor, where the memory stores a computer program, and the processor executes any one of the data transmission methods provided in the embodiment of the present application when calling the computer program in the memory.
In a fourth aspect, an embodiment of the present application further provides a storage medium, where the storage medium is used to store a computer program, and the computer program is loaded by a processor to execute any one of the data transmission methods provided in the embodiment of the present application.
The method and the device can detect the transmission speed of the integrated circuit bus during transmission, obtain the level interval of the level corresponding to the transmission speed of the integrated circuit bus during transmission according to the transmission speed, obtain the target level interval, then detect the level of the integrated circuit bus during data transmission, obtain the current level, and control the current level to be located in the target level interval if the current level is not in the target level interval. According to the scheme, the transmission speed of the integrated circuit bus during data transmission can be detected, the level interval corresponding to the level is obtained through the transmission speed, the level during data transmission at present is compared with the level interval, if the level during data transmission at present is not located in the level interval, the level interference problem occurs, and the level during data transmission at present needs to be controlled to be located in the level interval. Therefore, when the level of the integrated circuit bus is maintained in the level interval, the level change of the integrated circuit bus is stable, the integrated circuit bus can normally transmit data, and the level interference resistance and the data transmission efficiency of the integrated circuit bus are improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flowchart of a data transmission method according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of a data transmission device according to an embodiment of the present application;
fig. 3 is another schematic structural diagram of a data transmission device according to an embodiment of the present application;
fig. 4 is another schematic structural diagram of a data transmission device according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a mobile terminal according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Referring to fig. 1, fig. 1 is a schematic flow chart illustrating a data transmission method according to an embodiment of the present application. The execution main body of the data transmission method may be the data transmission device provided in the embodiment of the present application, or a mobile terminal integrated with the data transmission device, where the data transmission device may be implemented in a hardware or software manner, and the mobile terminal may be a smart phone, a tablet computer, a palm computer, or a notebook computer, etc. The data transmission method may include:
s101, detecting the transmission speed of the integrated circuit bus when the integrated circuit bus transmits data.
For example, a clock line of the integrated circuit bus transmits 1bit of data in one clock cycle, and if the transmission frequency of the clock line is 100KHz, 100K clock cycles of the clock line can be generated within 1s, that is, 100Kbit of data can be transmitted within 1 s. Therefore, the transmission frequency of 100KHz can be set to the transmission speed of 100 Kbit/s. At this time, the transmission frequency of the integrated circuit bus for transmitting data can be detected, and the transmission speed of the integrated circuit bus for transmitting data can be obtained after the transmission frequency is detected.
In some embodiments, detecting a transfer speed at which the integrated circuit bus transfers data may include: detecting a starting time of a first rising edge on a clock line of an integrated circuit bus; detecting a start time of a second rising edge on a clock line of the integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge; and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
Wherein, the relationship between the frequency and the period is as follows: and f is 1/T, calculating the time between the starting time of the first rising edge and the starting time of the second rising edge on the clock line of the integrated circuit bus, wherein the time is the clock period, the reciprocal of the clock period is the clock frequency according to the relation between the frequency and the period, thereby obtaining the clock frequency, and when the integrated circuit bus transmits data, the clock frequency is the transmission frequency, the transmission frequency is set as the transmission speed, thereby obtaining the transmission speed when the integrated circuit bus transmits the data.
And S102, acquiring a level interval corresponding to the transmission speed to obtain a target level interval.
The level interval can be a level interval enabling the integrated circuit bus to work normally, and can be obtained in a configuration file of the integrated circuit bus, the obtained level interval is divided into a plurality of level subintervals, when the integrated circuit bus transmits data, different transmission speeds correspond to the different level subintervals, and therefore the corresponding level subintervals are obtained according to the transmission speeds, and the target level interval is obtained.
In some embodiments, obtaining a level interval corresponding to the transmission speed, and before obtaining the target level interval, the method may further include: acquiring a level interval and a transmission speed interval when an integrated circuit bus transmits data; dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals; establishing a corresponding relation between each level subinterval and each transmission speed subinterval; acquiring a level interval corresponding to the transmission speed, wherein the acquiring of the target level interval comprises: determining a target transmission speed subinterval in which the transmission speed is positioned according to the transmission speed; and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
The level interval and the transmission speed interval may be obtained from a configuration file of an integrated circuit bus, the obtained level interval is divided into a plurality of level sub-intervals, and the transmission speed interval is divided into a plurality of transmission speed sub-intervals, for example, a plurality of level thresholds including an interval upper limit value and an interval lower limit value are set in the level interval, each level threshold is configured into a plurality of continuous non-intersection level sub-intervals, a plurality of transmission speed thresholds including an interval upper limit value and an interval lower limit value are set in the transmission speed interval, and each transmission speed threshold is configured into a plurality of continuous non-intersection transmission speed sub-intervals. Matching each level subinterval with each transmission speed subinterval, for example, when the transmission speed subinterval of the integrated circuit bus transmission data is Va1, selecting the level subinterval of the integrated circuit bus transmission data as Ua 1; when the transmission speed subinterval of the integrated circuit bus transmission data is Va2, selecting the level subinterval of the integrated circuit bus transmission data as Ua 2; when the transmission speed subinterval of the integrated circuit bus transmission data is VaN, the level subinterval when the integrated circuit bus is selected to transmit the data is UaN.
In a specific implementation, the obtained level interval may be divided into a plurality of level sub-intervals in other manners, and the transmission speed interval may be divided into a plurality of transmission speed sub-intervals, for example, a plurality of level thresholds including an upper limit and a lower limit are set in the level interval, each level threshold is configured into a plurality of discontinuous non-intersecting level sub-intervals, a plurality of transmission speed thresholds including an upper limit and a lower limit are set in the transmission speed interval, and each transmission speed threshold is configured into a plurality of continuous non-intersecting transmission speed sub-intervals. Matching each level subinterval with each transmission speed subinterval, for example, when the transmission speed subinterval of the integrated circuit bus transmission data is Vb1, selecting the level subinterval of the integrated circuit bus transmission data as Ub 1; when the transmission speed subinterval of the integrated circuit bus transmission data is Vb2, the level subinterval when the integrated circuit bus transmission data is selected to be Ub 2; when the transmission speed subinterval of the integrated circuit bus transmission data is VbN, the level subinterval when the integrated circuit bus is selected to transmit the data is UbN.
In some embodiments, dividing the level interval into a plurality of subintervals, resulting in a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals, resulting in a plurality of transmission speed subintervals may comprise: dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and obtaining a plurality of level subintervals; and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
The level section and the transmission speed section may be obtained from a configuration file of an integrated circuit bus, the obtained level section is divided into a plurality of level sub-sections, and the transmission speed section is divided into a plurality of transmission speed sub-sections, for example, the level section is divided into a plurality of level sub-sections, a lower limit value of the level section is set to be U0, and then a plurality of thresholds U1, U2, U3, U4 … … and UN are set, wherein U0< U1< U2< U3< U4 … … < UN, U1N is an upper limit value of the level section, the section [ U0, U2) is used as a level sub-section Ud1, the section [ U2, U4) is used as a level sub-section Ud2 … …, and the section [ UN-2, UN ] is used as a level sub-section UdN; dividing a transmission speed interval into a plurality of transmission speed subintervals, setting a plurality of thresholds V1, V2, V3 … … and VN in the transmission speed interval (0, VN), taking the interval (0, V1) as a level subinterval Vd1, taking the interval (V1 and V2) as a transmission speed subinterval Vd2, taking the interval (V2 and V3) as a transmission speed subinterval Vd3 and … …, taking the interval (VN-1 and VN) as a transmission speed subinterval VdN, wherein 0< V1< V2< V3< … … < VN. matches each level subinterval with each transmission speed subinterval, specifically, when the transmission speed subinterval of the integrated circuit bus for transmitting data is Vd1, selecting the level subinterval of the integrated circuit bus for transmitting data as Ud1, when the transmission speed subinterval of the integrated circuit bus for transmitting data is 2, selecting the level subinterval of the integrated circuit bus for transmitting data as Ud2, when the integrated circuit bus for transmitting data as Ud1, when the transmission speed subinterval of the integrated circuit bus for transmitting data is 2, and when the integrated circuit bus for transmitting data VdN, the level subinterval for selecting the integrated circuit bus to transmit data is UdN.
For example, when the transfer speed at which the integrated circuit bus transfers data is acquired is Vt, Vt is matched with the transfer speed subintervals Vd1, Vd2, Vd3 … … and VN to obtain the target transfer speed subinterval Vdt, and when the transfer speed subinterval at which the integrated circuit bus transfers data is Vdt, the level subinterval at which the integrated circuit bus transfers data is selected to be Udt, so that the target level subinterval Udt is obtained.
It should be noted that the level interval division subinterval and the transmission speed interval division subinterval may be flexibly divided according to actual needs, and in addition, a correspondence relationship is established between the level subinterval and the transmission speed subinterval, or may be flexibly established according to actual needs, and specific content is not limited herein.
And S103, detecting the level of the integrated circuit bus when the integrated circuit bus transmits data to obtain the current level.
The current level can be the level when the current integrated circuit bus transmits data, the current level can be obtained by measuring through a level measuring system, or a level judging system judges the current level interval in which the current level is positioned, then the current level or the current level interval is compared with the target level interval, and if the current level is not positioned in the target level interval, the current level is controlled to be positioned in the target level interval.
In some embodiments, detecting a level at which the integrated circuit bus transfers data, and obtaining the current level may include: collecting analog signals when the integrated circuit bus transmits data; converting the analog signal into a digital signal through an analog-to-digital converter; and converting the digital signal into a level to obtain the current level.
For example, an analog signal is converted into a digital signal by an analog-to-digital converter with precision such as 8 bits, 12 bits, 16 bits, etc., the digital signal is converted into a level signal by a digital-to-analog converter with precision such as 8 bits, 12 bits, 16 bits, etc., the level signal is converted into a current level, the current level is compared with a target level interval, and if the current level is not in the target level interval, the current level is controlled to be in the target level interval.
It should be noted that, the method for detecting the level when the integrated circuit bus transmits data may use other technical methods according to actual situations, and the specific content is not limited herein.
And S104, if the current level is not in the target level interval, controlling the current level to be in the target level interval.
Wherein, if the current level is not in the target level interval, the level of the integrated circuit bus transmitting data is changed, i.e. level interference is generated, which would cause the data transmission abnormality of the integrated circuit bus, therefore, it is necessary to control the current level to be lowered or raised so that the current level is in the target level interval, or to make the current level be in the target level interval by other means, and maintain the current level, so that the integrated circuit bus normally transmits data, for example, when the current level is lower than the target level, the transmission speed of the integrated circuit bus transmitting data can be lowered, when the transmission speed is lowered, the transmission speed interval corresponding to the transmission speed is reduced, the target level interval corresponding to the transmission speed interval is reduced, therefore, the current level and the target level interval are reduced simultaneously, so that the current level is in the target level interval, maintaining the current level causes the integrated circuit bus to normally transmit data. Furthermore, the pull-up resistor configured on the integrated circuit bus is adjusted to be larger, the pull-up resistor is increased to reduce the transmission speed when the integrated circuit bus transmits data, and when the transmission speed is reduced, the transmission speed interval corresponding to the transmission speed is reduced, the target level interval corresponding to the transmission speed interval is reduced, so that the current level and the target level interval are reduced simultaneously, the current level is located in the target level interval, and the current level is maintained to enable the integrated circuit bus to normally transmit data.
In some embodiments, if the current level is not in the target level interval, controlling the current level to be after the target level interval may further include: and if the current level is in the target level interval, maintaining the current level so that the integrated circuit bus can normally transmit data.
For example, setting the current level as a and the target level interval as a, if the current level is not located in the target level interval, that is, a □ a, because the current level deviates from the target level interval, that is, level interference is generated in the data transmission process of the integrated circuit bus, in order to eliminate the problem of abnormal data transmission of the integrated circuit bus caused by the level interference, it is necessary to control the current level to be located in the target level interval, that is, to control the current level to be increased or decreased, so as to enable a ∈ a, and if the current level is located in the target level interval, the problem of abnormal data transmission of the integrated circuit bus caused by the level interference is solved, the integrated circuit bus can normally transmit data, and the capability of resisting level interference and the data transmission efficiency are improved.
The method and the device can detect the transmission speed of the integrated circuit bus during transmission, obtain the level interval of the level corresponding to the transmission speed of the integrated circuit bus during transmission according to the transmission speed, obtain the target level interval, then detect the level of the integrated circuit bus during data transmission, obtain the current level, and control the current level to be located in the target level interval if the current level is not in the target level interval. According to the scheme, the transmission speed of the integrated circuit bus during data transmission can be detected, the level interval corresponding to the level is obtained through the transmission speed, the level during data transmission at present is compared with the level interval, if the level during data transmission at present is not located in the level interval, the level interference problem occurs, and the level during data transmission at present needs to be controlled to be located in the level interval. Therefore, when the level of the integrated circuit bus is maintained in the level interval, the level change of the integrated circuit bus is stable, the integrated circuit bus can normally transmit data, and the level interference resistance and the data transmission efficiency of the integrated circuit bus are improved.
In order to better implement the data transmission method provided by the embodiment of the present application, an embodiment of the present application further provides a device based on the data transmission method. The terms are the same as those in the data transmission method, and specific implementation details can refer to the description in the method embodiment.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a data transmission device according to an embodiment of the present disclosure, where the data transmission device may include a first detection module 301, a first obtaining module 302, a second detection module 303, a control module 304, and the like.
The first detecting module 301 is configured to detect a transmission speed of the integrated circuit bus when transmitting data.
For example, a clock line of the integrated circuit bus transmits 1bit of data in one clock cycle, and if the transmission frequency of the clock line is 100KHz, 100K clock cycles of the clock line can be generated within 1s, that is, 100Kbit of data can be transmitted within 1 s. Therefore, the transmission frequency of 100KHz can be set to the transmission speed of 100 Kbit/s. At this time, the transmission frequency of the integrated circuit bus for transmitting data can be detected, and the transmission speed of the integrated circuit bus for transmitting data can be obtained after the transmission frequency is detected.
In some embodiments, the first detection module 301 is specifically configured to: detecting a starting time of a first rising edge on a clock line of an integrated circuit bus; detecting a start time of a second rising edge on a clock line of the integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge; and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
Wherein, the relationship between the frequency and the period is as follows: and f is 1/T, calculating the time between the starting time of the first rising edge and the starting time of the second rising edge on the clock line of the integrated circuit bus, wherein the time is the clock period, the reciprocal of the clock period is the clock frequency according to the relation between the frequency and the period, thereby obtaining the clock frequency, and when the integrated circuit bus transmits data, the clock frequency is the transmission frequency, the transmission frequency is set as the transmission speed, thereby obtaining the transmission speed when the integrated circuit bus transmits the data.
The first obtaining module 302 is configured to obtain a level interval corresponding to a transmission speed, so as to obtain a target level interval.
The level interval can be a level interval enabling the integrated circuit bus to work normally, and can be obtained in a configuration file of the integrated circuit bus, the obtained level interval is divided into a plurality of level subintervals, when the integrated circuit bus transmits data, different transmission speeds correspond to the different level subintervals, and therefore the corresponding level subintervals are obtained according to the transmission speeds, and the target level interval is obtained.
In some embodiments, as shown in fig. 3, the data transmission apparatus may further include a second obtaining module 305, a dividing module 306, and an establishing module 307, which may specifically be as follows:
a second obtaining module 305, configured to obtain a level interval and a transmission speed interval when the integrated circuit bus transmits data;
a dividing module 306, configured to divide the level interval into multiple sub-intervals to obtain multiple level sub-intervals, and divide the transmission speed interval into multiple sub-intervals to obtain multiple transmission speed sub-intervals;
an establishing module 307, configured to establish a correspondence between each level subinterval and each transmission speed subinterval;
the first obtaining module 302 is specifically configured to:
determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed;
and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
The level interval and the transmission speed interval may be obtained from a configuration file of an integrated circuit bus, the obtained level interval is divided into a plurality of level sub-intervals, and the transmission speed interval is divided into a plurality of transmission speed sub-intervals, for example, a plurality of level thresholds including an interval upper limit value and an interval lower limit value are set in the level interval, each level threshold is configured into a plurality of continuous non-intersection level sub-intervals, a plurality of transmission speed thresholds including an interval upper limit value and an interval lower limit value are set in the transmission speed interval, and each transmission speed threshold is configured into a plurality of continuous non-intersection transmission speed sub-intervals. Matching each level subinterval with each transmission speed subinterval, for example, when the transmission speed subinterval of the integrated circuit bus transmission data is Va1, selecting the level subinterval of the integrated circuit bus transmission data as Ua 1; when the transmission speed subinterval of the integrated circuit bus transmission data is Va2, selecting the level subinterval of the integrated circuit bus transmission data as Ua 2; when the transmission speed subinterval of the integrated circuit bus transmission data is VaN, the level subinterval when the integrated circuit bus is selected to transmit the data is UaN.
In a specific implementation, the obtained level interval may be divided into a plurality of level sub-intervals in other manners, and the transmission speed interval may be divided into a plurality of transmission speed sub-intervals, for example, a plurality of level thresholds including an upper limit and a lower limit are set in the level interval, each level threshold is configured into a plurality of discontinuous non-intersecting level sub-intervals, a plurality of transmission speed thresholds including an upper limit and a lower limit are set in the transmission speed interval, and each transmission speed threshold is configured into a plurality of continuous non-intersecting transmission speed sub-intervals. Matching each level subinterval with each transmission speed subinterval, for example, when the transmission speed subinterval of the integrated circuit bus transmission data is Vb1, selecting the level subinterval of the integrated circuit bus transmission data as Ub 1; when the transmission speed subinterval of the integrated circuit bus transmission data is Vb2, the level subinterval when the integrated circuit bus transmission data is selected to be Ub 2; when the transmission speed subinterval of the integrated circuit bus transmission data is VbN, the level subinterval when the integrated circuit bus is selected to transmit the data is UbN.
In some embodiments, as shown in fig. 3, the dividing module 306 is specifically configured to: dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and obtaining a plurality of level subintervals; and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
The level section and the transmission speed section may be obtained from a configuration file of an integrated circuit bus, the obtained level section is divided into a plurality of level sub-sections, and the transmission speed section is divided into a plurality of transmission speed sub-sections, for example, the level section is divided into a plurality of level sub-sections, a lower limit value of the level section is set to be U0, and then a plurality of thresholds U1, U2, U3, U4 … … and UN are set, wherein U0< U1< U2< U3< U4 … … < UN, U1N is an upper limit value of the level section, the section [ U0, U2) is used as a level sub-section Ud1, the section [ U2, U4) is used as a level sub-section Ud2 … …, and the section [ UN-2, UN ] is used as a level sub-section UdN; dividing a transmission speed interval into a plurality of transmission speed subintervals, setting a plurality of thresholds V1, V2, V3 … … and VN in the transmission speed interval (0, VN), taking the interval (0, V1) as a level subinterval Vd1, taking the interval (V1 and V2) as a transmission speed subinterval Vd2, taking the interval (V2 and V3) as a transmission speed subinterval Vd3 and … …, taking the interval (VN-1 and VN) as a transmission speed subinterval VdN, wherein 0< V1< V2< V3< … … < VN. matches each level subinterval with each transmission speed subinterval, specifically, when the transmission speed subinterval of the integrated circuit bus for transmitting data is Vd1, selecting the level subinterval of the integrated circuit bus for transmitting data as Ud1, when the transmission speed subinterval of the integrated circuit bus for transmitting data is 2, selecting the level subinterval of the integrated circuit bus for transmitting data as Ud2, when the integrated circuit bus for transmitting data as Ud1, when the transmission speed subinterval of the integrated circuit bus for transmitting data is 2, and when the integrated circuit bus for transmitting data VdN, the level subinterval for selecting the integrated circuit bus to transmit data is UdN.
For example, the second obtaining module 305 obtains the target level sub-section Udt by matching Vt with the transfer speed sub-sections Vd1, Vd2, Vd3 … … and VN to obtain the target transfer speed sub-section Vdt, and selecting Udt as the level sub-section when the integrated circuit bus transfers data when the transfer speed sub-section of the integrated circuit bus transfers data is Vdt.
It should be noted that the level interval division subinterval and the transmission speed interval division subinterval may be flexibly divided according to actual needs, and in addition, a correspondence relationship is established between the level subinterval and the transmission speed subinterval, or may be flexibly established according to actual needs, and specific content is not limited herein.
The second detecting module 303 is configured to detect a level of the integrated circuit bus when data is transmitted, so as to obtain a current level.
The current level can be the level when the current integrated circuit bus transmits data, the current level can be obtained by measuring through a level measuring system, or a level judging system judges the current level interval in which the current level is positioned, then the current level or the current level interval is compared with the target level interval, and if the current level is not positioned in the target level interval, the current level is controlled to be positioned in the target level interval.
In some embodiments, the second detection module 303 is specifically configured to: collecting analog signals when the integrated circuit bus transmits data; converting the analog signal into a digital signal through an analog-to-digital converter; and converting the digital signal into a level to obtain the current level.
For example, the second detection module 303 converts an analog signal into a digital signal through an analog-to-digital converter with precision such as 8 bits, 12 bits, and 16 bits, converts the digital signal into a level signal through a digital-to-analog converter with precision such as 8 bits, 12 bits, and 16 bits, converts the level signal into a current level, compares the current level with a target level interval, and controls the current level to be in the target level interval if the current level is not in the target level interval.
It should be noted that, the method for detecting the level when the integrated circuit bus transmits data may use other technical methods according to actual situations, and the specific content is not limited herein.
The control module 304 is configured to control the current level to be located in the target level interval if the current level is not located in the target level interval.
Wherein, if the current level is not in the target level interval, the level of the integrated circuit bus transmitting data is changed, that is, level interference is generated, which would cause the integrated circuit bus data transmission to be abnormal, therefore, the control module 304 controls the current level to be lowered or raised, so that the current level is in the target level interval, or the current level is in the target level interval by other means, and maintains the current level, so that the integrated circuit bus normally transmits data, for example, when the current level is lower than the target level, the transmission speed of the integrated circuit bus transmitting data can be lowered, when the transmission speed is lowered, the transmission speed interval corresponding to the transmission speed is lowered, the target level interval corresponding to the transmission speed interval is lowered, so that the current level and the target level interval are both lowered, so that the current level is in the target level interval, maintaining the current level causes the integrated circuit bus to normally transmit data. Furthermore, the control module 304 increases the pull-up resistor configured on the integrated circuit bus, and the increase of the pull-up resistor decreases the transmission speed of the integrated circuit bus when transmitting data, and when the transmission speed decreases, the transmission speed interval corresponding to the transmission speed decreases, and the target level interval corresponding to the transmission speed interval decreases, so that the current level and the target level interval decrease simultaneously, and the current level is in the target level interval, and the current level is maintained, so that the integrated circuit bus normally transmits data.
In some embodiments, as shown in fig. 4, the data transmission apparatus further includes:
the maintaining module 308 is configured to maintain the current level if the current level is within the target level interval, so that the integrated circuit bus transmits data normally.
For example, the maintaining module 308 sets the current level to a, the target level interval to a, if the current level is not in the target level interval, that is, a □ a, since the current level deviates from the target level interval, that is, level interference is generated during data transmission of the integrated circuit bus, in order to eliminate the problem of abnormal data transmission of the integrated circuit bus caused by the level interference, it is necessary to control the current level to be in the target level interval, that is, control the current level to increase or decrease, so that a ∈ a, and if the current level is in the target level interval, the problem of abnormal data transmission of the integrated circuit bus caused by the level interference is solved, so that the integrated circuit bus can normally transmit data, thereby improving the capability of resisting level interference and the efficiency of data transmission.
In the embodiment of the present application, the first detecting module 301 may detect a transmission speed of the integrated circuit bus during transmission, and according to the transmission speed, the first obtaining module 302 obtains a level interval of a level corresponding to the transmission speed during the transmission of the integrated circuit bus to obtain a target level interval, then the second detecting module 303 detects the level during the data transmission of the integrated circuit bus to obtain a current level, and if the current level is not in the target level interval, the control module 304 controls the current level to be located in the target level interval. According to the scheme, the transmission speed of the integrated circuit bus during data transmission can be detected, the level interval corresponding to the level is obtained through the transmission speed, the level during data transmission at present is compared with the level interval, if the level during data transmission at present is not located in the level interval, the level interference problem occurs, and the level during data transmission at present needs to be controlled to be located in the level interval. Therefore, when the level of the integrated circuit bus is maintained in the level interval, the level change of the integrated circuit bus is stable, the integrated circuit bus can normally transmit data, and the level interference resistance and the data transmission efficiency of the integrated circuit bus are improved.
Accordingly, an embodiment of the present invention further provides a terminal, as shown in fig. 5, the terminal may include Radio Frequency (RF) circuit 601, a memory 602 including one or more computer-readable storage media, an input unit 603, a display unit 604, a sensor 605, an audio circuit 606, a Wireless Fidelity (WiFi) module 607, a processor 608 including one or more processing cores, and a power supply 609. Those skilled in the art will appreciate that the terminal structure shown in fig. 5 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components. Wherein:
the RF circuit 601 may be used for receiving and transmitting signals during a message transmission or communication process, and in particular, for receiving downlink messages from a base station and then processing the received downlink messages by one or more processors 608; in addition, data relating to uplink is transmitted to the base station. In general, the RF circuit 601 includes, but is not limited to, an antenna, at least one Amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, the RF circuit 601 may also communicate with networks and other devices via wireless communications. The wireless communication may use any communication standard or protocol, including but not limited to Global System for Mobile communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), email, Short Message Service (SMS), and the like.
The memory 602 may be used to store software programs and modules, and the processor 608 executes various functional applications and data processing by operating the software programs and modules stored in the memory 602. The memory 602 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the terminal, etc. Further, the memory 602 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 602 may also include a memory controller to provide the processor 608 and the input unit 603 access to the memory 602.
The input unit 603 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control. In particular, in one particular embodiment, input unit 603 may include a touch-sensitive surface as well as other input devices. The touch-sensitive surface, also referred to as a touch display screen or a touch pad, may collect touch operations by a user (e.g., operations by a user on or near the touch-sensitive surface using a finger, a stylus, or any other suitable object or attachment) thereon or nearby, and drive the corresponding connection device according to a predetermined program. Alternatively, the touch sensitive surface may comprise two parts, a touch detection means and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 608, and can receive and execute commands sent by the processor 608. In addition, touch sensitive surfaces may be implemented using various types of resistive, capacitive, infrared, and surface acoustic waves. The input unit 603 may include other input devices in addition to the touch-sensitive surface. In particular, other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 604 may be used to display information input by or provided to the user and various graphical user interfaces of the terminal, which may be made up of graphics, text, icons, video, and any combination thereof. The Display unit 604 may include a Display panel, and optionally, the Display panel may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. Further, the touch-sensitive surface may overlay the display panel, and when a touch operation is detected on or near the touch-sensitive surface, the touch operation is transmitted to the processor 608 to determine the type of touch event, and the processor 608 then provides a corresponding visual output on the display panel according to the type of touch event. Although in FIG. 5 the touch-sensitive surface and the display panel are two separate components to implement input and output functions, in some embodiments the touch-sensitive surface may be integrated with the display panel to implement input and output functions.
The terminal may also include at least one sensor 605, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that may adjust the brightness of the display panel according to the brightness of ambient light, and a proximity sensor that may turn off the display panel and/or the backlight when the terminal is moved to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), detect the magnitude and direction of gravity when the terminal is stationary, and can be used for applications of recognizing terminal gestures (such as horizontal and vertical screen switching, related games, magnetometer gesture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured in the terminal, detailed description is omitted here.
Audio circuitry 606, a speaker, and a microphone may provide an audio interface between the user and the terminal. The audio circuit 606 may transmit the electrical signal converted from the received audio data to a speaker, and convert the electrical signal into a sound signal for output; on the other hand, the microphone converts the collected sound signal into an electric signal, which is received by the audio circuit 606 and converted into audio data, which is then processed by the audio data output processor 608, and then transmitted to, for example, another terminal via the RF circuit 601, or the audio data is output to the memory 602 for further processing. The audio circuit 606 may also include an earbud jack to provide communication of peripheral headphones with the terminal.
WiFi belongs to short-distance wireless transmission technology, and the terminal can help a user to receive and send e-mails, browse webpages, access streaming media and the like through the WiFi module 607, and provides wireless broadband internet access for the user. Although fig. 5 shows the WiFi module 607, it is understood that it does not belong to the essential constitution of the terminal, and may be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 608 is a control center of the terminal, connects various parts of the entire terminal using various interfaces and lines, and performs various functions of the terminal and processes data by operating or executing software programs and/or modules stored in the memory 602 and calling data stored in the memory 602, thereby performing overall monitoring of the terminal. Optionally, processor 608 may include one or more processing cores; preferably, the processor 608 may integrate an application processor, which primarily handles operating systems, user interfaces, applications, etc., and a modem processor, which primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 608.
The terminal also includes a power supply 609 (e.g., a battery) for powering the various components, which may preferably be logically connected to the processor 608 via a power management system that may be used to manage charging, discharging, and power consumption. The power supply 609 may also include any component of one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
Although not shown, the terminal may further include a camera, a bluetooth module, and the like, which will not be described herein. Specifically, in this embodiment, the processor 608 in the terminal loads the executable file corresponding to the process of one or more application programs into the memory 602 according to the following instructions, and the processor 608 runs the application programs stored in the memory 602, thereby implementing various functions:
detecting the transmission speed of the integrated circuit bus when transmitting data; acquiring a level interval corresponding to the transmission speed to obtain a target level interval; detecting the level of the integrated circuit bus when transmitting data to obtain the current level; and if the current level is not in the target level interval, controlling the current level to be in the target level interval.
In some embodiments, before obtaining the level interval corresponding to the transmission speed and obtaining the target level interval, the processor 608 may further perform: acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data; dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals; establishing a corresponding relation between each level subinterval and each transmission speed subinterval; when obtaining the level interval corresponding to the transmission speed and obtaining the target level interval, the processor 608 may further perform: determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed; and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
In some embodiments, when the dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals and the dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals, the processor 608 may further perform: dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and a plurality of level subintervals are obtained; and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
In some embodiments, when detecting a transmission speed of the integrated circuit bus transmitting data, the processor 608 may further perform: detecting a starting time of a first rising edge on a clock line of an integrated circuit bus; detecting a start time of a second rising edge on a clock line of an integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge; and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
In some embodiments, if the current level is not in the target level interval, then controlling the current level to be in the target level interval is followed by the processor 608 further performing: and if the current level is within the target level interval, maintaining the current level so that the integrated circuit bus normally transmits data.
In some embodiments, the detecting the level of the integrated circuit bus transmitting data, and obtaining the current level, the processor 608 may further perform: collecting analog signals when the integrated circuit bus transmits data; converting the analog signal into a digital signal by an analog-to-digital converter; and converting the digital signal into a level to obtain the current level.
In the above embodiments, the descriptions of the embodiments have respective emphasis, and parts that are not described in detail in a certain embodiment may refer to the above detailed description of the data transmission method, and are not described herein again.
It will be understood by those skilled in the art that all or part of the steps of the methods of the above embodiments may be performed by instructions or by associated hardware controlled by the instructions, which may be stored in a computer readable storage medium and loaded and executed by a processor.
To this end, the present application provides a storage medium, in which a computer program is stored, where the computer program can be loaded by a processor to execute any one of the data transmission methods provided in the present application. For example, the computer program is loaded by a processor and may perform the following steps:
detecting the transmission speed of the integrated circuit bus when transmitting data; acquiring a level interval corresponding to the transmission speed to obtain a target level interval; detecting the level of the integrated circuit bus when transmitting data to obtain the current level; and if the current level is not in the target level interval, controlling the current level to be in the target level interval.
In some embodiments, the instructions may further perform the steps of: acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data; dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals; establishing a corresponding relation between each level subinterval and each transmission speed subinterval; the instructions may also perform the steps of: determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed; and determining a level subinterval corresponding to the target transmission speed subinterval according to the corresponding relation to obtain a target level interval.
In some embodiments, the instructions may further perform the steps of: dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and a plurality of level subintervals are obtained; and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
In some embodiments, the instructions may further perform the steps of: detecting a starting time of a first rising edge on a clock line of an integrated circuit bus; detecting a start time of a second rising edge on a clock line of an integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge; and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
In some embodiments, the instructions may further perform the steps of: and if the current level is within the target level interval, maintaining the current level so that the integrated circuit bus normally transmits data.
In some embodiments, the instructions may further perform the steps of: collecting analog signals when the integrated circuit bus transmits data; converting the analog signal into a digital signal by an analog-to-digital converter; and converting the digital signal into a level to obtain the current level.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
Wherein the storage medium may include: read Only Memory (ROM), Random Access Memory (RAM), magnetic or optical disks, and the like.
Since the instructions stored in the storage medium can execute any data transmission method provided in the embodiments of the present application, beneficial effects that can be achieved by any data transmission method provided in the embodiments of the present application can be achieved, for details, see the foregoing embodiments, and are not described herein again.
The data transmission method, the data transmission device, the mobile terminal and the storage medium provided by the embodiments of the present application are described in detail above, and a specific example is applied in the description to explain the principle and the implementation of the present application, and the description of the above embodiments is only used to help understanding the method and the core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (7)

1. A method of data transmission, comprising:
detecting the transmission speed of the integrated circuit bus when transmitting data;
acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data;
dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals, and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals;
establishing a corresponding relation between each level subinterval and each transmission speed subinterval;
determining a target transmission speed subinterval where the transmission speed is located according to the transmission speed;
according to the corresponding relation, determining a level subinterval corresponding to the target transmission speed subinterval to obtain a target level interval;
collecting analog signals when the integrated circuit bus transmits data;
converting the analog signal into a digital signal by an analog-to-digital converter;
converting the digital signal into a level to obtain a current level;
and if the current level is not in the target level interval, controlling the current level to be in the target level interval.
2. The data transmission method of claim 1, wherein the dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals and the dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals comprises:
dividing the level interval into a plurality of non-intersection level subintervals, wherein the union of the plurality of non-intersection level subintervals is equal to the level interval, and a plurality of level subintervals are obtained;
and dividing the transmission speed interval into a plurality of non-intersection transmission speed subintervals, wherein the union of the plurality of non-intersection transmission speed subintervals is equal to the transmission speed subintervals, and a plurality of transmission speed subintervals are obtained.
3. The data transmission method according to claim 1, wherein the detecting a transmission speed of the integrated circuit bus transmitting data comprises:
detecting a starting time of a first rising edge on a clock line of an integrated circuit bus;
detecting a start time of a second rising edge on a clock line of an integrated circuit bus, wherein the start time of the first rising edge lags behind the start time of the second rising edge;
and calculating the time difference between the starting time of the first rising edge and the starting time of the second rising edge, and calculating the transmission speed according to the time difference.
4. The data transmission method according to claim 1, wherein if the current level is not in the target level interval, controlling the current level to be after the target level interval, further comprises:
and if the current level is within the target level interval, maintaining the current level so that the integrated circuit bus normally transmits data.
5. A data transmission apparatus, comprising:
the first detection module is used for detecting the transmission speed of the integrated circuit bus when transmitting data;
the second acquisition module is used for acquiring a level interval and a transmission speed interval when the integrated circuit bus transmits data;
the dividing module is used for dividing the level interval into a plurality of subintervals to obtain a plurality of level subintervals and dividing the transmission speed interval into a plurality of subintervals to obtain a plurality of transmission speed subintervals;
the establishing module is used for establishing a corresponding relation between each level subinterval and each transmission speed subinterval;
the acquisition module is used for acquiring an analog signal when the integrated circuit bus transmits data;
the conversion module is used for converting the analog signal into a digital signal through an analog-to-digital converter;
the current level module is used for converting the digital signal into a level to obtain a current level;
and the control module is used for controlling the current level to be positioned in the target level interval if the current level is not positioned in the target level interval.
6. A mobile terminal, characterized in that it comprises a processor and a memory, in which a computer program is stored, the processor executing the data transmission method according to any one of claims 1 to 4 when it calls the computer program in the memory.
7. A storage medium for storing a computer program which is loaded by a processor to perform the data transfer method of any one of claims 1 to 4.
CN201910895339.5A 2019-09-20 2019-09-20 Data transmission method and device, mobile terminal and storage medium Active CN110688339B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910895339.5A CN110688339B (en) 2019-09-20 2019-09-20 Data transmission method and device, mobile terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910895339.5A CN110688339B (en) 2019-09-20 2019-09-20 Data transmission method and device, mobile terminal and storage medium

Publications (2)

Publication Number Publication Date
CN110688339A CN110688339A (en) 2020-01-14
CN110688339B true CN110688339B (en) 2022-03-25

Family

ID=69109941

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910895339.5A Active CN110688339B (en) 2019-09-20 2019-09-20 Data transmission method and device, mobile terminal and storage medium

Country Status (1)

Country Link
CN (1) CN110688339B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113381898B (en) * 2021-08-16 2021-11-09 深圳市聚视智能系统有限公司 Display module interference removing method and device, computer equipment and storage medium
CN115934450B (en) * 2023-03-08 2023-06-02 苏州浪潮智能科技有限公司 Method and device for detecting data transmission quality, storage medium and electronic device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6487620B1 (en) * 1999-06-11 2002-11-26 Telefonaktiebolaget Lm Ericsson (Publ) Combined low speed and high speed data bus
CN1642035A (en) * 2004-01-14 2005-07-20 索尼公司 Receiving device, receiving method and program
CN103490829A (en) * 2013-10-14 2014-01-01 Tcl通讯(宁波)有限公司 Method and device for preventing radio-frequency (RF) signal interference
KR20140146368A (en) * 2013-06-17 2014-12-26 에스케이하이닉스 주식회사 Input and output device and system including the same
WO2017070597A1 (en) * 2015-10-23 2017-04-27 Qualcomm Incorporated N-phase fast bus turnaround

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5396516A (en) * 1993-02-22 1995-03-07 Qualcomm Incorporated Method and system for the dynamic modification of control paremeters in a transmitter power control system
CN1632948A (en) * 2003-12-22 2005-06-29 上海迪比特实业有限公司 Method for implementing signal transmission between ICs using multilevel technology
CN108170627A (en) * 2017-12-12 2018-06-15 晶晨半导体(上海)股份有限公司 A kind of data transmission method controlled by clock signal

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6487620B1 (en) * 1999-06-11 2002-11-26 Telefonaktiebolaget Lm Ericsson (Publ) Combined low speed and high speed data bus
CN1642035A (en) * 2004-01-14 2005-07-20 索尼公司 Receiving device, receiving method and program
KR20140146368A (en) * 2013-06-17 2014-12-26 에스케이하이닉스 주식회사 Input and output device and system including the same
CN103490829A (en) * 2013-10-14 2014-01-01 Tcl通讯(宁波)有限公司 Method and device for preventing radio-frequency (RF) signal interference
WO2017070597A1 (en) * 2015-10-23 2017-04-27 Qualcomm Incorporated N-phase fast bus turnaround

Also Published As

Publication number Publication date
CN110688339A (en) 2020-01-14

Similar Documents

Publication Publication Date Title
CN106786962B (en) Charging control method and device and terminal
CN104778055B (en) Method and device for displaying progress bar
CN107507628B (en) Singing scoring method, singing scoring device and terminal
CN111681621B (en) Communication method and driving structure of time schedule controller and power management chip
CN108958606B (en) Split screen display method and device, storage medium and electronic equipment
WO2018166204A1 (en) Method for controlling fingerprint recognition module, and mobile terminal and storage medium
CN110688339B (en) Data transmission method and device, mobile terminal and storage medium
CN107734618B (en) Application program closing method and device, storage medium and electronic equipment
US11556158B2 (en) On-the-go (OTG) control and configuration method, mobile terminal, and storage medium
CN109687922B (en) Signal monitoring method and device of wireless network, storage medium and mobile terminal
CN111404242A (en) Charging method, charging device, storage medium and mobile terminal
CN115985323A (en) Voice wake-up method and device, electronic equipment and readable storage medium
JP2019533872A (en) Method and apparatus for interference prevention for touch panel
CN106547400B (en) Method, device and terminal for reporting information
CN112542867B (en) Mobile terminal power supply control method and device, terminal equipment and storage medium
CN114297322A (en) Data processing method, device, terminal and storage medium
CN110995324B (en) Bluetooth communication method, device, storage medium and terminal equipment
CN106155733B (en) Method and device for running application program
CN111966206A (en) Power-saving control method and device for fingerprint sensor and mobile terminal
CN112261634A (en) Bluetooth transmission control method, device, terminal equipment and storage medium
CN111144845A (en) Mobile terminal conference reminding method and device
CN110972221B (en) Communication signal processing method and device and mobile terminal
CN111654578B (en) Mobile terminal sensor restoration method
CN111984107B (en) Method and device for processing power supply abnormity of terminal equipment
CN105279175B (en) Data transmission method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20221220

Address after: 710000 Room 1405, Floor 14, Building 3, West Yungu Phase II, Dongzhang Village, Diaotai Street, Fengxi New City, Xixian New Area, Xi'an, Shaanxi

Patentee after: Xi'an Zhengdatong Information Technology Co.,Ltd.

Address before: 10 / F, No.5 Lane 999, Yangfan Road, high tech Zone, Ningbo City, Zhejiang Province

Patentee before: TCL mobile communication technology (Ningbo) Co.,Ltd.