CN113423093B - Bluetooth communication method and system based on vehicle-mounted terminal - Google Patents

Bluetooth communication method and system based on vehicle-mounted terminal Download PDF

Info

Publication number
CN113423093B
CN113423093B CN202110568499.6A CN202110568499A CN113423093B CN 113423093 B CN113423093 B CN 113423093B CN 202110568499 A CN202110568499 A CN 202110568499A CN 113423093 B CN113423093 B CN 113423093B
Authority
CN
China
Prior art keywords
message
vehicle
mounted terminal
standard
sequence number
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
CN202110568499.6A
Other languages
Chinese (zh)
Other versions
CN113423093A (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.)
Jiangling Motors Corp Ltd
Original Assignee
Jiangling Motors Corp 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 Jiangling Motors Corp Ltd filed Critical Jiangling Motors Corp Ltd
Priority to CN202110568499.6A priority Critical patent/CN113423093B/en
Publication of CN113423093A publication Critical patent/CN113423093A/en
Application granted granted Critical
Publication of CN113423093B publication Critical patent/CN113423093B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/30Services specially adapted for particular environments, situations or purposes
    • H04W4/40Services specially adapted for particular environments, situations or purposes for vehicles, e.g. vehicle-to-pedestrians [V2P]
    • H04W4/48Services specially adapted for particular environments, situations or purposes for vehicles, e.g. vehicle-to-pedestrians [V2P] for in-vehicle communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/02Arrangements for optimising operational condition
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Abstract

The invention provides a Bluetooth communication method and a system based on a vehicle-mounted terminal, wherein the method comprises the steps of establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number; judging whether the initial field length of the message sequence number is larger than the preset standard field length through an MTU (maximum Transmission Unit); if yes, carrying out segmentation processing on the initial field of the message serial number; and converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU, and sending the preset standard field formats to the vehicle-mounted terminal. By the method, the formats of the message header, the message body and the message serial number can be subjected to standardized constraint, so that the time for sending the information is shortened, the smoothness of message sending is improved, the time for automobile reaction is shortened, and the use experience of a user is improved.

Description

Bluetooth communication method and system based on vehicle-mounted terminal
Technical Field
The invention relates to the technical field of automobiles, in particular to a Bluetooth communication method and system based on a vehicle-mounted terminal.
Background
With the progress of science and technology and the rapid development of productivity, automobiles have been popularized in the lives of people, and meanwhile, the automobiles also become one of indispensable transportation tools for people to go out, so that the automobiles are convenient for the lives of people.
The existing automobile is provided with a Bluetooth function after leaving the factory so as to increase the interactivity between a driver or a passenger and the automobile.
However, the fluency of information interaction between the existing vehicle-mounted bluetooth and the mobile terminal is low, so that the time of automobile reaction is increased, and the use experience of a user is reduced.
Disclosure of Invention
Based on this, the invention aims to provide a vehicle-mounted terminal-based bluetooth communication method and system, so as to solve the problem that the smoothness of information interaction between vehicle-mounted bluetooth and a mobile terminal is low in the prior art, so that the response time of an automobile is increased.
A Bluetooth communication method based on a vehicle-mounted terminal comprises the following steps:
establishing Bluetooth communication connection with a vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number;
judging whether the initial field length of the message sequence number is larger than the preset standard field length through an MTU (maximum Transmission Unit);
if yes, carrying out segmentation processing on the initial field of the message sequence number;
and converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU, and sending the preset standard field formats to the vehicle-mounted terminal.
The invention has the beneficial effects that: the initial field of the message serial number is processed in a segmented mode and is simultaneously sent to the vehicle-mounted terminal, so that the sending time of the message serial number can be shortened, the sending smoothness of the message serial number is improved, and the reaction time of an automobile is correspondingly shortened; in addition, the field formats of the message header, the message body and the message serial number are all converted into the preset standard field format, so that the standardized constraint can be carried out on the formats of the message header, the message body and the message serial number, the time for sending the information is shortened, the smoothness for sending the message header, the message body and the message serial number is improved, the time for automobile reaction is further shortened, and the use experience of a user is improved.
Preferably, the step of establishing a bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal includes:
when a Bluetooth signal of the vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
judging whether the request instruction is in the acceptance range of the Bluetooth module;
if so, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
Preferably, the step of determining whether the field length of the message body is greater than a preset length through the MTU includes:
comparing the initial field length of the message sequence number with a standard field length preset in the MTU;
when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal;
and when the initial field length of the message sequence number is greater than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number.
Preferably, the step of performing segmentation processing on the initial field of the message sequence number includes:
equally dividing an initial field of the message sequence number into a plurality of standard field units;
and sequentially decreasing the labels of a plurality of standard field units.
Preferably, the step of converting the field formats of the message header, the message body and the message sequence number into preset standard field formats through the MTU and sending the preset standard field formats to the vehicle-mounted terminal includes:
a standard field format list is preset in the MTU, and the standard field format list comprises a standard message header, a standard message body and a standard message sequence number;
and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
Another object of the present invention is to provide a bluetooth communication system based on a vehicle-mounted terminal, the system comprising:
the communication module is used for establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number;
the judging module is used for judging whether the initial field length of the message serial number is greater than the preset standard field length through the MTU;
the processing module is used for carrying out segmentation processing on the initial field of the message sequence number if the initial field length of the message sequence number is greater than the preset standard field length;
and the conversion module is used for converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU and sending the preset standard field formats to the vehicle-mounted terminal.
In the bluetooth communication system based on the vehicle-mounted terminal, the communication module is specifically configured to:
when a Bluetooth signal of a vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
judging whether the request instruction is in the acceptance range of the Bluetooth module;
if so, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
In the above bluetooth communication system based on the vehicle-mounted terminal, the determining module is specifically configured to:
comparing the initial field length of the message sequence number with a standard field length preset in the MTU;
when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal;
and when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number.
In the above bluetooth communication system based on the vehicle-mounted terminal, the determining module is specifically configured to:
equally dividing an initial field of the message sequence number into a plurality of standard field units;
and sequentially decreasing the labels of a plurality of standard field units.
In the above bluetooth communication system based on the vehicle-mounted terminal, the conversion module is specifically configured to:
a standard field format list is preset in the MTU, and the standard field format list comprises a standard message header, a standard message body and a standard message sequence number;
and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
Additional aspects and advantages of the invention will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the invention.
Drawings
Fig. 1 is a flowchart of a bluetooth communication method based on a vehicle-mounted terminal according to a first embodiment of the present invention;
fig. 2 is a flowchart of a bluetooth communication method based on a vehicle-mounted terminal according to a second embodiment of the present invention;
fig. 3 is a block diagram of a bluetooth communication system based on a vehicle-mounted terminal according to a third embodiment of the present invention.
The following detailed description will further illustrate the invention in conjunction with the above-described figures.
Detailed Description
To facilitate an understanding of the invention, the invention will now be described more fully with reference to the accompanying drawings. Several embodiments of the invention are shown in the drawings. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete.
It will be understood that when an element is referred to as being "secured to" another element, it can be directly on the other element or intervening elements may also be present. When an element is referred to as being "connected" to another element, it can be directly connected to the other element or intervening elements may also be present. The terms "vertical," "horizontal," "left," "right," and the like as used herein are for illustrative purposes only.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
The information interaction fluency between the existing vehicle-mounted Bluetooth and the mobile terminal is low, so that the automobile reaction time is prolonged, and the use experience of a user is reduced.
Referring to fig. 1, a bluetooth communication method based on a vehicle-mounted terminal according to a first embodiment of the present invention is specifically applied between a mobile terminal, the vehicle-mounted terminal, and an MTU (maximum transmission module), where the mobile terminal may be an electronic device such as a mobile phone, a tablet, and a notebook computer, and the vehicle-mounted terminal is a vehicle controller.
Specifically, in this embodiment, the bluetooth communication method based on the vehicle-mounted terminal includes the following steps:
step S10, establishing Bluetooth communication connection with a vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number;
specifically, in this embodiment, the mobile terminal is a mobile phone, and the vehicle-mounted terminal is a vehicle control unit, and in implementation, it can be understood that the mobile terminal and the vehicle-mounted terminal are both pre-installed with a bluetooth communication function, so that a user can establish a bluetooth communication connection with the vehicle-mounted terminal through the mobile terminal, so that the mobile terminal can send a data packet to the vehicle-mounted terminal, and more specifically, the data packet includes a message header, a message body, and a message serial number.
Step S20, judging whether the initial field length of the message serial number is larger than the preset standard field length through the MTU;
specifically, in this embodiment, it should be noted that the data packet sent by the mobile terminal will first pass through the MTU and then be sent by the MTU to the vehicle-mounted terminal, so when the mobile terminal sends the data packet, the MTU will first determine whether the initial field length of the message sequence number in the data packet is greater than the preset standard field length.
In addition, a standard field length is preset in the MTU, and the standard field length is a reasonable field length range that the vehicle-mounted terminal can receive quickly. In this embodiment, when the initial field length of the message sequence number is greater than the preset standard field length, step S30 is performed.
Step S30, if yes, the initial field of the message sequence number is processed in a segmented mode;
if not, the message serial number is directly sent to the vehicle-mounted terminal.
It can be understood that, when the initial field length of the message sequence number is greater than the standard field length, the MTU performs segmentation processing on the portion of the initial field length exceeding the standard field length, so that the initial field length of each segment is within the standard field length range, and the vehicle-mounted terminal can quickly receive the data packet sent by the mobile terminal;
in addition, when the initial field length of the message serial number is smaller than the standard field length, the message serial number is directly transmitted to the vehicle-mounted terminal, so that the vehicle-mounted terminal can quickly receive the data packet transmitted by the mobile terminal.
And step S40, converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU, and sending the preset standard field formats to the vehicle-mounted terminal.
Specifically, in this embodiment, when the MTU receives the message header, the message body, and the message serial number, the MTU can respectively recognize the field formats of the message header, the message body, and the message serial number, respectively convert the field formats of the message header, the message body, and the message serial number into the preset standard field format, and send the converted field format to the vehicle-mounted terminal.
When the method is used, the initial field of the message serial number is processed in a segmented mode and is simultaneously sent to the vehicle-mounted terminal, so that the sending time of the message serial number can be shortened, the sending smoothness of the message serial number is improved, and the response time of an automobile is correspondingly shortened; in addition, the field formats of the message header, the message body and the message serial number are all converted into the preset standard field format, so that the standardized constraint can be carried out on the formats of the message header, the message body and the message serial number, the time for sending the information is shortened, the smoothness for sending the message header, the message body and the message serial number is improved, the time for automobile reaction is further shortened, and the use experience of a user is improved.
It should be noted that the implementation procedure described above is only for illustrating the applicability of the present application, but this does not represent that the vehicle-mounted terminal based bluetooth communication method of the present application has only the above-mentioned one implementation procedure, and on the contrary, the vehicle-mounted terminal based bluetooth communication method of the present application can be incorporated into a feasible implementation scheme of the present application as long as the vehicle-mounted terminal based bluetooth communication method of the present application can be implemented.
In summary, the bluetooth communication method based on the vehicle-mounted terminal in the embodiments of the present invention can perform standardized restriction on formats of the message header, the message body, and the message serial number, shorten the time for sending the information, improve the smoothness for sending the message header, the message body, and the message serial number, further shorten the time for vehicle reaction, and improve the user experience.
Referring to fig. 2, a bluetooth communication method based on a vehicle-mounted terminal according to a second embodiment of the present invention is shown, which includes the following steps:
step S11, when a Bluetooth signal of the vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
specifically, in this embodiment, the mobile terminal is a mobile phone, and the vehicle-mounted terminal is a vehicle control unit, and in implementation, it can be understood that bluetooth communication modules are pre-installed in both the mobile terminal and the vehicle-mounted terminal to implement a bluetooth communication function.
Therefore, when the mobile terminal approaches the vehicle-mounted terminal, the mobile terminal can detect a bluetooth signal of the vehicle-mounted terminal, and the user can send a request instruction for establishing bluetooth connection to a bluetooth module of the vehicle-mounted terminal.
Step S21, judging whether the request instruction is in the acceptance range of the Bluetooth module;
it can be understood that the existing mobile terminals and vehicle-mounted terminals have various models, and only the adapted mobile terminal and vehicle-mounted terminal can establish bluetooth communication connection with each other, so that when the vehicle-mounted terminal receives a request instruction sent by the mobile terminal, it is immediately determined whether the request instruction is within the acceptance range of the bluetooth module in the vehicle-mounted terminal, and if so, step S31 is executed.
And S31, if yes, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
If not, refusing to receive the request instruction of the mobile terminal, namely the current mobile terminal can not establish communication connection with the current vehicle-mounted terminal.
Step S41, comparing the initial field length of the message serial number with the standard field length preset in the MTU; when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal; and when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number.
Specifically, the working principle of this step is similar to that of step S30, and when receiving a data packet sent by the mobile terminal, the MTU can identify the initial field length of the message sequence number in the data packet, and compare the initial field length of the message sequence number with the standard field length preset in the MTU.
When the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal; and when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number.
Step S51, equally dividing the initial field of the message serial number into a plurality of standard field units; and sequentially and progressively reducing the labels of a plurality of standard field units.
Specifically, in this embodiment, when the initial field length of the message sequence number is greater than the standard field length preset in the MTU, the initial field length of the message sequence number is segmented.
And dividing the initial field of the message sequence number into a plurality of standard field units at equal intervals, and sequentially decrementing the standard field units to label the standard field units. That is, when the initial field of the message sequence number needs to be segmented, the sequence number of each segment of message is set as 0xF0+ (number of segments), the following sequence number of each segment of message is sequentially subtracted by 1 for the number of segments, and when the sequence number is subtracted to 0x01, it is indicated that the sequence number is the last segment of message sequence number:
namely: 0xF0+ (number of packets) → 0xF0+ (number of packets-1) → 0xF0+ (number of packets-2) → 0xF0+ (number of packets-n) → 8230; → 0x01.
For example, when the initial field of the message sequence number needs to be divided into 5 segments, that is, each segment is numbered as: 0xF5 → 0x04 → 0x03 → 0x02 → 0x01.
Step S61, presetting a standard field format list in the MTU, wherein the standard field format list comprises a standard message header, a standard message body and a standard message sequence number; and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
Specifically, in this embodiment, in order to constrain the field formats of the message header, the message body, and the message sequence number in the data packet, a standard field format list is preset in the MTU, and the standard field format list includes the standard message header, the standard message body, and the standard message sequence number.
In implementation, the MTU replaces the initial formats of the message header, the message body and the message serial number in sequence through the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
It should be noted that, the method provided by the second embodiment of the present invention, which has the same implementation principle and produces some technical effects as the first embodiment, for the sake of brief description, the corresponding contents in the first embodiment may be referred to where this embodiment is not mentioned.
In summary, the bluetooth communication method based on the vehicle-mounted terminal in the embodiments of the present invention can perform standardized restriction on formats of the message header, the message body, and the message serial number, shorten the time for sending the information, improve the smoothness for sending the message header, the message body, and the message serial number, further shorten the time for vehicle reaction, and improve the user experience.
Referring to fig. 3, a bluetooth communication system based on a vehicle-mounted terminal according to a third embodiment of the present invention is shown, and the system specifically includes:
the communication module 12 is configured to establish a bluetooth communication connection with a vehicle-mounted terminal and send a data packet to the vehicle-mounted terminal, where the data packet includes a message header, a message body, and a message sequence number;
the judging module 22 is configured to judge whether the initial field length of the message sequence number is greater than a preset standard field length through the MTU;
a processing module 32, configured to perform a segmentation process on the initial field of the message sequence number if the initial field length of the message sequence number is greater than a preset standard field length;
and the conversion module 42 is configured to convert the field formats of the message header, the message body, and the message sequence number into preset standard field formats through the MTU, and send the preset standard field formats to the vehicle-mounted terminal.
In the above bluetooth communication system based on the vehicle-mounted terminal, the communication module 12 is specifically configured to:
when a Bluetooth signal of the vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
judging whether the request instruction is in the acceptance range of the Bluetooth module;
if yes, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
In the above bluetooth communication system based on the vehicle-mounted terminal, the determining module 22 is specifically configured to:
comparing the initial field length of the message sequence number with a standard field length preset in the MTU;
when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal;
and when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number.
In the above bluetooth communication system based on the vehicle-mounted terminal, the determining module 22 is specifically configured to:
equally dividing an initial field of the message sequence number into a plurality of standard field units;
and sequentially decreasing the labels of a plurality of standard field units.
In the above bluetooth communication system based on the vehicle-mounted terminal, the conversion module 32 is specifically configured to:
a standard field format list is preset in the MTU, and comprises a standard message header, a standard message body and a standard message sequence number;
and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
In summary, the bluetooth communication method and system based on the vehicle-mounted terminal in the embodiments of the present invention can perform standardized restriction on formats of the message header, the message body, and the message serial number, shorten the time for sending the information, improve the smoothness for sending the message header, the message body, and the message serial number, further shorten the time for vehicle reaction, and improve the user experience.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Further, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following technologies, which are well known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent should be subject to the appended claims.

Claims (4)

1. A Bluetooth communication method based on a vehicle-mounted terminal is characterized by comprising the following steps:
establishing Bluetooth communication connection with a vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number;
judging whether the initial field length of the message sequence number is larger than a preset standard field length through an MTU (maximum Transmission Unit);
if yes, carrying out segmentation processing on the initial field of the message sequence number;
converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU and sending the preset standard field formats to the vehicle-mounted terminal;
the step of judging whether the field length of the message body is greater than a preset length through the MTU comprises the following steps:
comparing the initial field length of the message sequence number with a standard field length preset in the MTU;
when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal;
when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number;
the step of performing segmentation processing on the initial field length of the message sequence number comprises:
equally dividing an initial field of the message sequence number into a plurality of standard field units;
sequentially decreasing the labels of the plurality of standard field units;
the step of sequentially decrementing the labels for the plurality of standard field units comprises:
setting the message sequence number of each segment as 0xF0+ segment number, and subtracting 1 from the segment number in sequence by the sequence number of each following segment, wherein the sequence number is the last segment of message sequence number when the sequence number is subtracted to 0x 01:
0xF0+ number of packets → 0xF0+ number of packets-1 → 0xF0+ number of packets-2 → 0xF0+ number of packets-n → 8230; → 0x01;
the step of converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU and sending the preset standard field formats to the vehicle-mounted terminal comprises the following steps:
a standard field format list is preset in the MTU, and comprises a standard message header, a standard message body and a standard message sequence number;
and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
2. The vehicle-mounted terminal based bluetooth communication method according to claim 1, wherein: the step of establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal comprises the following steps:
when a Bluetooth signal of the vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
judging whether the request instruction is within the acceptance range of the Bluetooth module;
if so, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
3. A Bluetooth communication system based on a vehicle-mounted terminal, the system comprising:
the communication module is used for establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal, wherein the data packet comprises a message header, a message body and a message serial number;
the judging module is used for judging whether the initial field length of the message serial number is greater than the preset standard field length through the MTU;
the processing module is used for carrying out segmentation processing on the initial field of the message sequence number if the initial field length of the message sequence number is greater than the preset standard field length;
the conversion module is used for converting the field formats of the message header, the message body and the message serial number into preset standard field formats through the MTU and sending the preset standard field formats to the vehicle-mounted terminal;
the judgment module is specifically configured to:
comparing the initial field length of the message sequence number with a standard field length preset in the MTU;
when the initial field length of the message serial number is smaller than the standard field length preset in the MTU, the message serial number is directly sent to the vehicle-mounted terminal;
when the initial field length of the message sequence number is larger than the standard field length preset in the MTU, carrying out segmentation processing on the initial field length of the message sequence number;
equally dividing an initial field of the message sequence number into a plurality of standard field units;
sequentially decreasing the labels of the plurality of standard field units;
the judging module is further configured to:
setting the message sequence number of each segment as 0xF0+ segment number, and subtracting 1 from the segment number of each subsequent segment, wherein when the message sequence number is subtracted to 0x01, the message sequence number is the last segment:
0xF0+ packet → 0xF0+ packet-1 → 0xF0+ packet-2 → 0xF0+ packet-n → 8230; → 0x01;
the conversion module is specifically configured to:
a standard field format list is preset in the MTU, and comprises a standard message header, a standard message body and a standard message sequence number;
and when the MTU receives the message header, the message body and the message serial number, sequentially replacing the initial formats of the message header, the message body and the message serial number by the standard message header, the standard message body and the standard message serial number so as to convert the message header, the message body and the message serial number into a preset standard field format and send the preset standard field format to the vehicle-mounted terminal.
4. The vehicle terminal-based bluetooth communication system according to claim 3, wherein: the communication module is specifically configured to:
when a Bluetooth signal of the vehicle-mounted terminal is detected, a request instruction for establishing Bluetooth connection is sent to a Bluetooth module of the vehicle-mounted terminal;
judging whether the request instruction is within the acceptance range of the Bluetooth module;
if so, establishing Bluetooth communication connection with the vehicle-mounted terminal and sending a data packet to the vehicle-mounted terminal.
CN202110568499.6A 2021-05-25 2021-05-25 Bluetooth communication method and system based on vehicle-mounted terminal Active CN113423093B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110568499.6A CN113423093B (en) 2021-05-25 2021-05-25 Bluetooth communication method and system based on vehicle-mounted terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110568499.6A CN113423093B (en) 2021-05-25 2021-05-25 Bluetooth communication method and system based on vehicle-mounted terminal

Publications (2)

Publication Number Publication Date
CN113423093A CN113423093A (en) 2021-09-21
CN113423093B true CN113423093B (en) 2023-04-14

Family

ID=77712809

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110568499.6A Active CN113423093B (en) 2021-05-25 2021-05-25 Bluetooth communication method and system based on vehicle-mounted terminal

Country Status (1)

Country Link
CN (1) CN113423093B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113873486B (en) * 2021-09-23 2022-07-12 上海山景集成电路股份有限公司 Bluetooth communication method, communication equipment and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104135339A (en) * 2014-07-08 2014-11-05 福建联迪商用设备有限公司 Bluetooth low-power-consumption communication method, Bluetooth equipment and system
WO2017217579A1 (en) * 2016-06-17 2017-12-21 엘지전자(주) Mobile terminal
US10542574B1 (en) * 2017-11-15 2020-01-21 Amazon Technologies, Inc. Wireless device connection handover
CN111654450A (en) * 2020-05-28 2020-09-11 北京小米移动软件有限公司 Data transmission method and device and storage medium

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7483376B2 (en) * 2004-06-17 2009-01-27 International Business Machines Corporation Method and apparatus for discovering path maximum transmission unit (PMTU)
CN101226700A (en) * 2008-01-28 2008-07-23 哈尔滨工业大学 Teaching experimental approach for slicing and regrouping process of IP datagram
CN103248452B (en) * 2012-02-10 2017-02-15 宇龙计算机通信科技(深圳)有限公司 Data sending device, data receiving device, terminal and data transmission method
CN102629263B (en) * 2012-02-29 2014-08-20 上海安捷力信息系统有限公司 Method and system for format conversion of interactive business data among enterprises
CN103391289A (en) * 2013-07-16 2013-11-13 中船重工(武汉)凌久高科有限公司 Multilink safety communication method based on completion port model
US10742541B2 (en) * 2016-07-26 2020-08-11 Nokia Of America Corporation Systems and methods for multi-path communication over multiple radio access technologies
CN107592608A (en) * 2017-09-20 2018-01-16 诚迈科技(南京)股份有限公司 A kind of schedule synchronization electronic equipment and terminal, method for schedule synchronization
CN110365609B (en) * 2018-04-10 2021-12-14 华为技术有限公司 Data packet segmentation method and device
CN110191439B (en) * 2019-06-06 2022-07-12 广州小鹏汽车科技有限公司 Vehicle data transmission system and method
EP3783932B1 (en) * 2019-08-23 2022-09-21 Nokia Solutions and Networks Oy Receiving vehicular communication messages
CN111355704B (en) * 2020-01-09 2022-04-29 重庆高开清芯智联网络科技有限公司 IPV6 network system based on bluetooth low-power consumption
CN111277988B (en) * 2020-03-17 2023-06-23 北京百瑞互联技术有限公司 Method for improving Bluetooth transmission speed of WeChat applet

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104135339A (en) * 2014-07-08 2014-11-05 福建联迪商用设备有限公司 Bluetooth low-power-consumption communication method, Bluetooth equipment and system
WO2017217579A1 (en) * 2016-06-17 2017-12-21 엘지전자(주) Mobile terminal
US10542574B1 (en) * 2017-11-15 2020-01-21 Amazon Technologies, Inc. Wireless device connection handover
CN111654450A (en) * 2020-05-28 2020-09-11 北京小米移动软件有限公司 Data transmission method and device and storage medium

Also Published As

Publication number Publication date
CN113423093A (en) 2021-09-21

Similar Documents

Publication Publication Date Title
CN110386064B (en) Control system and method of vehicle-mounted camera, vehicle-mounted equipment and automobile
CN110545220B (en) Automobile diagnosis protocol detection method and related product
CN113423093B (en) Bluetooth communication method and system based on vehicle-mounted terminal
CN111627435A (en) Voice recognition method and system and control method and system based on voice instruction
CN105357178A (en) Login method for vehicle-mounted terminal and vehicle-mounted terminal
CN105067831A (en) CAN-bus rotating speed sensor and data processing method based on CAN bus
CN110784846B (en) Vehicle-mounted Bluetooth equipment identification method and device, electronic equipment and storage medium
CN114103848B (en) Vehicle control method, vehicle control device, vehicle, and storage medium
CN111836213A (en) Vehicle communication method, vehicle, and computer-readable storage medium
CN110662191B (en) Communication mode selection method and device and electronic equipment
CN203225896U (en) Control system based on interconnection of mobile phone and vehicle terminal
CN112765199A (en) Vehicle detection method and system and readable storage medium
US20230161304A1 (en) Method and system for interaction between vehicle and smart device
CN111913472A (en) Operation mode control method of vehicle diagnostic device and related device
CN116449092A (en) Automobile power detection method, system, computer and readable storage medium
CN115080085A (en) Method and system for solving EOL calibration in OEM
CN107205241B (en) Wireless communication detection method and equipment thereof
CN114220198A (en) Automatic activation method, system, computer and readable storage medium for Bluetooth key
KR20090059277A (en) System and method for automatically setting driver service device using portable communication apparatus
CN105786555B (en) The initial method and device of demodulator and tuner
CN112364042A (en) Vehicle type configuration method and system and readable storage medium
CN113220328A (en) Upgrading method and device, computer equipment and storage medium
CN112109723A (en) Plug and play method and device for vehicle automatic driving module and storage medium
CN109976812B (en) Vehicle starting method and system, vehicle and device with storage function
CN105472121A (en) System and method for automatically starting mobile phone vehicle-borne mode

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