Printer configuration webpage access method based on USB-to-network conversion

By loading a USB virtual network adapter driver into the printer device, assigning an IP address and subnet mask to the USB port, generating a virtual network port, and configuring the Domain Name System, the problem of cumbersome web page access for printer configuration in existing technologies is solved, achieving a fast and simplified configuration process and improving the user experience.

CN116723173BActive Publication Date: 2026-05-08JIANGMEN DASCOM COMP PERIPHERAL +1
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
JIANGMEN DASCOM COMP PERIPHERAL
Filing Date
2023-05-25
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

In existing technologies, accessing printer configuration web pages requires users to install configuration tools on their computers and perform complex network configurations, which is cumbersome and affects user experience.

Method used

By loading the Linux kernel's USB virtual network card driver into the printer device, an IP address and subnet mask are assigned to the USB port, a virtual network port is generated, and domain name system configuration is performed to assign a slave IP address to the terminal device, enabling the terminal device to directly access the printer configuration webpage.

Benefits of technology

It simplifies the printer configuration webpage access process and improves the user experience. By using a USB virtual network adapter driver to simulate the printer's USB port as a virtual network port, terminal devices can quickly connect to and access the printer configuration webpage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116723173B_ABST
    Figure CN116723173B_ABST
Patent Text Reader

Abstract

The application discloses a printer configuration webpage access method based on a USB-to-network port and a printer device, and the method comprises the following steps: controlling a LINUX kernel to load a USB virtual network card driver, allocating an IP address and a subnet mask for a USB port, and generating a virtual network port according to the USB port; performing domain name system configuration processing on the virtual network port, and allocating a slave IP address for a terminal device connected to the USB port according to the IP address and the subnet mask, wherein, the USB port of the printer is simulated into a virtual network port through the USB virtual network card driver, so that the terminal device can obtain the slave IP address allocated by the virtual network port by connecting the USB port, access the network of the printer device through the slave IP address, and access the configuration webpage of the printer device, thereby simply and effectively realizing the printer configuration webpage access, not needing additional hardware devices, and further simplifying the configuration webpage access process and improving the use experience of users.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of printer configuration technology, specifically to a method and device for accessing a printer configuration webpage based on a USB-to-Ethernet port. Background Technology

[0002] A printer configuration webpage is a web interface used to configure and manage printer settings. Users can use this interface to set printer parameters, view printer status, manage print jobs, etc. The operation method and content of the configuration webpage may vary for different brands or models of printers.

[0003] Typically, accessing a printer configuration webpage requires users to install configuration tools on their computers and perform relatively complex network configurations before connecting the computer to the network where the printer is located. This process is cumbersome, slow, and negatively impacts the user experience. Summary of the Invention

[0004] This application provides a method and device for accessing a printer configuration webpage based on a USB-to-Ethernet port. At a minimum, the printer device in this application includes a Linux kernel and a USB port. The Linux kernel can generate a virtual network port based on the USB port, enabling terminal devices such as computers to quickly connect to the printer device's network through this virtual network port. This allows for simple and effective access to the printer configuration webpage, simplifying the configuration process and improving configuration speed and user experience.

[0005] In a first aspect, embodiments of this application provide a method for accessing a printer configuration webpage based on a USB-to-Ethernet port. The method is applied to a printer device, which includes a Linux kernel and a USB port. The method includes:

[0006] The LINUX kernel is controlled to load the USB virtual network adapter driver, and an IP address and subnet mask are assigned to the USB port to generate a virtual network port based on the USB port.

[0007] The virtual network port is configured using the Domain Name System (DNS). Based on the IP address and subnet mask, a slave IP address is assigned to the terminal device connected to the USB port, so that the terminal device can access the network of the printer device through the slave IP address and access the configuration webpage of the printer device.

[0008] In some embodiments, the step of performing Domain Name System (DNS) configuration processing on the virtual network port, and assigning a slave IP address to the terminal device connected to the USB port based on the IP address and the subnet mask, includes:

[0009] Perform Domain Name System (DNS) configuration processing on the virtual network port and obtain DNS configuration information;

[0010] Based on the domain name system configuration information and preset network protocols, the virtual network port is controlled to enable IP allocation service;

[0011] The virtual network port is controlled to assign slave IP addresses to terminal devices connected to the USB port based on the IP address and the subnet mask.

[0012] In some embodiments, the preset network protocol includes the Domain Name System (DNS) configuration protocol and the Domain Name System (DNS) configuration protocol. The step of controlling the virtual network port to enable IP allocation service according to the DNS configuration information and the preset network protocol includes:

[0013] Based on the Domain Name System (DNS) configuration information, control the virtual network port to enable Dynamic Host Configuration Service (DHS) and DNS configuration service.

[0014] In some embodiments, after performing Domain Name System (DNS) configuration processing on the virtual network port, the method further includes:

[0015] Assign slave IP addresses to the terminal devices connected to the USB port based on the IP address and the subnet mask, and generate a shared network between the printer device and the terminal devices to enable information interaction between the printer device and the terminal devices through the shared network.

[0016] In some embodiments, before controlling the LINUX kernel to load the USB virtual network adapter driver and assign an IP address and subnet mask to the USB port, the method further includes:

[0017] Control the USB port to execute a USB port shutdown command so that the USB port stops printing service.

[0018] In some embodiments, the terminal device is connected to the USB port via a USB cable.

[0019] Secondly, embodiments of this application provide a method for configuring web page access for a printer based on a USB-to-Ethernet port. The method is applied to a terminal device, which is equipped with an RNDIS driver. The terminal device is connected to a USB port on a printer device, which includes a Linux kernel and a USB port. The method includes:

[0020] Run the RNDIS driver to identify the network of the printer device through the virtual network port;

[0021] Obtain the slave IP address assigned by the virtual network port, access the network of the printer device through the slave IP address, and access the configuration webpage of the printer device;

[0022] The printer device controls the LINUX kernel to load the USB virtual network card driver, and assigns an IP address and subnet mask to the USB port to generate the virtual network port based on the USB port;

[0023] The printer device performs Domain Name System (DNS) configuration on the virtual network port and assigns the slave IP address to the terminal device based on the IP address and the subnet mask.

[0024] Thirdly, embodiments of this application provide a printer device, which includes a LINUX kernel and a USB port;

[0025] The LINUX kernel is used to load the USB virtual network card driver, allocate an IP address and subnet mask to the USB port, generate a virtual network port based on the USB port, perform Domain Name System (DNS) configuration processing on the virtual network port, and allocate a slave IP address to the terminal device connected to the USB port based on the IP address and the subnet mask, so that the terminal device can access the network of the printer device through the slave IP address and access the configuration webpage of the printer device.

[0026] Fourthly, embodiments of this application provide a controller, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the printer configuration webpage access method based on a USB-to-Ethernet port as described in any one of the embodiments of the first or second aspect.

[0027] Fifthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions for performing the USB-to-Ethernet printer configuration webpage access method as described in any one of the embodiments of the first or second aspect.

[0028] This application has at least the following beneficial effects: It is applied to a printer device and a terminal device. The printer device includes a LINUX kernel and a USB port. The method includes: controlling the LINUX kernel to load a USB virtual network card driver, assigning an IP address and subnet mask to the USB port to generate a virtual network port; performing Domain Name System (DNS) configuration processing on the virtual network port, and assigning a slave IP address to the terminal device connected to the USB port based on the IP address and subnet mask, so that the terminal device can access the printer device's network through the slave IP address and access the printer device's configuration webpage. Specifically, this application uses a USB virtual network card driver to simulate the printer's USB port as a virtual network port, enabling the terminal device to obtain the slave IP address assigned by the virtual network port by connecting to the USB port, access the printer device's network through the slave IP address, and access the printer device's configuration webpage. This provides a simple and effective way to access the printer configuration webpage, simplifying the access process and improving the user experience. Attached Figure Description

[0029] Figure 1 A flowchart illustrating a method for configuring web page access for a printer based on a USB-to-Ethernet port, according to an embodiment of this application;

[0030] Figure 2 A flowchart illustrating the allocation of slave device IP addresses in a method for configuring web page access for a printer based on a USB-to-Ethernet port, as proposed in another embodiment of this application.

[0031] Figure 3 A flowchart illustrating the process of enabling IP allocation service in a method for configuring web page access for a printer based on a USB-to-Ethernet port, as proposed in another embodiment of this application.

[0032] Figure 4 A flowchart of additional steps in a method for configuring web page access for a printer based on a USB-to-Ethernet port, as proposed in another embodiment of this application;

[0033] Figure 5 A flowchart illustrating the execution of a USB port shutdown command in a method for configuring web page access for a printer based on a USB-to-Ethernet port, as proposed in another embodiment of this application.

[0034] Figure 6 A flowchart illustrating the application of a USB-to-Ethernet printer configuration webpage access method to a terminal device, according to another embodiment of this application.

[0035] Figure 7 This is a schematic diagram of a controller proposed in another embodiment of this application. Detailed Implementation

[0036] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0037] In some embodiments, although functional modules are divided in the system diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the system or the order in the flowchart. The terms "first," "second," etc., in the specification, claims, and the foregoing drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0038] Furthermore, unless otherwise explicitly specified and limited, the term "connection / linkage" should be interpreted broadly, for example, it can be a fixed connection or a movable connection, a detachable connection or a non-detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection or a connection that can communicate with each other; it can be a direct connection or an indirect connection through an intermediate medium.

[0039] In the description of the embodiments in this application, the terms "one embodiment / implementation," "another embodiment / implementation," or "some embodiments / implementations," "in the above embodiments / implementations," etc., refer to specific features, structures, materials, or characteristics described in conjunction with embodiments or examples that are included in at least two embodiments or implementations disclosed in this application. In this disclosure, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or implementation. It should be noted that although a logical order is shown in the flowcharts, in some cases, the steps shown or described may be performed in a different order than that shown in the flowcharts.

[0040] Currently, printer configuration web pages refer to web interfaces used to configure and manage printer settings. Users can use this interface to set printer parameters, view printer status, manage print jobs, etc. The operation method and content of configuration web pages may vary for different brands or models of printers. Usually, to access printer configuration web pages, users need to install configuration tools on their computers and perform relatively complex network configurations before connecting the computer to the network where the printer is located. This process is quite cumbersome and affects the user experience.

[0041] In other words, the existing network configuration process is quite cumbersome, and there is a lack of a simple and effective method for terminal devices to access printer configuration web pages.

[0042] To at least address the aforementioned issues, this application discloses a method and device for accessing a printer configuration webpage based on a USB-to-Ethernet adapter. The method includes: controlling the Linux kernel to load a USB virtual network adapter driver, assigning an IP address and subnet mask to the USB port to generate a virtual network port; performing Domain Name System (DNS) configuration processing on the virtual network port, and assigning a slave IP address to the terminal device connected to the USB port based on the IP address and subnet mask. Specifically, this application uses a USB virtual network adapter driver to simulate the printer's USB port as a virtual network port, enabling the terminal device to obtain the slave IP address assigned by the virtual network port by connecting to the USB port, access the printer device's network through the slave IP address, and access the printer device's configuration webpage. This provides a simple and effective way to access the printer configuration webpage, simplifying the process and improving the user experience.

[0043] The embodiments of this application will be further described below with reference to the accompanying drawings.

[0044] refer to Figure 1 , Figure 1 This is a flowchart of a method for configuring web page access for a printer based on a USB-to-Ethernet port according to an embodiment of this application. In some embodiments, this application provides a method for configuring web page access for a printer based on a USB-to-Ethernet port. The method is applied to a printer device, which includes a LINUX kernel and a USB port. The method includes, but is not limited to, the following steps S110 and S120.

[0045] Step S110: Control the LINUX kernel to load the USB virtual network card driver, assign an IP address and subnet mask to the USB port, and generate a virtual network port based on the USB port.

[0046] Step S120: Perform Domain Name System (DNS) configuration processing on the virtual network port. Assign a slave IP address to the terminal device connected to the USB port based on the IP address and subnet mask, so that the terminal device can access the printer device's network through the slave IP address and access the printer device's configuration webpage.

[0047] In some embodiments, the printer device can support multiple drivers and protocols, including the g_ether driver. The g_ether driver is a USB virtual network adapter driver that enables the establishment of a shared network between the printer device and terminal devices such as computers. Typically, users simply connect the computer and printer using a USB cable, then enable the g_ether driver in the printer device. This allows the computer to identify a new network interface and communicate with the printer through that interface. In the Linux kernel, the g_ether driver is usually included in the Linux kernel driver, meaning the Linux kernel can run the g_ether driver. It can simulate a device connected via a USB port as a network adapter, allowing the system to treat it as an independent network interface. Therefore, after enabling the g_ether driver in this application, users can configure the printer's network on their computer using network configuration tools, including IP address, subnet mask, and gateway. This method enables data transfer and resource sharing between the printer and computer without requiring additional hardware.

[0048] In some embodiments, a virtual network port is generated by loading a USB virtual network adapter driver in the Linux kernel to assign an IP address and subnet mask to the USB port. Then, this virtual network port undergoes Domain Name System (DNS) configuration to assign a slave IP address to the terminal device connected to the printer. This allows the terminal device to access the network and the printer's configuration webpage via the slave IP address. It is conceivable that the printer configuration method based on a USB-to-Ethernet adapter can be implemented using RNDIS technology. RNDIS (Remote Network Driver Interface Specification) is a network protocol used by devices that can connect to the network via a USB interface. It implements the TCP / IP protocol on the USB device, enabling it to function like a network adapter. Using RNDIS technology, the printer's USB port can be virtualized as an Ethernet port, allowing users to remotely configure and manage the printer using popular network configuration tools.

[0049] When using the method described in this application, users only need to connect the printer's USB port to the computer's USB port, enable DHCP for the printer's assigned IP address and subnet mask, and then use common network configuration tools, such as a browser or the ping command, to access the printer's configuration webpage and quickly configure the printer. Compared to traditional configuration tools, this RNDIS-based method does not require downloading and installing additional drivers, simplifying the configuration process and improving the user experience.

[0050] refer to Figure 2, Figure 2 The flowchart for configuring web page access for a printer based on a USB-to-Ethernet port according to another embodiment of this application includes the following steps: configuring the virtual network port with Domain Name System (DNS) and allocating a slave IP address to the terminal device connected to the USB port according to the IP address and subnet mask. This includes, but is not limited to, the following steps: S210, S220 and S230.

[0051] Step S210: Perform Domain Name System (DNS) configuration processing on the virtual network port and obtain DNS configuration information;

[0052] Step S220: Control the virtual network port to enable IP allocation service according to the domain name system configuration information and preset network protocol;

[0053] Step S230: Control the virtual network port to assign slave IP addresses to terminal devices connected to the USB port based on IP addresses and subnet masks.

[0054] In some embodiments, within a computer network, the Domain Name System (DNS) is used to translate domain names into their corresponding IP addresses. In step S210, the virtual network port is first configured with DNS to ensure it can correctly translate domain names into their corresponding IP addresses. For example, the virtual network port can be configured as a DNS server, or connected to a network that already has a configured DNS server. Then, DNS configuration information is obtained, such as the DNS server's IP address, DNS lookup settings, and other related configurations.

[0055] In some embodiments, after obtaining the relevant information of the DNS server in the above steps, it is necessary to control the virtual network port to enable the IP address allocation service according to a preset network protocol (such as TCP / IP). For example, enabling the IP address allocation service DHCP (Dynamic Host Configuration Protocol) will automatically allocate an available IP address, gateway, and other necessary network configuration information to devices accessing the network. Step S220 configures and enables a DHCP server for the virtual network port in order to allocate IP addresses to terminal devices.

[0056] In some embodiments, corresponding to step S230, after enabling the IP allocation service on the virtual network port, slave IP addresses can be assigned to terminal devices connected to the USB port based on their IP addresses and subnet masks. This process requires binding the virtual network port and the devices connected to the USB port to distinguish different devices and assigning an available IP address to each device. This enables connected terminal devices such as computers to communicate with each other via IP addresses, forming a shared network.

[0057] refer to Figure 3 , Figure 3 The flowchart for enabling IP allocation service in the method for configuring web page access for a printer based on a USB-to-Ethernet port proposed in another embodiment of this application; the preset network protocols include Domain Name System Configuration Protocol and Domain Name System Configuration Protocol, and the virtual network port is controlled to enable IP allocation service according to the Domain Name System Configuration Information and the preset network protocols, including the following steps S310;

[0058] Step S310: Control the virtual network port to enable dynamic host configuration service and domain name system configuration service according to the domain name system configuration information.

[0059] refer to Figure 4 , Figure 4 A flowchart of additional steps in a method for configuring web page access for a printer based on a USB-to-Ethernet port according to another embodiment of this application; after performing Domain Name System (DNS) configuration processing on the virtual network port, the method further includes the following step S410;

[0060] Step S410: Assign a slave IP address to the terminal device connected to the USB port according to the IP address and subnet mask, and generate a shared network between the printer device and the terminal device to realize information interaction between the printer device and the terminal device through the shared network.

[0061] refer to Figure 5 , Figure 5 The flowchart of the method for configuring web page access for a printer based on a USB-to-Ethernet port according to another embodiment of this application includes the following steps before controlling the LINUX kernel to load the USB virtual network card driver and assign an IP address and subnet mask to the USB port: S510.

[0062] Step S510: Control the USB port to execute a USB port shutdown command so that the USB port stops printing service.

[0063] It is conceivable that, since the printer's USB port is bound to the printing service by default, in order for the subsequent steps to proceed effectively, the command to close the USB port should be executed first, so that the USB port can be used for data exchange.

[0064] In some embodiments, Domain Name System Configuration Information (DNS) is a network protocol mainly used to translate readable domain names into network-recognizable IP addresses. This application configures Dynamic Host Configuration Service (DHCP) and DNS service by controlling DNS to form a virtual network environment so that terminal devices can access the printer device and access the printer configuration webpage.

[0065] In some embodiments, the terminal device is connected to a USB port via a USB cable.

[0066] refer to Figure 6 , Figure 6 A flowchart illustrating the application of a method for configuring web page access for a printer based on a USB-to-Ethernet port, according to another embodiment of this application, to a terminal device; the method is applied to a terminal device, which is equipped with an RNDIS driver, and the terminal device is connected to a USB port on a printer device, which includes a LINUX kernel and a USB port; the method includes, but is not limited to, the following steps S610 and S620.

[0067] Step S610: Run the RNDIS driver to identify the network of the printer device through the virtual network port;

[0068] Step S620: Obtain the slave IP address assigned by the virtual network port, access the printer device's network through the slave IP address, and access the printer device's configuration webpage.

[0069] The printer device controls the LINUX kernel to load the USB virtual network card driver, assigns an IP address and subnet mask to the USB port, and generates a virtual network port based on the USB port. The printer device performs Domain Name System (DNS) configuration on the virtual network port and assigns a slave IP address to the terminal device based on the IP address and subnet mask.

[0070] In some embodiments, the goal of step S610 is to identify the printer. Typically, the RNDIS driver starts automatically and identifies the printer via a port. This port can be considered a virtual network connection. After the port is started, the terminal device sends a device connection request to the printer's virtual network port. The printer responds to the request. The RNDIS protocol between the terminal device and the printer allows data to be transferred between them. Once the printer device is successfully detected, the terminal device can open it and access the printer's configuration page.

[0071] After the terminal device successfully connects to the printer, the printer will be assigned a corresponding slave IP address. This IP address can access the printer's configuration page via the RNDIS protocol, and access various settings and options on the printer configuration page, such as printer page rotation direction, printer page type, etc.

[0072] In some embodiments, this application is applied to both the printer device and the terminal device, and the specific process is as follows:

[0073] Printer device end:

[0074] 1) The printer firmware LINUX kernel supports USB virtual network adapter drivers, which can be used to establish a shared network between the printer device and the terminal device using a USB cable.

[0075] 2) Execute the driver mount command on the printer and run the driver.

[0076] 3) Execute the command to close the USB port.

[0077] 4) Bind the USB port to an IP address and subnet mask. For example, execute the following command to virtualize it as a network port: ifconfig usb0 169.254.200.1netmask 255.255.255.0up.

[0078] 5) Configure DNS settings to assign slave IP addresses, for example, assign a slave IP address of 169.254.200.1 to the terminal device;

[0079] 6) Enable DHCP / DNS service.

[0080] Terminal device side:

[0081] 1) First, install the RNDIS driver tool.

[0082] 2) After the printer starts the USB-to-Ethernet service, the terminal device will display a "Recognizing" message, waiting for the printer to be assigned an IP address (169.254.200.1):

[0083] Once the allocation is complete, a prompt will appear. At this point, the printer's IP address (169.254.200.1) can be successfully pinged. Entering the printer's IP address (169.254.200.1) will access the printer configuration webpage. After entering the webpage, the user can enter the printer's username and password. If an access password has already been set, the correct username and password must be entered to access the configuration page. Once on the printer's webpage configuration page, various settings and management operations can be performed as needed, such as printer name, network settings, print job management, etc. The layout and content of the configuration page may vary depending on the brand or model of the printer, but this does not limit the scope of this application.

[0084] refer to Figure 7 , Figure 7 This is a schematic diagram of the controller provided in the embodiments of this application.

[0085] Some embodiments of this application provide a controller, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the USB-to-Ethernet printer configuration webpage access method of any of the above embodiments, for example, performing the above-described... Figure 1 Method steps S110 to S120 Figure 2 Method steps S210 to S230, Figure 3 Method steps S310, Figure 4 Method steps S410, Figure 5 Method steps S510, Figure 6 Method steps S610 to S620.

[0086] The controller 700 in this embodiment includes one or more processors 710 and a memory 720. Figure 7 The example uses a processor 710 and a memory 720.

[0087] The processor 710 and memory 720 can be connected via a bus or other means. Figure 7 Taking the example of a connection between China and Israel via a bus.

[0088] The memory 720, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, the memory 720 may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device.

[0089] In some embodiments, the memory 720 may optionally include a memory 720 remotely located relative to the processor 710, which can be connected to the controller 700 via a network. Examples of such networks include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0090] In some embodiments, when the processor executes a computer program, it executes the USB-to-Ethernet printer configuration webpage access method of any of the above embodiments at preset intervals.

[0091] Those skilled in the art will understand that Figure 7 The system architecture shown does not constitute a limitation on the controller 700 and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0092] exist Figure 7In the controller 700 shown, the processor 710 can be used to call the printer configuration webpage access method based on USB to Ethernet port stored in the memory 720, thereby realizing the printer configuration webpage access method based on USB to Ethernet port.

[0093] Based on the hardware structure of the controller 700 described above, various embodiments of the multi-sensor boarding pass positioning system of this application are proposed. Meanwhile, the non-transitory software program and instructions required to implement the printer configuration webpage access method based on USB to Ethernet port of the above embodiments are stored in the memory. When executed by the processor, the printer configuration webpage access method based on USB to Ethernet port of the above embodiments is executed.

[0094] Furthermore, embodiments of this application also provide a multi-sensor boarding pass positioning system, which includes the controller described above.

[0095] In some embodiments, since the multi-sensor boarding pass positioning system of this application has the controller of the above embodiments, and the controller of the above embodiments is capable of executing the printer configuration webpage access method based on USB to Ethernet port of the above embodiments, the specific implementation and technical effects of the multi-sensor boarding pass positioning system of this application can refer to the specific implementation and technical effects of the printer configuration webpage access method based on USB to Ethernet port of any of the above embodiments.

[0096] This application also provides a computer-readable storage medium storing computer-executable instructions. These instructions are used to execute the aforementioned method for accessing a printer configuration webpage based on a USB-to-Ethernet port. For example, they can cause one or more processors to execute the method for accessing a printer configuration webpage based on a USB-to-Ethernet port as described above, such as executing the above-described... Figure 1 Method steps S110 to S120 Figure 2 Method steps S210 to S230, Figure 3 Method steps S310, Figure 4 Method steps S410, Figure 5 Method steps S510, Figure 6 Method steps S610 to S620.

[0097] The system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network nodes. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0098] Those skilled in the art will understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer-readable storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer-readable storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer-readable storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage systems, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, as is known to those skilled in the art, communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium.

[0099] The above is a detailed description of the preferred embodiments of this application. However, this application is not limited to the above embodiments. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of this application. All such equivalent modifications or substitutions are included within the scope defined by the claims of this application.

Claims

1. A method for configuring web page access for a printer based on a USB-to-Ethernet adapter, characterized in that, The method is applied to a printer device, the printer device including a LINUX kernel and a USB port, the method comprising: Control the USB port to execute a USB port shutdown command so that the USB port stops printing service; The LINUX kernel is controlled to load the USB virtual network adapter driver, and an IP address and subnet mask are assigned to the USB port to generate a virtual network port based on the USB port. The USB virtual network adapter driver is the g_ether driver. The virtual network port is configured using the Domain Name System (DNS). Based on the IP address and subnet mask, a slave IP address is assigned to the terminal device connected to the USB port, so that the terminal device can access the network of the printer device through the slave IP address and access the configuration webpage of the printer device.

2. The method for configuring web page access for a printer based on a USB-to-Ethernet port according to claim 1, characterized in that, The step of configuring the virtual network port using the Domain Name System (DNS) and assigning slave IP addresses to the terminal devices connected to the USB port based on the IP address and the subnet mask includes: Perform Domain Name System (DNS) configuration processing on the virtual network port and obtain DNS configuration information; Based on the domain name system configuration information and preset network protocols, the virtual network port is controlled to enable IP allocation service; The virtual network port is controlled to assign slave IP addresses to terminal devices connected to the USB port based on the IP address and the subnet mask.

3. The method for configuring web page access for a printer based on a USB-to-Ethernet port according to claim 2, characterized in that, The preset network protocols include Dynamic Host Configuration Protocol (DHCP) and Domain Name System (DNS) configuration protocol. The step of controlling the virtual network port to enable IP allocation service based on the DNS configuration information and the preset network protocols includes: Based on the Domain Name System (DNS) configuration information, control the virtual network port to enable Dynamic Host Configuration Service (DHS) and DNS configuration service.

4. The method for configuring web page access for a printer based on a USB-to-Ethernet port according to claim 1, characterized in that, After performing Domain Name System (DNS) configuration on the virtual network port, the process further includes: Assign slave IP addresses to the terminal devices connected to the USB port based on the IP address and the subnet mask, and generate a shared network between the printer device and the terminal devices to enable information interaction between the printer device and the terminal devices through the shared network.

5. The method for configuring web page access for a printer based on a USB-to-Ethernet port according to claim 1, characterized in that, The terminal device is connected to the USB port via a USB cable.

6. A method for configuring web page access for a printer based on a USB-to-Ethernet port, characterized in that, The method is applied to a terminal device equipped with an RNDIS driver. The terminal device is connected to a USB port on a printer device, which includes a Linux kernel and a USB port. The method includes: Run the RNDIS driver to identify the network of the printer device through the virtual network port; Obtain the slave IP address assigned by the virtual network port, access the network of the printer device through the slave IP address, and access the configuration webpage of the printer device; The printer device controls the USB port to execute a USB port shutdown command, so that the USB port stops printing service; The Linux kernel is controlled to load the USB virtual network adapter driver, and an IP address and subnet mask are assigned to the USB port to generate the virtual network port. The USB virtual network adapter driver is the g_ether driver. The printer device performs Domain Name System (DNS) configuration processing on the virtual network port and assigns the slave IP address to the terminal device according to the IP address and subnet mask.

7. A printer device, characterized in that, The printer device includes a LINUX kernel and a USB port; The USB port is used to execute a USB port shutdown command, so that the USB port stops printing service; The LINUX kernel is used to load the USB virtual network adapter driver, allocate an IP address and subnet mask to the USB port, generate a virtual network port based on the USB port, perform Domain Name System (DNS) configuration processing on the virtual network port, and allocate a slave IP address to the terminal device connected to the USB port based on the IP address and subnet mask, so that the terminal device can access the network of the printer device through the slave IP address and access the configuration webpage of the printer device. The USB virtual network adapter driver is the g_ether driver.

8. A controller, characterized in that, The device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the USB-to-Ethernet printer configuration webpage access method as described in any one of claims 1 to 6.

9. A computer-readable storage medium storing computer-executable instructions for performing the USB-to-Ethernet printer configuration webpage access method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Connection method and device, vehicle-mounted system, terminal and storage medium

    CN107222637A

  • Data communication method, device and system and computer readable storage medium

    CN111177053A

  • Network sharing method and system

    CN113595777A