1. Field of the Invention
The present invention relates to a Universal Serial Bus (USB) system and a power management module and a method thereof.
2. Description of the Related Art
A USB is a serial port bus standard connecting a computer system and an external device. Due to advantages of hot plug and Plug and Play (PNP), the USB interface has become a mainstream transmission interface. When a USB device is connected to or removed from a host system, the power of the host system does not need to be switched off and then switched on again. In addition, a user only needs to connect the USB device to the host system to operate the USB device immediately, and does not need to worry about any issue related to installation or setup.
The host computer system 11 may include an Operating System (OS) 112, a USB device driving program 114, a USB driving program 116, and a USB host controller driving program 118. The OS 112 is responsible for managing and maintaining communication between the host computer system 11 and the USB peripheral devices. The USB device driving program 114 includes a program code describing features of the USB peripheral devices, so that the host computer system 11 can access the USB peripheral devices, for example, read data from the peripheral device, write data to the peripheral device, transmit a command to the peripheral device, or receive status data related to the peripheral device. The USB device driving program 114 may send a request to the USB driving program 116 through an I/O Request Packet (IRP). The USB driving program 116 is a software interface providing a USB serial transmission mechanism. When the USB driving program 116 receives an IRP from the USB device driving program 114, the USB driving program 116 organizes the IRP into an individual processing action, so as to execute the action in a continuous frame. The USB host controller driving program 118 in
Currently available USB transmission lines support a Network Device Interface Standard (NDIS). Under this standard, when the host computer system 10 detects attachment of the USB peripheral devices (particularly a wireless network card 18), the host computer system 10 operates in a normal power mode, so as to access the wireless network card 18. However, when the wireless network card 18 is in an idle status, that is, the wireless network card 18 is not transmitting a packet, the host computer system 11 is limited by the NDIS and fails to enter a power saving mode, thereby causing unnecessary power consumption.
Therefore, it is necessary to provide a power management device and a method thereof applied to a computer system. When a USB peripheral device is attached to the host computer system, the host computer system can operate in a power saving mode, so as to reduce the power loss.
The present invention discloses a power management module and a method thereof, configured to set up a power mode of a computer system. A peripheral device having a USB is connected to the computer system. An embodiment of the present invention discloses a power management module, which includes an OS and a filter driver. The OS is configured to set up the power mode of the computer system, and the filter driver is configured to change the power mode of the computer system according to a packet transmitting/receiving status of the peripheral device.
Another embodiment of the present invention discloses a USB system, which includes a peripheral device and a host device. The peripheral device communicates with a host device through a USB. The host device includes an OS, which is configured to set up a power mode of the host device. The host device further includes a filter driver, which is configured to change the power mode of the host device according to a packet transmitting/receiving status of the peripheral device.
Still another embodiment of the present invention discloses a power management method, which is used to set up a power mode of a computer system. A peripheral device having a USB is connected to the computer system. The method includes the following steps: detecting a packet transmitting/receiving status of the peripheral device through a filter driver; generating a Power IRP (PIRP) through the filter driver when the peripheral device is not receiving or transmitting a packet; and changing the mode of the computer system from a normal power mode to a power saving mode according to the PIRP.
The invention will be described according to the appended drawings in which:
The present invention is directed to a power management module and a method thereof applied to a computer system. For thorough understanding of the present invention, detailed steps and structures are provided in the following description. Obviously, the implementation of the present invention is not limited to special details familiar to those skilled in the art. In another aspect, structures or steps known to all are not described in detail, so as to avoid unnecessary limitation to the present invention. The preferred embodiments of the present invention will be described below. However, apart from these detailed descriptions, the present invention may further be implemented in other embodiments. The scope of the present invention is not limited, and is subject to the scope of the appended claims.
In order to clearly illustrate the power management method of the present invention, a USB system executing the method of the present invention will be described first as follows.
Referring to
Referring to
If the peripheral device 24 is in an idle status, that is, the peripheral device 24 does not receive or transmit a packet, after detecting the idle status, the filter driver 226 generates a PIRP2 to a CPU 222 of the host device 22, so as to change the power mode of the host device 22 from the normal power mode to a power saving mode.
According to another embodiment of the present invention, the host device 22 further includes a timing unit 228, as shown in
In conclusion, without changing a conventional driver of a computer system, the present invention changes a power mode of the computer system by adding a filter driver to generate a PIRP to a CPU. By using an architecture disclosed in the present invention, when a peripheral device is attached but is not used, the computer system can enter a power saving mode to reduce the power consumption.
The technical content and technical features of the present invention are disclosed. However, persons skilled in the art may still make other replacements and modifications without departing from the spirit of the present invention based on the disclosure and teachings of the invention. Therefore, the scope of the present invention shall not be limited to the embodiments disclosed. Rather, the scope of the present invention shall include all the replacements and modifications without departing from the present invention and shall be covered by the appended claims.
Number | Date | Country | Kind |
---|---|---|---|
099145139 | Dec 2010 | TW | national |