CN111176854B - Method and system for synchronizing exit of Carplay - Google Patents

Method and system for synchronizing exit of Carplay Download PDF

Info

Publication number
CN111176854B
CN111176854B CN201911151894.3A CN201911151894A CN111176854B CN 111176854 B CN111176854 B CN 111176854B CN 201911151894 A CN201911151894 A CN 201911151894A CN 111176854 B CN111176854 B CN 111176854B
Authority
CN
China
Prior art keywords
state
usb
carplay
vehicle
service
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
CN201911151894.3A
Other languages
Chinese (zh)
Other versions
CN111176854A (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.)
Huizhou Desay SV Intelligent Transport Technology Research Institute Co Ltd
Original Assignee
Huizhou Desay SV Intelligent Transport Technology Research Institute Co 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 Huizhou Desay SV Intelligent Transport Technology Research Institute Co Ltd filed Critical Huizhou Desay SV Intelligent Transport Technology Research Institute Co Ltd
Priority to CN201911151894.3A priority Critical patent/CN111176854B/en
Publication of CN111176854A publication Critical patent/CN111176854A/en
Application granted granted Critical
Publication of CN111176854B publication Critical patent/CN111176854B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/52Program synchronisation; Mutual exclusion, e.g. by means of semaphores

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Telephone Function (AREA)

Abstract

The invention provides a method and a system for the synchronization of the escape of a Carplay, which are mainly improved based on the prior read-write. Therefore, the technical problems that the communication equipment is unreliable to pull out due to overtime judgment of read-write data and the requirement of exiting a Carplay session within 500ms cannot be met due to overlong overtime time of the read-write data are solved.

Description

Method and system for synchronizing exit of Carplay
Technical Field
The invention relates to a vehicle-mounted information entertainment system, in particular to a method and a system for synchronizing the exit of a Carplay.
Background
With the continuous development of vehicle-mounted entertainment systems, more and more applications related to vehicle-mounted usb interconnection are required, in the design flow of the vehicle-mounted usb connection, after the mobile phone is pulled out, the exit of the vehicle-mounted usb connection must be within 500ms, but when the mobile phone is pulled out, the vehicle Service does not know that only the read-write data is overtime, and then the exit of the vehicle is judged by the error of the read-write overtime, but in the using process of the vehicle, the vehicle is quite normal, so that the mobile phone is judged to be unreliable according to the read-write overtime, and a new reliable and stable method for judging the iPhone is required to be found.
Disclosure of Invention
The invention provides a method and a system for synchronizing the card play exit, aiming at solving the technical problems that the read-write data overtime judgment is unreliable in extracting an iPhone mobile phone and the read-write data overtime time is too long to cause that the requirement of exiting the card play session within 500ms cannot be met.
A method for synchronizing exit of a Carplay, comprising the steps of:
after the communication equipment is connected with the USB interface, the enumeration equipment is started.
And starting a USB state detection program, and enabling the USB of the vehicle to enter a suspend state after a preset time.
When the USB of the vehicle machine enters a Default state or an address state, detecting after reaching a time threshold, reading the USB state, judging whether the USB state is a delayed state, if so, sending a REMOVE event, and informing the card Service that the communication equipment is pulled out; otherwise, executing the step (d).
When the USB of the vehicle is in a Configured state, connection of the communication equipment and the Carplay is completed, a Carplay session is started, a USB data reading state is entered until the USB of the vehicle is detected to enter a suspend state, a REMOVE event is sent out, and the Carplay Service is notified that the communication equipment is pulled out.
Preferably, the time threshold is a preset time value, and the time value is 500ms.
Further, notification of the Carplay Service is through a driver UDEV event notification Service.
Preferably, the Service receives notification within 100 ms.
Further, the communication device also comprises a prompt notification information dialog box visually presented at the communication device end.
As another preferred embodiment, the present invention further provides a system for card play out synchronization, including:
and the initialization unit is used for starting to enumerate the equipment after the communication equipment is connected with the USB interface.
And a detection unit: the USB state detection program is used for starting the USB state detection program, and after a preset time, the USB of the vehicle enters a suspend state.
A state judgment unit: and the device is used for matching the working mode according to the detected current state, starting to detect when the USB of the vehicle enters a Default state or an address state, reading the USB state after reaching a time threshold, judging whether the USB state is a delayed state, if so, sending a REMOVE event, and notifying the card Service that the communication equipment is pulled out.
A data reading unit: when the USB of the vehicle is in the Configured state, the connection between the communication equipment and the Carplay is completed, the Carplay session is started, the USB data reading state is entered until the USB of the vehicle is detected to enter the suspend state, a REMOVE event is sent out, and the Carplay Service is notified that the communication equipment is pulled out.
Preferably, the time value is 500ms.
Further, notification of the Carplay Service is through a driver UDEV event notification Service.
Preferably, the Service receives notification within 100 ms.
Further, the communication device also comprises a prompt notification information dialog box visually presented at the communication device end.
The invention provides a method and a system for exiting synchronization of a Carplay, which are mainly based on the improvement of the prior read-write, the prior data connection is mainly based on the read-write timeout to judge whether the connection between a communication device and the Carplay is successful or not, in order to solve the technical problems that the judgment is inaccurate and the requirement of exiting the Carplay session within 500ms cannot be met. The method and the system of the invention are used for judging the data connection state between the communication equipment and the Carplay, and the preset time value of 500ms is used for high-precision control, thereby effectively ensuring the accuracy and the high efficiency of judging the connection state of the USB when mobile equipment such as a mobile phone and the like is connected with the vehicle-mounted entertainment system.
Drawings
FIG. 1 is a flowchart of a method for performing a card play out synchronization according to an embodiment.
FIG. 2 is a schematic diagram of a system for the synchronization of the card play exit in an embodiment.
Detailed Description
The method and system for the synchronization of the Carplay exit of the present invention will be described in further detail with reference to the following embodiments and the accompanying drawings.
In a preferred embodiment, as shown in fig. 1, the core of the present invention is to redesign the method according to the connection flow of the Carplay and the change of the USB state machine during the connection, and further use the UDEV method to determine that the iPhone has been pulled out from the driver layer, and then send a REMOVE event notification Service, and exit the Carplay session after receiving the notification. The method specifically comprises the following steps.
a. After the iPhone mobile enumerates the car, the USB state detection program is started, and the car can enter a suspend state for a period of time.
b. The USB of the vehicle is in a Default state, the detection is delayed for 500ms, the USB state is read, if the USB state is the suspend, a REMOVE event is sent out, and the card Service is notified, and the iPhone mobile phone is pulled out.
c. The USB of the vehicle is in an advanced state, the detection is delayed for 500ms, the USB state is read, if the USB state is in a delayed state, a REMOVE event is sent out, and the card Service is notified, and the iPhone mobile phone is pulled out.
d. The USB of the car machine enters a Configured state, which indicates that the car machine is successfully connected with the card, the USB state is directly read, if the car machine is in a suspend state, a REMOVE event is sent out, and the card Service is notified, and the iPhone mobile phone is pulled out.
e. And (3) pulling out the mobile phone, directly reading the USB state, and if the mobile phone is in a suspend state, sending a REMOVE event to inform the Carplay Service that the iPhone mobile phone is pulled out.
Preferably, the Service receives notification within 100 ms.
Further, the communication device also comprises a prompt notification information dialog box visually presented at the communication device end.
As another embodiment of the invention, the invention also provides a system for the synchronization of the card play exit, which comprises the following parts.
And the initialization unit is used for starting to enumerate the equipment after the communication equipment is connected with the USB interface.
And a detection unit: the USB state detection program is used for starting the USB state detection program, and after a preset time, the USB of the vehicle enters a suspend state.
A state judgment unit: and the device is used for matching the working mode according to the detected current state, starting to detect when the USB of the vehicle enters a Default state or an address state, reading the USB state after reaching a time threshold, judging whether the USB state is a delayed state, if so, sending a REMOVE event, and notifying the card Service that the communication equipment is pulled out.
A data reading unit: when the USB of the vehicle is in the Configured state, the connection between the communication equipment and the Carplay is completed, the Carplay session is started, the USB data reading state is entered until the USB of the vehicle is detected to enter the suspend state, a REMOVE event is sent out, and the Carplay Service is notified that the communication equipment is pulled out.
Preferably, the time value is 500ms.
Further, notification of the Carplay Service is through a driver UDEV event notification Service.
Preferably, the Service receives notification within 100 ms.
Further, the communication device also comprises a prompt notification information dialog box visually presented at the communication device end.
In the embodiment of the present invention, the communication device is preferably one or more mobile communication devices such as an iPhone phone and an ipad, but is not limited thereto.
In summary, the method and system for synchronizing the card play exit provided by the invention detect the USB of the vehicle in the Default state, the address state, and the Configured state respectively, and determine whether the USB is a suspend, and further send a REMOVE event by using a UDEV manner, notify the real-time connection condition of the card play Service and the iPhone phone, and feed back the request to the user through a message prompt dialog box. The invention can meet the requirement of exiting the Carplay session within 500ms, also solves the technical problem of unreliable judgment of the iPhone mobile phone extraction only by overtime of read-write data in the prior art, realizes accurate detection and judgment of the connection condition between the iPhone mobile phone and the Carplay, and greatly improves the technical effect of untimely feedback of the data read-write state.
While the invention has been described in conjunction with the specific embodiments above, it is evident that many alternatives, modifications and variations will be apparent to those skilled in the art in light of the foregoing description. Accordingly, all such alternatives, modifications, and variations are included within the spirit and scope of the following claims.

Claims (9)

1. A method for synchronizing exit of a Carplay, comprising the steps of:
after the communication equipment is connected with the USB interface, starting to enumerate the equipment;
starting a USB state detection program, and enabling the USB of the vehicle to enter a suspend state after a preset time;
when the USB of the vehicle machine enters a Default state or an address state, detecting after reaching a time threshold, reading the USB state, judging whether the USB state is a delayed state, if yes, judging that the communication equipment is pulled out from a driving layer, sending a REMOVE event, and notifying the Carplay Service through driving the UDEV event, wherein the communication equipment is pulled out; otherwise, the USB of the vehicle machine enters a Configured state;
when the USB of the vehicle is in a Configured state, connection of the communication equipment and the Carplay is completed, a Carplay session is started, a USB data reading state is entered until the USB of the vehicle is detected to enter a suspend state, a REMOVE event is sent out, and the Carplay Service is notified that the communication equipment is pulled out.
2. The method of claim 1, wherein the time threshold is a preset time value, the time value being 500ms.
3. The method of claim 1, wherein the Service receives notification within 100 ms.
4. The method of claim 3, further comprising a prompt notification dialog visually presented at the communication device.
5. A system for card play out synchronization comprising the following:
the initialization unit is used for starting to enumerate equipment after the communication equipment is connected with the USB interface;
the detection unit is used for starting a USB state detection program, and after a preset time, the USB of the vehicle machine enters a suspend state;
the state judging unit is used for matching the working modes according to the detected current state, starting to detect when the USB of the vehicle enters a Default state or an address state, reading the USB state, judging whether the USB state is a suspend or not, if so, sending a REMOVE event, notifying the Carplay Service, and extracting the communication equipment;
and the data reading unit is used for starting a Carplay session when the USB of the vehicle is in a Configured state, completing the connection between the communication equipment and the Carplay, and entering a USB data reading state until the USB of the vehicle is detected to be in a suspend state, sending a REMOVE event to inform the Carplay Service that the communication equipment is pulled out.
6. The system of claim 5, wherein the time threshold is a preset time value, the time value being 500ms.
7. The system of claim 5, wherein notification of the carrlay Service is through a drive UDEV event notification Service.
8. The system of claim 7, wherein the Service receives notification within 100 ms.
9. The system of claim 8, further comprising a prompt notification dialog visually presented at the communication device.
CN201911151894.3A 2019-11-22 2019-11-22 Method and system for synchronizing exit of Carplay Active CN111176854B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911151894.3A CN111176854B (en) 2019-11-22 2019-11-22 Method and system for synchronizing exit of Carplay

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911151894.3A CN111176854B (en) 2019-11-22 2019-11-22 Method and system for synchronizing exit of Carplay

Publications (2)

Publication Number Publication Date
CN111176854A CN111176854A (en) 2020-05-19
CN111176854B true CN111176854B (en) 2023-12-29

Family

ID=70647294

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911151894.3A Active CN111176854B (en) 2019-11-22 2019-11-22 Method and system for synchronizing exit of Carplay

Country Status (1)

Country Link
CN (1) CN111176854B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101261607A (en) * 2008-01-24 2008-09-10 北京飞天诚信科技有限公司 Overtime self-closing portable USB device and method
CN104734979A (en) * 2015-04-07 2015-06-24 北京极科极客科技有限公司 Control method for storage device externally connected with router
CN105573939A (en) * 2014-10-10 2016-05-11 深圳市中兴微电子技术有限公司 Method for carrying out data transmission on the basis of universal serial bus, and terminal
CN105760328A (en) * 2016-02-03 2016-07-13 深圳多哚新技术有限责任公司 USB master and slave switching method and system for VR device
CN110381027A (en) * 2019-06-17 2019-10-25 深圳市点嘀互联网络有限公司 Embedded device carries the device and method that carplay agreement connects vehicle device by USB

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4724187B2 (en) * 2008-01-22 2011-07-13 レノボ・シンガポール・プライベート・リミテッド Method and computer for accessing externally connected external storage device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101261607A (en) * 2008-01-24 2008-09-10 北京飞天诚信科技有限公司 Overtime self-closing portable USB device and method
CN105573939A (en) * 2014-10-10 2016-05-11 深圳市中兴微电子技术有限公司 Method for carrying out data transmission on the basis of universal serial bus, and terminal
CN104734979A (en) * 2015-04-07 2015-06-24 北京极科极客科技有限公司 Control method for storage device externally connected with router
CN105760328A (en) * 2016-02-03 2016-07-13 深圳多哚新技术有限责任公司 USB master and slave switching method and system for VR device
CN110381027A (en) * 2019-06-17 2019-10-25 深圳市点嘀互联网络有限公司 Embedded device carries the device and method that carplay agreement connects vehicle device by USB

Also Published As

Publication number Publication date
CN111176854A (en) 2020-05-19

Similar Documents

Publication Publication Date Title
US10068390B2 (en) Method for obtaining product feedback from drivers in a non-distracting manner
CN102890662B (en) By USB HID device is carried out the method that secondary enumerates to identify host operating system
CN105398226B (en) The restorative procedure of ink horn of regeneration, repair chip and ink horn of regeneration
JP2013099246A5 (en)
JP2008165533A (en) Usb device, and control method and program therefor
CN103309834A (en) Control method, control device and electronic device
CN115407116A (en) Method and device for determining charging current
CN111176854B (en) Method and system for synchronizing exit of Carplay
CN106293845A (en) A kind of terminal enters control method and the device of brush machine pattern
CN106250263A (en) The standby processing control apparatus of electronic equipment and standby process control method
CN104077193A (en) Control method and electronic device
US8412146B2 (en) Mutual awakening system and method thereof between a handheld device and a wireless communication module
CN103176877A (en) Method and system for debugging peripheral of embedded device
CN107086634B (en) Vehicle-mounted charging mode control method and device
TW202126053A (en) On-vehicle multimedia device having function of automatically switching master control identification and control method thereof comprising a first connection port and a second connection port for connection with an on-vehicle display device and a control module connected with the first connection port and the second connection port
CN114860520B (en) USB slave equipment extraction detection circuit
CN111383633A (en) Voice recognition continuity control method and device, intelligent terminal and storage medium
CN104463034A (en) Method and device for safely, conveniently and quickly uninstalling external storage device
CN115528768A (en) Charging control method and device
CN114647607A (en) Method for recovering communication interface interruption and communication interface controller
CN101859248B (en) Method for popping out external CD-ROM equipment without caution by Windows operation system
US8423801B2 (en) Electronic device, and method of controlling the electronic device
CN109634906B (en) IC communication system and method
EP2747301A1 (en) Communication program, information processing apparatus, communication system, and communication method
US20110196992A1 (en) Method for dismounting a storage device, and computer program product and electronic apparatus for implementing the method

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