Application debugging method and device, equipment and storage medium

By switching the upstream and downstream port modes of the hub, the application debugging of the vehicle-side equipment is realized, which solves the problems caused by the reservation of debugging lines and the removal of baffles, and improves the safety and convenience of debugging.

CN120353208APending Publication Date: 2025-07-22RUILIAN XINGCHEN (BEIJING) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410058416.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-01-15
Publication Date
2025-07-22

AI Technical Summary

Technical Problem

In the prior art, the debugging process of vehicle-side equipment requires the reservation of debugging lines or the removal of baffles, resulting in confusion of lines, increased installation costs and safety risks, and inconvenient debugging.

Method used

By switching the upstream and downstream ports of the hub, data transmission mode switching is achieved, avoiding the reservation of debug lines and removal of baffles, and using the hub to transmit data in different modes to receive and send debugging data, and perform debugging of target applications.

Benefits of technology

Reduces installation and material costs, improves the safety and convenience of application debugging, and simplifies the debugging process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120353208A_ABST
    Figure CN120353208A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an application debugging method and device, equipment and a storage medium. The application debugging method comprises the steps that at a first device, in response to a received debugging instruction for a target application in the first device, a first mode switching instruction is sent to a hub to instruct the hub to be switched from a first mode to a second mode, and the hub is used for connecting the first device and a second device, the hub is used for sending data from the first equipment to the second equipment in the first mode, and the hub is used for sending data from the second equipment to the first equipment in the second mode; receiving debug data from the second device via the hub in the second mode; and debugging the target application based on the debugging data. In this way, application debugging can be achieved by switching the upstream port and the downstream port of the hub, and application debugging safety and convenience can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Example embodiments of the present disclosure generally relate to the field of computers, and particularly to methods, apparatuses, devices, and computer-readable storage media for application debugging. Background Art

[0002] With the continuous development of social economy and vehicle technology, vehicles have become essential transportation equipment in people's lives. Vehicle-side devices (such as in-vehicle infotainment systems) are often installed on vehicles. To ensure driving safety, it may be necessary to debug the vehicle-side devices (which can also be referred to as in-vehicle infotainment system debugging). The object of debugging can be an application installed at the vehicle-side device. It is desired to conveniently and quickly implement the debugging of the application at the vehicle-side device. Summary of the Invention

[0003] In a first aspect of the present disclosure, there is provided an application debugging method. The method includes: at a first device, in response to receiving a debugging instruction for a target application in the first device, sending a first mode switching instruction to a hub to instruct the hub to switch from a first mode to a second mode, where the hub is used to connect the first device and a second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; receiving debugging data from the second device via the hub in the second mode; and performing debugging on the target application based on the debugging data.

[0004] In a second aspect of the present disclosure, there is provided an application debugging method. The method includes: at the hub, in response to receiving the first mode switching instruction, switching from the first mode to the second mode, where the hub is used to connect the first device and the second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; receiving debugging data from the second device in the second mode; and sending the debugging data to the first device in the second mode for performing debugging on the target application in the first device.

[0005] In a third aspect of the present disclosure, there is provided an apparatus for application debugging. The apparatus includes: a first instruction sending module configured to, at a first device, in response to receiving a debugging instruction for a target application in the first device, send a first mode switching instruction to a hub to instruct the hub to switch from the first mode to the second mode, where the hub is used to connect the first device and the second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; a debugging data receiving module configured to receive debugging data from the second device via the hub in the second mode; and a debugging execution module configured to perform debugging on the target application based on the debugging data.

[0006] In a fourth aspect of the present disclosure, there is provided an apparatus for application debugging. The apparatus includes: a mode switching module configured to switch from a first mode to a second mode at a hub in response to receiving a first mode switching instruction, the hub being used to connect a first device and a second device, the hub being used to send data from the first device to the second device in the first mode, and the hub being used to send data from the second device to the first device in the second mode; a data receiving module configured to receive debugging data from the second device in the second mode; and a data sending module configured to send the debugging data to the first device in the second mode for performing debugging on a target application in the first device.

[0007] In a fifth aspect of the present disclosure, there is provided an electronic device. The device includes at least one processing unit; and at least one memory, the at least one memory being coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit. When executed by the at least one processing unit, the instructions cause the device to execute the method of the first aspect or execute the method of the second aspect.

[0008] In a sixth aspect of the present disclosure, there is provided a computer-readable storage medium. A computer program is stored on the computer-readable storage medium, and the computer program can be executed by a processor to implement the method of the first aspect or implement the method of the second aspect.

[0009] It should be understood that the content described in the present invention content section is not intended to limit the key features or important features of the embodiments of the present disclosure, nor is it used to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] In combination with the drawings and with reference to the following detailed description, the above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent. In the drawings, the same or similar reference numerals denote the same or similar elements, where:

[0011] Figure 1 A schematic diagram of an example environment in which the embodiments of the present disclosure can be implemented is shown;

[0012] Figure 2 A flowchart of an information flow for application debugging according to some embodiments of the present disclosure is shown;

[0013] Figure 3 A schematic diagram of an example framework for application debugging according to some embodiments of the present disclosure is shown;

[0014] Figure 4 A flowchart of a process of application debugging according to some embodiments of the present disclosure is shown;

[0015] Figure 5 A flowchart showing the process of application debugging according to other embodiments of the present disclosure;

[0016] Figure 6 A schematic structural block diagram of a device for application debugging according to some embodiments of the present disclosure;

[0017] Figure 7 A schematic structural block diagram of a device for application debugging according to other embodiments of the present disclosure; and

[0018] Figure 8 A block diagram of an electronic device in which one or more embodiments of the present disclosure can be implemented. Detailed implementation manners

[0019] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although some embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to more thoroughly and completely understand the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not used to limit the protection scope of the present disclosure.

[0020] It should be noted that the titles of any sections / subsections provided herein are not restrictive. Various embodiments are described throughout this document, and any type of embodiment can be included under any section / subsection. In addition, the embodiments described in any section / subsection can be combined with any other embodiments described in the same section / subsection and / or different sections / subsections in any manner.

[0021] In the description of the embodiments of the present disclosure, the term "comprising" and its like should be understood as an open inclusion, that is, "including but not limited to". The term "based on" should be understood as "at least partially based on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The term "some embodiments" should be understood as "at least some embodiments". There may also be other explicit and implicit definitions hereinafter. The terms "first", "second", etc. may refer to different or the same objects. There may also be other explicit and implicit definitions hereinafter.

[0022] The term "in response to" means that the corresponding event occurs or the condition is satisfied. It will be understood that the timing of the subsequent action executed in response to the event or condition and the time when the event occurs or the condition is satisfied are not necessarily strongly correlated. In some cases, the subsequent action can be executed immediately when the event occurs or the condition holds; in other cases, the subsequent action can also be executed after a period of time after the event occurs or the condition holds.

[0023] Embodiments of the present disclosure may involve user data, data acquisition, and / or use, etc. These aspects all comply with the corresponding laws, regulations, and related provisions. In the embodiments of the present disclosure, the collection, acquisition, processing, processing, forwarding, use, etc. of all data are carried out on the premise that the user is aware and has confirmed. Accordingly, when implementing the embodiments of the present disclosure, the types, usage scopes, usage scenarios, etc. of the data or information that may be involved should be informed to the user and the user's authorization should be obtained through appropriate means in accordance with relevant laws and regulations. The specific informing and / or authorization methods may vary according to the actual situation and application scenarios, and the scope of the present disclosure is not limited in this regard.

[0024] For the solutions described in this specification and the embodiments, if they involve personal information processing, they will all be processed on the premise of having a legal basis (such as obtaining the consent of the personal information subject, or being necessary for performing a contract, etc.), and will only be processed within the specified or agreed scope. The user's refusal to process personal information other than the necessary information required for the basic functions will not affect the user's use of the basic functions.

[0025] As discussed above, with the continuous development of social economy and vehicle technology, vehicles have become an essential transportation device in people's lives. Vehicle-side devices (such as in-vehicle infotainment systems) are often installed on vehicles. To ensure driving safety, it may be necessary to debug the vehicle-side devices (which can also be called in-vehicle infotainment system debugging). The object of debugging can be an application installed at the vehicle-side device. Traditionally, debugging lines are usually reserved in the vehicle-side device or the vehicle. If it is necessary to debug the vehicle-side device, the debugging device can be connected to the vehicle-side device through this line to send debugging data to the vehicle-side device. However, reserving the debugging line may cause the wiring of the vehicle-side device to be chaotic and may increase the installation cost of the device. In addition, if the debugging line is not reserved, the debugging personnel often need to disassemble the vehicle-side device (such as removing the baffle) to expose the debugging port. This will increase the debugging difficulty and requires certain professional knowledge. Moreover, both reserving the debugging line and disassembling the device require retaining a physical debugging interface, which may pose a security risk. It is desired to conveniently and quickly implement the debugging of the application at the vehicle-side device to ensure driving safety.

[0026] In view of this, embodiments of the present disclosure provide an application debugging method. The method includes: at a first device, in response to receiving a debugging instruction for a target application in the first device, sending a first mode switching instruction to a hub to instruct the hub to switch from a first mode to a second mode. The hub is used to connect the first device and the second device. In the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device. Receive debugging data from the second device via the hub in the second mode. Based on the debugging data, perform debugging on the target application.

[0027] Embodiments of the present disclosure also provide an application debugging method. The method includes: at the hub, in response to receiving the first mode switching instruction, switching from the first mode to the second mode. The hub is used to connect the first device and the second device. In the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device. In the second mode, receive debugging data from the second device. In the second mode, send the debugging data to the first device for performing debugging on the target application in the first device.

[0028] In this way, application debugging can be achieved by switching the upstream and downstream ports of the hub, without reserving a debugging line or removing a baffle, which can reduce the installation and material costs and improve the security and convenience of application debugging.

[0029] Example scenario

[0030] First, refer to Figure 1 , which schematically shows a schematic diagram of an example environment 100 in which embodiments of the present disclosure can be implemented. As Figure 1 shown, the environment 100 may include a first device 110, a hub (HUB) 120, a second device 130, and a vehicle 140.

[0031] The first device 110 may be, for example, an electronic device associated with the vehicle 140. The vehicle 140 may include, for example, any suitable vehicle, including but not limited to sedans, taxis, vans, and the like. The present disclosure does not limit the specific type of the vehicle. In some embodiments, the first device 110 may be an electronic device installed in the vehicle 140 that can control the vehicle 140, and it may be, for example, a car machine device.

[0032] In some embodiments, a communication connection may be established between the first device 110 and the second device 130. The communication connection may be established in a wired or wireless manner. The communication connection may include, but is not limited to, a Bluetooth connection, a mobile network connection, a Universal Serial Bus (USB) connection (which may also be referred to as a USB data cable connection), a WiFi connection, etc. Embodiments of the present disclosure are not limited in this regard. In some embodiments, the first device 110 and the second device 130 may perform data communication based on a communication protocol. Such communication protocols may include, for example, the Transmission Control Protocol (TCP), the IPv4 communication protocol, the IPv6 communication protocol, and so on.

[0033] In some embodiments, the environment 100 further includes a hub 120. The hub 120 may include a plurality of ports. The first device 110 may be connected to the hub 120 via any one of the plurality of ports, and the second device 130 may be connected to the hub 120 via another one of the plurality of ports. In some embodiments, the first device 110 and the second device 130 may be connected to the hub 120 in a wired manner respectively. For example, the first device 110 and the second device 130 may be connected to the hub 120 via data cables respectively. The first device 110 may also receive data sent by the second device 130 via the hub 120, for example. In some embodiments, the second device 130 may send debugging data 105 to the first device 110 via the hub 120. The first device 110 may perform debugging based on the received debugging data 105.

[0034] The first device 110 and the second device 130 may include any computing system with computing capabilities, such as various computing devices / systems, terminal devices, server devices, etc. The terminal device may be any type of mobile terminal, fixed terminal or portable terminal, including mobile phones, desktop computers, laptop computers, notebook computers, netbook computers, tablet computers, media computers, multimedia tablets, Personal Communication System (PCS) devices, personal navigation devices, Personal Digital Assistant (PDA), audio / video players, digital cameras / cameras, positioning devices, television receivers, radio broadcast receivers, e-book devices, game devices or any combination of the foregoing, including accessories and peripherals of these devices or any combination thereof.

[0035] The server device can be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks, and big data and artificial intelligence platforms. The server device can be various types of computing systems / servers capable of providing computing power, including but not limited to mainframes, edge computing nodes, computing devices in a cloud environment, and so on.

[0036] It should be understood that the structure and functions of the environment 100 are described only for exemplary purposes, without implying any limitation to the scope of the present disclosure.

[0037] Some exemplary embodiments of the present disclosure will be described hereinafter with continued reference to the accompanying drawings.

[0038] Example interaction and framework

[0039] Figure 2 A flowchart of an information flow 200 for application debugging according to some embodiments of the present disclosure is shown. The information flow 200 involves a first device 110, a hub 120, and a second device 130. In some embodiments, the first device 110 may include a vehicle-side device, and the second device 120 may include a terminal device. For ease of discussion, the information flow 200 will be described with reference to Figure 1 the environment 100.

[0040] In the information flow 200, the first device 110 may receive (205) a debugging instruction. In some embodiments, the first device 110 may include a debugging control. This debugging control can be a physical control. In some embodiments, the first device 110 may further include a display screen, and the first device 110 may present various interfaces via the display screen. In this case, the debugging control can also be a virtual control presented in the interface.

[0041] The first device 110 may, for example, determine that a debugging instruction has been received in response to receiving a trigger operation on the debugging control. In some embodiments, the first device 110 may switch to a debugging mode in response to receiving the debugging instruction. The first device 110 can only receive debugging data sent to it by other devices when it is in the debugging mode.

[0042] In some embodiments, the debugging control may be a debugging control provided by the first device 110 for all applications installed on the first device 110. In this case, the first device 110 may, for example, switch to the debugging mode in response to receiving a trigger operation for the debugging control. In such a debugging mode, the first device 110 may receive debugging data for any application installed on the first device 110.

[0043] Alternatively or additionally, in some embodiments, the debugging control may also be a debugging control provided by a target application installed on the first device 110 and only for the target application. The target application here may include, for example, any suitable application, system, file, program, etc., and the present disclosure does not limit this. In this case, the first device 110 may, for example, switch to the debugging mode for the target application in response to receiving a trigger operation for the debugging control. In such a debugging mode, the first device 110 may, for example, only receive debugging data for the target application.

[0044] The first device 110 may, in response to receiving a debugging instruction for the target application in the first device 110, send (210) a first mode switching instruction to the hub 120 to instruct the hub 210 to switch from the first mode to the second mode. The first device 110 may, for example, send the first mode switching instruction to the hub 120 through a communication connection with the hub 120. Such a communication connection may include a wired communication connection or a wireless communication connection, and the present disclosure does not limit this.

[0045] Regarding the specific manner of sending the first mode switching instruction, the first device 110 may send the first mode switching instruction to the hub 120 by sending a USB message including the first mode switching instruction to the hub 120, and / or by sending an input / output (I / O) data stream including the first mode switching instruction to the hub 120.

[0046] The hub 120 may, in response to receiving the first mode switching instruction, switch (215) from the first mode to the second mode. In some embodiments, the hub 120 includes at least a first port connected to the first device 110 and a second port connected to the second device 130. In the first mode, the first port is an upstream port and the second port is a downstream port. In the second mode, the first port is a downstream port and the second port is an upstream port. It should be noted that the hub 120 may receive data sent by an electronic device connected to the upstream port and send the received data to an electronic device connected to the downstream port. That is, in the second mode, the hub 120 may receive data from the second device 130 and send the received data to the first device 110.

[0047] Hub 120 may receive (220) debugging data from the second device 130 in the second mode. Hub 120 may also send (225) the debugging data to the first device 110 for performing debugging on a target application in the first device 110. Exemplarily, hub 120 may receive debugging data from the second device 130 via a second port connected to the second device 130. Hub 120 may then send the debugging data to the first device 110 via a first port connected to the first device 110. The debugging data at least includes debugging data for debugging the target application.

[0048] In some embodiments, hub 120 may remain in the second mode until a mode switching instruction indicating to switch back to the first mode sent by the first device 110 is received. Alternatively or additionally, in some embodiments, hub 120 may also switch back to the first mode from the second mode in response to not being in a data receiving and transmitting state currently (that is, neither receiving data nor sending data out), and the duration of not being in the data receiving and transmitting state reaching a predetermined duration.

[0049] Correspondingly, the first device 110 may receive (230) debugging data via hub 120 in the second mode. Since hub 120 in the second mode is only used to forward the debugging data from the second device 130 to the first device 110, it can also be said that the first device 110 receives debugging data from the second device 130 via hub 120 in the second mode. The first device 110 may perform (235) debugging on the target application based on the debugging data.

[0050] In some embodiments, after the first device 110 finishes debugging, it may also generate a debugging result. For example, the first device 110 may directly present the debugging result to the user, or send the debugging result to the second device 130 so that the user can view the debugging result through the second device 130. Exemplarily, for example, the first device 110 may, in response to obtaining the debugging result, instruct hub 120 to switch back to the first mode. The first device 110 may then send the debugging result to the second device 130 via hub 120 in the first mode.

[0051] The specific method for performing debugging on the target application in the first device 110 is described above. Next, the method for causing the first device 110 to perform a system reinstallation is described. Continuing to refer to Figure 2 , in the information flow 200, if hub 120 is in the first mode, hub 120 may receive (240) a switching instruction from the second device 130.

[0052] In some embodiments, the second device 130 may send a switching instruction to the hub 120 by sending a USB message including the switching instruction and / or an input / output data stream including the switching instruction to the hub 120. The hub 120 may determine the switching instruction from the received USB message and / or the input / output data stream.

[0053] Alternatively or additionally, in some embodiments, the hub 120 may further include a mode switching control. Similar to the debugging control, this mode switching control may be a physical control or a virtual control. The hub 120 may, for example, determine that a switching instruction has been received in response to receiving a triggering operation for the mode switching control.

[0054] If the hub 120 is in the first mode, the hub 120 may switch (245) from the first mode to the second mode in response to receiving the switching instruction. Similarly, in some embodiments, the hub 120 may remain in the second mode until receiving a switching instruction sent by the second device 130 indicating a switch back to the first mode. Alternatively or additionally, in some embodiments, the hub 120 may also switch back from the second mode to the first mode in response to not being in a data transceiver state currently (i.e., neither receiving data nor sending data out) and the duration of not being in the data transceiver state reaching a predetermined duration.

[0055] In some embodiments, in the case of not switching to the second mode in response to a first mode switching instruction, the hub 120 may send (250) a second mode switching instruction to the first device 110 to indicate that the first device 110 switches to an update mode in response to switching to the second mode.

[0056] The first device 110 may switch (255) to the update mode of the first device 110 in response to receiving the second mode switching instruction from the hub 120 in the second mode. The first device 110 may, for example, receive update data for a target application in the update mode.

[0057] In some embodiments, the first device 110 may send response data indicating that the first device 110 has switched to the update mode to the hub 120 in response to switching to the update mode. The hub 120 may determine that the first device 110 has switched to the update mode in response to receiving the response data. The hub 120 may receive (260) update data (which may also be referred to as flashing data) from the second device 130 in the second mode in response to the first device 110 switching to the update mode. The hub 120 may also send (265) the update data to the first device 110 in the second mode for the first device 110 to perform a system reinstallation (which may also be referred to as flashing).

[0058] Accordingly, the first device 110 may receive (270) update data from the second device 130 via the hub 120 in the second mode. The first device 110 may perform (275) a system reinstallation of the first device 110 based on the received update data. Exemplarily, if the update data includes update data for a target application, the first device 110 may perform a system reinstallation of the target application based on the update data.

[0059] Figure 3 FIG. 5 shows a schematic diagram of an example framework 300 for application debugging according to some embodiments of the present disclosure. The example framework 300 includes a first device 110, a hub 120, a second device 130, and a third device 310. For example, an input / output data stream may be included between the first device 110 and the hub 120. The first device 110 and the hub 120 may send data via the input / output data stream. The hub 120 may include, for example, port 0, port 1, port 2, and port 3. When the hub 120 is in the first mode, port 0 is an upstream port, and ports 1, 2, and 3 are all downstream ports. When the hub 120 is in the second mode, port 0 is a downstream port, and ports 1, 2, and 3 are all upstream ports. The hub 120 may be connected to the first device 110 via port 0, to the second device 130 via port 1, and to the third device 310 via port 3.

[0060] When the first device 110 is in the normal mode 302, the hub 120 may be in the first mode. In this case, the hub 120 may receive a USB packet including data sent by the first device 110 via port 0. The hub 120 may also receive data sent by the first device 110 via the input / output data stream. The hub 120 may send the received data to the third device 310 via port 3, for example.

[0061] In some embodiments, if the first device 110 is in the debug mode, the hub 120 may switch to the second mode in response to receiving a first mode switch instruction sent by the first device 110. In some embodiments, the hub 120 may also switch to the second mode, for example, in response to receiving a switch instruction (e.g., in response to receiving a trigger operation on a mode switch control at the hub 120, receiving a switch instruction). The hub 120 may then send a second mode switch instruction to the first device 110 to instruct the first device 110 to switch to the update mode.

[0062] When the first device 110 is in the debug mode or the update mode (i.e., the debug / update mode 304 in the figure), the hub 120 is in the second mode. The hub 120 can receive debug data / update data from the second device 130 via port 1, for example. In the second mode, the hub 120 can send the received debug data / update data to the first device 110 via a USB message or an input / output data stream. The first device 110 can perform debugging / system reinstallation based on the received debug data / update data.

[0063] In summary, in the embodiments of the present disclosure, the hub 120 can switch to the second mode based on the first mode switching instruction sent by the first device 110, the switching instruction sent by the second device 120, or the triggering operation on the mode switching control. When the hub 120 is in the second mode, the first device 110 can receive debug data / update data from the second device 130 via the hub 120 in the second mode.

[0064] In this way, application debugging can be achieved by switching the upstream and downstream ports of the hub, without reserving a debug cable or removing a baffle, which can reduce the installation and material costs and improve the security and convenience of application debugging.

[0065] Example process

[0066] Figure 4 The flowchart of the process 400 of application debugging according to some embodiments of the present disclosure is shown. The process 400 can be implemented at the first device 110.

[0067] In block 410, at the first device 110, in response to receiving a debug instruction for a target application in the first device, a first mode switching instruction is sent to the hub to instruct the hub to switch from the first mode to the second mode. The hub is used to connect the first device and the second device. In the first mode, the hub is used to send data from the first device to the second device. In the second mode, the hub is used to send data from the second device to the first device.

[0068] In block 420, the first device 110 receives debug data from the second device via the hub in the second mode.

[0069] In block 430, the first device 110 performs debugging on the target application based on the debug data.

[0070] In some embodiments, the hub includes at least a first port connected to the first device and a second port connected to the second device, where the first port is an upstream port in the first mode and a downstream port in the second mode, and the second port is a downstream port in the first mode and an upstream port in the second mode.

[0071] In some embodiments, the first device includes a debugging control, and process 400 further includes: the first device determines that a debugging instruction is received in response to receiving a trigger operation for the debugging control.

[0072] In some embodiments, sending a first mode switching instruction to the hub includes at least one of the following: sending a Universal Serial Bus (USB) message including the first mode switching instruction to the hub, or sending an Input / Output (I / O) data stream including the first mode switching instruction to the hub.

[0073] In some embodiments, process 400 further includes: switching to an update mode of the first device in response to receiving a second mode switching instruction from a hub in a second mode; receiving update data from a second device via the hub in the second mode; and performing a system reinstallation of the first device based on the update data.

[0074] In some embodiments, the first device includes a vehicle-side device, and the second device includes a terminal device.

[0075] Figure 5 A flowchart of a process 500 for application debugging according to some embodiments of the present disclosure is shown. Process 500 may be implemented at the hub 120.

[0076] In block 510, at the hub 120, in response to receiving a first mode switching instruction, switch from a first mode to a second mode. The hub is used to connect a first device and a second device. In the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device.

[0077] In block 520, the hub 120 receives debugging data from the second device in the second mode.

[0078] In block 530, the hub 120 sends the debugging data to the first device in the second mode for performing debugging on a target application in the first device.

[0079] In some embodiments, the hub includes at least a first port connected to the first device and a second port connected to the second device. The first port is an upstream port in the first mode and a downstream port in the second mode, and the second port is a downstream port in the first mode and an upstream port in the second mode.

[0080] In some embodiments, process 500 further includes: if the hub is in the first mode, in response to receiving a switching instruction, switching from the first mode to the second mode; sending a second mode switching instruction to the first device to instruct the first device to switch to the update mode; in response to the first device switching to the update mode, in the second mode, receiving update data from the second device; and in the second mode, sending the update data to the first device for the first device to perform a system reinstallation.

[0081] In some embodiments, the switching instruction is received from the second device.

[0082] In some embodiments, the hub 120 includes a mode switching control, and process 500 further includes: in response to receiving a triggering operation on the mode switching control, determining that the switching instruction is received.

[0083] Example device and equipment

[0084] Embodiments of the present disclosure also provide corresponding apparatuses for implementing the above methods or processes.

[0085] Figure 6 A schematic structural block diagram of an apparatus 600 for application debugging according to certain embodiments of the present disclosure is shown. The apparatus 600 can be implemented as or included in the first device 110. Each module / component in the apparatus 600 can be implemented by hardware, software, firmware, or any combination thereof.

[0086] As Figure 6 shown, the apparatus 600 includes a first instruction sending module 610 configured to, at the first device, in response to receiving a debugging instruction for a target application in the first device, send a first mode switching instruction to the hub to instruct the hub to switch from the first mode to the second mode. The hub is used to connect the first device and the second device. In the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device. The apparatus 600 further includes a debugging data receiving module 620 configured to receive debugging data from the second device via the hub in the second mode. The apparatus 600 further includes a debugging execution module 630 configured to perform debugging on the target application based on the debugging data.

[0087] In some embodiments, the hub includes at least a first port connected to the first device and a second port connected to the second device, where the first port is an upstream port in the first mode and a downstream port in the second mode, and the second port is a downstream port in the first mode and an upstream port in the second mode.

[0088] In some embodiments, the first device includes a debugging control, and apparatus 600 further includes: a debugging instruction receiving module configured to determine that a debugging instruction is received in response to the first device receiving a trigger operation for the debugging control.

[0089] In some embodiments, the first instruction sending module 610 is further configured to: send a Universal Serial Bus (USB) message including a first mode switching instruction to the hub, or send an Input / Output (I / O) data stream including the first mode switching instruction to the hub.

[0090] In some embodiments, apparatus 600 further includes: an update mode switching module configured to switch to an update mode of the first device in response to receiving a second mode switching instruction from a hub in a second mode; an update data receiving module configured to receive update data from a second device via the hub in the second mode; and a system reinstallation execution module configured to perform a system reinstallation of the first device based on the update data.

[0091] In some embodiments, the first device includes a vehicle-side device, and the second device includes a terminal device.

[0092] Figure 7 FIG. shows a schematic structural block diagram of apparatus 700 for application debugging according to certain embodiments of the present disclosure. Apparatus 700 may be implemented as or included in hub 120. Each module / component in apparatus 700 may be implemented by hardware, software, firmware, or any combination thereof.

[0093] As Figure 7 shown, apparatus 700 includes a mode switching module 710 configured to switch from a first mode to a second mode at the hub in response to receiving a first mode switching instruction. The hub is used to connect the first device and the second device. In the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device. Apparatus 700 further includes a data receiving module 720 configured to receive debugging data from the second device in the second mode. Apparatus 700 further includes a data sending module 730 configured to send the debugging data to the first device in the second mode for performing debugging on a target application in the first device.

[0094] In some embodiments, the hub includes at least a first port connected to the first device and a second port connected to the second device. The first port is an upstream port in the first mode and a downstream port in the second mode, and the second port is a downstream port in the first mode and an upstream port in the second mode.

[0095] In some embodiments, the apparatus 700 further includes: a second mode switching module configured to switch from the first mode to the second mode in response to receiving a switching instruction if the hub is in the first mode; an instruction sending module configured to send a second mode switching instruction to the first device to instruct the first device to switch to an update mode; a second data receiving module configured to receive update data from the second device in the second mode in response to the first device switching to the update mode; and an update data sending module configured to send the update data to the first device in the second mode for the first device to perform a system reinstallation.

[0096] In some embodiments, the switching instruction is received from the second device.

[0097] In some embodiments, the hub 120 includes a mode switching control, and the apparatus 700 further includes: an instruction receiving determination module configured to determine that a switching instruction is received in response to receiving a triggering operation on the mode switching control.

[0098] The units and / or modules included in the apparatus 600 and the apparatus 700 can be implemented in various ways, including software, hardware, firmware, or any combination thereof. In some embodiments, one or more units and / or modules can be implemented using software and / or firmware, such as machine-executable instructions stored on a storage medium. In addition to or as an alternative to the machine-executable instructions, some or all of the units and / or modules in these apparatuses can be at least partially implemented by one or more hardware logic components. By way of example and not limitation, exemplary types of hardware logic components that can be used include field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on a chip (SOCs), complex programmable logic devices (CPLDs), and the like.

[0099] Figure 8 A block diagram of an electronic device 800 in which one or more embodiments of the present disclosure can be implemented is shown. It should be understood that Figure 8 the illustrated electronic device 800 is merely exemplary and should not impose any limitation on the functions and scopes of the embodiments described herein. Figure 8 The illustrated electronic device 800 can be used to implement Figure 1 the first device 110, the hub 120, or the second device 130.

[0100] As Figure 8As shown, the electronic device 800 is in the form of a general-purpose electronic device. The components of the electronic device 800 may include, but are not limited to, one or more processors or processing units 810, a memory 820, a storage device 830, one or more communication units 840, one or more input devices 850, and one or more output devices 860. The processing unit 810 may be an actual or virtual processor and be capable of performing various processes according to the programs stored in the memory 820. In a multi-processor system, multiple processing units execute computer-executable instructions in parallel to improve the parallel processing ability of the electronic device 800.

[0101] The electronic device 800 generally includes multiple computer storage media. Such media can be any available media accessible to the electronic device 800, including but not limited to volatile and non-volatile media, removable and non-removable media. The memory 820 may be volatile memory (such as registers, caches, random access memory (RAM)), non-volatile memory (such as read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory), or some combination thereof. The storage device 830 may be removable or non-removable media and may include machine-readable media, such as a flash drive, a magnetic disk, or any other media that can be used to store information and / or data and can be accessed within the electronic device 800.

[0102] The electronic device 800 may further include additional removable / non-removable, volatile / non-volatile storage media. Although not shown in Figure 8 , a disk drive for reading from or writing to a removable, non-volatile magnetic disk (such as a "floppy disk") and an optical disk drive for reading from or writing to a removable, non-volatile optical disk may be provided. In these cases, each drive may be connected to a bus (not shown) by one or more data media interfaces. The memory 820 may include a computer program product 825 having one or more program modules configured to perform the various methods or actions of the various embodiments of the present disclosure.

[0103] The communication unit 840 enables communication with other electronic devices through a communication medium. Additionally, the functions of the components of the electronic device 800 may be implemented in a single computing cluster or multiple computer machines that are capable of communicating through a communication connection. Thus, the electronic device 800 may operate in a networked environment using a logical connection with one or more other servers, network personal computers (PCs), or another network node.

[0104] The input device 850 can be one or more input devices, such as a mouse, a keyboard, a trackball, etc. The output device 860 can be one or more output devices, such as a display, a speaker, a printer, etc. The electronic device 800 can also communicate with one or more external devices (not shown) as needed through the communication unit 840. The external devices such as a storage device, a display device, etc., communicate with one or more devices that enable a user to interact with the electronic device 800, or communicate with any device that enables the electronic device 800 to communicate with one or more other electronic devices (e.g., a network card, a modem, etc.). Such communication can be performed via an input / output (I / O) interface (not shown).

[0105] According to an exemplary implementation of the present disclosure, there is provided a computer-readable storage medium having computer-executable instructions stored thereon, wherein the computer-executable instructions are executed by a processor to implement the method described above. According to an exemplary implementation of the present disclosure, there is also provided a computer program product, which is tangibly stored on a non-transitory computer-readable medium and includes computer-executable instructions, and the computer-executable instructions are executed by a processor to implement the method described above.

[0106] Aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of methods, apparatuses, devices, and computer program products according to the present disclosure. It should be understood that each block of the flowcharts and / or block diagrams, and the combinations of blocks in the flowcharts and / or block diagrams, can be implemented by computer-readable program instructions.

[0107] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine such that when these instructions are executed by the processing unit of the computer or other programmable data processing device, a device is produced that implements the functions / actions specified in one or more blocks of the flowchart and / or block diagram. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, the programmable data processing device, and / or other devices to work in a specific manner. Thus, the computer-readable medium storing the instructions includes a manufacture, which includes instructions for implementing various aspects of the functions / actions specified in one or more blocks of the flowchart and / or block diagram.

[0108] The computer-readable program instructions can be loaded onto a computer, other programmable data processing device, or other device, such that a series of operation steps are performed on the computer, other programmable data processing device, or other device to produce a computer-implemented process, so that the instructions executed on the computer, other programmable data processing device, or other device implement the functions / actions specified in one or more blocks of the flowchart and / or block diagram.

[0109] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various implementations of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, a segment of a program, or a portion of an instruction, which contains one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions noted in the blocks may occur in a different order than noted in the accompanying drawings. For example, two consecutive blocks may actually be executed substantially in parallel, or they may sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented by a dedicated hardware-based system that performs the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.

[0110] The various implementations of the present disclosure have been described above. The above description is exemplary, not exhaustive, and is not limited to the disclosed implementations. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described implementations. The choice of terms used herein is intended to best explain the principles of the implementations, the practical application, or improvements to the technology in the market, or to enable other ordinary skilled persons in the art to understand the various implementations disclosed herein.

Claims

1. A method for application debugging, comprising: At a first device, in response to receiving a debugging instruction for a target application in the first device, sending a first mode switching instruction to a hub to instruct the hub to switch from a first mode to a second mode, where the hub is used to connect the first device and a second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; Receiving debugging data from the second device via the hub in the second mode; And Performing debugging on the target application based on the debugging data.

2. The method according to claim 1, wherein the hub at least includes a first port connected to the first device and a second port connected to the second device, where the first port is an upstream port in the first mode and a downstream port in the second mode, and the second port is a downstream port in the first mode and an upstream port in the second mode.

3. The method according to claim 1, wherein the first device includes a debugging control, and the method further includes: The first device determines that the debugging instruction is received in response to receiving a trigger operation for the debugging control.

4. The method according to claim 1, wherein sending the first mode switching instruction to the hub includes at least one of the following: Sending a Universal Serial Bus (USB) message including the first mode switching instruction to the hub, or Sending an Input / Output (I / O) data stream including the first mode switching instruction to the hub.

5. The method according to claim 1, further includes: Switching to an update mode of the first device in response to receiving a second mode switching instruction from the hub in the second mode; Receiving update data from the second device via the hub in the second mode; And Performing a system reinstallation of the first device based on the update data.

6. The method according to any one of claims 1 to 5, wherein the first device includes a vehicle-side device, and the second device includes a terminal device.

7. A method for application debugging, comprising: At a hub, in response to receiving a first mode switching instruction, switching from a first mode to a second mode, where the hub is used to connect a first device and a second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; Receiving debugging data from the second device in the second mode; And In the second mode, sending the debugging data to the first device for performing debugging on a target application in the first device.

8. The method according to claim 7, wherein the hub includes at least a first port connected to the first device and a second port connected to the second device, the first port being an upstream port in the first mode and a downstream port in the second mode, and the second port being a downstream port in the first mode and an upstream port in the second mode.

9. The method according to claim 7, further comprising: If the hub is in the first mode, in response to receiving a switching instruction, switching from the first mode to the second mode; Sending a second mode switching instruction to the first device to instruct the first device to switch to an update mode; In response to the first device switching to the update mode, in the second mode, receiving update data from the second device; And In the second mode, sending the update data to the first device for the first device to perform a system reinstallation.

10. The method according to claim 9, wherein the switching instruction is received from the second device.

11. The method according to claim 9, wherein the hub includes a mode switching control, and the method further comprises: In response to receiving a triggering operation on the mode switching control, determining that the switching instruction is received.

12. An apparatus for application debugging, comprising: A first instruction sending module, configured to, at a first device, in response to receiving a debugging instruction for a target application in the first device, send a first mode switching instruction to a hub to instruct the hub to switch from a first mode to a second mode, the hub being used to connect the first device and a second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; A debugging data receiving module, configured to receive debugging data from the second device via the hub in the second mode; And A debugging execution module, configured to perform debugging on the target application based on the debugging data.

13. An apparatus for application debugging, comprising: A mode switching module, configured to, at a hub, in response to receiving a first mode switching instruction, switch from a first mode to a second mode, the hub being used to connect a first device and a second device, and in the first mode, the hub is used to send data from the first device to the second device, and in the second mode, the hub is used to send data from the second device to the first device; A data receiving module, configured to receive debugging data from the second device in the second mode; And A data sending module, configured to send the debugging data to the first device in the second mode for performing debugging on a target application in the first device.

14. An electronic device, At least one processing unit; and At least one memory, the at least one memory being coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit, the instructions, when executed by the at least one processing unit, causing the electronic device to perform the method according to any one of claims 1 to 6 or the method according to any one of claims 7 to 11.

15. A computer-readable storage medium having stored thereon a computer program, the computer program being executable by a processor to implement the method according to any one of claims 1 to 6 or the method according to any one of claims 7 to 11.