[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

TWI446179B - Computer system and control method thereof - Google Patents

Computer system and control method thereof Download PDF

Info

Publication number
TWI446179B
TWI446179B TW100133030A TW100133030A TWI446179B TW I446179 B TWI446179 B TW I446179B TW 100133030 A TW100133030 A TW 100133030A TW 100133030 A TW100133030 A TW 100133030A TW I446179 B TWI446179 B TW I446179B
Authority
TW
Taiwan
Prior art keywords
computer system
embedded controller
transposition
state
basic input
Prior art date
Application number
TW100133030A
Other languages
Chinese (zh)
Other versions
TW201312360A (en
Inventor
Chia Chi Yang
Yung Yen Chang
Original Assignee
Wistron 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 Wistron Corp filed Critical Wistron Corp
Priority to TW100133030A priority Critical patent/TWI446179B/en
Priority to CN201110316806.8A priority patent/CN102999157B/en
Priority to US13/326,263 priority patent/US8875138B2/en
Publication of TW201312360A publication Critical patent/TW201312360A/en
Application granted granted Critical
Publication of TWI446179B publication Critical patent/TWI446179B/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2200/00Indexing scheme relating to G06F1/04 - G06F1/32
    • G06F2200/16Indexing scheme relating to G06F1/16 - G06F1/18
    • G06F2200/163Indexing scheme relating to constructional details of the computer
    • G06F2200/1637Sensing arrangement for detection of housing movement or orientation, e.g. for controlling scrolling or cursor movement on the display of an handheld computer
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Input From Keyboards Or The Like (AREA)

Description

電腦系統及其控制方法Computer system and control method thereof

本發明是有關於一種控制電腦系統的方法,且特別是有關於一種依據電腦系統之轉置狀態來進行控制的方法,以及使用此方法的電腦系統。The present invention relates to a method of controlling a computer system, and more particularly to a method of controlling according to a transposition state of a computer system, and a computer system using the method.

電腦產業的蓬勃發展使得電腦系統的普及率有逐年升高之勢。現代人也越來越習慣以電腦系統作為辦公、學習,或休閒娛樂的工具。為了隨時享受電腦系統所帶來的便利,同時兼具效能與可攜性的筆記型電腦或平板電腦(Tablet PC)也愈發受到消費者的重視。其中,平板電腦更因為體積小與重量輕等特性而相當受到青睞。The booming development of the computer industry has led to a year-on-year increase in the penetration rate of computer systems. Modern people are also becoming more accustomed to using computer systems as tools for office, study, or recreation. In order to enjoy the convenience brought by the computer system at any time, the notebook PC or tablet PC (Tablet PC) with both performance and portability is increasingly valued by consumers. Among them, tablet PCs are quite popular because of their small size and light weight.

一般來說,平板電腦會設計為使用者可單手拿持的大小,因此使用者能輕鬆地利用另一手握持觸控筆(stylus)或直接以手指來對平板電腦進行操控。而在某些使用情境下,使用者也可將平板電腦置於桌面或膝上,甚至還能外接滑鼠或鍵盤等輸入裝置來增添輸入上的便利性。In general, the tablet is designed to be sized by the user, so the user can easily hold the stylus with the other hand or directly manipulate the tablet with his finger. In some usage scenarios, the user can also place the tablet on the desktop or laptop, and even external input devices such as a mouse or keyboard to increase the convenience of input.

對電腦系統的製造商來說,在同業百家爭鳴且競爭激烈的市場環境下,如何以消費者的使用需求為出發點,進一步地增加產品的功能性來創造競爭力同時提升市佔率,無疑也成為電腦系統製造商在研發新產品之際的重要目標。For manufacturers of computer systems, in the market environment where competition among the peers is fierce and competitive, how to further increase the functionality of products to create competitiveness and increase market share in the market environment of consumer demand is undoubtedly The important goal of computer system manufacturers in developing new products.

有鑑於此,本發明提供一種電腦系統及其控制方法,能依據電腦系統目前的轉置狀態自動執行相關的操作。In view of this, the present invention provides a computer system and a control method thereof, which can automatically perform related operations according to the current transposition state of the computer system.

本發明提出一種電腦系統的控制方法,此電腦系統包括嵌入式控制器、基本輸入輸出系統以及作業系統,此方法包括當電腦系統被轉動時,由嵌入式控制器利用中斷訊號與內部溝通機制使基本輸入輸出系統得知電腦系統目前的轉置狀態,再由基本輸入輸出系統根據虛擬掃瞄碼與轉置狀態建立資料結構,並將資料結構傳送至作業系統,進而由作業系統控制一程式根據資料結構來執行與轉置狀態相關的操作。The invention provides a computer system control method. The computer system comprises an embedded controller, a basic input/output system and an operating system. The method comprises: when the computer system is rotated, the embedded controller uses the interrupt signal and the internal communication mechanism to make The basic input/output system knows the current transposition state of the computer system, and then the basic input/output system establishes a data structure according to the virtual scan code and the transposition state, and transmits the data structure to the operating system, and then the operating system controls a program according to The data structure is used to perform operations related to the transposition state.

在本發明之一實施例中,此電腦系統的控制方法更包括由運動感測器在偵測到電腦系統被轉動時取得電腦系統目前的轉置狀態,並且將對應此轉置狀態的訊號傳送至嵌入式控制器。In an embodiment of the present invention, the control method of the computer system further includes: obtaining, by the motion sensor, the current transposition state of the computer system when detecting that the computer system is rotated, and transmitting the signal corresponding to the transposition state To the embedded controller.

在本發明之一實施例中,其中內部溝通機制是透過基本輸入輸出系統在電腦系統啟動時,於電腦系統之主記憶體所定義的第一特定位址範圍所提供。而嵌入式控制器利用中斷訊號與內部溝通機制使基本輸入輸出系統得知轉置狀態的步驟包括由嵌入式控制器解析來自運動感測器的訊號,以判斷電腦系統目前之轉置狀態,並且將虛擬掃瞄碼及對應轉置狀態的轉置參數寫入第一特定位址範圍,再將中斷訊號發送至基本輸入輸出系統,以通知基本輸入輸出系統讀取第一特定位址範圍來取得虛擬掃瞄碼與轉置參數。In an embodiment of the invention, the internal communication mechanism is provided by the basic input/output system at a first specific address range defined by the main memory of the computer system when the computer system is started. The step of the embedded controller using the interrupt signal and the internal communication mechanism to make the basic input/output system aware of the transposed state includes the embedded controller parsing the signal from the motion sensor to determine the current transposed state of the computer system, and Write the virtual scan code and the transposed parameter of the corresponding transposition state into the first specific address range, and then send the interrupt signal to the basic input/output system to notify the basic input/output system to read the first specific address range to obtain Virtual scan code and transpose parameters.

在本發明之一實施例中,其中內部溝通機制是透過嵌入式控制器之內部記憶體中的第二特定位址範圍所提供,而此電腦系統的控制方法更包括在電腦系統接收到特定按鍵輸入時,由嵌入式控制器根據特定按鍵輸入判斷電腦系統目前的轉置狀態,並且將虛擬掃瞄碼及對應電腦系統之轉置狀態的轉置參數寫入第二特定位址範圍。In an embodiment of the present invention, the internal communication mechanism is provided by a second specific address range in the internal memory of the embedded controller, and the control method of the computer system further includes receiving a specific button in the computer system. When inputting, the embedded controller determines the current transposition state of the computer system according to the specific key input, and writes the virtual scan code and the transpose parameter corresponding to the transposed state of the computer system into the second specific address range.

在本發明之一實施例中,其中嵌入式控制器利用中斷訊號與內部溝通機制使基本輸入輸出系統得知轉置狀態的步驟包括由作業系統因應嵌入式控制器所發送的中斷訊號而透過基本輸入輸出系統去命令嵌入式控制器讀取第二特定位址範圍,再由嵌入式控制器將第二特定位址範圍所記錄的虛擬掃瞄碼與轉置參數回傳至基本輸入輸出系統。In an embodiment of the present invention, the step of the embedded controller using the interrupt signal and the internal communication mechanism to make the basic input/output system aware of the transposed state includes the basic response by the operating system in response to the interrupt signal sent by the embedded controller. The input/output system commands the embedded controller to read the second specific address range, and then the embedded controller returns the virtual scan code and the transposition parameter recorded in the second specific address range to the basic input/output system.

在本發明之一實施例中,其中由基本輸入輸出系統根據虛擬掃瞄碼與轉置狀態建立資料結構的步驟包括由基本輸入輸出系統利用取自電腦系統之主記憶體的緩衝區域來建立資料結構。其中,基本輸入輸出系統將虛擬掃瞄碼填入緩衝區域中的第一預設區域,並將轉置參數填入緩衝區域中的第二預設區域。In an embodiment of the invention, the step of establishing a data structure based on the virtual scan code and the transposed state by the basic input/output system includes establishing, by the basic input/output system, a buffer region from the main memory of the computer system to establish data. structure. The basic input/output system fills the virtual scan code into the first preset area in the buffer domain, and fills the transposition parameter into the second preset area in the buffer domain.

在本發明之一實施例中,其中程式為顯示器應用程式,而由作業系統控制此程式根據資料結構執行與轉置狀態相關的操作的步驟包括由作業系統將資料結構傳送至顯示器應用程式。接著,由顯示器應用程式根據資料結構中的轉置參數判斷電腦系統的轉置狀態,並呼叫顯示器應用程式介面以根據轉置狀態旋轉電腦系統的螢幕畫面。In one embodiment of the invention, wherein the program is a display application, and the step of controlling, by the operating system, the program to perform an operation associated with the transposition state based on the data structure includes transmitting, by the operating system, the data structure to the display application. Next, the display application determines the transposition status of the computer system based on the transpose parameters in the data structure, and calls the display application interface to rotate the screen of the computer system according to the transposed state.

在本發明之一實施例中,其中程式為音效卡驅動程式,而由作業系統控制此程式根據資料結構執行與轉置狀態相關的操作的步驟由作業系統將資料結構傳送至音效卡驅動程式,再由音效卡驅動程式根據資料結構中的轉置參數判斷電腦系統的轉置狀態,並通知音效晶片根據轉置狀態啟動配置於電腦系統的第一組麥克風或第二組麥克風。其中,第一組麥克風是配置在電腦系統未被轉動時的垂直兩側,而第二組麥克風是配置在電腦系統未被轉動時的水平兩側。In an embodiment of the present invention, wherein the program is a sound card driver, and the operating system controls the program to perform the operation related to the transposition state according to the data structure, the operating system transfers the data structure to the sound card driver. Then, the sound card driver determines the transposition state of the computer system according to the transposition parameter in the data structure, and notifies the audio chip to start the first group microphone or the second group microphone configured in the computer system according to the transposition state. The first set of microphones are disposed on both sides of the vertical when the computer system is not rotated, and the second set of microphones are disposed on both sides of the horizontal when the computer system is not rotated.

從另一觀點來看,本發明提出一種電腦系統,包括嵌入式控制器、基本輸入輸出系統、主記憶體、晶片組以及處理器。其中,晶片組耦接嵌入式控制器、基本輸入輸出系統、主記憶體與處理器。處理器用以執行被載入至主記憶體的作業系統。其中,當電腦系統被轉動時,嵌入式控制器利用中斷訊號與內部溝通機制使基本輸入輸出系統得知電腦系統目前的轉置狀態,而基本輸入輸出系統會根據虛擬掃瞄碼與上述轉置狀態建立資料結構,並將資料結構傳送至作業系統。而作業系統將控制一程式根據資料結構執行與轉置狀態相關的操作。From another point of view, the present invention provides a computer system including an embedded controller, a basic input/output system, a main memory, a chipset, and a processor. The chipset is coupled to the embedded controller, the basic input/output system, the main memory and the processor. The processor is configured to execute an operating system that is loaded into the main memory. Wherein, when the computer system is rotated, the embedded controller uses the interrupt signal and the internal communication mechanism to make the basic input/output system know the current transposition state of the computer system, and the basic input/output system converts the virtual scan code according to the above. The state establishes a data structure and transfers the data structure to the operating system. The operating system will control a program to perform operations related to the transposed state based on the data structure.

在本發明之一實施例中,其中基本輸入輸出系統在電腦系統啟動時,定義主記憶體中的第一特定位址範圍以作為內部溝通機制。In an embodiment of the invention, the basic input/output system defines a first specific address range in the main memory as an internal communication mechanism when the computer system is booted.

在本發明之一實施例中,此電腦系統更包括運動感測器,其耦接至嵌入式控制器。運動感測器在偵測到電腦系統被轉動時取得電腦系統目前的轉置狀態,並將對應轉置狀態的訊號傳送至嵌入式控制器。In an embodiment of the invention, the computer system further includes a motion sensor coupled to the embedded controller. The motion sensor obtains the current transposition state of the computer system when detecting that the computer system is rotated, and transmits a signal corresponding to the transposition state to the embedded controller.

在本發明之一實施例中,其中嵌入式控制器解析來自運動感測器的訊號以判斷電腦系統目前之轉置狀態,並將虛擬掃瞄碼及對應轉置狀態的轉置參數寫入第一特定位址範圍,再發送中斷訊號至基本輸入輸出系統,以通知基本輸入輸出系統讀取第一特定位址範圍來取得虛擬掃瞄碼與轉置參數。In an embodiment of the present invention, the embedded controller parses the signal from the motion sensor to determine the current transposition state of the computer system, and writes the virtual scan code and the transpose parameter corresponding to the transposed state. A specific address range, and then sending an interrupt signal to the basic input/output system to notify the basic input/output system to read the first specific address range to obtain the virtual scan code and the transpose parameter.

在本發明之一實施例中,其中嵌入式控制器定義其內部記憶體中的第二特定位址範圍以作為內部溝通機制。In an embodiment of the invention, the embedded controller defines a second specific address range in its internal memory as an internal communication mechanism.

在本發明之一實施例中,此電腦系統更包括鍵盤,其耦接至嵌入式控制器。其中當電腦系統接收到來自鍵盤的特定按鍵輸入時,嵌入式控制器根據特定按鍵輸入判斷電腦系統目前的轉置狀態,並將虛擬掃瞄碼及對應轉置狀態的轉置參數寫入第二特定位址範圍。In an embodiment of the invention, the computer system further includes a keyboard coupled to the embedded controller. When the computer system receives a specific key input from the keyboard, the embedded controller determines the current transposition state of the computer system according to the specific key input, and writes the virtual scan code and the transposed parameter of the corresponding transposition state into the second. Specific address range.

在本發明之一實施例中,其中作業系統因應嵌入式控制器所發送的中斷訊號,透過基本輸入輸出系統命令嵌入式控制器讀取第二特定位址範圍。而嵌入式控制器會將第二特定位址範圍所記錄的虛擬掃瞄碼與轉置參數回傳至基本輸入輸出系統。In an embodiment of the invention, the operating system commands the embedded controller to read the second specific address range through the basic input/output system in response to the interrupt signal sent by the embedded controller. The embedded controller returns the virtual scan code and transpose parameters recorded in the second specific address range to the basic input/output system.

在本發明之一實施例中,其中基本輸入輸出系統在一緩衝區域中的第一預設區域填入虛擬掃瞄碼,並在緩衝區域中的第二預設區域填入轉置參數,而上述緩衝區域是取自主記憶體。In an embodiment of the present invention, the basic input/output system fills the virtual scan code in a first preset area in a buffer domain, and fills in a transposition parameter in a second preset area in the buffer domain, and The above buffer area is taken as autonomous memory.

在本發明之一實施例中,其中程式為顯示器應用程式,而作業系統將資料結構傳送至顯示器應用程式,以由顯示器應用程式根據資料結構中的轉置參數判斷電腦系統的轉置狀態,並呼叫顯示器應用程式介面而根據轉置狀態旋轉電腦系統的螢幕畫面。In an embodiment of the invention, the program is a display application, and the operating system transmits the data structure to the display application, so that the display application determines the transposition status of the computer system according to the transpose parameter in the data structure, and Call the display application interface to rotate the screen of the computer system according to the transposition status.

在本發明之一實施例中,其中程式為音效卡驅動程式,而作業系統將資料結構傳送至音效卡驅動程式,以由音效卡驅動程式根據資料結構中的轉置參數判斷電腦系統的轉置狀態,並通知音效晶片根據轉置狀態啟動配置於電腦系統的第一組麥克風或第二組麥克風。其中,第一組麥克風是配置在電腦系統未被轉動時的垂直兩側,而第二組麥克風是配置在電腦系統未被轉動時的水平兩側。In an embodiment of the invention, the program is a sound card driver, and the operating system transmits the data structure to the sound card driver to determine the transposition of the computer system by the sound card driver according to the transpose parameter in the data structure. Status, and notify the audio chip to activate the first set of microphones or the second set of microphones configured in the computer system according to the transposed state. The first set of microphones are disposed on both sides of the vertical when the computer system is not rotated, and the second set of microphones are disposed on both sides of the horizontal when the computer system is not rotated.

基於上述,本發明在電腦系統被轉動時,係透過內部溝通機制與虛擬掃瞄碼讓作業系統取得目前的轉置狀態,從而控制一程式自動根據轉置狀態執行相關操作。如此一來,能使電腦系統自動配合轉置狀態來運作,據以提升使用電腦系統的便利性。Based on the above, the present invention allows the operating system to obtain the current transposition state through the internal communication mechanism and the virtual scan code when the computer system is rotated, thereby controlling a program to automatically perform related operations according to the transposition state. In this way, the computer system can be automatically operated in conjunction with the transposition state, thereby improving the convenience of using the computer system.

為讓本發明之上述特徵和優點能更明顯易懂,下文特舉實施例,並配合所附圖式作詳細說明如下。The above described features and advantages of the present invention will be more apparent from the following description.

圖1是依照本發明之一實施例所繪示之電腦系統的方塊圖。請參閱圖1,電腦系統100包括嵌入式控制器(Embedded Controller,EC)110、基本輸入輸出系統(Basic Input/Output System,BIOS)120、主記憶體130、晶片組140,以及處理器150。電腦系統100例如是筆記型電腦、平板電腦,或其他具可攜性的電子裝置,在此並不對電腦系統100的種類加以限制。1 is a block diagram of a computer system in accordance with an embodiment of the present invention. Referring to FIG. 1 , the computer system 100 includes an embedded controller (EC) 110 , a basic input/output system (BIOS) 120 , a main memory 130 , a chip set 140 , and a processor 150 . The computer system 100 is, for example, a notebook computer, a tablet computer, or other portable electronic device, and the type of the computer system 100 is not limited herein.

嵌入式控制器110負責管理電腦系統100的電源,並用以管理如鍵盤或觸控墊(touch pad)等輸入裝置。在本實施例中,嵌入式控制器110例如是鍵盤控制器(Keyboard Controller,KBC)。The embedded controller 110 is responsible for managing the power of the computer system 100 and for managing input devices such as a keyboard or a touch pad. In this embodiment, the embedded controller 110 is, for example, a keyboard controller (KBC).

基本輸入輸出系統120是介於電腦系統100之軟硬體之間的介面,同時也負責電腦系統100的開機程序,例如在電腦系統100的電源被啟動後執行開機自我測試(Power On Self Test,POST)。具體來說,基本輸入輸出系統120是燒錄在唯讀記憶體(未繪示)中的程式碼。The basic input/output system 120 is an interface between the hardware and software of the computer system 100, and is also responsible for the booting process of the computer system 100, for example, performing a power on self test after the power of the computer system 100 is started. POST). Specifically, the basic input/output system 120 is a program code that is programmed in a read-only memory (not shown).

主記憶體130可以是動態隨機存取記憶體(Dynamic Random Access Memory,DRAM)或靜態隨機存取記憶體(Static Random Access Memory,SRAM)等,在此並不對主記憶體130的種類加以限制。主記憶體130用以載入各種程式與資料以供處理器150執行和運用。The main memory 130 may be a dynamic random access memory (DRAM) or a static random access memory (SRAM). The type of the main memory 130 is not limited herein. The main memory 130 is used to load various programs and materials for execution and operation by the processor 150.

晶片組140分別耦接至嵌入式控制器110、基本輸入輸出系統120、主記憶體130以及處理器150。晶片組140主要負責電腦系統100中各種硬體元件的溝通。在一實施例中,晶片組140包括南橋晶片與北橋晶片,其中南橋晶片用以連接嵌入式控制器110、基本輸入輸出系統120,以及速度較慢的週邊設備,而北橋晶片則連接如主記憶體130和處理器150等速度較快的元件。The chipset 140 is coupled to the embedded controller 110, the basic input/output system 120, the main memory 130, and the processor 150, respectively. Wafer set 140 is primarily responsible for the communication of various hardware components in computer system 100. In one embodiment, the wafer set 140 includes a south bridge wafer and a north bridge wafer, wherein the south bridge wafer is used to connect the embedded controller 110, the basic input/output system 120, and the slower peripheral devices, and the north bridge wafer is connected as the main memory. The faster components such as the body 130 and the processor 150.

處理器150例如是中央處理器(Central Processing Unit,CPU),負責控管電腦系統100的整體運作。詳言之,處理器150會執行被載入至主記憶體130的作業系統160,讓使用者能透過作業系統160與電腦系統100互動。The processor 150 is, for example, a Central Processing Unit (CPU), which is responsible for controlling the overall operation of the computer system 100. In particular, the processor 150 executes the operating system 160 that is loaded into the main memory 130 to allow the user to interact with the computer system 100 through the operating system 160.

以下將以另一實施例配合圖1來說明本發明之電腦系統控制方法的詳細流程。圖2是依照本發明之一實施例所繪示之電腦系統的控制方法的流程圖,請同時參閱圖1與圖2。The detailed flow of the computer system control method of the present invention will be described below with reference to FIG. 1 in another embodiment. 2 is a flow chart of a control method of a computer system according to an embodiment of the present invention. Please refer to FIG. 1 and FIG. 2 at the same time.

首先如步驟S210所示,當電腦系統100被轉動時,嵌入式控制器110會利用中斷訊號與一內部溝通機制使基本輸入輸出系統120得知電腦系統100目前的轉置狀態。內部溝通機制的詳細進行方式將於後配合圖示再做說明。必須說明的是,在本實施例中轉動電腦系統100是指轉動電腦系統100的整體。在另一實施例中,倘若電腦系統100是由數個部件所組成,那麼轉動電腦系統100也可以是指轉動部份的部件(例如,只轉動用以呈現畫面的顯示部件)。First, as shown in step S210, when the computer system 100 is rotated, the embedded controller 110 uses the interrupt signal and an internal communication mechanism to cause the basic input/output system 120 to know the current transposition state of the computer system 100. The detailed implementation of the internal communication mechanism will be explained later in conjunction with the diagram. It should be noted that turning the computer system 100 in the present embodiment refers to rotating the entire computer system 100. In another embodiment, if the computer system 100 is comprised of a plurality of components, the rotating computer system 100 can also be referred to as a rotating component (eg, only rotating the display component for presenting a picture).

接著在步驟S220中,基本輸入輸出系統120根據一虛擬掃瞄碼與電腦系統100目前的轉置狀態建立資料結構,並將資料結構傳送至作業系統160。其中,虛擬掃描碼是用以表示電腦系統100被轉動的預設識別碼,其長度可為3位元組(byte)。而基本輸入輸出系統120會利用主記憶體130中的一塊緩衝區域來建立資料結構,此緩衝區域可以事先配置或在需要時才動態取得。圖3是依照本發明之一實施例所繪示之資料結構的示意圖,在本實施例中,緩衝區域300包括位址00至12之間的儲存區域,其中位址00至04被定義為第一預設區域310,位址06至07則被定義為第二預設區域320。基本輸入輸出系統120在建立資料結構時,會將虛擬掃瞄碼填入第一預設區域310,並將對應於轉置狀態的轉置參數填入第二預設區域320。除此之外,基本輸入輸出系統120還會產生資料結構的標頭(header)330,以記錄緩衝區域300的實際記憶體位址等相關資訊。圖4是依照本發明之一實施例所繪示之轉置狀態與轉置參數之對應關係的示意圖。請參閱圖4,在本實施例中電腦系統100具有0度、90度、180度,以及270度這四種轉置狀態,分別對應的轉置參數為1、2、3、4。舉例來說,當電腦系統100目前的轉置狀態為90度時,基本輸入輸出系統120會將轉置參數2填入第二預設區域320。Next, in step S220, the basic input/output system 120 establishes a data structure according to a virtual scan code and the current transposition state of the computer system 100, and transmits the data structure to the operating system 160. The virtual scan code is a preset identification code used to indicate that the computer system 100 is rotated, and the length thereof may be 3 bytes. The basic input/output system 120 uses a buffer area in the main memory 130 to establish a data structure, which can be configured in advance or dynamically obtained when needed. 3 is a schematic diagram of a data structure according to an embodiment of the present invention. In this embodiment, the buffer area 300 includes a storage area between addresses 00 to 12, where addresses 00 to 04 are defined as A preset area 310, addresses 06 to 07 are defined as a second preset area 320. When the basic input/output system 120 establishes the data structure, the virtual scan code is filled into the first preset area 310, and the transposition parameter corresponding to the transposed state is filled into the second preset area 320. In addition, the basic input/output system 120 also generates a header 330 of the data structure to record related information such as the actual memory address of the buffer area 300. 4 is a schematic diagram showing the correspondence between a transposition state and a transposition parameter according to an embodiment of the invention. Referring to FIG. 4, in the embodiment, the computer system 100 has four transposition states of 0 degrees, 90 degrees, 180 degrees, and 270 degrees, and the corresponding transposition parameters are 1, 2, 3, and 4, respectively. For example, when the current transposition state of the computer system 100 is 90 degrees, the basic input/output system 120 fills the transposition parameter 2 into the second preset area 320.

請回到圖2之步驟S230,作業系統160在接收到資料結構後,會將資料結構轉傳給安裝於電腦系統100的程式,以控制此程式根據資料結構來執行與轉置狀態相關的操作。具體而言,由於資料結構的內容會反映電腦系統100已被轉動,同時也指出目前的轉置狀態,故程式能在解析資料結構後決定要執行哪種相對應的操作,進而使電腦系統100呈現對應轉置狀態的結果。Returning to step S230 of FIG. 2, after receiving the data structure, the operating system 160 transfers the data structure to the program installed in the computer system 100 to control the program to perform operations related to the transposition state according to the data structure. . Specifically, since the content of the data structure reflects that the computer system 100 has been rotated, and also indicates the current transposition state, the program can determine which corresponding operation to perform after parsing the data structure, thereby causing the computer system 100 to perform the corresponding operation. Presents the result corresponding to the transposed state.

以下將以數個實施例來說明在利用不同方式得知電腦系統被轉動時所採用之內部溝通機制,以及依照轉置狀態控制電腦系統的詳細流程。In the following, the internal communication mechanism used when the computer system is rotated in different ways and the detailed flow of controlling the computer system according to the transposition state will be described in several embodiments.

圖5是依照本發明之另一實施例所繪示之電腦系統的方塊圖。由於電腦系統500與圖1所示之電腦系統100的架構大致相似,故以下僅就兩者不同之處進行說明。FIG. 5 is a block diagram of a computer system in accordance with another embodiment of the present invention. Since the computer system 500 is substantially similar to the architecture of the computer system 100 shown in FIG. 1, only the differences between the two will be described below.

請參閱圖5,除了嵌入式控制器110、基本輸入輸出系統120、主記憶體130、晶片組140,以及處理器150之外,電腦系統500還包括耦接至嵌入式控制器110的運動感測器510。運動感測器510可以是重力感測器(G-sensor)或陀螺儀(Gyro Meter)等,用以偵測電腦系統500是否被轉動,並能取得轉動角度等資訊。一旦運動感測器510偵測到電腦系統500被轉動,嵌入式控制器110與基本輸入輸出系統120便會利用一內部溝通機制及虛擬掃描碼來通知作業系統160目前的轉置狀態,以控制安裝於電腦系統500的一或多個程式執行對應操作。Referring to FIG. 5, in addition to the embedded controller 110, the basic input/output system 120, the main memory 130, the chipset 140, and the processor 150, the computer system 500 further includes a sense of motion coupled to the embedded controller 110. Detector 510. The motion sensor 510 may be a G-sensor or a Gyro Meter, etc., for detecting whether the computer system 500 is rotated, and obtaining information such as a rotation angle. Once the motion sensor 510 detects that the computer system 500 is rotated, the embedded controller 110 and the basic input/output system 120 use an internal communication mechanism and a virtual scan code to notify the operating system 160 of the current transposition state to control. One or more programs installed in computer system 500 perform corresponding operations.

本實施例所採用的內部溝通機制是信箱(mailbox)機制。詳言之,基本輸入輸出系統120在電腦系統500啟動時會在主記憶體130指定一塊區域,並將其中的第一特定位址範圍(大小為4位元組)定義為信箱。嵌入式控制器110與基本輸入輸出系統120便是利用主記憶體130中的第一特定位址範圍相互溝通。具體來說,嵌入式控制器110可將資訊寫入第一特定位址範圍以供基本輸入輸出系統120讀取。The internal communication mechanism adopted in this embodiment is a mailbox mechanism. In detail, the basic input/output system 120 specifies an area in the main memory 130 when the computer system 500 is booted, and defines a first specific address range (a size of 4 bytes) as a mailbox. The embedded controller 110 and the basic input/output system 120 communicate with each other using a first specific address range in the main memory 130. In particular, embedded controller 110 can write information to a first particular address range for reading by basic input output system 120.

以下將以圖6來說明電腦系統500之控制方法的詳細流程,請同時參閱圖5與圖6。The detailed flow of the control method of the computer system 500 will be described below with reference to FIG. 6, please refer to FIG. 5 and FIG.

在本實施例中是由運動感測器510偵測電腦系統500是否被轉動。首先如步驟S610所示,運動感測器510在偵測到電腦系統500被轉動時,取得電腦系統500目前的轉置狀態,並將對應轉置狀態的訊號傳送至嵌入式控制器110。舉例來說,運動感測器510可透過設置通用輸入輸出(General Purpose Input/Output,GPIO)接腳以將訊號傳送至嵌入式控制器110。In the present embodiment, the motion sensor 510 detects whether the computer system 500 is rotated. First, as shown in step S610, the motion sensor 510 obtains the current transposition state of the computer system 500 when detecting that the computer system 500 is rotated, and transmits the signal corresponding to the transposition state to the embedded controller 110. For example, the motion sensor 510 can transmit a signal to the embedded controller 110 by setting a General Purpose Input/Output (GPIO) pin.

接著在步驟S620中,嵌入式控制器110解析來自運動感測器510的訊號以判斷電腦系統500目前的轉置狀態,並將用以表示電腦系統500已被轉動的虛擬掃瞄碼,以及對應目前轉置狀態的轉置參數一併寫入主記憶體130中的第一特定位址範圍。Next, in step S620, the embedded controller 110 parses the signal from the motion sensor 510 to determine the current transposition state of the computer system 500, and will indicate the virtual scan code that the computer system 500 has been rotated, and corresponding The transpose parameters of the current transposed state are collectively written into the first specific address range in the main memory 130.

接下來如步驟S630所示,嵌入式控制器110發送中斷訊號至基本輸入輸出系統120,以通知基本輸入輸出系統120去讀取第一特定位址範圍來取得虛擬掃瞄碼與轉置參數。在本實施例中,嵌入式控制器110可透過設置晶片組140的一通用輸入輸出接腳以向基本輸入輸出系統120發出中斷訊號,而此中斷訊號可以是系統管理中斷(System Management Interrupt,SMI)或系統控制中斷(System Control Interrupt,SCI)。Next, as shown in step S630, the embedded controller 110 sends an interrupt signal to the basic input/output system 120 to notify the basic input output system 120 to read the first specific address range to obtain the virtual scan code and the transpose parameter. In this embodiment, the embedded controller 110 can send an interrupt signal to the basic input/output system 120 by setting a general-purpose input/output pin of the chip set 140, and the interrupt signal can be a system management interrupt (SMI). ) or System Control Interrupt (SCI).

在基本輸入輸出系統120自第一特定位址範圍取得虛擬掃瞄碼與轉置參數後,如步驟S640所示,基本輸入輸出系統120利用取自主記憶體130的緩衝區域來建立資料結構,並將此資料結構傳送至作業系統160。其中,基本輸入輸出系統120是將虛擬掃瞄碼填入緩衝區域的第一預設區域,並將轉置參數填入緩衝區域的第二預設區域。After the basic input/output system 120 obtains the virtual scan code and the transposition parameters from the first specific address range, as shown in step S640, the basic input/output system 120 uses the buffer area of the autonomous memory 130 to establish a data structure, and This data structure is transferred to the operating system 160. The basic input/output system 120 fills the virtual scan code into the first preset area of the buffer area, and fills the transposition parameter into the second preset area of the buffer area.

當作業系統160收到資料結構,便會將此資料結構轉傳給安裝於電腦系統500的一或多個程式。When the operating system 160 receives the data structure, the data structure is forwarded to one or more programs installed on the computer system 500.

在步驟S650中,作業系統160會將資料結構傳送至顯示器應用程式,接著如步驟S660所示,顯示器應用程式根據資料結構中的虛擬掃瞄碼得知電腦系統500已被轉動,而根據資料結構中的轉置參數可判斷電腦系統500目前的轉置狀態。據此,顯示器應用程式會呼叫顯示器應用程式介面(例如,由微軟作業系統所提供的EnumDisplaySettings應用程式介面,或由顯示卡所提供的SetConfiguration應用程式介面)去根據轉置狀態來旋轉電腦系統500的螢幕畫面。舉例來說,倘若電腦系統500的轉置狀態為90度,顯示器應用程式會呼叫顯示器應用程式介面將螢幕畫面旋轉90度,進而讓使用者能以較舒適的角度觀看螢幕畫面的內容。In step S650, the operating system 160 transmits the data structure to the display application. Then, as shown in step S660, the display application knows that the computer system 500 has been rotated according to the virtual scan code in the data structure, and according to the data structure. The transpose parameter in the system can determine the current transposition state of the computer system 500. Accordingly, the display application will call the display application interface (for example, the EnumDisplaySettings application interface provided by the Microsoft operating system, or the SetConfiguration application interface provided by the display card) to rotate the computer system 500 according to the transposition state. Screen shot. For example, if the transposition status of the computer system 500 is 90 degrees, the display application will call the display application interface to rotate the screen 90 degrees, thereby allowing the user to view the contents of the screen at a more comfortable angle.

另外如步驟S670所示,作業系統160亦會將資料結構傳送至音效卡驅動程式。接著在步驟S680中,音效卡驅動程式根據資料結構中的轉置參數判斷電腦系統500目前的轉置狀態,並通知音效晶片根據轉置狀態啟動第一組麥克風或第二組麥克風。圖7是依照本發明之一實施例所繪示之電腦系統500未被轉動時的外觀示意圖(亦即,此時電腦系統500的轉置狀態為0度)。請參閱圖7,本實施例之第一組麥克風包括麥克風M1與M2,其是配置在電腦系統500未被轉動時的垂直兩側(例如分別配置在左側與右側),而第二組麥克風包括麥克風M3與M4,其是配置在電腦系統500未被轉動時的水平兩側(例如分別配置在上側與下側)。在本實施例中,當轉置狀態為90度或270度時,音效晶片會啟動第二組麥克風,而當轉置狀態為0度或180度時,音效晶片會啟動第一組麥克風。配合轉置狀態開啟對應的麥克風組讓使用者在轉動電腦系統500後,能透過適當的麥克風組獲得立體聲感受。In addition, as shown in step S670, the operating system 160 also transmits the data structure to the sound card driver. Next, in step S680, the sound card driver determines the current transposition state of the computer system 500 according to the transposition parameters in the data structure, and notifies the audio chip to activate the first group of microphones or the second group of microphones according to the transposed state. FIG. 7 is a schematic diagram of the appearance of the computer system 500 when the computer system 500 is not rotated according to an embodiment of the present invention (that is, the transposed state of the computer system 500 is 0 degrees at this time). Referring to FIG. 7, the first group of microphones in this embodiment includes microphones M1 and M2 disposed on vertical sides of the computer system 500 when not rotated (eg, respectively disposed on the left side and the right side), and the second group of microphones includes The microphones M3 and M4 are disposed on both sides of the horizontal when the computer system 500 is not rotated (for example, disposed on the upper side and the lower side, respectively). In this embodiment, when the transposition state is 90 degrees or 270 degrees, the audio chip starts the second group of microphones, and when the transposition state is 0 degrees or 180 degrees, the audio chip starts the first group of microphones. Turning on the corresponding microphone set in conjunction with the transposition state allows the user to obtain a stereo experience through the appropriate microphone set after turning the computer system 500.

圖8是依照本發明之又一實施例所繪示之電腦系統的方塊圖。由於電腦系統800與圖1所示之電腦系統100的架構大致相似,故以下僅就兩者的不同之處進行說明。FIG. 8 is a block diagram of a computer system in accordance with yet another embodiment of the present invention. Since the computer system 800 is substantially similar to the architecture of the computer system 100 shown in FIG. 1, only the differences between the two will be described below.

如圖8所示,電腦系統800除了包括嵌入式控制器110、基本輸入輸出系統120、主記憶體130、晶片組140,以及處理器150,還包括鍵盤810。鍵盤810耦接嵌入式控制器110。在本實施例中,使用者在轉動電腦系統800後,需按壓鍵盤810上的特定組合鍵(或特定按鍵)來知會系統目前的轉置狀態。舉例來說,假設電腦系統800具有0度、90度、180度,以及270度這四種轉置狀態,上述轉置狀態依序對應由鍵盤810上的“Alt”鍵分別與上、左、下、右等四個方向鍵所構成的四種特定組合鍵。基此,只要嵌入式控制器110接收到任一種特定組合鍵,表示電腦系統800已被轉動,此時嵌入式控制器110與基本輸入輸出系統120便會利用內部溝通機制及虛擬掃描碼通知作業系統160目前的轉置狀態,從而控制電腦系統800中的程式執行對應操作。As shown in FIG. 8, computer system 800 includes, in addition to embedded controller 110, basic input output system 120, main memory 130, chipset 140, and processor 150, a keyboard 810. The keyboard 810 is coupled to the embedded controller 110. In this embodiment, after rotating the computer system 800, the user needs to press a specific combination key (or a specific button) on the keyboard 810 to notify the current transposition state of the system. For example, suppose the computer system 800 has four transposition states of 0 degrees, 90 degrees, 180 degrees, and 270 degrees, and the transposition states are sequentially corresponding to the "Alt" keys on the keyboard 810, respectively, up and down, Four specific combination keys composed of four direction keys, such as lower and right. Therefore, as long as the embedded controller 110 receives any specific combination key, indicating that the computer system 800 has been rotated, the embedded controller 110 and the basic input/output system 120 will use the internal communication mechanism and the virtual scan code to notify the operation. The system 160 is currently in a transposed state, thereby controlling the programs in the computer system 800 to perform corresponding operations.

本實施例所採用的內部溝通機制是透過嵌入式控制器110之內部記憶體中的第二特定位址範圍所提供。其中,內部記憶體例如是嵌入式控制器隨機存取記憶體(Embedded Controller Random Access Memory,ECRAM),而嵌入式控制器110所定義之第二特定位址範圍的大小為4位元組。The internal communication mechanism employed in this embodiment is provided by a second specific address range in the internal memory of the embedded controller 110. The internal memory is, for example, an Embedded Controller Random Access Memory (ECRAM), and the size of the second specific address range defined by the embedded controller 110 is 4 bytes.

以下將以圖9來說明電腦系統800之控制方法的詳細流程,請同時參閱圖8與圖9。The detailed flow of the control method of the computer system 800 will be described below with reference to FIG. 9, please refer to FIG. 8 and FIG.

首先在步驟S910中,在電腦系統800接收到特定按鍵輸入(例如使用者按壓鍵盤810上的特定組合鍵)時,嵌入式控制器110會根據特定按鍵輸入來判斷電腦系統800目前的轉置狀態,並將表示電腦系統800已被轉動的虛擬掃瞄碼及對應轉置狀態的轉置參數寫入第二特定位址範圍。舉例來說,當使用者按壓“Alt”鍵與左方向鍵所構成的特定組合鍵時,嵌入式控制器110可識別出電腦系統800目前的轉置狀態為90度,進而將虛擬掃瞄碼與對應的轉置參數(例如2)寫入第二特定位址範圍。First, in step S910, when the computer system 800 receives a specific key input (for example, the user presses a specific combination key on the keyboard 810), the embedded controller 110 determines the current transposition state of the computer system 800 according to the specific key input. And the virtual scan code indicating that the computer system 800 has been rotated and the transpose parameter corresponding to the transposed state are written into the second specific address range. For example, when the user presses the specific combination key formed by the “Alt” key and the left direction key, the embedded controller 110 can recognize that the current transposition state of the computer system 800 is 90 degrees, and then the virtual scan code. Write a second specific address range with the corresponding transpose parameter (eg 2).

爾後如步驟S920所示,作業系統160因應嵌入式控制器110所發送的中斷訊號,透過基本輸入輸出系統120命令嵌入式控制器110讀取第二特定位址範圍。詳細地說,嵌入式控制器110在如步驟S910所示將虛擬掃瞄碼與轉置參數寫入第二特定位址範圍之後,嵌入式控制器110會向基本輸入輸出系統120發出中斷訊號,此中斷訊號例如是中斷要求(interrupt request,IRQ)。基本輸入輸出系統120接獲中斷訊號後,則向作業系統160發出軟體中斷。之後當作業系統160處於非忙錄狀態時,便會通知基本輸入輸出系統120去取得與按鍵輸入相關的資訊。此時,基本輸入輸出系統120會透過嵌入式控制器110的特定輸入輸出埠(例如位址60h的輸入輸出埠)要求嵌入式控制器110去讀取記錄在其內部記憶體之第二特定位址範圍中的資訊。Then, as shown in step S920, the operating system 160 instructs the embedded controller 110 to read the second specific address range through the basic input/output system 120 in response to the interrupt signal sent by the embedded controller 110. In detail, after the embedded controller 110 writes the virtual scan code and the transposition parameter to the second specific address range as shown in step S910, the embedded controller 110 sends an interrupt signal to the basic input/output system 120. The interrupt signal is, for example, an interrupt request (IRQ). After receiving the interrupt signal, the basic input/output system 120 issues a software interrupt to the operating system 160. Then, when the operating system 160 is in the non-busy state, the basic input/output system 120 is notified to obtain information related to the key input. At this time, the basic input/output system 120 requests the embedded controller 110 to read the second specific bit recorded in the internal memory through the specific input/output port of the embedded controller 110 (for example, the input/output port of the address 60h). Information in the address range.

接著如步驟S930所示,嵌入式控制器110將第二特定位址範圍所記錄的虛擬掃瞄碼與轉置參數回傳至基本輸入輸出系統120。如此一來,基本輸入輸出系統120便可根據轉置參數得知電腦系統800目前的轉置狀態。Then, as shown in step S930, the embedded controller 110 returns the virtual scan code and the transposition parameters recorded in the second specific address range to the basic input/output system 120. In this way, the basic input/output system 120 can know the current transposition state of the computer system 800 based on the transposition parameters.

接下來的步驟S940至S980是關於基本輸入輸出系統120依據虛擬掃瞄碼與轉置狀態建立資料結構,並透過作業系統160將資料結構轉傳至顯示器應用程式與音效卡驅動程式,以控制上述程式執行與轉置狀態相關之操作的詳細流程。由於圖9之步驟S940至S980與圖6之步驟S640至步驟S680相同或相似,故在此不再贅述。The following steps S940 to S980 are related to the basic input/output system 120 establishing a data structure according to the virtual scan code and the transposition state, and transferring the data structure to the display application and the sound card driver through the operating system 160 to control the above. The detailed flow of the program's operations related to the transposition state. Since steps S940 to S980 of FIG. 9 are the same as or similar to steps S640 to S680 of FIG. 6, they are not described herein again.

必須特別說明的是,在圖6與圖9所示之實施例中,一旦電腦系統被轉動,電腦系統的螢幕畫面與用以播放聲音的麥克風組都會對應轉置狀態做切換。但在本發明的另一實施例中,作業系統也可僅將資料結構傳送至顯示器應用程式,而只根據轉置狀態旋轉螢幕畫面;或者,作業系統也可以只將資料結構傳送至音效卡驅動程式,而只因應轉置狀態改變所要開啟的麥克風組。It should be particularly noted that in the embodiment shown in FIG. 6 and FIG. 9, once the computer system is rotated, the screen screen of the computer system and the microphone group for playing the sound are switched in corresponding transposition states. However, in another embodiment of the present invention, the operating system may only transfer the data structure to the display application, and only rotate the screen according to the transposition state; or the operating system may only transmit the data structure to the sound card driver. Program, and only change the microphone group to be turned on in response to the transposition status.

上述實施例雖然是以顯示器應用程式與音效卡驅動程式為例來對本發明進行說明,但本發明並不以此為限。換言之,作業系統可將接收自基本輸入輸出系統的資料結構傳送給安裝於電腦系統的任何程式,以控制該程式根據不同的電腦系統轉置狀態產生對應的結果。Although the above embodiment describes the present invention by taking a display application and a sound card driver as an example, the present invention is not limited thereto. In other words, the operating system can transfer the data structure received from the basic input/output system to any program installed on the computer system to control the program to generate corresponding results according to different computer system transposition states.

綜上所述,本發明所述之電腦系統及其控制方法是利用預設的虛擬掃描碼表示電腦系統被轉動,並透過內部溝通機制讓作業系統得知電腦系統目前的轉置狀態,從而能控制程式執行對應轉置狀態的操作。據此,在使用者轉動電腦系統後,電腦系統會自動適應轉置狀態來呈現不同的結果,以提升使用者在轉動電腦系統後進行後續操作的便利性。In summary, the computer system and the control method thereof according to the present invention use a preset virtual scan code to indicate that the computer system is rotated, and the internal communication mechanism is used to let the operating system know the current transposition state of the computer system, thereby enabling The control program performs an operation corresponding to the transposed state. Accordingly, after the user turns the computer system, the computer system automatically adapts to the transposition state to present different results, thereby improving the convenience of the user to perform subsequent operations after turning the computer system.

雖然本發明已以實施例揭露如上,然其並非用以限定本發明,任何所屬技術領域中具有通常知識者,在不脫離本發明之精神和範圍內,當可作些許之更動與潤飾,故本發明之保護範圍當視後附之申請專利範圍所界定者為準。Although the present invention has been disclosed in the above embodiments, it is not intended to limit the invention, and any one of ordinary skill in the art can make some modifications and refinements without departing from the spirit and scope of the invention. The scope of the invention is defined by the scope of the appended claims.

100、500、800...電腦系統100, 500, 800. . . computer system

110...嵌入式控制器110. . . Embedded controller

120...基本輸入輸出系統120. . . Basic input and output system

130...主記憶體130. . . Main memory

140...晶片組140. . . Chipset

150...處理器150. . . processor

160...作業系統160. . . working system

S210~S230...本發明之一實施例所述之電腦系統的控制方法之各步驟S210~S230. . . Each step of the control method of the computer system according to an embodiment of the present invention

300...緩衝區域300. . . Buffer area

310...第一預設區域310. . . First preset area

320...第二預設區域320. . . Second preset area

330...標頭330. . . Header

510...運動感測器510. . . Motion sensor

S610~S680...本發明之另一實施例所述之電腦系統的控制方法之各步驟S610~S680. . . Each step of the control method of the computer system according to another embodiment of the present invention

M1、M2、M3、M4...麥克風M1, M2, M3, M4. . . microphone

810...鍵盤810. . . keyboard

S910~S980...本發明之另一實施例所述之電腦系統的控制方法之各步驟S910~S980. . . Each step of the control method of the computer system according to another embodiment of the present invention

圖1是依照本發明之一實施例所繪示之電腦系統的方塊圖。1 is a block diagram of a computer system in accordance with an embodiment of the present invention.

圖2是依照本發明之一實施例所繪示之電腦系統的控制方法的流程圖。2 is a flow chart of a method of controlling a computer system according to an embodiment of the invention.

圖3是依照本發明之一實施例所繪示之資料結構的示意圖。FIG. 3 is a schematic diagram of a data structure according to an embodiment of the invention.

圖4是依照本發明之一實施例所繪示之轉置狀態與轉置參數之對應關係的示意圖。4 is a schematic diagram showing the correspondence between a transposition state and a transposition parameter according to an embodiment of the invention.

圖5是依照本發明之另一實施例所繪示之電腦系統的方塊圖。FIG. 5 is a block diagram of a computer system in accordance with another embodiment of the present invention.

圖6是依照本發明之另一實施例所繪示之電腦系統的控制方法的流程圖。FIG. 6 is a flow chart of a control method of a computer system according to another embodiment of the present invention.

圖7是依照本發明之一實施例所繪示之電腦系統未被轉動時的外觀示意圖。FIG. 7 is a schematic diagram showing the appearance of a computer system when it is not rotated according to an embodiment of the invention.

圖8是依照本發明之又一實施例所繪示之電腦系統的方塊圖。FIG. 8 is a block diagram of a computer system in accordance with yet another embodiment of the present invention.

圖9是依照本發明之又一實施例所繪示之電腦系統的控制方法的流程圖。FIG. 9 is a flow chart of a control method of a computer system according to still another embodiment of the present invention.

S210~S230...本發明之一實施例所述之電腦系統的控制方法之各步驟S210~S230. . . Each step of the control method of the computer system according to an embodiment of the present invention

Claims (17)

一種電腦系統的控制方法,其中該電腦系統包括一嵌入式控制器、一基本輸入輸出系統以及一作業系統,該方法包括:當該電腦系統被轉動時,由該嵌入式控制器利用一中斷訊號與一內部溝通機制使該基本輸入輸出系統得知該電腦系統目前的一轉置狀態;由該基本輸入輸出系統根據一虛擬掃瞄碼與該轉置狀態建立一資料結構,並傳送該資料結構至該作業系統;以及由該作業系統控制一程式根據該資料結構執行與該轉置狀態相關的一操作,其中該內部溝通機制是透過該基本輸入輸出系統在該電腦系統啟動時,於該電腦系統之一主記憶體所定義的一第一特定位址範圍所提供,其中該嵌入式控制器利用該中斷訊號與該內部溝通機制使該基本輸入輸出系統得知該轉置狀態的步驟包括:由該嵌入式控制器將該虛擬掃瞄碼及對應該轉置狀態的一轉置參數寫入該第一特定位址範圍;以及由該嵌入式控制器發送該中斷訊號至該基本輸入輸出系統,以通知該基本輸入輸出系統讀取該第一特定位址範圍而取得該虛擬掃瞄碼與該轉置參數。 A computer system control method, wherein the computer system includes an embedded controller, a basic input/output system, and an operating system, the method comprising: utilizing an interrupt signal by the embedded controller when the computer system is rotated And an internal communication mechanism to enable the basic input/output system to know a current transposition state of the computer system; the basic input/output system establishes a data structure according to a virtual scan code and the transposition state, and transmits the data structure And the operation system is controlled by the operating system to perform an operation related to the transposition state according to the data structure, wherein the internal communication mechanism is used by the basic input/output system when the computer system is started A first specific address range defined by one of the main memory of the system is provided, wherein the step of the embedded controller using the interrupt signal and the internal communication mechanism to make the basic input/output system aware of the transposed state comprises: Writing, by the embedded controller, the virtual scan code and a transpose parameter corresponding to the transposed state a specific address range; and the embedded controller sends the interrupt signal to the basic input/output system to notify the basic input/output system to read the first specific address range to obtain the virtual scan code and the turn Set the parameters. 如申請專利範圍第1項所述之電腦系統的控制方法,更包括: 由一運動感測器在偵測到該電腦系統被轉動時取得該電腦系統目前的該轉置狀態;以及由該運動感測器將對應該電腦系統之該轉置狀態的一訊號傳送至該嵌入式控制器。 For example, the control method of the computer system described in claim 1 of the patent scope further includes: Receiving, by the motion sensor, the current transposition state of the computer system when detecting that the computer system is rotated; and transmitting, by the motion sensor, a signal corresponding to the transposed state of the computer system to the Embedded controller. 如申請專利範圍第2項所述之電腦系統的控制方法,其中該嵌入式控制器利用該中斷訊號與該內部溝通機制使該基本輸入輸出系統得知該轉置狀態的步驟更包括:由該嵌入式控制器解析來自該運動感測器的該訊號,以判斷該電腦系統目前之該轉置狀態。 The control method of the computer system according to the second aspect of the invention, wherein the step of the embedded controller using the interrupt signal and the internal communication mechanism to enable the basic input/output system to learn the transposition state further comprises: The embedded controller parses the signal from the motion sensor to determine the current state of the transposition of the computer system. 如申請專利範圍第1項所述之電腦系統的控制方法,其中該內部溝通機制是透過該嵌入式控制器之一內部記憶體中的一第二特定位址範圍所提供,該方法更包括:在該電腦系統接收到一特定按鍵輸入時,由該嵌入式控制器根據該特定按鍵輸入判斷該電腦系統目前的該轉置狀態;以及由該嵌入式控制器將該虛擬掃瞄碼及對應該電腦系統之該轉置狀態的一轉置參數寫入該第二特定位址範圍。 The method of controlling a computer system according to the first aspect of the invention, wherein the internal communication mechanism is provided by a second specific address range in an internal memory of the embedded controller, the method further comprising: When the computer system receives a specific key input, the embedded controller determines the current transposition state of the computer system according to the specific key input; and the virtual scan code corresponding to the embedded controller A transpose parameter of the transposed state of the computer system is written to the second specific address range. 如申請專利範圍第4項所述之電腦系統的控制方法,其中該嵌入式控制器利用該中斷訊號與該內部溝通機制使該基本輸入輸出系統得知該轉置狀態的步驟包括:由該作業系統因應該嵌入式控制器所發送的該中斷訊號,透過該基本輸入輸出系統命令該嵌入式控制器讀取該第二特定位址範圍;以及由該嵌入式控制器將該第二特定位址範圍所記錄的 該虛擬掃瞄碼與該轉置參數回傳至該基本輸入輸出系統。 The control method of the computer system according to claim 4, wherein the step of the embedded controller using the interrupt signal and the internal communication mechanism to cause the basic input/output system to know the transposition state comprises: The system instructs the embedded controller to read the second specific address range through the basic input/output system according to the interrupt signal sent by the embedded controller; and the second specific address is determined by the embedded controller Recorded by the scope The virtual scan code and the transposition parameter are transmitted back to the basic input/output system. 如申請專利範圍第3或5項所述之電腦系統的控制方法,其中由該基本輸入輸出系統根據該虛擬掃瞄碼與該轉置狀態建立該資料結構的步驟包括:由該基本輸入輸出系統利用取自該電腦系統之一主記憶體的一緩衝區域建立該資料結構,其中該基本輸入輸出系統將該虛擬掃瞄碼填入該緩衝區域中的一第一預設區域,並將該轉置參數填入該緩衝區域中的一第二預設區域。 The control method of the computer system according to claim 3 or 5, wherein the step of establishing the data structure by the basic input/output system according to the virtual scan code and the transposed state comprises: the basic input/output system The data structure is established by using a buffer area taken from one of the main memory of the computer system, wherein the basic input/output system fills the virtual scan code into a first preset area in the buffer field, and the transfer The parameter is filled in a second preset area in the buffer domain. 如申請專利範圍第6項所述之電腦系統的控制方法,其中該程式為一顯示器應用程式,而由該作業系統控制該程式根據該資料結構執行與該轉置狀態相關的該操作的步驟包括:由該作業系統傳送該資料結構至該顯示器應用程式;由該顯示器應用程式根據該資料結構中的該轉置參數判斷該電腦系統的該轉置狀態;以及由該顯示器應用程式呼叫一顯示器應用程式介面以根據該轉置狀態旋轉該電腦系統的一螢幕畫面。 The control method of the computer system according to claim 6, wherein the program is a display application, and the step of controlling, by the operating system, the program to perform the operation related to the transposition state according to the data structure comprises: Transmitting the data structure to the display application by the operating system; determining, by the display application, the transposition state of the computer system based on the transposition parameter in the data structure; and calling the display application by the display application The program interface rotates a screen of the computer system according to the transposed state. 如申請專利範圍第6項所述之電腦系統的控制方法,其中該程式為一音效卡驅動程式,而由該作業系統控制該程式根據該資料結構執行與該轉置狀態相關的該操作的步驟包括:由該作業系統傳送該資料結構至該音效卡驅動程式;由該音效卡驅動程式根據該資料結構中的該轉置參數判斷該電腦系統的該轉置狀態;以及 由該音效卡驅動程式通知一音效晶片根據該轉置狀態啟動配置於該電腦系統的一第一組麥克風或一第二組麥克風,其中該第一組麥克風是配置在該電腦系統未被轉動時的垂直兩側,而該第二組麥克風是配置在該電腦系統未被轉動時的水平兩側。 The control method of the computer system according to claim 6, wherein the program is a sound card driver, and the operating system controls the step of the program to perform the operation related to the transposition state according to the data structure. The method includes: transmitting, by the operating system, the data structure to the sound card driver; determining, by the sound card driver, the transposition state of the computer system according to the transposition parameter in the data structure; Transmitting, by the sound card driver, an audio chip to activate a first set of microphones or a second set of microphones disposed on the computer system according to the transposed state, wherein the first set of microphones is configured when the computer system is not rotated The vertical sides of the second set of microphones are disposed on both sides of the horizontal when the computer system is not rotated. 一種電腦系統,包括:一嵌入式控制器;一基本輸入輸出系統;一主記憶體;一晶片組,耦接該嵌入式控制器、該基本輸入輸出系統與該主記憶體;以及一處理器,耦接該晶片組,該處理器執行被載入至該主記憶體的一作業系統,其中當該電腦系統被轉動時,該嵌入式控制器利用一中斷訊號與一內部溝通機制使該基本輸入輸出系統得知該電腦系統目前的一轉置狀態,其中該基本輸入輸出系統在該電腦系統啟動時,定義該主記憶體中的一第一特定位址範圍以作為該內部溝通機制,該基本輸入輸出系統根據一虛擬掃瞄碼與該轉置狀態建立一資料結構,並傳送該資料結構至該作業系統,該作業系統控制一程式根據該資料結構執行與該轉置狀態相關的一操作,其中該嵌入式控制器將該虛擬掃瞄碼及對應該轉置狀態的一轉置參數寫入該第一特定位址範圍,再發送該中 斷訊號至該基本輸入輸出系統,以通知該基本輸入輸出系統讀取該第一特定位址範圍而取得該虛擬掃瞄碼與該轉置參數。 A computer system comprising: an embedded controller; a basic input/output system; a main memory; a chipset coupled to the embedded controller, the basic input/output system and the main memory; and a processor Coupling the chip set, the processor executes an operating system loaded into the main memory, wherein when the computer system is rotated, the embedded controller utilizes an interrupt signal and an internal communication mechanism to enable the basic The input/output system knows a current transposition state of the computer system, wherein the basic input/output system defines a first specific address range in the main memory as the internal communication mechanism when the computer system is started, The basic input/output system establishes a data structure according to a virtual scan code and the transposition state, and transmits the data structure to the operating system, and the operating system controls a program to perform an operation related to the transposition state according to the data structure. The embedded controller writes the virtual scan code and a transpose parameter corresponding to the transposed state to the first specific address range, and then Send in the Disconnecting the signal to the basic input/output system to notify the basic input/output system to read the first specific address range to obtain the virtual scan code and the transposition parameter. 如申請專利範圍第9項所述之電腦系統,更包括:一運動感測器,耦接該嵌入式控制器,其中該運動感測器在偵測到該電腦系統被轉動時取得該電腦系統目前的該轉置狀態,並將對應該電腦系統之該轉置狀態的一訊號傳送至該嵌入式控制器。 The computer system of claim 9, further comprising: a motion sensor coupled to the embedded controller, wherein the motion sensor obtains the computer system when detecting that the computer system is rotated The current transposition state and a signal corresponding to the transposed state of the computer system is transmitted to the embedded controller. 如申請專利範圍第10項所述之電腦系統,其中該嵌入式控制器解析來自該運動感測器的該訊號以判斷該電腦系統目前之該轉置狀態。 The computer system of claim 10, wherein the embedded controller parses the signal from the motion sensor to determine the current transposition state of the computer system. 如申請專利範圍第9項所述之電腦系統,其中該嵌入式控制器定義一內部記憶體中的一第二特定位址範圍以作為該內部溝通機制。 The computer system of claim 9, wherein the embedded controller defines a second specific address range in an internal memory as the internal communication mechanism. 如申請專利範圍第12項所述之電腦系統,更包括:一鍵盤,耦接該嵌入式控制器,其中當該電腦系統接收到來自該鍵盤的一特定按鍵輸入時,該嵌入式控制器根據該特定按鍵輸入判斷該電腦系統目前的該轉置狀態,並將該虛擬掃瞄碼及對應該電腦系統之該轉置狀態的一轉置參數寫入該第二特定位址範圍。 The computer system of claim 12, further comprising: a keyboard coupled to the embedded controller, wherein when the computer system receives a specific key input from the keyboard, the embedded controller is The specific key input determines the current transposition state of the computer system, and writes the virtual scan code and a transpose parameter corresponding to the transposed state of the computer system to the second specific address range. 如申請專利範圍第13項所述之電腦系統,其中該作業系統因應該嵌入式控制器所發送的該中斷訊號,透過該基本輸入輸出系統命令該嵌入式控制器讀取該第二特定 位址範圍,該嵌入式控制器將該第二特定位址範圍所記錄的該虛擬掃瞄碼與該轉置參數回傳至該基本輸入輸出系統。 The computer system of claim 13, wherein the operating system commands the embedded controller to read the second specific through the basic input/output system according to the interrupt signal sent by the embedded controller. The address range, the embedded controller returns the virtual scan code recorded by the second specific address range and the transposition parameter to the basic input/output system. 如申請專利範圍第11或14項所述之電腦系統,其中該基本輸入輸出系統在一緩衝區域中的一第一預設區域填入該虛擬掃瞄碼,並在該緩衝區域中的一第二預設區域填入該轉置參數,其中該緩衝區域是取自該主記憶體。 The computer system according to claim 11 or 14, wherein the basic input/output system fills the virtual scan code in a first preset area in a buffer area, and is in the buffer field. The second preset area fills in the transposition parameter, wherein the buffer area is taken from the main memory. 如申請專利範圍第15項所述之電腦系統,其中該程式為一顯示器應用程式,該作業系統傳送該資料結構至該顯示器應用程式,以由該顯示器應用程式根據該資料結構中的該轉置參數判斷該電腦系統的該轉置狀態,並呼叫一顯示器應用程式介面而根據該轉置狀態旋轉該電腦系統的一螢幕畫面。 The computer system of claim 15, wherein the program is a display application, the operating system transmits the data structure to the display application, wherein the display application is based on the transposition in the data structure The parameter determines the transposed state of the computer system and calls a display application interface to rotate a screen of the computer system according to the transposed state. 如申請專利範圍第15項所述之電腦系統,其中該程式為一音效卡驅動程式,該作業系統傳送該資料結構至該音效卡驅動程式,以由該音效卡驅動程式根據該資料結構中的該轉置參數判斷該電腦系統的該轉置狀態,並通知一音效晶片根據該轉置狀態啟動配置於該電腦系統的一第一組麥克風或一第二組麥克風,其中該第一組麥克風是配置在該電腦系統未被轉動時的垂直兩側,而該第二組麥克風是配置在該電腦系統未被轉動時的水平兩側。The computer system of claim 15, wherein the program is a sound card driver, and the operating system transmits the data structure to the sound card driver, wherein the sound card driver is based on the data structure The transposition parameter determines the transposition state of the computer system, and notifies an audio chip to activate a first group of microphones or a second group of microphones configured in the computer system according to the transposition state, wherein the first group of microphones is The two sides of the microphone are disposed on both sides of the vertical when the computer system is not rotated, and the second group of microphones are disposed on both sides of the horizontal when the computer system is not rotated.
TW100133030A 2011-09-14 2011-09-14 Computer system and control method thereof TWI446179B (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
TW100133030A TWI446179B (en) 2011-09-14 2011-09-14 Computer system and control method thereof
CN201110316806.8A CN102999157B (en) 2011-09-14 2011-10-18 Computer system and control method thereof
US13/326,263 US8875138B2 (en) 2011-09-14 2011-12-14 Computer system and control method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW100133030A TWI446179B (en) 2011-09-14 2011-09-14 Computer system and control method thereof

Publications (2)

Publication Number Publication Date
TW201312360A TW201312360A (en) 2013-03-16
TWI446179B true TWI446179B (en) 2014-07-21

Family

ID=47831057

Family Applications (1)

Application Number Title Priority Date Filing Date
TW100133030A TWI446179B (en) 2011-09-14 2011-09-14 Computer system and control method thereof

Country Status (3)

Country Link
US (1) US8875138B2 (en)
CN (1) CN102999157B (en)
TW (1) TWI446179B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104808958B (en) * 2015-04-29 2018-03-13 山东超越数控电子有限公司 A kind of LVDS screen control methods based on Shen prestige notebook
CN106294117A (en) * 2015-06-12 2017-01-04 神讯电脑(昆山)有限公司 The method of testing of the embedded controller BIOS of customized machine

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005092702A (en) * 2003-09-19 2005-04-07 Toshiba Corp Information processor
TWI287204B (en) * 2005-03-18 2007-09-21 Mitac Int Corp Automatic adjustment for the picture display direction for a handheld electronic device
JP4350740B2 (en) * 2006-12-05 2009-10-21 レノボ・シンガポール・プライベート・リミテッド Portable electronic device, method for changing display direction of screen, program, and storage medium
TWI354926B (en) * 2007-11-27 2011-12-21 Inventec Besta Co Ltd Portable electronic device capable of inverse a fr
TW201019215A (en) * 2008-11-14 2010-05-16 Hon Hai Prec Ind Co Ltd Mobile terminal and method for displaying images
TW201020898A (en) * 2008-11-27 2010-06-01 Inventec Corp Method for rotating screen frame by capacitive key module

Also Published As

Publication number Publication date
CN102999157A (en) 2013-03-27
CN102999157B (en) 2015-09-30
US20130067477A1 (en) 2013-03-14
US8875138B2 (en) 2014-10-28
TW201312360A (en) 2013-03-16

Similar Documents

Publication Publication Date Title
US11902355B2 (en) Method for sharing data in local area network and electronic device
US20240144932A1 (en) Always-On Audio Control for Mobile Device
US9813662B2 (en) Transfer to target disambiguation
US20160350543A1 (en) Electronic device and method of accessing kernel data
JP2016201122A (en) Touch event model programming interface
KR102024959B1 (en) Host side implementation for hid i2c data bus
US10283117B2 (en) Systems and methods for identification of response cue at peripheral device
US20160062780A1 (en) Pausing virtual machine based on idle state
US8078800B2 (en) Dynamic operating point modification in an integrated circuit
WO2022151707A1 (en) Memory testing method and apparatus, readable storage medium, and electronic device
TWI412934B (en) External direct memory access of embedded controller memory
JP3575603B2 (en) Information processing apparatus and method, recording medium, and program
US9086843B2 (en) Audio controller
TWI446179B (en) Computer system and control method thereof
TWI590055B (en) Usb device interrupt signal
US20140267096A1 (en) Providing a hybrid touchpad in a computing device
CN112306558A (en) Processing unit, processor, processing system, electronic device, and processing method
TWI779273B (en) Multi-screen display method and electronic apparatus
US20220365805A1 (en) Device pass-through method for virtual machine and server using the same
US11182103B1 (en) Dedicated communications cache
US8578397B2 (en) System and method for supporting a remote isochronous device
TWI405080B (en) Method foe remapping memory
TWI382343B (en) Basic input/output system instruction controlling method
Bhesania et al. Host side implementation for HID I 2 C data bus