[go: up one dir, main page]

TWI471866B - Power saving external USB mass storage device (mass storage device) and its power saving method - Google Patents

Power saving external USB mass storage device (mass storage device) and its power saving method Download PDF

Info

Publication number
TWI471866B
TWI471866B TW100104696A TW100104696A TWI471866B TW I471866 B TWI471866 B TW I471866B TW 100104696 A TW100104696 A TW 100104696A TW 100104696 A TW100104696 A TW 100104696A TW I471866 B TWI471866 B TW I471866B
Authority
TW
Taiwan
Prior art keywords
interface
usb
controller
command
external
Prior art date
Application number
TW100104696A
Other languages
Chinese (zh)
Other versions
TW201234382A (en
Inventor
cheng fang Liu
Original Assignee
Innostor Technology Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Innostor Technology Corp filed Critical Innostor Technology Corp
Priority to TW100104696A priority Critical patent/TWI471866B/en
Publication of TW201234382A publication Critical patent/TW201234382A/en
Application granted granted Critical
Publication of TWI471866B publication Critical patent/TWI471866B/en

Links

Landscapes

  • Power Sources (AREA)

Description

省電型外接式USB大容量記憶裝置(mass storage device)及其省電方法Power-saving external USB mass storage device (mass storage device) and power saving method thereof

本發明係關於一種外接式USB大容量記憶裝置(mass storage device),尤指一種能自動休眠達到省電效果之外接式USB大容量記憶裝置。The invention relates to an external USB mass storage device, in particular to an external USB large-capacity memory device capable of automatically sleeping to achieve a power saving effect.

外接式USB大容量記憶裝置(mass storage device)係用以作為隨身攜帶資料用,使用時係配合一具存取該外接式USB大容量記憶裝置之外部主機(如筆記型主機)使用,該外接式USB大容量記憶裝置係具有一USB介面(Universal Serial Bus,通用匯流排),該匯流排端子插入該外部主機,該外部主機則可輸出主機命令至該外接式USB大容量記憶裝置,進一步對該外接式USB大容量記憶裝置進行資料存取,請參閱圖6,係為習用之外接式USB大容量記憶裝置60功能方塊圖,其中包含有一USB介面60、一USB控制器62、一介面單元63、一介面控制器64及一記憶單元65;該USB控制器62係分別與該USB介面61及該介面單元63電連接,並透過該USB介面61與一外部主機70電連接,且透過該介面單元63與該介面控制器64電連接,又該介面控制器64係與該記憶單元65電連接。The external USB mass storage device is used as a portable data, and is used in conjunction with an external host (such as a notebook type) that accesses the external USB mass storage device. The USB mass storage device has a USB interface (Universal Serial Bus), and the bus terminal is inserted into the external host, and the external host can output a host command to the external USB mass storage device, further The external USB mass storage device performs data access. Please refer to FIG. 6 , which is a functional block diagram of a conventional external USB mass storage device 60 , which includes a USB interface 60 , a USB controller 62 , and an interface unit . 63. An interface controller 64 and a memory unit 65. The USB controller 62 is electrically connected to the USB interface 61 and the interface unit 63, and is electrically connected to an external host 70 through the USB interface 61. The interface unit 63 is electrically connected to the interface controller 64, and the interface controller 64 is electrically connected to the memory unit 65.

上述外部主機70係輸出一主機命令,當該外接式USB大容量記憶裝置60接收該主機命令時,則由該USB控制器62處理該主機命令中包含之指令,若該主機命令中包含有一內部裝置指令,則該USB控制器62會透過該介面單元63而令該介面控制器64存取該記憶單元65;若該主機命令中未包含該內部裝置指令,則該USB控制器62處理該主機命令後係直接回覆該主機。The external host 70 outputs a host command. When the external USB mass storage device 60 receives the host command, the USB controller 62 processes the command included in the host command, if the host command includes an internal command. The device controller 64 causes the interface controller 64 to access the memory unit 65 through the interface unit 63; if the internal device command is not included in the host command, the USB controller 62 processes the host After the command, the host is directly replied to.

例如:一般主機會週期確認外接裝置狀態,故會發出包含有輪詢指令的主機命令,以偵測該外接式USB大容量記憶裝置60係處於可存取(accessible)或已拔除狀態,當該USB控制器62接收該主命令並判斷為輪詢指令,而非內部裝置指令時,直接回覆該外部主機70,該介面單元63、該介面控制器64及該記憶單元65均不動作;即便如此該介面單元63處於激活(active)狀態,且該介面控制器64處於甦醒(wake up)之狀態,以備於隨時接收該內部裝置指令時可直接透過該介面單元63及該介面控制器64存取該記憶單元65。For example, the general host periodically checks the status of the external device, so a host command including a polling command is issued to detect that the external USB mass storage device 60 is in an accessible or unplugged state. The USB controller 62 receives the main command and determines that it is a polling command, and instead of the internal device command, directly responds to the external host 70, and the interface unit 63, the interface controller 64, and the memory unit 65 do not operate; The interface unit 63 is in an active state, and the interface controller 64 is in a wake up state, so as to be directly stored through the interface unit 63 and the interface controller 64 when receiving the internal device command at any time. This memory unit 65 is taken.

由於一般使用者使用該外接式USB大容量記憶裝置60之習慣,並非長時間透過主機對該記憶單元65頻繁存取資料,通常插接至主機後,將存取資料路徑設定好並下達存取指令後即靜置等待資料存取完成;是以,該外接式USB大容量記憶裝置60插接於主機上進行實際資料存取作業時間較少,而再由上述說明可知,目前該外接式USB大容量記憶裝置60為因應主機不定時作業,故該USB控制器、該介面單元63及該介面控制器64均保持在待機狀態,以及時反應主機命令,如此一來即要長時間仍消耗電力。Since the general user uses the external USB mass storage device 60, the memory unit 65 is not frequently accessed through the host for a long time. After the host is plugged into the host, the access data path is set and the access is released. After the command, the device waits for the data access to be completed; that is, the external USB mass storage device 60 is plugged into the host to perform the actual data access operation time, and the above description shows that the external USB is currently available. The large-capacity memory device 60 keeps the USB controller, the interface unit 63, and the interface controller 64 in a standby state in response to an untimely operation of the host, and responds to the host command in a timely manner, so that power is still consumed for a long time. .

雖然一般USB 1.1、2.0及3.0USB控制器均已建置休眠指令(Suspend),但對於外接式USB大容量記憶裝置60來說僅限於主機控制該USB控制器62進入休眠,並無法進一步控制該介面單元63及該介面控制器64進入休眠模式,以降低電力消耗,加上一般外接式USB大容量記憶裝置60的使用習慣確實會長時間消耗電力,故此種外接式USB大容量記憶裝置需要有所改良。Although the USB 1.1, 2.0, and 3.0 USB controllers have been configured with a sleep command (Suspend), for the external USB mass storage device 60, the host controller only controls the USB controller 62 to go to sleep, and cannot further control the The interface unit 63 and the interface controller 64 enter a sleep mode to reduce power consumption, and the usage habit of the general external USB mass storage device 60 does consume power for a long time, so the external USB mass storage device needs to have some Improvement.

有鑑於上述現有外接式USB大容量記憶裝置在外部主機不對其進行讀取時,會長時間耗電之技術缺陷,本發明的主要目的係提出一種省電型外接式USB大容量記憶裝置及其省電方法。In view of the technical defects that the existing external USB mass storage device does not read the external host for a long time, the main purpose of the present invention is to provide a power-saving external USB large-capacity memory device and the province thereof. Electrical method.

欲達上述目的所使用的主要技術手段係令該省電型外接式USB大容量記憶裝置包含有:一USB介面、一USB控制器、一介面單元、一介面控制器及一記憶單元,而該USB控制器係內建一休眠判斷程序,用以預估出該USB大容量記憶裝置以USB插接的外部主機即將長時間不對記憶單元進行資料存取動作時,由該USB控制器透過該介面單元觸發該介面控制器的休眠模式,令介面控制器及其記憶單元進入低電力消耗(Power down),達到省電功效。The main technical means for achieving the above purpose is that the power-saving external USB mass storage device comprises: a USB interface, a USB controller, an interface unit, an interface controller and a memory unit, and the The USB controller has a built-in sleep judging program for estimating that the external host of the USB mass storage device connected to the USB is not going to access the memory unit for a long time, and the USB controller passes through the interface. The unit triggers the sleep mode of the interface controller, so that the interface controller and its memory unit enter a low power consumption (Power down) to achieve power saving effect.

上述USB控制器的休眠判斷程序係以過濾主機命令是否包含內部裝置指令,作為預估外部主機是否將長時間不對記憶單元進行資料存取動作之依據,因此該USB控制器係設計一指令計數單元,判斷連續N個主機命令不含內部裝置指令,意即主機已一段時間未對介面控制器及其記憶單元發出如資料存取的內部裝置指令;是以,該USB控制器即可驅動該介面控制器的休眠模式,令介面控制器及其記憶單元進入低電力消耗,達到休眠效果。The sleep determination program of the USB controller is configured to filter whether the host command includes an internal device command as a basis for estimating whether the external host will not perform data access operations on the memory unit for a long time, and therefore the USB controller is configured with an instruction counting unit. , determining that the consecutive N host commands do not contain an internal device command, that is, the host has not issued an internal device command such as data access to the interface controller and its memory unit for a period of time; that is, the USB controller can drive the interface The sleep mode of the controller causes the interface controller and its memory unit to enter low power consumption and achieve a sleep effect.

上述USB控制器的休眠判斷程序亦可以設定一時間週期,由該USB控制器的一計數器進行該時間週期的計數,確認於單一時間週期內是否未收到包含內部裝置指令的主機命令;若是則代表主機即將長時間不對記憶單元進行資料存取動作,而該USB控制器即驅動該介面控制器的休眠模式,令介面控制器及其記憶單元進入低電力消耗,達到休眠效果。The sleep determination program of the USB controller may also be set for a time period, and a counter of the USB controller performs counting of the time period to confirm whether a host command including an internal device command is not received within a single time period; if yes On behalf of the host, the data access operation of the memory unit is not performed for a long time, and the USB controller drives the sleep mode of the interface controller, so that the interface controller and its memory unit enter low power consumption to achieve the sleep effect.

又,本發明欲達上述目的所使用的主要技術手段係令該省電型外接式USB大容量記憶裝置的省電方法包含有:接收外部主機命令;預估外接式USB大容量記憶裝置的記憶單元的資料將長時間不被讀取,係判斷所接收包含有內部裝置指令之外部主機命令的頻率;及於判斷所接收的外部主機命令中包含有內部裝置指令之頻率低,則觸發該USB大容量記憶裝置的介面控制器進入休眠模式;於判斷所接收的外部主機命令中包含有內部裝置指令之頻率高,則回到第一步驟。Moreover, the main technical means used by the present invention to achieve the above object is that the power saving method of the power-saving external USB mass storage device includes: receiving an external host command; estimating the memory of the external USB mass storage device The data of the unit will not be read for a long time, and the frequency of receiving the external host command containing the internal device command is judged; and when the frequency of the received external host command containing the internal device command is low, the USB is triggered. The interface controller of the mass storage device enters the sleep mode; when it is determined that the received external host command contains the internal device command at a high frequency, the process returns to the first step.

上述判斷所接收包含有內部裝置指令之外部主機命令的頻率,係設定一N數值,於判斷所接收主機命令是否已累計連續N個主機命令不含內部裝置指令,並以此為判斷包含有內部裝置指令之外部主機命令的頻率高低;當接收到的連續N個主機命令不包含內部裝置指令時,則代表主機已一段時間未對介面控制器及其記憶單元發出如資料存取的內部裝置指令,而令該介面控制器進入休眠模式,達到休眠效果。The above judgment determines the frequency of the external host command including the internal device command, and sets an N value to determine whether the received host command has accumulated consecutive N host commands without an internal device command, and includes an internal judgment as a judgment. The frequency of the external host command of the device command; when the received consecutive N host commands do not include the internal device command, the internal device command that the host controller has not issued the data access to the interface controller and its memory unit for a period of time And let the interface controller enter the sleep mode to achieve the sleep effect.

上述判斷所接收包含有內部裝置指令之外部主機命令的頻率,係設定一時間週期,於單一時間週期內判斷未收到包含內部裝置指令的主機命令,則代表主機即將長時間不對記憶單元進行資料存取動作,並令該介面控制器進入休眠模式,讓該介面控制器及該記憶單元進入低電力消耗,達到休眠效果。The above judgment determines that the frequency of the external host command including the internal device command is set for a time period, and if the host command containing the internal device command is not received within a single time period, the host will not perform data for the memory unit for a long time. The access action is performed, and the interface controller enters a sleep mode, so that the interface controller and the memory unit enter a low power consumption to achieve a sleep effect.

請參閱圖1,本發明省電型外接式USB大容量記憶裝置10,其可為HD、ODD及非揮發性記憶體(non-volatile memory),並插接於一外部主機20,且包含有:一USB介面11,係為通用匯流排(Universal Serial Bus),並插接於該外部主機20,以接收外部主機20的主機命令;一USB控制器12,係與該USB介面11電連接,並透過該USB介面11與該外部主機20電連接,且內建一休眠判斷程序;一介面單元13,係與該USB控制器12電連接,該介面單元13可為ATA、SATA、ATAPI、SCSI、記憶體匯流排(memory bus)或記憶卡匯流排(memory card bus);一介面控制器14,並包含有一休眠模式;及一記憶單元15,係與該介面控制器14電連接。Referring to FIG. 1 , the power-saving external USB mass storage device 10 of the present invention can be HD, ODD, and non-volatile memory, and is plugged into an external host 20 and includes a USB interface 11 is a Universal Serial Bus and is plugged into the external host 20 to receive a host command from the external host 20; a USB controller 12 is electrically connected to the USB interface 11 The USB interface 11 is electrically connected to the external host 20, and a sleep determination program is built in. An interface unit 13 is electrically connected to the USB controller 12. The interface unit 13 can be ATA, SATA, ATAPI, or SCSI. And a memory bus or a memory card bus; an interface controller 14 and including a sleep mode; and a memory unit 15 electrically connected to the interface controller 14.

上述休眠判斷程序係用以預估出該外部主機20即將長時間不對該記憶單元15進行資料存取動作時,由該USB控制器12透過該介面單元13觸發該介面控制器14的休眠模式,令介面控制器14及其記憶單元15進入低電力消耗,亦可進一步令該介面單元13切換為非激活(inactive)狀態,達到省電功效。The sleep determination program is configured to trigger the sleep mode of the interface controller 14 by the USB controller 12 through the interface unit 13 when the external host 20 is not going to perform data access operation on the memory unit 15 for a long time. The interface controller 14 and its memory unit 15 are allowed to enter low power consumption, and the interface unit 13 can be further switched to an inactive state to achieve power saving effect.

上述USB控制器12的休眠判斷程序係以過濾主機命令是否包含內部裝置指令,作為預估外部主機20是否將長時間不對記憶單元進行資料存取動作之依據,於本實施例,該USB控制器12係設計一指令計數單元,判斷連續N個主機命令不包含內部裝置指令,意即主機已一段時間未對介面控制器14及其記憶單元15發出如資料存取的內部裝置指令;是以,該USB控制器12即可驅動該介面控制器14的休眠模式,令介面控制器14及其記憶單元15進入低電力消耗,亦可進一步令該介面單元13進入非激活狀態,達到休眠效果。The sleep determination program of the USB controller 12 is based on whether the filter host command includes an internal device command as a basis for estimating whether the external host 20 will not perform data access operations on the memory unit for a long time. In this embodiment, the USB controller The 12 series designing an instruction counting unit determines that the consecutive N host commands do not include an internal device command, that is, the host has not issued an internal device command such as data access to the interface controller 14 and its memory unit 15 for a period of time; The USB controller 12 can drive the sleep mode of the interface controller 14 to make the interface controller 14 and its memory unit 15 enter low power consumption, and further enable the interface unit 13 to enter an inactive state to achieve a sleep effect.

本發明又提供另一較佳實施例,係令該USB控制器12的休眠判斷程序設定一時間週期,由該USB控制器12的一計數器進行該時間週期的計數,確認於單一時間週期內是否未收到包含內部裝置指令的主機命令;若是則代表主機即將長時間不對記憶單元進行資料存取動作,而該USB控制器12即驅動該介面控制器14的休眠模式,令介面控制器14及其記憶單元15進入低電力消耗,亦可進一步令該介面單元13進入非激活狀態,達到休眠效果。The present invention further provides another preferred embodiment, wherein the sleep determination program of the USB controller 12 is set for a time period, and a counter of the USB controller 12 performs counting of the time period to confirm whether it is within a single time period. The host command containing the internal device command is not received; if it is, the host will not perform the data access operation to the memory unit for a long time, and the USB controller 12 drives the sleep mode of the interface controller 14, so that the interface controller 14 The memory unit 15 enters a low power consumption, and the interface unit 13 can be further brought into an inactive state to achieve a sleep effect.

本發明省電型外接式USB大容量記憶裝置的USB控制器進一步內建有一喚醒程序,以於控制該介面控制器14及其記憶單元15進入低電力消耗後,接收到包含有內部裝置指令的主機命令仍能順利由介面控制器14反應此內部裝置指令。請參閱圖3,係為該喚醒程序的流程圖,該喚醒程序係於USB控制器12判斷外部主機命令包含有內部裝置指令後始執行之,其包含以下步驟:開始S41;確認介面單元13是否為激活(active)狀態S42;若否,則進一步激活該介面單元13(S43);若是,則執行下一步驟;確認該介面控制器14及該記憶單元15(S44)是否為休眠狀態;若是,則喚醒該介面控制器14及該記憶單元15(S45)並透過介面單元13傳送內部裝置指令至該介面控制器14(S46)。The USB controller of the power-saving external USB mass storage device of the present invention further has a wake-up program built therein to control the interface controller 14 and its memory unit 15 to enter a low power consumption, and receive an instruction including an internal device. The host command can still successfully react to this internal device command by the interface controller 14. Please refer to FIG. 3 , which is a flowchart of the wake-up procedure. The wake-up procedure is executed after the USB controller 12 determines that the external host command includes an internal device command, and includes the following steps: start S41; confirm whether the interface unit 13 is Active state S42; if not, further activate the interface unit 13 (S43); if yes, perform the next step; confirm whether the interface controller 14 and the memory unit 15 (S44) are in a dormant state; Then, the interface controller 14 and the memory unit 15 are awakened (S45) and the internal device command is transmitted to the interface controller 14 through the interface unit 13 (S46).

如此,當USB控制器12控制該介面單元13進入非激活狀態,以及該介面控制器14及其記憶單元15進入低電力消耗狀態後,會於接收到包含有內部裝置指令的主機命令時,先令介面單元13返回激活狀態,再喚醒該介面控制器14及其記憶單元15,再將內部裝置指令透過介面單元13傳送至該介面控制器14,由該介面控制器14反應該內部裝置指令;如此,即可令該外部主機20透過該USB控制器12對已休眠的該記憶單元15完成存取動作。Thus, when the USB controller 12 controls the interface unit 13 to enter an inactive state, and the interface controller 14 and its memory unit 15 enter a low power consumption state, upon receiving a host command including an internal device command, The interface unit 13 is returned to the active state, and then the interface controller 14 and its memory unit 15 are awake, and the internal device command is transmitted to the interface controller 14 through the interface unit 13, and the internal controller command is reacted by the interface controller 14; In this way, the external host 20 can complete the access operation to the memory unit 15 that has been hibernated through the USB controller 12.

請進一步參閱圖2,係為本發明一省電型外接式USB大容量記憶裝置10的省電方法,其包含有:接收外部主機命令S11;預估外接式USB大容量記憶裝置10的記憶單元15的資料將長時間不被讀取,係判斷所接收包含有內部裝置指令之外部主機命令的頻率S12;及於判斷所接收的外部主機命令中包含有內部裝置指令之頻率低,則觸發該USB大容量記憶裝置10的介面控制器14的休眠模式S13,令介面控制器14及其記憶單元15進入低電力消耗;於判斷所接收的外部主機命令中包含有內部裝置指令之頻率高,則回到第一步驟S11。Please refer to FIG. 2 , which is a power saving method for a power-saving external USB mass storage device 10 of the present invention, which includes: receiving an external host command S11; estimating a memory unit of the external USB mass storage device 10 The data of 15 will not be read for a long time, and it is judged that the frequency S12 of the external host command containing the internal device command is received; and when the frequency of the internal device command included in the received external host command is low, the trigger is triggered. The sleep mode S13 of the interface controller 14 of the USB mass storage device 10 causes the interface controller 14 and its memory unit 15 to enter low power consumption; when it is determined that the received external host command contains a high frequency of internal device commands, then Going back to the first step S11.

再請進一步參閱圖4,係為本發明省電型外接式USB大容量記憶裝置10省電方法之一較佳實施例流程圖,其主要於上述判斷所接收包含有內部裝置指令之外部主機命令頻率的步驟中設定一N數值,詳細流程如下:接收外部主機命令S21;累計主機命令數量S22,並判斷是否已達N個主機命令S23,若尚未到達,則回到第一步驟S21;若是,則執行下一步驟;判斷所接收N個主機命令中,是否已有包含內部裝置指令的主機命令S24,若是則令計數歸零S23再回到第一步驟S21;若否,則進入休眠模式S25。Please refer to FIG. 4 again, which is a flowchart of a power saving method for the power-saving external USB mass storage device 10 of the present invention, which mainly receives the external host command including the internal device command in the above judgment. In the frequency step, an N value is set, and the detailed procedure is as follows: receiving an external host command S21; accumulating the number of host commands S22, and determining whether N host commands S23 have been reached, and if not yet, returning to the first step S21; if yes, Then, the next step is performed; determining whether there is a host command S24 containing the internal device command among the received N host commands, and if so, returning the count to zero S23 and returning to the first step S21; if not, entering the sleep mode S25 .

此實施例係主要預設一N數值,於判斷所接收主機命令是否已累計連續N個主機命令不含內部裝置指令,並以此判斷包含有內部裝置指令之外部主機命令的頻率高低;當接收到的連續N個主機命令不包含內部裝置指令時,則代表主機已一段時間未對介面控制器14及其記憶單元15發出如資料存取的內部裝置指令,而令該介面控制器14進入休眠模式,使該介面控制器14及其記憶單元15進入低電力消耗,達到省電效果。This embodiment mainly presets an N value, and determines whether the received host command has accumulated consecutive N host commands without an internal device command, and thereby determines the frequency of the external host command including the internal device command; when receiving When the consecutive N host commands are not included in the internal device command, the host controller 14 has not issued an internal device command such as data access to the interface controller 14 and its memory unit 15 for a period of time, and the interface controller 14 is put into sleep. The mode causes the interface controller 14 and its memory unit 15 to enter low power consumption to achieve a power saving effect.

再請進一步參閱圖5,係為本發明省電型外接式USB大容量記憶省電方法之另一較佳實施例的流程圖,其主要於上述判斷所接收包含有內部裝置指令之外部主機命令頻率的步驟中設定一時間週期,詳細流程如下:開始計時S31;接收外部主機命令S32;判斷該外部主機命令是否包含內部裝置指令S33;若包含則重新計S34時並回到第一步驟S31;若不包含內部裝置指令,則執行下一步驟;判斷是否計時已達時間週期S35,若是則進入休眠模式S36;反之,若尚未達時間週期,則回到接收主機命令之步驟S32。Please refer to FIG. 5 again, which is a flowchart of another preferred embodiment of the power-saving external USB large-capacity memory power-saving method according to the present invention, which mainly receives the external host command including the internal device command in the above judgment. Setting a time period in the frequency step, the detailed flow is as follows: start timing S31; receive an external host command S32; determine whether the external host command includes an internal device command S33; if it is included, re-count S34 and return to the first step S31; If the internal device command is not included, the next step is performed; it is determined whether the time has elapsed for the time period S35, and if so, the sleep mode S36 is entered; otherwise, if the time period has not yet reached, the process returns to the receiving host command step S32.

由此一實施例可知,本實施例係預設一時間週期,並於單一時間週期內判斷所接收到主機命令包含內部裝置指令的狀態,以作為判斷接收包含有內部裝置指令之外部主機命令的頻率,若未收到包含內部裝置指令的主機命令,則代表主機即將長時間不對記憶單元進行資料存取動作,並令該介面控制器14進入休眠模式,使介面控制器14及其記憶單元15進入低電力消耗,達到省電效果。As can be seen from an embodiment, the present embodiment presets a time period and determines, in a single time period, that the received host command includes an internal device command as a judgment to receive an external host command including an internal device command. If the host does not receive the host command including the internal device command, the host will not perform the data access operation for the memory unit for a long time, and the interface controller 14 enters the sleep mode, so that the interface controller 14 and its memory unit 15 Enter low power consumption to achieve power saving effect.

綜上所述,本發明USB控制器內建之休眠判斷程序,係可預估該外部主機將長時間不存取該記憶單元,而進一步自動令該介面控制器及該記憶單元進入低電力消耗,而於欲存取該記憶單元時再將該介面控制器及該記憶單元喚醒,如此,長期使用下來即可達到省電之效果。In summary, the sleep determination program built in the USB controller of the present invention can predict that the external host will not access the memory unit for a long time, and further automatically enter the interface controller and the memory unit to enter low power consumption. When the memory unit is to be accessed, the interface controller and the memory unit are awakened, so that the power saving effect can be achieved by long-term use.

10...外接式USB大容量記憶裝置10. . . External USB mass storage device

11...USB介面11. . . USB interface

12...USB控制器12. . . USB controller

13...介面單元13. . . Interface unit

14...介面控制器14. . . Interface controller

15...記憶單元15. . . Memory unit

20...外部主機20. . . External host

60...USB大容量記憶裝置60. . . USB mass storage device

61...USB介面61. . . USB interface

62...USB控制器62. . . USB controller

63...介面單元63. . . Interface unit

64...介面控制器64. . . Interface controller

65...記憶單元65. . . Memory unit

70...外部主機70. . . External host

圖1:為本發明之功能方塊圖。Figure 1 is a functional block diagram of the present invention.

圖2:為本發明省電方法之流程圖。2 is a flow chart of a power saving method of the present invention.

圖3:為本發明喚醒程序流程圖。Figure 3 is a flow chart of the wake-up procedure of the present invention.

圖4:為本發明一較佳實施例休眠程序流程圖。4 is a flow chart of a sleep program according to a preferred embodiment of the present invention.

圖5:為本發明另一較佳實施例休眠程序流程圖。FIG. 5 is a flow chart of a sleep program according to another preferred embodiment of the present invention.

圖6:為習用之外接式USB大容量記憶裝置功能方塊圖。Figure 6: Functional block diagram of a conventional external USB mass storage device.

10...USB大容量記憶裝置10. . . USB mass storage device

11...USB介面11. . . USB interface

12...USB控制器12. . . USB controller

13...介面單元13. . . Interface unit

14...介面控制器14. . . Interface controller

15...記憶單元15. . . Memory unit

20...外部主機20. . . External host

Claims (8)

一種省電型外接式USB大容量記憶裝置,係包含有:一USB介面,係供插接於一外部主機,以接收外部主機的主機命令;一USB控制器,係包含一指令計數單元,且與該USB介面電連接,並內建一休眠判斷程序;一介面單元,係與該USB控制器電連接;一介面控制器,係包含有一休眠模式;及一記憶單元,係與該介面控制器電連接,供儲存資料用;上述USB控制器執行休眠判斷程序,係判斷連續N個主機命令不含內部裝置指令後,透過該介面單元觸發該介面控制器的休眠模式,令介面控制器及其記憶單元進入低電力消耗。 A power-saving external USB mass storage device includes: a USB interface for plugging in an external host to receive a host command of an external host; and a USB controller including an instruction counting unit, and Electrically connecting with the USB interface and having a sleep determination program; an interface unit electrically connected to the USB controller; an interface controller including a sleep mode; and a memory unit coupled to the interface controller Electrical connection for storing data; the USB controller performs a sleep determination procedure, and determines that the continuous N host commands do not include an internal device command, triggers a sleep mode of the interface controller through the interface unit, and causes the interface controller and The memory unit enters low power consumption. 如申請專利範圍第1項所述之省電型外接式USB大容量記憶裝置,該USB控制器係包含一計時器,並預設一時間週期,以計時單一時間週期內是否未收到包含內部裝置指令的主機命令;若是則驅動該介面控制器的休眠模式,令介面控制器及其記憶單元進入低電力消耗。 The power-saving external USB mass storage device according to claim 1, wherein the USB controller includes a timer and presets a time period to time whether a time period is not received within a single time period. The host command of the device command; if so, the sleep mode of the interface controller is driven to cause the interface controller and its memory unit to enter low power consumption. 如申請專利範圍第1或2項所述之省電型外接式USB大容量記憶裝置,該USB控制器在令介面控制器及其記憶單元進入低電力消耗後,令該介面單元進入非激活狀態。 The power-saving external USB mass storage device according to claim 1 or 2, wherein the USB controller enters the interface unit into an inactive state after the interface controller and the memory unit thereof enter low power consumption. . 如申請專利範圍第3項所述之省電型外接式USB大容量記憶裝置,該USB控制器進一步內建一喚醒程序,並於接收包含有內部裝置指令的主機命令時,執行該喚醒程 序,且該喚醒程序係包含以下步驟:開始;確認介面單元是否為激活狀態;若否,則進一步激活該介面單元;若是,則執行下一步驟;確認該介面控制器及該記憶單元是否為休眠狀態;若是,則喚醒該介面控制器及該記憶單元並透過介面單元傳送該介面控制器。 For example, in the power-saving external USB mass storage device described in claim 3, the USB controller further includes a wake-up program, and executes the wake-up procedure when receiving a host command including an internal device command. And the wake-up procedure includes the steps of: starting; confirming whether the interface unit is in an active state; if not, further activating the interface unit; if yes, performing the next step; confirming whether the interface controller and the memory unit are a sleep state; if so, waking up the interface controller and the memory unit and transmitting the interface controller through the interface unit. 如申請專利範圍第1或2項所述之省電型外接式USB大容量記憶裝置,該介面單元為ATA、SATA、ATAPI、SCSI、記憶體匯流排(memory bus)或記憶卡匯流排(memory card bus)。 The power-saving external USB mass storage device according to claim 1 or 2, wherein the interface unit is ATA, SATA, ATAPI, SCSI, memory bus or memory card bus (memory) Card bus). 如申請專利範圍第4項所述之省電型外接式USB大容量記憶裝置,該介面單元為ATA、SATA、ATAPI、SCSI、記憶體匯流排(memory bus)或記憶卡匯流排(memory card bus)。 The power-saving external USB mass storage device described in claim 4, wherein the interface unit is ATA, SATA, ATAPI, SCSI, memory bus or memory card bus (memory card bus) ). 一種省電型外接式USB大容量記憶裝置的省電方法,其中該外接式USB大容量記憶裝置包含有一USB介面、一USB控制器、一介面單元、一介面控制器及一記憶單元;而該省電方法係包含有:設定一數值N;接收外部主機命令;累計主機命令數量;於判斷所接收的外部主機命令已累計連續N個外部主機命令不含內部裝置指令時,則觸發該USB大容量記憶裝置的介面控制器進入休眠模式,令介面控制器及其記憶單元 進入低電力消耗;及於判斷所接收的外部主機命令連續N個外部主機命令中至少一外部主機命令包含內部裝置指令時,則回到該接收外部主機命令之步驟。 A power saving method for a power-saving external USB mass storage device, wherein the external USB mass storage device comprises a USB interface, a USB controller, an interface unit, an interface controller and a memory unit; The power saving method includes: setting a value N; receiving an external host command; accumulating the number of host commands; and triggering the USB large when determining that the received external host command has accumulated consecutive N external host commands without an internal device command The interface controller of the capacity memory device enters the sleep mode, and the interface controller and its memory unit Entering low power consumption; and when determining that the received external host command at least one of the consecutive N external host commands includes an internal device command, returning to the step of receiving the external host command. 如申請專利範圍第7項所述之省電型外接式USB大容量記憶裝置的省電方法,其中判斷所接收包含有內部裝置指令之外部主機命令頻率步驟中,係設定一時間週期,於單一時間週期內判斷未收到包含內部裝置指令的主機命令,令該介面控制器進入休眠模式,讓該介面控制器及該記憶單元進入低電力消耗。 The power saving method of the power-saving external USB mass storage device according to claim 7, wherein in the step of determining the frequency of receiving the external host command including the internal device command, setting a time period to a single During the time period, it is determined that the host command containing the internal device command is not received, and the interface controller enters the sleep mode, so that the interface controller and the memory unit enter low power consumption.
TW100104696A 2011-02-14 2011-02-14 Power saving external USB mass storage device (mass storage device) and its power saving method TWI471866B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW100104696A TWI471866B (en) 2011-02-14 2011-02-14 Power saving external USB mass storage device (mass storage device) and its power saving method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW100104696A TWI471866B (en) 2011-02-14 2011-02-14 Power saving external USB mass storage device (mass storage device) and its power saving method

Publications (2)

Publication Number Publication Date
TW201234382A TW201234382A (en) 2012-08-16
TWI471866B true TWI471866B (en) 2015-02-01

Family

ID=47070119

Family Applications (1)

Application Number Title Priority Date Filing Date
TW100104696A TWI471866B (en) 2011-02-14 2011-02-14 Power saving external USB mass storage device (mass storage device) and its power saving method

Country Status (1)

Country Link
TW (1) TWI471866B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI630610B (en) * 2015-09-04 2018-07-21 高通公司 System and method for dynamically adjusting memory state transition timer

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103677197B (en) * 2012-08-30 2017-08-25 中兴通讯股份有限公司 The electricity saving method and device of USB data transmission system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200818125A (en) * 2006-10-13 2008-04-16 Optimark Technology Co Ltd Power saving method for an external hard-disk
US7793042B2 (en) * 2007-01-05 2010-09-07 Dell Products, Lp System, method, and module for reducing power states for storage devices and associated logical volumes
TW201035744A (en) * 2009-03-22 2010-10-01 Silicon Motion Inc Method for controlling power consumption of a USB mass storage, associated personal computer, and storage medium storing an associated USB mass storage driver

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200818125A (en) * 2006-10-13 2008-04-16 Optimark Technology Co Ltd Power saving method for an external hard-disk
US7793042B2 (en) * 2007-01-05 2010-09-07 Dell Products, Lp System, method, and module for reducing power states for storage devices and associated logical volumes
TW201035744A (en) * 2009-03-22 2010-10-01 Silicon Motion Inc Method for controlling power consumption of a USB mass storage, associated personal computer, and storage medium storing an associated USB mass storage driver

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI630610B (en) * 2015-09-04 2018-07-21 高通公司 System and method for dynamically adjusting memory state transition timer

Also Published As

Publication number Publication date
TW201234382A (en) 2012-08-16

Similar Documents

Publication Publication Date Title
US8843700B1 (en) Power efficient method for cold storage data retention management
TWI774787B (en) Memory controller and operating method thereof
US9740645B2 (en) Reducing latency in a peripheral component interconnect express link
US8443221B2 (en) Methods, systems, and computer readable media for advanced power management for serial advanced technology attachment (SATA)-based storage devices
CN102707784B (en) For power control so that the minimum method and system of power consumption
US8677057B1 (en) Initiating memory wear leveling
CN104246655B (en) Message processing device, information processing method and program
TWI475368B (en) Power control system and method thereof
TWI567541B (en) Implementing a power off state in a computing device
CN102725709A (en) Memory power reduction during hibernation
WO2021233219A1 (en) Automatic wake-up and diagnosis method for battery management system, battery management system, and vehicle
CN101154131A (en) Information processing device and system state control method
US20170371574A1 (en) Managing host communication with a regulator in a low power mode
JPH09237463A (en) Hard disk control method and information processing apparatus
CN101034305A (en) Computer automatic dormancy/awaking circuit
CN107179819B (en) Method for preventing battery from swelling and electronic device thereof
US20120260116A1 (en) External power-saving usb mass storage device and power-saving method thereof
CN105474182A (en) Storage device supporting periodic writes while in a low power mode for an electronic device
TWI471866B (en) Power saving external USB mass storage device (mass storage device) and its power saving method
CN111813455B (en) Low-power-consumption realization method and device of solid state disk, computer equipment and storage medium
JP5795758B2 (en) Method for protecting data in non-volatile storage device
US7370215B2 (en) Method and apparatus of self-powering down ATA devices
WO2024036452A1 (en) Processing apparatus, and related control method for low-power-consumption standby
CN105260146A (en) Setting method and device capable of saving energy for disk
CN100561405C (en) Power Management Method in Computer System Power Saving State

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees