TW201442464A - The controlling system and the method of the remote device and the server - Google Patents

The controlling system and the method of the remote device and the server Download PDF

Info

Publication number
TW201442464A
TW201442464A TW102114492A TW102114492A TW201442464A TW 201442464 A TW201442464 A TW 201442464A TW 102114492 A TW102114492 A TW 102114492A TW 102114492 A TW102114492 A TW 102114492A TW 201442464 A TW201442464 A TW 201442464A
Authority
TW
Taiwan
Prior art keywords
client
remote server
virtual
virtual machine
communication port
Prior art date
Application number
TW102114492A
Other languages
Chinese (zh)
Other versions
TWI497953B (en
Inventor
Ming-Cheng Lin
Hung-Chou Lin
Original Assignee
Sunix Co Ltd
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 Sunix Co Ltd filed Critical Sunix Co Ltd
Priority to TW102114492A priority Critical patent/TWI497953B/en
Publication of TW201442464A publication Critical patent/TW201442464A/en
Application granted granted Critical
Publication of TWI497953B publication Critical patent/TWI497953B/en

Links

Landscapes

  • Computer And Data Communications (AREA)

Abstract

The controlling system and the method of the remote device and the server applies to remote the device. The device control method comprises of steps. A server generates a plurality of the virtual machine. The virtual machine generates a virtual port. When the client connects to the server, the server selects one of the virtual machines. The client connects to the selected virtual machine. The virtual machine maps the virtual port to the target port of the client. The virtual machine sends the operation command to the target port via the virtual port. When the client loses connection, the virtual machine stores the operation command into the buffer. The client connects the virtual machine again; the virtual machine sends the operation command in the buffer to device and the target port.

Description

遠端周邊的控制系統、方法及其遠端服務器 Remote peripheral control system, method and remote server thereof

一種周邊的控制系統、方法及其服務器,特別有關於一種遠端周邊的控制系統、方法及其遠端服務器。 A peripheral control system, method and server thereof are particularly related to a remote peripheral control system, method and remote server thereof.

習知的虛擬化主機僅提供文字輸入介面的環境,對於使用者而言在使用的過程多有限制。因此隨著網路架構的成熟與計算機運算能力的提昇,虛擬化主機可以提供多組虛擬桌面結構基礎(Virtual Desktop Infrastructure)給不同的終端設備(Terminal)。使用者可以透過終端設備連接至遠端服務器中的虛擬機器(Virtual Machine)後,並在終端設備的螢幕上顯示遠端服務器所運行的視窗環境的操作畫面。 The conventional virtualization host only provides an environment for the text input interface, and there are many restrictions on the process for the user to use. Therefore, as the network architecture matures and the computing power of the computer increases, the virtualization host can provide multiple sets of Virtual Desktop Infrastructures to different terminal devices (Terminal). The user can connect to the virtual machine in the remote server through the terminal device, and display the operation screen of the window environment running by the remote server on the screen of the terminal device.

遠端服務器具有提供多台虛擬機器的服務的能力,所以資訊管理人員可以在遠端服務器上進行虛擬機器的部屬。一般而言,終端設備可以不用具備快速的運算能力。因此資訊管理人員可以利用個人電腦(Personal Computer,PC)或精簡型電腦(Thin Client)作為終端設備。例如超市中的收銀機或客服中心(Call Center)中各客服人員所用的電腦都可以是前述的終端設備。 The remote server has the ability to provide services for multiple virtual machines, so the information manager can perform subordinates of the virtual machine on the remote server. In general, terminal devices do not have to have fast computing power. Therefore, information management personnel can use a personal computer (PC) or a thin computer (Thin Client) as a terminal device. For example, a cash register in a supermarket or a computer used by various customer service personnel in a Call Center may be the aforementioned terminal device.

習知的遠端服務器僅能提供顯示畫面與輸入裝置的操控處理,因此遠端服務器並無法對終端設備所連接的各種周邊設備進行調用。以RS-232的周邊設備為例,在本機的情況下,主機可以直接透過RS-232通訊埠與連接的周邊設備進行開啟、傳送、接收、停止或關閉的操作。在虛擬機器中並不存在實體的RS-232通訊埠。因此虛擬機器一旦進行應用程序時,應用程序偵測不到實體的RS-232通訊埠,應用程序將會回應錯誤訊息並終止對實體的RS-232通訊埠的操作。 The known remote server can only provide the display processing of the display screen and the input device, so the remote server cannot make calls to various peripheral devices connected to the terminal device. Taking the RS-232 peripheral device as an example, in the case of this machine, the host can directly open, transmit, receive, stop or close the connected peripheral device through the RS-232 communication port. There is no physical RS-232 communication in the virtual machine. Therefore, once the virtual machine is running the application, the application does not detect the physical RS-232 communication, and the application will respond to the error message and terminate the operation of the entity's RS-232 communication.

雖然可以透過虛擬機器與終端設備的映射處理,使得虛擬機器可以偵測到終端設備所連接的RS-232的周邊設備。當終端設備一旦中斷 與虛擬機器的連線時,虛擬機器仍可能會將操作指令發送至終端設備。由於虛擬機器並未與終端設備相連接,所以虛擬機器的應用程序就會發生找不到通訊埠的錯誤。 Although the mapping process between the virtual machine and the terminal device can be performed, the virtual machine can detect the RS-232 peripheral device to which the terminal device is connected. When the terminal device is interrupted When connecting to a virtual machine, the virtual machine may still send operational instructions to the terminal device. Since the virtual machine is not connected to the terminal device, the virtual machine's application will fail to find the communication port.

因此資訊管理人員需要再次設定通訊埠的連接。若資訊管理人員要同時對多台虛擬機器進行設定時,資訊管理人員除了上述的問題外還得另外考量虛擬機器的網路佈署的情況。這些終端設備的設定組態幾乎相同,而且這些終端設備均會與遠端服務器的虛擬機器相連接。所以在大量佈署虛擬機器的過程中,對於資訊管理人員而言是一項沈重的負擔。 Therefore, the information manager needs to set the communication port again. If the information management staff wants to set up multiple virtual machines at the same time, the information management personnel must consider the network deployment of the virtual machine in addition to the above problems. The configuration of these terminal devices is almost identical, and these terminal devices are connected to the virtual machines of the remote server. Therefore, in the process of deploying virtual machines in a large amount, it is a heavy burden for information managers.

除了前述的連線遺失的錯誤外,虛擬機器也會發生辨識終端設備連接的周邊設備的問題。而這些問題也同樣的會出現在終端設備的其他種類的通訊埠。 In addition to the aforementioned missing errors in the connection, the virtual machine also has a problem of identifying peripheral devices connected to the terminal device. These problems also occur in other types of communication devices in the terminal device.

鑒於以上的問題,本發明在於提供一種遠端周邊的控制系統,遠端服務器與客戶端所連接的周邊設備進行映射處理,其特徵在於即時的資料輸出或輸入處理的周邊設備的控制。 In view of the above problems, the present invention provides a remote peripheral control system. The remote server performs mapping processing with peripheral devices connected to the client, and is characterized by immediate data output or control of peripheral devices for input processing.

本發明所揭露之遠端周邊的控制系統包括客戶端與遠端服務器。客戶端具有多個目標通訊埠,每一目標通訊埠各自耦接周邊設備;遠端服務器於運行應用程序時產生至少一虛擬通訊埠與緩存空間;客戶端與遠端服務器未連線時,遠端服務器將應用程序發向虛擬通訊埠的操作指令儲存於緩存空間;遠端服務器會模擬目標通訊埠的正常回應動作,並將該些回應傳回應用程序;當客戶端連線至遠端服務器,遠端服務器將虛擬通訊埠映射於該客戶端的目標通訊埠,遠端服務器將緩存空間中的操作指令傳送至客戶端。 The remote peripheral control system disclosed by the present invention includes a client and a remote server. The client has multiple target communications, each of which is coupled to the peripheral device; the remote server generates at least one virtual communication port and cache space when the application is running; when the client and the remote server are not connected, the far The server stores the operation instructions sent by the application to the virtual communication port in the cache space; the remote server simulates the normal response action of the target communication port, and transmits the responses back to the application; when the client connects to the remote server The remote server maps the virtual communication port to the target communication port of the client, and the remote server transmits the operation instruction in the cache space to the client.

本發明另揭露之遠端周邊的控制方法,其係包括以下步驟:當遠端服務器運行應用程序時,產生至少一虛擬通訊埠與緩存空間;等待客戶端的連線至遠端服務器;在客戶端未連線至遠端服務器的期間中,應用程序向虛擬通訊埠下達操作指令,則遠端服務器將操作指令暫存於緩存空間;若客戶端連線至遠端服務器時,遠端服務器將每一個虛擬通訊埠對應客戶端的目標通訊埠;若客戶端與遠端服務器中斷連線時,遠端服務器 將操作指令暫存於緩存空間中;當客戶端再次連接於遠端服務器時,遠端服務器將暫存於緩存空間的操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備。 The remote peripheral control method of the present invention further comprises the steps of: generating at least one virtual communication port and buffer space when the remote server runs the application; waiting for the client to connect to the remote server; During the period when the server is not connected to the remote server, the application sends an operation command to the virtual communication port, and the remote server temporarily stores the operation instruction in the cache space; if the client connects to the remote server, the remote server will each A virtual communication port corresponds to the target communication of the client; if the client and the remote server are disconnected, the remote server The operation instruction is temporarily stored in the cache space; when the client is connected to the remote server again, the remote server maps the operation instruction temporarily stored in the cache space to the corresponding target communication port and the peripheral device through the virtual communication port.

本發明揭露之遠端周邊的控制方法,其係包括以下步驟:於遠端服務器中佈署多台虛擬機器,虛擬機器運行應用程序時產生至少一虛擬通訊埠與緩存空間,應用程序向虛擬通訊埠發送操作指令;若客戶端與虛擬機器未連線時,虛擬機器將操作指令暫存於緩存空間中;若客戶端與虛擬機器連線時,虛擬機器將這些虛擬通訊埠與客戶端的多個目標通訊埠進行映射處理,虛擬機器透過虛擬通訊埠將操作指令傳送至目標通訊埠。 The remote peripheral control method disclosed in the present invention includes the following steps: deploying multiple virtual machines in a remote server, and generating at least one virtual communication port and cache space when the virtual machine runs the application, and the application program is virtual communication埠 Send operation instructions; if the client and the virtual machine are not connected, the virtual machine temporarily stores the operation instructions in the cache space; if the client connects to the virtual machine, the virtual machine smashes the virtual communication with the client. The target communication is mapped, and the virtual machine transmits the operation command to the target communication port through the virtual communication.

本發明更揭露一種遠端服務器,其係包括網路傳輸介面與控制單元;網路傳輸介面連接至少一客戶端;控制單元連接於該網路傳輸介面;控制單元運行至少一虛擬機器,虛擬機器均具有多個虛擬通訊埠與緩存空間,虛擬機器將操作指令發送至虛擬通訊埠;客戶端連線至遠端服務器,控制單元選擇任一虛擬機器,並將虛擬機器連接於客戶端,當客戶端連接於遠端服務器時,虛擬機器透過虛擬通訊埠將操作指令映射至客戶端並將操作指令傳送至客戶端的目標通訊埠,當客戶端中斷與虛擬機器的連線時,虛擬機器將操作指令儲存於緩存空間。 The invention further discloses a remote server, which comprises a network transmission interface and a control unit; the network transmission interface is connected to at least one client; the control unit is connected to the network transmission interface; and the control unit runs at least one virtual machine, the virtual machine Each has multiple virtual communication ports and cache space, the virtual machine sends operation instructions to the virtual communication port; the client connects to the remote server, the control unit selects any virtual machine, and connects the virtual machine to the client, when the client When the terminal is connected to the remote server, the virtual machine maps the operation instruction to the client through the virtual communication port and transmits the operation instruction to the target communication port of the client. When the client interrupts the connection with the virtual machine, the virtual machine operates the instruction. Stored in the cache space.

本發明所揭露之遠端周邊的控制系統包括客戶端與遠端服務器。客戶端具有多個目標通訊埠,每一目標通訊埠各自耦接周邊設備;遠端服務器連接於客戶端,客戶端與遠端服務器連線時,遠端服務器根據客戶端的確認資訊產生緩存空間與至少一虛擬通訊埠,遠端服務器將操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備;客戶端與遠端服務器連接中斷時,遠端服務器將發送至客戶端的操作指令儲存於緩存空間,直至客戶端連接於遠端服務器時,遠端服務器將緩存空間中的操作指令傳送至客戶端。 The remote peripheral control system disclosed by the present invention includes a client and a remote server. The client has multiple target communication ports, each of which is coupled to the peripheral device; the remote server is connected to the client, and when the client is connected to the remote server, the remote server generates the cache space according to the confirmation information of the client. After at least one virtual communication, the remote server maps the operation command to the corresponding target communication device and the peripheral device through the virtual communication port; when the connection between the client and the remote server is interrupted, the remote server stores the operation instruction sent to the client terminal. The cache space, until the client connects to the remote server, the remote server transmits the operation instructions in the cache space to the client.

本發明所提出的遠端周邊的控制系統、方法及其遠端服務器除了可以辨識終端設備所連接的周邊設備,也可以在中斷連線的期間中確保虛擬機器對於周邊設備的存取過程中不會發生錯誤。有關本發明的特徵與實作,茲配合圖式作最佳實施例詳細說明如下。 The remote peripheral control system and method and the remote server thereof provided by the present invention can recognize the peripheral devices connected to the terminal device, and can also ensure that the virtual machine does not access the peripheral devices during the disconnection period. An error will occur. The features and implementations of the present invention are described in detail below with reference to the drawings.

110‧‧‧客戶端 110‧‧‧Client

111‧‧‧處理單元 111‧‧‧Processing unit

112‧‧‧網路存取單元 112‧‧‧Network access unit

113‧‧‧目標通訊埠 113‧‧‧Target Communication埠

114‧‧‧第一儲存單元 114‧‧‧First storage unit

120‧‧‧遠端服務器 120‧‧‧Remote Server

121‧‧‧控制單元 121‧‧‧Control unit

122‧‧‧第二儲存單元 122‧‧‧Second storage unit

123‧‧‧網路傳輸介面 123‧‧‧Network transmission interface

124、513‧‧‧虛擬通訊埠 124, 513‧‧‧Virtual Communications埠

125、512‧‧‧緩存空間 125, 512‧‧‧ cache space

126‧‧‧映射表 126‧‧‧ mapping table

130‧‧‧周邊設備 130‧‧‧ Peripherals

500‧‧‧虛擬機器 500‧‧‧Virtual Machine

510‧‧‧虛擬控制單元 510‧‧‧Virtual Control Unit

514‧‧‧虛擬第二儲存單元 514‧‧‧Virtual second storage unit

515‧‧‧虛擬網路傳輸介面 515‧‧‧Virtual network transmission interface

710‧‧‧收銀機 710‧‧‧ cash register

721‧‧‧條碼讀取器 721‧‧‧Barcode reader

722‧‧‧印表機 722‧‧‧Printer

723‧‧‧螢幕 723‧‧‧ screen

724‧‧‧讀卡機 724‧‧‧ card reader

725‧‧‧錢箱 725‧‧‧ cash box

731‧‧‧COM1通訊埠 731‧‧‧COM1 Communication埠

732‧‧‧LTP通訊埠 732‧‧‧LTP Communication埠

733‧‧‧視頻圖形陣列通訊埠 733‧‧‧Video Graphics Array Communication埠

734‧‧‧COM2通訊埠 734‧‧‧COM2 Communication埠

735‧‧‧USB通訊埠 735‧‧‧USB communication埠

第1圖係為本發明的架構示意圖。 Figure 1 is a schematic diagram of the architecture of the present invention.

第2圖係為本發明的客戶端架構示意圖。 Figure 2 is a schematic diagram of the client architecture of the present invention.

第3圖係為本發明的遠端服務器的架構示意圖。 Figure 3 is a schematic diagram of the architecture of the remote server of the present invention.

第4圖係分別為本發明的運作流程示意圖。 Figure 4 is a schematic diagram of the operational flow of the present invention.

第5圖係分別為本發明另一實施態樣的架構示意圖。 Figure 5 is a schematic diagram of the architecture of another embodiment of the present invention.

第6圖係為本發明的另一種實施態樣的運作流程示意圖。 Figure 6 is a schematic diagram of the operational flow of another embodiment of the present invention.

第7A圖係為本發明的運作過程示意圖。 Figure 7A is a schematic diagram of the operation of the present invention.

第7B圖係為本發明的運作過程示意圖。 Figure 7B is a schematic diagram of the operation of the present invention.

第7C圖係為本發明的運作過程示意圖。 Figure 7C is a schematic diagram of the operation of the present invention.

第7D圖係為本發明的運作過程示意圖。 Figure 7D is a schematic diagram of the operation of the present invention.

第8圖係為本發明的遠端服務器的架構示意圖。 Figure 8 is a schematic diagram of the architecture of the remote server of the present invention.

第9圖係分別為本發明的運作流程示意圖。 Figure 9 is a schematic diagram of the operational flow of the present invention.

第10圖係分別為本發明另一實施態樣的架構示意圖。 Figure 10 is a schematic diagram showing the architecture of another embodiment of the present invention.

第11圖係為本發明的另一種實施態樣的運作流程示意圖。 Figure 11 is a schematic diagram of the operational flow of another embodiment of the present invention.

第12圖係為本發明的此一種實施態樣的運作流程示意圖。 Figure 12 is a schematic diagram of the operational flow of this embodiment of the present invention.

第13圖係為本發明的映射表的架構示意圖。 Figure 13 is a schematic diagram of the architecture of the mapping table of the present invention.

請參考第1圖所示,其係為本發明的架構示意圖。本發明的遠端周邊的控制系統包括客戶端110與遠端服務器120。遠端服務器120透過網路連結至少一個客戶端110。客戶端110可以藉由精簡型電腦、個人電腦、嵌入式系統(Embedded System)或具有運算能力與網路連接能力的計算裝置所實現。客戶端110可以選擇連接所需的周邊設備130。 Please refer to FIG. 1 , which is a schematic diagram of the architecture of the present invention. The remote peripheral control system of the present invention includes a client 110 and a remote server 120. The remote server 120 connects at least one client 110 over the network. The client 110 can be implemented by a compact computer, a personal computer, an embedded system, or a computing device having computing power and network connectivity. Client 110 may choose to connect peripheral devices 130 as needed.

請參考第2圖所示,其係為本發明的客戶端架構示意圖。本發明的客戶端110包括:處理單元111、網路存取單元112、多個目標通訊埠113與第一儲存單元114。處理單元111耦接於網路存取單元112、第一儲存單元114與該些目標通訊埠113。網路存取單元112用以連接遠端服務 器120。處理單元111經由網路存取單元112傳送或接收來自於遠端服務器120的資料封包。舉例來說,遠端服務器120將其操作畫面可以透過網路傳送至客戶端110,客戶端110在藉由網路存取單元112接收操作畫面。網路存取單元112並不限定為有線或無線的連接方式。第一儲存單元114用以儲存客戶端110在運作時的相關程式,例如作業系統(Operation System,簡稱OS)、通訊埠映射的代理程序(Agent)或網路傳輸的處理程序。第一儲存單元114可以由快閃記憶體(flash memory)實現,也可以是唯讀記憶體(Read Only Memory,簡稱ROM)或硬碟等方式實現。此外,客戶端110另可以連接顯示器,顯示器用以繪製來自於遠端服務器120所輸出的作業系統的操作畫面。 Please refer to FIG. 2, which is a schematic diagram of the client architecture of the present invention. The client 110 of the present invention includes a processing unit 111, a network access unit 112, a plurality of target communication ports 113, and a first storage unit 114. The processing unit 111 is coupled to the network access unit 112, the first storage unit 114, and the target communication ports 113. The network access unit 112 is used to connect to the remote service. 120. The processing unit 111 transmits or receives a data packet from the remote server 120 via the network access unit 112. For example, the remote server 120 can transmit its operation screen to the client 110 through the network, and the client 110 receives the operation screen through the network access unit 112. The network access unit 112 is not limited to a wired or wireless connection. The first storage unit 114 is configured to store related programs of the client 110 during operation, such as an operation system (OS), a communication agent (Agent), or a network transmission processing program. The first storage unit 114 can be implemented by a flash memory or a read only memory (ROM) or a hard disk. In addition, the client 110 may be further connected to a display for drawing an operation screen from the operating system output by the remote server 120.

目標通訊埠113的種類係為串列通訊埠(Parallel Port)或並列通訊埠(Serial Port)。目標通訊埠113用以連接周邊設備130。周邊設備130的種類可以是但不限定為條碼讀取器(Bar Code Reader)、錢箱(Cash Box Drawer)、讀卡機(Card Reader)或印表機。而目標通訊埠113除了可以是客戶端110自身所具備的通訊埠外,也可以是客戶端110在擴充後的通訊埠。舉例來說,客戶端110可以自行加裝具有多個串口(意即本發明所述的通訊埠)的介面卡,而此一加裝的介面卡在本發明中也可被視為目標通訊埠113。 The type of the target communication port 113 is a Parallel Port or a Serial Port. The target communication port 113 is used to connect the peripheral device 130. The type of the peripheral device 130 may be, but not limited to, a Bar Code Reader, a Cash Box Drawer, a Card Reader, or a printer. The target communication port 113 can be the communication port of the client 110 itself, or the extended communication port of the client 110. For example, the client 110 can add an interface card having a plurality of serial ports (that is, the communication port of the present invention), and the added interface card can also be regarded as a target communication in the present invention. 113.

對於本發明而言,人機介面裝置(Human Interface Device,簡稱HID)的配置雖然也是可以透過遠端服務器120(或虛擬機器,關於虛擬機器的描述將於後文另外解說)所決定。但HID是由作業系統(亦即應用程序層(Application Layer))所決定,因此HID的配置(Configuration)設定均為相同。換言之,HID的配置不會因為不同機器而有所改變。而本發明所述的周邊設備130由於需進行硬體層的設定,因此本發明的周邊設備130與HID在配置的層級別上是有所差異的。 For the purposes of the present invention, the configuration of the Human Interface Device (HID) can be determined by the remote server 120 (or virtual machine, and the description of the virtual machine will be explained later). However, the HID is determined by the operating system (that is, the application layer), so the configuration settings of the HID are the same. In other words, the configuration of the HID will not change due to different machines. However, since the peripheral device 130 of the present invention needs to set the hardware layer, the peripheral device 130 and the HID of the present invention are different in the layer level of the configuration.

請參考第3圖所示,其係為本發明的遠端服務器的架構示意圖。遠端服務器120更包括:控制單元121、第二儲存單元122、網路傳輸介面123、虛擬通訊埠124與緩存空間125。控制單元121耦接於第二儲存單元122與網路傳輸介面123。第二儲存單元122除了可以儲存虛擬機器的 應用程序,也可以儲存客戶端110所需要運行的應用程序。控制單元121透過網路傳輸介面123與所連接的客戶端110進行資料的交換。在遠端服務器120中配置至少一個虛擬通訊埠124。在本發明中為能區別終端設備上的目標通訊埠113,因此將遠端服務器120上所配置的通訊埠定義為虛擬通訊埠124。此外,虛擬通訊埠124也可能是遠端服務器120中的實體的通訊埠。 Please refer to FIG. 3, which is a schematic diagram of the architecture of the remote server of the present invention. The remote server 120 further includes: a control unit 121, a second storage unit 122, a network transmission interface 123, a virtual communication port 124, and a cache space 125. The control unit 121 is coupled to the second storage unit 122 and the network transmission interface 123. The second storage unit 122 can store the virtual machine in addition to The application can also store the application that the client 110 needs to run. The control unit 121 exchanges data with the connected client 110 through the network transmission interface 123. At least one virtual communication port 124 is configured in the remote server 120. In the present invention, it is possible to distinguish the target communication port 113 on the terminal device, and thus the communication port configured on the remote server 120 is defined as the virtual communication port 124. In addition, the virtual communication port 124 may also be the communication port of the entity in the remote server 120.

緩存空間125可以是由實體的儲存設備所實現(例如:硬碟、固態磁碟(solid-state drive,SSD)),也可以由各遠端服務器120依據動態配置所完成。緩存空間125的容量可以根據不同的使用情況所決定,所以在本發明中並不侷限緩存空間125的容量。為清楚表現本發明的具體架構,因此在第3圖中還是將緩存空間125以獨立元件作為表示。緩存空間125用以暫存發向周邊設備130的操作指令。 The cache space 125 can be implemented by a physical storage device (for example, a hard disk, a solid-state drive (SSD)), or can be completed by each remote server 120 according to a dynamic configuration. The capacity of the cache space 125 can be determined according to different usage conditions, so the capacity of the cache space 125 is not limited in the present invention. To clearly illustrate the specific architecture of the present invention, the cache space 125 is also represented in Figure 3 as a separate component. The cache space 125 is used to temporarily store the operation instructions sent to the peripheral device 130.

請參考第4圖所示,其係分別為本發明的運作流程示意圖。本發明的遠端服務器120對周邊設備130的控制方法包括以下步驟:步驟S410:當遠端服務器運行應用程序時,產生至少一虛擬通訊埠與緩存空間;步驟S420:等待客戶端的連線至遠端服務器;步驟S430:在客戶端未連線至遠端服務器的期間中,應用程序向虛擬通訊埠下達操作指令,則遠端服務器將操作指令暫存於緩存空間;步驟S440:客戶端透過網路連接至遠端服務器,遠端服務器確認客戶端的目標通訊埠的種類與數量;步驟S441:若客戶端不符合所述條件時,遠端服務器斷開與客戶端的連線;步驟S442:若客戶端符合所述條件時,遠端服務器將每一個虛擬通訊埠對應客戶端的目標通訊埠;步驟S450:遠端服務器透過虛擬通訊埠將操作指令轉發至客戶端與所相應的目標通訊埠;步驟S460:判斷客戶端的連線是否發生中斷;步驟S461:若客戶端與遠端服務器連線時,遠端服務器透過虛擬通訊 埠將操作指令傳送至目標通訊埠與所連接的周邊設備;步驟S462:若客戶端與遠端服務器中斷連線時,遠端服務器將操作指令暫存於緩存空間中;以及步驟S470:當客戶端再次連接於遠端服務器時,遠端服務器將暫存於緩存空間的操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備。 Please refer to FIG. 4, which is a schematic diagram of the operational flow of the present invention. The method for controlling the peripheral device 130 of the remote server 120 of the present invention includes the following steps: Step S410: When the remote server runs the application, generate at least one virtual communication port and the cache space; Step S420: Wait for the connection of the client to the far end End server; step S430: in the period when the client is not connected to the remote server, the application sends an operation instruction to the virtual communication, the remote server temporarily stores the operation instruction in the cache space; step S440: the client accesses the network The path is connected to the remote server, and the remote server confirms the type and quantity of the target communication port of the client; Step S441: If the client does not meet the condition, the remote server disconnects from the client; Step S442: If the client When the terminal meets the condition, the remote server communicates each virtual communication port with the target communication of the client; step S450: the remote server forwards the operation instruction to the client and the corresponding target communication port through the virtual communication; step S460 : determining whether the connection of the client is interrupted; step S461: if the client is connected to the remote server Remote server through a virtual communications 传送 transmitting the operation command to the target communication device and the connected peripheral device; step S462: if the client disconnects with the remote server, the remote server temporarily stores the operation instruction in the cache space; and step S470: when the client When the terminal is connected to the remote server again, the remote server maps the operation instructions temporarily stored in the cache space to the corresponding target communication port and the peripheral device through the virtual communication port.

首先,遠端服務器120啟動後,遠端服務器120可以預先產生至少一虛擬通訊埠124。產生虛擬通訊埠124的時機可以在客戶端110連線至遠端服務器120之前,也可以在客戶端110連線至遠端服務器120之後。而虛擬通訊埠124的種類與數量可以根據不同的環境而改變。當客戶端110第一次連接於遠端服務器120時,遠端服務器120會收到客戶端110的連線要求。本發明的連線要求中至少包括目標通訊埠113的種類與數量。遠端服務器120判斷虛擬通訊埠124的種類與數量是否滿足客戶端110的連線要求。當遠端服務器120的虛擬通訊埠124的種類與數量均滿足連線要求時,遠端服務器120將虛擬通訊埠124映射於客戶端110的目標通訊埠113。在此所稱的滿足連線要求的定義係為:虛擬通訊埠124的種類與目標通訊埠113,且虛擬通訊埠124的數量與目標通訊埠113的數量一致。 First, after the remote server 120 is started, the remote server 120 can generate at least one virtual communication port 124 in advance. The timing of generating the virtual communication port 124 may be before the client 110 is connected to the remote server 120, or after the client 110 is connected to the remote server 120. The type and number of virtual communication ports 124 can be changed according to different environments. When the client 110 connects to the remote server 120 for the first time, the remote server 120 receives the connection request from the client 110. At least the type and number of target communication ports 113 are included in the connection requirements of the present invention. The remote server 120 determines whether the type and number of the virtual communication ports 124 meet the connection requirements of the client 110. When the type and quantity of the virtual communication port 124 of the remote server 120 meet the connection requirements, the remote server 120 maps the virtual communication port 124 to the target communication port 113 of the client 110. The definition of meeting the connection requirement is as follows: the type of virtual communication port 124 and the target communication port 113, and the number of virtual communication ports 124 is consistent with the number of target communication ports 113.

當客戶端110的連線要求符合時,遠端服務器120會決定是否接受目前要求連接的客戶端110。若是連線要求不符合時,遠端服務器120將會拒絕與客戶端110的連線要求。換言之,客戶端110的目標通訊埠113的種類與虛擬通訊埠124的種類不一致時,遠端服務器120將不會對該客戶端110提供連線的相關服務。若客戶端110的目標通訊埠113的種類符合虛擬通訊埠124的種類時,則遠端服務器120會進一步的比對每一種目標通訊埠113的數量是否與相應的虛擬通訊埠124的數量。 When the connection requirements of the client 110 are met, the remote server 120 will decide whether to accept the client 110 that is currently required to connect. If the connection request is not met, the remote server 120 will reject the connection request with the client 110. In other words, when the type of the target communication port 113 of the client 110 does not match the type of the virtual communication port 124, the remote server 120 will not provide the associated service to the client 110. If the type of the target communication port 113 of the client 110 conforms to the type of the virtual communication port 124, the remote server 120 further compares the number of each of the target communication ports 113 with the number of corresponding virtual communication ports 124.

若是客戶端110的目標通訊埠113的數量少於或等於虛擬通訊埠124的數量,遠端服務器120才會向客戶端110進行連線與映射的處理。在遠端服務器120確認後,遠端服務器120將操作指令轉換為網路封包,並將網路路封包傳送至客戶端110,客戶端110將網路封包轉換為操作指令,將操作指令驅動目標通訊埠113與周邊設備130。 If the number of target communication ports 113 of the client 110 is less than or equal to the number of virtual communication ports 124, the remote server 120 performs processing of connection and mapping to the client 110. After the remote server 120 confirms, the remote server 120 converts the operation instruction into a network packet, and transmits the network path packet to the client 110, and the client 110 converts the network packet into an operation instruction, and drives the operation instruction to drive the target. The communication port 113 and the peripheral device 130.

在客戶端110與遠端服務器120連線的過程中可能由於操作或網路品質不佳等原因,使得客戶端110與遠端服務器120的連線產生中斷。一旦發生連線中斷的問題,遠端服務器120可以透過網路傳輸介面123得到連線是否異常的反饋回應。當遠端服務器120與客戶端110間發生連線中斷時,遠端服務器120會開始擷取操作指令,並判斷操作指令的種類並決定是否需要進行模擬該操作指令回應的處理。所述的操作指令可以被分類為設定種類與操作種類。設定種類泛指的是設定周邊設備的環境的指令。而操作種類的目的在於控制各項周邊設備。舉例來說,設定種類的操作指令係為開啟通訊埠、設定鮑率(baud rate)等。而操作種類的操作指令係為讀取、寫入或暫停等。 During the connection between the client 110 and the remote server 120, the connection between the client 110 and the remote server 120 may be interrupted due to reasons such as poor operation or network quality. In the event of a connection interruption, the remote server 120 can obtain an abnormal feedback response via the network transmission interface 123. When a connection interruption occurs between the remote server 120 and the client 110, the remote server 120 starts to retrieve an operation instruction, determines the type of the operation instruction, and determines whether it is necessary to perform a process of simulating the operation instruction response. The operation instructions described can be classified into a set type and an operation type. The setting type generally refers to an instruction to set the environment of the peripheral device. The purpose of the operation type is to control various peripheral devices. For example, the operation command of the set type is to open the communication port, set the baud rate, and the like. The operation instructions of the operation type are read, write or pause.

遠端服務器120偵測中斷連線時,遠端服務器120會對操作指令進行分類的處理。若是操作指令屬於前述的設定種類,遠端服務器120會以模擬的方式執行該筆操作指令。例如:遠端服務器120接到開啟通訊埠時,遠端服務器120會向應用程序發送開啟成功的回應訊息。若是操作指令係為操作種類,遠端服務器120會將操作指令轉存至緩存空間125中,使得操作指令不會直接傳達至虛擬通訊埠124。因此虛擬通訊埠124不會將操作指令映射至客戶端110。如此一來就避免虛擬通訊埠124無法收到客戶端110的回應會產生操作上的錯誤。此外,客戶端110於中斷連線的期間也可以將所接收到的各項操作存儲在所屬的記憶體之中。當客戶端110與遠端服務器120再次連線時,客戶端110將記憶體中的各項操作依序的傳送至遠端服務器120。 When the remote server 120 detects the disconnection, the remote server 120 processes the operation instructions. If the operation command belongs to the aforementioned setting type, the remote server 120 executes the operation command in an analog manner. For example, when the remote server 120 receives the communication port, the remote server 120 sends a response message to the application that the connection is successful. If the operation command is an operation type, the remote server 120 dumps the operation instruction into the cache space 125 so that the operation instruction is not directly transmitted to the virtual communication port 124. Therefore, the virtual communication port 124 does not map the operation instructions to the client 110. As a result, the virtual communication 124 is prevented from receiving the response of the client 110, which may cause an operational error. In addition, the client 110 may store the received operations in the associated memory during the disconnection. When the client 110 and the remote server 120 are connected again, the client 110 sequentially transfers the operations in the memory to the remote server 120.

以RS-232通訊埠作為目標通訊埠113為示例說明,應用程序會對RS-232通訊埠與所連接的周邊設備130會進行開啟、設定、讀取、寫入與結束等操作指令。當虛擬通訊埠124下達所述的操作指令時,由於網路中斷的緣故使得操作指令不會下達到周邊設備130。所以虛擬通訊埠124就不會收到相關的回應。因此習知技術的遠端服務器120在操作逾期後就會發生通訊埠錯誤的問題。於此同時,客戶端110也會將所發出的操作暫存於所屬的記憶體中。本發明的遠端服務器120在偵測到網路連線中斷後,遠端服務器120會將操作指令暫存至緩存空間125中。當遠端服務器 120偵測到客戶端110再次連結上,遠端服務器120則將會把緩存空間125中的操作指令依序的發送至客戶端110與周邊設備130。客戶端110也會將記憶體裡的各項操作傳送至遠端服務器120。 Taking the RS-232 communication port as the target communication port 113 as an example, the application program will open, set, read, write, and end the RS-232 communication port and the connected peripheral device 130. When the virtual communication port 124 issues the operation command, the operation command does not reach the peripheral device 130 due to the network interruption. Therefore, the virtual communication 埠124 will not receive the relevant response. Therefore, the remote server 120 of the prior art has a problem of communication error after the operation is overdue. At the same time, the client 110 also temporarily stores the issued operation in the associated memory. After detecting the network connection interruption, the remote server 120 of the present invention temporarily stores the operation instruction into the buffer space 125. Remote server 120 detects that the client 110 is connected again, and the remote server 120 will sequentially send the operation instructions in the cache space 125 to the client 110 and the peripheral device 130. The client 110 also transmits operations in the memory to the remote server 120.

舉例來說,當遠端服務器120在未與客戶端110連接時,遠端服務器120就會開始運行應用程序。應用程序會預先開啟RS-232通訊埠。遠端服務器120會將開啟的操作指令存入緩存空間125中。遠端服務器120會等待客戶端110連線過來。當客戶端110再次連線至遠端服務器120時,遠端服務器120會從緩存空間125中將操作指令取出並透過虛擬通訊埠124發送至客戶端110。 For example, when the remote server 120 is not connected to the client 110, the remote server 120 will begin running the application. The application will pre-open the RS-232 communication port. The remote server 120 stores the opened operational commands in the cache space 125. The remote server 120 will wait for the client 110 to connect. When the client 110 is again connected to the remote server 120, the remote server 120 fetches the operation instructions from the cache space 125 and transmits them to the client 110 via the virtual communication port 124.

除了所述的實施態樣外,本發明更可以對操作指令進行分類,並於分類後再決定是否直接回應或儲存在緩存空間125中。承接前文所述的例子,由於開啟與關閉的操作指令是屬於固定的宣告操作。因此遠端服務器120可以將對應結果先回應給應用程序。若是屬於設定、寫入或讀取的操作指令,由於該些操作指令並無法透過模擬的方式產生結果。所以遠端服務器120會將該些操作指令存入緩存空間125中,暫待客戶端110連接至遠端服務器120。 In addition to the described embodiments, the present invention can further classify operational instructions and, after sorting, decide whether to directly respond or store in the cache space 125. Following the example described above, the open and close operational commands are fixed announcement operations. Therefore, the remote server 120 can respond to the application with the corresponding result. If it is an operation command that is set, written, or read, the result cannot be generated by simulation because of these operation instructions. Therefore, the remote server 120 stores the operation instructions in the cache space 125, and the temporary client 110 connects to the remote server 120.

除了前述遠端服務器120可以與客戶端110直接進行連接與通訊埠的映射處理外,本發明另可以應用在虛擬機器500的通訊埠映射處理中。由於遠端服務器120的運算能力可以提供多個客戶端110所要求的服務。因此遠端服務器120上可以運行多台的虛擬機器500,請參考第5圖所示。每一虛擬機器500配置有:虛擬控制單元510、緩存空間512、虛擬通訊埠513、虛擬第二儲存單元514與虛擬網路傳輸介面515。虛擬控制單元510連接於緩存空間512、虛擬通訊埠513、虛擬第二儲存單元514與虛擬網路傳輸介面515。而緩存空間512、虛擬通訊埠513、虛擬第二儲存單元514與虛擬網路傳輸介面515分別與前述遠端服務器120的緩存空間125、虛擬通訊埠124、第二儲存單元122與網路傳輸介面123所起的作用相同,因此在此不重複說明其功能。 In addition to the foregoing mapping process in which the remote server 120 can directly perform connection and communication with the client 110, the present invention can be applied to the communication port mapping process of the virtual machine 500. The services required by the plurality of clients 110 can be provided due to the computing power of the remote server 120. Therefore, multiple virtual machines 500 can be operated on the remote server 120, as shown in FIG. Each virtual machine 500 is configured with: a virtual control unit 510, a cache space 512, a virtual communication port 513, a virtual second storage unit 514, and a virtual network transmission interface 515. The virtual control unit 510 is connected to the cache space 512, the virtual communication port 513, the virtual second storage unit 514, and the virtual network transmission interface 515. The cache space 512, the virtual communication port 513, the virtual second storage unit 514, and the virtual network transmission interface 515 are respectively associated with the cache space 125 of the remote server 120, the virtual communication port 124, the second storage unit 122, and the network transmission interface. 123 plays the same role, so its function will not be repeated here.

對於客戶端110而言,虛擬機器500係提供相關的作業系統的操作環境,因此虛擬機器500可以調用客戶端110的周邊設備130。而每 一台虛擬機器500的組態方式可以根據實際情況有所調整。請參考第6圖所示,其係為本發明的另一種實施態樣的運作流程示意圖。本發明的此一實施態樣包括以下步驟:步驟S610:於遠端服務器佈署至少一個虛擬機器;步驟S620:虛擬機器運行應用程序時產生至少一虛擬通訊埠與緩存空間,應用程序向虛擬通訊埠發送操作指令;步驟S630:判斷客戶端是否連線至遠端服務器;步驟S640:若客戶端與虛擬機器未連線時,虛擬機器將操作指令暫存於緩存空間中;步驟S650:若客戶端與虛擬機器連線時,客戶端透過網路連接至遠端服務器,遠端服務器選擇虛擬機器,並將所選的虛擬機器與客戶端進行連接;步驟S660:虛擬機器將虛擬通訊埠與客戶端的多個目標通訊埠進行映射處理,虛擬機器透過虛擬通訊埠將操作指令傳送至目標通訊埠;步驟S670:判斷客戶端的連線是否發生中斷;步驟S680:若客戶端與虛擬機器中斷連線時,虛擬機器將操作指令暫存於緩存空間中;以及步驟S690:當客戶端再次連接於虛擬機器時,虛擬機器將暫存於緩存空間的操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備。 For the client 110, the virtual machine 500 provides an operating environment for the associated operating system, so the virtual machine 500 can invoke the peripheral device 130 of the client 110. And each The configuration of a virtual machine 500 can be adjusted according to the actual situation. Please refer to FIG. 6, which is a schematic diagram of the operational flow of another embodiment of the present invention. This embodiment of the present invention includes the following steps: Step S610: deploying at least one virtual machine on the remote server; Step S620: generating at least one virtual communication port and cache space when the virtual machine runs the application, and the application is in virtual communication埠 sending an operation instruction; step S630: determining whether the client is connected to the remote server; step S640: if the client is not connected to the virtual machine, the virtual machine temporarily stores the operation instruction in the cache space; step S650: if the client When the terminal is connected to the virtual machine, the client connects to the remote server through the network, the remote server selects the virtual machine, and connects the selected virtual machine to the client; step S660: the virtual machine connects the virtual communication with the client The plurality of target communications of the terminal perform mapping processing, and the virtual machine transmits the operation command to the target communication port through the virtual communication; step S670: determining whether the connection of the client is interrupted; and step S680: if the client disconnects with the virtual machine , the virtual machine temporarily stores the operation instruction in the cache space; and step S690: when the client re When connected to the virtual machine, the virtual machine operating temporarily in the instruction buffer space is mapped through a virtual communications port corresponding to a target Port and peripheral devices.

在遠端服務器120中佈署至少一個以上的虛擬機器500。而虛擬機器500的佈署方式與其作業環境係根據客戶端110的需求所決定。舉例來說,資訊管理人員可以利用預設的虛擬機器500進行批次的複製,如此一來可以在遠端服務器120中進行多台虛擬機器500的快速佈署。而每一台虛擬機器500的配置設備(例如:運算能力、記憶體容量、儲存空間或網路組態)都會是相同的。或者,也可以由資訊管理人員逐一的設定每一台的虛擬機器500。 At least one or more virtual machines 500 are deployed in the remote server 120. The deployment mode of the virtual machine 500 and its operating environment are determined according to the needs of the client 110. For example, the information manager can use the preset virtual machine 500 to perform batch copying, so that the rapid deployment of multiple virtual machines 500 can be performed in the remote server 120. The configuration device (for example, computing power, memory capacity, storage space, or network configuration) of each virtual machine 500 will be the same. Alternatively, each virtual machine 500 may be set by the information manager one by one.

在虛擬機器500中會設置至少一虛擬通訊埠513與緩存空間 512。每一台虛擬機器500的虛擬通訊埠513均為獨立的。換句話說,不同的虛擬機器500的虛擬通訊埠513不會相互干擾。舉例來說,在遠端服務器120中配置有虛擬機器A與虛擬機器B。虛擬機器A可以配置有RS-232埠、USB(Universal Serial Bus)埠與LPT埠(Line Print Terminal Port),虛擬機器B配置有RS-232埠與USB埠。由於兩個虛擬機器A、B是相互獨立的,兩虛擬機器A、B所配置的RS-232埠在傳輸的過程中兩個虛擬機器A、B的RS-232埠在運作時也不會相互干涉。同理,遠端服務器120中的每一台虛擬機器500的緩存空間512也是各自獨立的。 At least one virtual communication port 513 and a cache space are set in the virtual machine 500. 512. The virtual communication port 513 of each virtual machine 500 is independent. In other words, the virtual communication ports 513 of different virtual machines 500 do not interfere with each other. For example, virtual machine A and virtual machine B are configured in remote server 120. The virtual machine A can be configured with RS-232 port, USB (Universal Serial Bus) and LPT (Line Print Terminal Port), and the virtual machine B is configured with RS-232 port and USB port. Since the two virtual machines A and B are independent of each other, the RS-232 ports configured by the two virtual machines A and B will not interact with each other during the transmission of the two virtual machines A and B. put one's oar in. Similarly, the cache space 512 of each virtual machine 500 in the remote server 120 is also independent.

客戶端110透過網路連接至遠端服務器120,遠端服務器120可以根據前述的方式選擇相應的虛擬機器500。遠端服務器120會判斷虛擬機器500的虛擬通訊埠513的種類與數量是否與目標通訊埠113一致。當遠端服務器120確認是否還有剩餘的虛擬機器500且該台虛擬機器500未配置給其他的客戶端110時,遠端服務器120將會優先選擇該台虛擬機器500給客戶端110並進行虛擬通訊埠513與目標通訊埠113的映射處理。若是遠端服務器120未搜尋到合適的虛擬機器500,遠端服務器120會查詢虛擬通訊埠513的種類與數量大於客戶端110的虛擬機器500。 The client 110 is connected to the remote server 120 via a network, and the remote server 120 can select the corresponding virtual machine 500 according to the manner described above. The remote server 120 determines whether the type and number of virtual communication ports 513 of the virtual machine 500 are consistent with the target communication port 113. When the remote server 120 confirms whether there are remaining virtual machines 500 and the virtual machine 500 is not configured to other clients 110, the remote server 120 will preferentially select the virtual machine 500 to the client 110 and perform virtualization. The mapping between the communication port 513 and the target communication port 113 is performed. If the remote server 120 does not find a suitable virtual machine 500, the remote server 120 queries the virtual machine 500 of the virtual communication device 513 for a type and number greater than the client 110.

若遠端服務器120中存在前述的虛擬機器500時,遠端服務器120也會選擇符合該條件的虛擬機器500。除了前述的判斷條件外,遠端服務器120也可以根據以下條件進行虛擬機器500的篩選判斷,例如:連線時間、網路位址(IP Address)或媒體存取控制位址(Media Access Control Address)。遠端服務器120可以根據客戶端110的連線順序選擇虛擬機器500,並由所選的虛擬機器500與客戶端110進行連線。 If the aforementioned virtual machine 500 exists in the remote server 120, the remote server 120 also selects the virtual machine 500 that meets the condition. In addition to the foregoing determination conditions, the remote server 120 may also perform the screening judgment of the virtual machine 500 according to the following conditions, such as: connection time, network address (IP Address) or media access control address (Media Access Control Address) ). The remote server 120 can select the virtual machine 500 according to the connection order of the client 110, and connect the selected virtual machine 500 to the client 110.

遠端服務器120可以根據所述的連線要求確認客戶端110是否為合法。在本發明中所指的合法客戶端110是:客戶端110的目標通訊埠113的種類與數量係與虛擬通訊埠513的種類與數量均為一致。除了前述合法的情況外,當客戶端110的目標通訊埠113的種類與虛擬通訊埠513一致時,若目標通訊埠113的數量少於虛擬通訊埠513時也可以被視為合法的。 The remote server 120 can confirm whether the client 110 is legitimate according to the connection request. In the legitimate client 110 referred to in the present invention, the type and number of the target communication ports 113 of the client 110 are the same as the type and number of the virtual communication ports 513. In addition to the aforementioned legal case, when the type of the target communication port 113 of the client 110 coincides with the virtual communication port 513, the number of the target communication port 113 can be regarded as legal if it is less than the virtual communication port 513.

虛擬機器500中可以預先記錄客戶端110所連接的周邊設備130的種類與相關設定。當客戶端110連接至虛擬機器500時,虛擬機器500 可以根據連線要求進而判斷客戶端110所連接的周邊設備130。虛擬機器500根據連線要求將虛擬通訊埠513映射於客戶端110的目標通訊埠113,虛擬機器500透過虛擬通訊埠513將操作指令傳送至目標通訊埠113。 The type and related settings of the peripheral device 130 to which the client 110 is connected may be recorded in advance in the virtual machine 500. When the client 110 is connected to the virtual machine 500, the virtual machine 500 The peripheral device 130 to which the client 110 is connected can be further determined according to the connection requirements. The virtual machine 500 maps the virtual communication port 513 to the target communication port 113 of the client 110 according to the connection request, and the virtual machine 500 transmits the operation command to the target communication port 113 through the virtual communication port 513.

虛擬機器500會即時的監控對客戶端110的連線狀況。虛擬機器500偵測中斷連線時,虛擬機器500會對操作指令進行分類的處理。若是操作指令屬於設定種類,虛擬機器500會以模擬的方式執行該筆操作指令。例如:虛擬機器500接到開啟通訊埠時,虛擬機器500會向應用程序發送開啟成功的回應訊息。 The virtual machine 500 will immediately monitor the connection status to the client 110. When the virtual machine 500 detects an interrupted connection, the virtual machine 500 classifies the operation instructions. If the operation command belongs to the set type, the virtual machine 500 executes the operation command in an analog manner. For example, when the virtual machine 500 receives the communication port, the virtual machine 500 sends a response message to the application that the connection is successful.

當客戶端110中斷與虛擬機器500的連線時,虛擬機器500會立即將操作指令轉存至緩存空間512。因此操作指令不會直接就傳送至虛擬通訊埠513。當客戶端110再次連線至虛擬機器500時,虛擬機器500會偵測緩存空間512中是否有操作指令。若緩存空間512中存在操作指令時,虛擬機器500會將緩存空間512中的操作指令依序的發送至客戶端110與相應的周邊設備130。 When the client 110 interrupts the connection with the virtual machine 500, the virtual machine 500 immediately dumps the operation instructions to the cache space 512. Therefore, the operation command is not directly transmitted to the virtual communication port 513. When the client 110 is again connected to the virtual machine 500, the virtual machine 500 detects whether there is an operation instruction in the cache space 512. If there is an operation instruction in the cache space 512, the virtual machine 500 sequentially transmits the operation instructions in the cache space 512 to the client 110 and the corresponding peripheral device 130.

若以賣場的收銀機710為例,每一台收銀機710可以被視為本發明所述的客戶端110。收銀機710的主要作用是貨品的確認、金額的結算與對銀行的交易處理,請參考第7A圖與第7B圖所示。所以收銀機710會配置有條碼讀取器721、印表機722、螢幕723、讀卡機724與錢箱725,而所述的周邊設備130可以透過RS-232通訊埠、LTP通訊埠或USB通訊埠等方式相連接。假設條碼讀取器721與讀卡機724分別連接於COM1通訊埠731與COM2通訊埠734(其係為RS-232的通稱),印表機722連接於LTP通訊埠732,錢箱725連接於USB通訊埠735,螢幕723連接於視頻圖形陣列通訊埠733(Video Graph Array,簡稱VGA)。收銀機710可以透過區域網路(Local Area Network,LAN)與遠端服務器120連接,或者透過網際網路與域外的遠端服務器120相連接。 If the cash register 710 of the store is taken as an example, each cash register 710 can be regarded as the client 110 described in the present invention. The main functions of the cash register 710 are the confirmation of the goods, the settlement of the amount, and the transaction processing of the bank. Please refer to Figures 7A and 7B. Therefore, the cash register 710 is configured with a bar code reader 721, a printer 722, a screen 723, a card reader 724 and a cash box 725, and the peripheral device 130 can communicate via RS-232 communication, LTP communication or USB. Communication, etc. are connected. It is assumed that the barcode reader 721 and the card reader 724 are respectively connected to the COM1 communication port 731 and the COM2 communication port 734 (which is a general name of RS-232), the printer 722 is connected to the LTP communication port 732, and the cash box 725 is connected to USB communication port 735, the screen 723 is connected to the video graphics array communication 埠 733 (Video Graph Array, referred to as VGA). The cash register 710 can be connected to the remote server 120 via a local area network (LAN) or to the remote server 120 outside the domain via the Internet.

資訊管理人員可以在遠端服務器120中預先產生虛擬機器500,而虛擬機器500的數量可以根據賣場裡的收銀機710的數量所決定。在第7A圖中對於客戶端110所連接的虛擬機器500係以虛線框作為表示。在第7B圖中,虛擬機器500在運行應用程序時會同時的產生虛擬通訊埠 513。 The information manager can pre-generate the virtual machine 500 in the remote server 120, and the number of virtual machines 500 can be determined based on the number of cash registers 710 in the store. The virtual machine 500 to which the client 110 is connected in FIG. 7A is indicated by a dashed box. In Figure 7B, the virtual machine 500 generates virtual communication at the same time when the application is running. 513.

一般而言,虛擬機器500的數量可以等同於(或少於)收銀機710的總數量。當虛擬機器500的數量等同於收銀機710的數量時,遠端服務器120可以將虛擬機器500與收銀機710進行一對一的配置。在完成配置後,虛擬機器500會與客戶端110進行虛擬通訊埠513與目標通訊埠113的映射處理。在第7C圖中各虛擬通訊埠513與目標通訊埠113的對應連接係以虛線表示。客戶端110可以對虛擬機器500進行操作,而虛擬機器500也可以透過虛擬通訊埠513對目標通訊埠113與周邊設備130進行調用。 In general, the number of virtual machines 500 can be equal to (or less than) the total number of cash registers 710. When the number of virtual machines 500 is equal to the number of cash registers 710, the remote server 120 can configure the virtual machines 500 and the cash register 710 one-to-one. After the configuration is completed, the virtual machine 500 performs a mapping process between the virtual communication port 513 and the target communication port 113 with the client 110. Corresponding connections between the virtual communication ports 513 and the target communication port 113 in Fig. 7C are indicated by broken lines. The client 110 can operate on the virtual machine 500, and the virtual machine 500 can also invoke the target communication port 113 and the peripheral device 130 through the virtual communication port 513.

虛擬機器500會即時的監控收銀機710是否已經連線。虛擬機器500可以透過遠端服務器120的網路傳輸介面123判斷對收銀機710的連線狀態。一般而言,收銀機710可能在營業時間外關機。所以在非營業時間中,收銀機710與虛擬機器500是未連線的情況。這樣的情形對於本發明而言也算是網路中斷的一種情況。若收銀機710發生網路中斷時,虛擬機器500會將操作指令暫時除存在緩存空間512中,如第7D圖所示。當收銀機710再次與虛擬機器500連線時,虛擬機器500會檢查緩存空間512中是否存在操作指令。若緩存空間512中存在有操作指令時,虛擬機器500會將緩存空間512的操作指令依序的發送至收銀機710。對於遠端服務器120中的多台虛擬機器500而言,每一台虛擬機器500連接不同的收銀機710。每一台收銀機710的操作可以被視為是各自獨立。 The virtual machine 500 will immediately monitor whether the cash register 710 has been connected. The virtual machine 500 can determine the connection status to the cash register 710 through the network transmission interface 123 of the remote server 120. In general, the cash register 710 may be shut down outside of business hours. Therefore, in the non-business hours, the cash register 710 and the virtual machine 500 are not connected. Such a situation is also considered a case of network interruption for the present invention. If a cashout occurs at the cash register 710, the virtual machine 500 temporarily interprets the operational command in the cache space 512 as shown in FIG. 7D. When the cash register 710 is again connected to the virtual machine 500, the virtual machine 500 checks whether there is an operation command in the cache space 512. If there is an operation instruction in the cache space 512, the virtual machine 500 sequentially transmits the operation instruction of the buffer space 512 to the cash register 710. For multiple virtual machines 500 in the remote server 120, each virtual machine 500 is connected to a different cash register 710. The operation of each cash register 710 can be considered to be independent of each other.

除了前述的實施態樣外,本發明另可以透過以下方式實現。此一實施態樣的組成架構請參考第8圖所示。此一實施態樣係由遠端服務器120與客戶端110所構成。客戶端110包括:處理單元111、網路存取單元112、多個目標通訊埠113與第一儲存單元114。處理單元111耦接於網路存取單元112、第一儲存單元114與該些目標通訊埠113。網路存取單元112用以連接遠端服務器120。處理單元111經由網路存取單元112傳送或接收來自於遠端服務器120的資料封包。 In addition to the foregoing embodiments, the present invention can be implemented in the following manner. Please refer to Figure 8 for the composition of this implementation. This embodiment is composed of a remote server 120 and a client 110. The client 110 includes a processing unit 111, a network access unit 112, a plurality of target communication ports 113, and a first storage unit 114. The processing unit 111 is coupled to the network access unit 112, the first storage unit 114, and the target communication ports 113. The network access unit 112 is used to connect to the remote server 120. The processing unit 111 transmits or receives a data packet from the remote server 120 via the network access unit 112.

遠端服務器120包括:控制單元121、第二儲存單元122、網路傳輸介面123、虛擬通訊埠124與緩存空間125。控制單元121耦接於第二儲存單元122與網路傳輸介面123。第二儲存單元122可以儲存虛擬機 器500的應用程序,也可以儲存客戶端110所運行的應用程序。控制單元121透過網路傳輸介面123與所連接的客戶端110進行資料的交換。在遠端服務器120中配置至少一個虛擬通訊埠124。 The remote server 120 includes a control unit 121, a second storage unit 122, a network transmission interface 123, a virtual communication port 124, and a cache space 125. The control unit 121 is coupled to the second storage unit 122 and the network transmission interface 123. The second storage unit 122 can store the virtual machine The application of the device 500 can also store the application running by the client 110. The control unit 121 exchanges data with the connected client 110 through the network transmission interface 123. At least one virtual communication port 124 is configured in the remote server 120.

請參考第9圖所示,其係分別為本發明的運作流程示意圖。本發明的遠端服務器120對周邊設備的控制方法包括以下步驟:步驟S910:遠端服務器等待客戶端的連線;步驟S920:遠端服務器根據客戶端的確認資訊產生至少一虛擬通訊埠;步驟S930:將虛擬通訊埠與客戶端的多個目標通訊埠進行映射;步驟S940:偵測客戶端的連線是否發生中斷;步驟S950:若客戶端與遠端服務器連線時,使得遠端服務器的操作指令通過虛擬通訊埠傳送至對應的目標通訊埠;步驟S960:若客戶端與遠端服務器中斷連線時,遠端服務器將操作指令暫存於緩存空間中;以及步驟S970:當客戶端再次連接於遠端服務器時,遠端服務器將暫存於緩存空間的操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備。 Please refer to FIG. 9 , which is a schematic diagram of the operational flow of the present invention. The method for controlling the peripheral device of the remote server 120 of the present invention includes the following steps: Step S910: The remote server waits for the connection of the client; Step S920: The remote server generates at least one virtual communication according to the confirmation information of the client; Step S930: Mapping the virtual communication port to the plurality of target communication ports of the client; step S940: detecting whether the connection of the client is interrupted; and step S950: if the client connects with the remote server, the operation command of the remote server is passed The virtual communication is transmitted to the corresponding target communication port; step S960: if the client disconnects with the remote server, the remote server temporarily stores the operation instruction in the cache space; and step S970: when the client is connected to the remote again When the server is in the server, the remote server maps the operation instructions temporarily stored in the cache space to the corresponding target communication port and the peripheral device through the virtual communication port.

首先,遠端服務器120啟動後,遠端服務器120會監聽有無客戶端110的連線要求。當遠端服務器120接到客戶端110連線要求後,客戶端110會另外發出確認資訊給遠端服務器120。當客戶端110第一次連接於遠端服務器120時,遠端服務器120120會收到客戶端110的確認資訊。客戶端110會根據所插接的介面卡或自身的通訊埠產生相應的確認資訊。 First, after the remote server 120 is started, the remote server 120 listens for the connection request of the client 110. After the remote server 120 receives the connection request from the client 110, the client 110 additionally sends a confirmation message to the remote server 120. When the client 110 connects to the remote server 120 for the first time, the remote server 120120 receives the confirmation information of the client 110. The client 110 generates corresponding confirmation information according to the interface card or the communication port of the interface.

遠端服務器120根據確認資訊產生虛擬通訊埠124。虛擬通訊埠124的種類與數量係與目標通訊埠113的種類與數量是一致的。遠端服務器120將操作指令轉換為網路封包,並將網路路封包傳送至客戶端110。客戶端110再將網路封包轉換為操作指令,將操作指令驅動目標通訊埠113與周邊設備130。 The remote server 120 generates a virtual communication port 124 based on the confirmation information. The type and number of virtual communication ports 124 are consistent with the type and number of target communication ports 113. The remote server 120 converts the operational instructions into network packets and transmits the network packets to the client 110. The client 110 then converts the network packet into an operation command, and drives the target communication port 113 and the peripheral device 130.

在客戶端110與遠端服務器120連線的過程中可能由於操作或網路品質不佳等原因,使得客戶端110與遠端服務器120的連線產生中斷。一旦發生連線中斷的問題,遠端服務器120可以透過網路傳輸介面123 得到連線是否異常的反饋回應。於此同時,遠端服務器120會將操作指令轉存至緩存空間125中,使得操作指令不會直接傳達至虛擬通訊埠124。因此虛擬通訊埠124不會將操作指令映射至客戶端110,避免虛擬通訊埠124無法收到客戶端110的回應會產生操作上的錯誤。 During the connection between the client 110 and the remote server 120, the connection between the client 110 and the remote server 120 may be interrupted due to reasons such as poor operation or network quality. In the event of a disconnection, the remote server 120 can transmit through the network interface 123. Get a feedback response if the connection is abnormal. At the same time, the remote server 120 dumps the operation instructions into the cache space 125 so that the operation instructions are not directly communicated to the virtual communication port 124. Therefore, the virtual communication port 124 does not map the operation instruction to the client 110, and the virtual communication port 124 is prevented from receiving an response from the client 110, which may cause an operation error.

以RS-232作為目標通訊埠113為例,RS-232通訊埠對所連接的周邊設備130會進行開啟、讀取、寫入與結束等操作指令。當虛擬通訊埠124下達所述的操作指令時,由於網路中斷的緣故使得周邊設備130不會有任何的回應給遠端服務器120。因此習知技術的遠端服務器120在操作逾期後就會發生通訊埠錯誤的問題。本發明的遠端服務器120在偵測到網路連線中斷後,遠端服務器120會將操作指令暫存至緩存空間125中。當遠端服務器120偵測到客戶端110再次連結上,遠端服務器120則將會把緩存空間125中的操作指令依序的發送至客戶端110與其周邊設備130。 Taking RS-232 as the target communication port 113 as an example, the RS-232 communication port performs operation commands such as opening, reading, writing, and ending to the connected peripheral device 130. When the virtual communication port 124 issues the operation command, the peripheral device 130 does not have any response to the remote server 120 due to the network interruption. Therefore, the remote server 120 of the prior art has a problem of communication error after the operation is overdue. After detecting the network connection interruption, the remote server 120 of the present invention temporarily stores the operation instruction into the buffer space 125. When the remote server 120 detects that the client 110 is connected again, the remote server 120 will sequentially send the operation instructions in the cache space 125 to the client 110 and its peripheral devices 130.

除了前述遠端服務器120可以與客戶端110直接進行連接與通訊埠的映射處理外,本發明另可以應用在虛擬機器500的通訊埠映射處理中。由於現有的遠端服務器120的運算能力可以提供多名客戶端110所要求的服務。所以遠端服務器120上可以同時的運行多台的虛擬機器500,請參考第10圖所示。 In addition to the foregoing mapping process in which the remote server 120 can directly perform connection and communication with the client 110, the present invention can be applied to the communication port mapping process of the virtual machine 500. The services required by the plurality of clients 110 can be provided due to the computing power of the existing remote server 120. Therefore, the remote server 120 can simultaneously run multiple virtual machines 500, as shown in FIG.

對於客戶端110而言,虛擬機器500係提供相關的作業系統的操作環境,因此虛擬機器500可以調用客戶端110的周邊設備130。而每一台虛擬機器500的組態方式可以根據實際情況有所調整。本發明的虛擬機器500配置有:虛擬控制單元510、緩存空間512、虛擬通訊埠513、虛擬第二儲存單元514與虛擬網路傳輸介面515。虛擬控制單元510連接於緩存空間512、虛擬通訊埠513、虛擬第二儲存單元514與虛擬網路傳輸介面515。 For the client 110, the virtual machine 500 provides an operating environment for the associated operating system, so the virtual machine 500 can invoke the peripheral device 130 of the client 110. The configuration of each virtual machine 500 can be adjusted according to the actual situation. The virtual machine 500 of the present invention is configured with a virtual control unit 510, a cache space 512, a virtual communication port 513, a virtual second storage unit 514, and a virtual network transmission interface 515. The virtual control unit 510 is connected to the cache space 512, the virtual communication port 513, the virtual second storage unit 514, and the virtual network transmission interface 515.

請參考第11圖所示,其係為本發明的此一種實施態樣的運作流程示意圖。本發明的此一實施態樣包括以下步驟:步驟S1110:於遠端服務器佈署至少一個虛擬機器;步驟S1120:遠端服務器等待客戶端的連線;步驟S1130:客戶端透過網路連接至遠端服務器,遠端服務器選擇虛擬機器,並將所選的虛擬機器與客戶端進行連接; 步驟S1140:被選擇的虛擬機器根據客戶端的確認資訊產生至少一虛擬通訊埠;步驟S1150:虛擬機器根據確認資訊將虛擬通訊埠映射於客戶端的目標通訊埠,虛擬機器透過虛擬通訊埠將操作指令傳送至目標通訊埠;步驟S1150:偵測客戶端的連線是否發生中斷;步驟S1170:若客戶端與虛擬機器中斷連線時,虛擬機器將操作指令暫存於緩存空間中;以及步驟S1180:當客戶端再次連接於虛擬機器時,虛擬機器將暫存於緩存空間的操作指令透過虛擬通訊埠映射至所對應的目標通訊埠與周邊設備。 Please refer to FIG. 11 , which is a schematic diagram of the operational flow of this embodiment of the present invention. This embodiment of the present invention includes the following steps: Step S1110: deploying at least one virtual machine on the remote server; Step S1120: The remote server waits for the connection of the client; Step S1130: The client connects to the remote through the network Server, the remote server selects the virtual machine and connects the selected virtual machine to the client; Step S1140: The selected virtual machine generates at least one virtual communication according to the confirmation information of the client. Step S1150: the virtual machine maps the virtual communication to the target communication of the client according to the confirmation information, and the virtual machine transmits the operation instruction through the virtual communication. To the target communication port; step S1150: detecting whether the connection of the client is interrupted; step S1170: if the client disconnects the virtual machine, the virtual machine temporarily stores the operation instruction in the cache space; and step S1180: when the client When the terminal is connected to the virtual machine again, the virtual machine maps the operation instruction temporarily stored in the cache space to the corresponding target communication port and the peripheral device through the virtual communication port.

首先,在遠端服務器120中佈署至少一個以上的虛擬機器500。而虛擬機器500的佈署數量與其作業環境係根據客戶端110的需求所決定。遠端服務器120初始該些虛擬機器500後,遠端服務器120會等待有無客戶端110的連線。客戶端110透過網路連接至遠端服務器120,遠端服務器120可以根據客戶端110的確認資訊選擇相應的虛擬機器500。確認資訊的種類可以是但不限定為連線時間、網路位址(IP Address)、媒體存取控制位址(Media Access Control Address)或使用者帳號。遠端服務器120可以根據客戶端110的連線順序選擇虛擬機器500,並由所選的虛擬機器500與客戶端110進行連線。 First, at least one or more virtual machines 500 are deployed in the remote server 120. The number of deployments of the virtual machine 500 and its operating environment are determined according to the needs of the client 110. After the remote server 120 initials the virtual machines 500, the remote server 120 waits for the connection of the client 110. The client 110 connects to the remote server 120 through a network, and the remote server 120 can select the corresponding virtual machine 500 according to the confirmation information of the client 110. The type of confirmation information may be, but is not limited to, the connection time, the IP address, the Media Access Control Address, or the user account. The remote server 120 can select the virtual machine 500 according to the connection order of the client 110, and connect the selected virtual machine 500 to the client 110.

接著,虛擬機器500會根據確認資訊設置至少一虛擬通訊埠513與緩存空間512。虛擬機器500將虛擬通訊埠513映射於客戶端110的目標通訊埠113,虛擬機器500透過虛擬通訊埠513將操作指令傳送至目標通訊埠113。而每一台虛擬機器500的虛擬通訊埠513均為獨立的。虛擬機器500會即時的監控對客戶端110的連線狀況。當客戶端110中斷與虛擬機器500的連線時,虛擬機器500會立即將操作指令轉存至緩存空間512。因此操作指令不會直接就傳送至虛擬通訊埠513。當客戶端110再次連線至虛擬機器500時,虛擬機器500會偵測緩存空間512中是否有操作指令。若緩存空間512中存在操作指令時,虛擬機器500會將緩存空間512中的操作指 令依序的發送至客戶端110與相應的周邊設備130。 Next, the virtual machine 500 sets at least one virtual communication port 513 and the cache space 512 according to the confirmation information. The virtual machine 500 maps the virtual communication port 513 to the target communication port 113 of the client 110, and the virtual machine 500 transmits the operation command to the target communication port 113 via the virtual communication port 513. The virtual communication port 513 of each virtual machine 500 is independent. The virtual machine 500 will immediately monitor the connection status to the client 110. When the client 110 interrupts the connection with the virtual machine 500, the virtual machine 500 immediately dumps the operation instructions to the cache space 512. Therefore, the operation command is not directly transmitted to the virtual communication port 513. When the client 110 is again connected to the virtual machine 500, the virtual machine 500 detects whether there is an operation instruction in the cache space 512. If there is an operation instruction in the cache space 512, the virtual machine 500 will refer to the operation in the cache space 512. The sequence is sent to the client 110 and the corresponding peripheral device 130.

本發明更可以實現多個不同的客戶端110連線至同一虛擬機器500的目的。請參考第12圖所示,其係為本發明的另一實施態樣的運作流程圖。此一實施態樣包括以下步驟:步驟S1210:遠端服務器將多個客戶端的確認資訊與所連接的虛擬機器記錄至映射表中;步驟S1220:遠端服務器等待客戶端的連線;步驟S1230:客戶端連線至遠端服務器時,遠端服務器查找映射表中是否存在客戶端與虛擬機器;步驟S1240:若映射表中不存在虛擬機器,則執行步驟S1130;步驟S1250:若映射表中存在虛擬機器,則判斷虛擬機器是否與其他客戶端進行連線;步驟S1251:若虛擬機器沒有與其他客戶端連線,則客戶端連線至虛擬機器;以及步驟S1252:若虛擬機器有其他客戶端連線,則遠端服務器暫停客戶端對虛擬機器的連線處理。 The present invention can further achieve the purpose of connecting a plurality of different clients 110 to the same virtual machine 500. Please refer to FIG. 12, which is a flowchart of operation of another embodiment of the present invention. The embodiment includes the following steps: Step S1210: The remote server records the confirmation information of the multiple clients and the connected virtual machine into the mapping table; Step S1220: The remote server waits for the connection of the client; Step S1230: The client When the terminal is connected to the remote server, the remote server searches for the presence of the client and the virtual machine in the mapping table. Step S1240: If there is no virtual machine in the mapping table, step S1130 is performed; step S1250: if there is virtual in the mapping table The machine determines whether the virtual machine is connected to other clients; step S1251: if the virtual machine is not connected to other clients, the client is connected to the virtual machine; and step S1252: if the virtual machine has other client connections Line, the remote server suspends the client's connection to the virtual machine.

在第二儲存單元122中儲存映射表126,映射表126記錄虛擬機器500與多個客戶端110的對應關連,請參考第13圖所示。在此一實施態樣中,虛擬機器500可以在不同時段時提供給不同的客戶端110所使用。所以在映射表126中會記錄虛擬機器500可以由哪些客戶端110所使用。遠端服務器120在接到客戶端110的連線時,遠端服務器120會判斷該客戶端110所對應的虛擬機器500。接著,遠端服務器120會判斷該台虛擬機器500是否存在有其他客戶端110的連線。若是虛擬機器500當前與其他客戶端110進行連線時,遠端服務器120可以選擇:暫停客戶端110對遠端服務器120的連線處理或是將要連線的客戶端110轉連線至其他未連線的虛擬機器500。 A mapping table 126 is stored in the second storage unit 122. The mapping table 126 records the corresponding association of the virtual machine 500 with the plurality of clients 110. Please refer to FIG. In this implementation aspect, virtual machine 500 can be provided to different clients 110 for use at different time periods. Therefore, which client 110 the virtual machine 500 can be used in the mapping table 126 is recorded. When the remote server 120 is connected to the client 110, the remote server 120 determines the virtual machine 500 corresponding to the client 110. Next, the remote server 120 determines whether the virtual machine 500 has a connection with other clients 110. If the virtual machine 500 is currently connected to other clients 110, the remote server 120 may select to suspend the connection processing of the client 110 to the remote server 120 or to connect the client 110 to be connected to other clients. Connected virtual machine 500.

本發明所提出的遠端周邊的控制系統、方法及其遠端服務器120除了可以辨識終端設備所連接的周邊設備130,也可以在中斷連線的期間中確保虛擬機器500對於周邊設備130的存取過程中不會發生錯誤。此 外,資訊管理人員可以在佈署虛擬機器500時,不需要逐一的設定虛擬機器500的環境組態。而且遠端服務器120可以自動的分配虛擬機器500給連線的客戶端110。 The remote peripheral control system and method and the remote server 120 of the present invention can recognize the peripheral device 130 to which the terminal device is connected, and can also ensure the virtual machine 500 for the peripheral device 130 during the disconnection. No errors will occur during the fetching process. this In addition, the information management personnel can set the virtual machine 500 environment configuration one by one when deploying the virtual machine 500. Moreover, the remote server 120 can automatically assign the virtual machine 500 to the connected client 110.

雖然本發明以前述之較佳實施例揭露如上,然其並非用以限定本發明,任何熟習相像技藝者,在不脫離本發明之精神和範圍內,當可作些許之更動與潤飾,因此本發明之專利保護範圍須視本說明書所附之申請專利範圍所界定者為準。 While the present invention has been described above in terms of the preferred embodiments thereof, it is not intended to limit the invention, and the invention may be modified and modified without departing from the spirit and scope of the invention. The patent protection scope of the invention is subject to the definition of the scope of the patent application attached to the specification.

Claims (13)

一種遠端周邊的控制系統,遠端服務器與客戶端所連接的周邊設備進行映射處理,其特徵在於即時的資料輸出或輸入處理的周邊設備的控制,該遠端周邊的控制系統包括:一客戶端,具有多個目標通訊埠,每一該目標通訊埠各自耦接一周邊設備;以及一遠端服務器,其係於運行一應用程序時產生至少一虛擬通訊埠與一緩存空間;其中,該客戶端與該遠端服務器未連線時,該遠端服務器將該應用程序發向該虛擬通訊埠的一操作指令儲存於該緩存空間,在該客戶端連線至該遠端服務器,該遠端服務器將該虛擬通訊埠映射於該客戶端的該目標通訊埠,該遠端服務器將該緩存空間中的該操作指令傳送至該客戶端。 A remote peripheral control system, wherein the remote server performs mapping processing with a peripheral device connected to the client, and is characterized by immediate data output or control of peripheral devices for input processing, and the remote peripheral control system includes: a client End, having a plurality of target communication ports, each of the target communication ports being coupled to a peripheral device; and a remote server for generating at least one virtual communication port and a buffer space when running an application; wherein When the client is not connected to the remote server, an operation instruction sent by the remote server to the virtual communication port is stored in the cache space, and the client is connected to the remote server. The end server maps the virtual communication port to the target communication port of the client, and the remote server transmits the operation instruction in the cache space to the client. 如請求項1所述的遠端周邊的控制系統,其中該目標通訊埠的種類係為串列通訊埠(Parallel Port)或並列通訊埠(Serial Port),該周邊設備的種類係為條碼讀取器(Bar Code Reader)、錢箱(Cash Box Drawer)、讀卡機(Card Reader)、人機介面裝置、印表機或螢幕。 The control system of the remote periphery as described in claim 1, wherein the type of the target communication port is a Parallel Port or a Serial Port, and the type of the peripheral device is a barcode reading. Bar Code Reader, Cash Box Drawer, Card Reader, Human Interface Device, Printer or Screen. 如請求項1所述的遠端周邊的控制系統,其中該遠端服務器未連線至該客戶端或該遠端服務器中斷與該客戶端的連線時,該遠端服務器對該操作指令進行分類,該遠端服務器將設定種類的該操作指令進行模擬,並將該操作指令的模擬結果返回該應用程序,該遠端服務器將其餘的該操作指令儲存於該緩存空間中。 The remote peripheral control system according to claim 1, wherein the remote server classifies the operation instruction when the remote server is not connected to the client or the remote server disconnects the connection with the client The remote server simulates the operation instruction of the set type, and returns the simulation result of the operation instruction to the application, and the remote server stores the remaining operation instructions in the cache space. 一種遠端周邊設備的控制方法,其係包括以下步驟:當一遠端服務器運行一應用程序時,產生至少一虛擬通訊埠與一緩存空間;等待一客戶端的連線至該遠端服務器;在該客戶端未連線至該遠端服務器的期間中,該應用程序向該虛擬通訊埠下達一操作指令,則該遠端服務器將該操作指令暫存於該緩存空間;若該客戶端連線至該遠端服務器時,該遠端服務器將每一該虛擬通 訊埠對應一客戶端的一目標通訊埠;若該客戶端與該遠端服務器中斷連線時,該遠端服務器將該操作指令暫存於一緩存空間中;以及當該客戶端再次連接於該遠端服務器時,該遠端服務器將暫存於該緩存空間的該操作指令透過該虛擬通訊埠映射至所對應的該目標通訊埠與該周邊設備。 A method for controlling a remote peripheral device includes the following steps: when a remote server runs an application, generates at least one virtual communication port and a cache space; waits for a client to connect to the remote server; During the period when the client is not connected to the remote server, the application sends an operation instruction to the virtual communication, and the remote server temporarily stores the operation instruction in the cache space; if the client is connected When the remote server is reached, the remote server will each of the virtual channels Corresponding to a target communication port of a client; if the client disconnects from the remote server, the remote server temporarily stores the operation instruction in a cache space; and when the client is connected to the server again The remote server maps the operation command temporarily stored in the cache space to the corresponding target communication device and the peripheral device through the virtual communication port. 如請求項4所述的遠端周邊設備的控制方法,其中在建立該些虛擬通訊埠的步驟前更包括:在該遠端服務器中佈署至少一虛擬機器;以及每一該虛擬機器產生至少一該虛擬通訊埠。 The method for controlling a remote peripheral device according to claim 4, wherein before the step of establishing the virtual communication ports, the method further comprises: deploying at least one virtual machine in the remote server; and each of the virtual machines generates at least one virtual machine One of the virtual communications. 如請求項5所述遠端周邊設備的控制方法,其中映射該些虛擬通訊埠的步驟中更包括:該遠端服務器從該虛擬通訊埠的數量多於或等於該目標通訊埠的該些虛擬機器中選擇任一;該客戶端與該遠端服務器將所選出的該虛擬機器進行連接;以及該遠端服務器將該虛擬通訊埠映射至該目標通訊埠。 The method for controlling a remote peripheral device according to claim 5, wherein the step of mapping the virtual communication ports further comprises: the remote server from the virtual communication port has more than or equal to the virtual number of the target communication port Selecting any one of the machines; the client and the remote server connect the selected virtual machine; and the remote server maps the virtual communication port to the target communication port. 如請求項4所述的遠端周邊設備的控制方法,其中該遠端服務器未連線至該客戶端或該遠端服務器中斷與該客戶端的連線時,該遠端服務器對該操作指令進行分類,該遠端服務器將設定種類的該操作指令進行模擬,並將該操作指令的模擬結果送至該應用程序,該遠端服務器將其餘的該操作指令儲存於該緩存空間中。 The method for controlling a remote peripheral device according to claim 4, wherein when the remote server is not connected to the client or the remote server disconnects the connection with the client, the remote server performs the operation instruction Classification, the remote server simulates the operation instruction of the set type, and sends the simulation result of the operation instruction to the application, and the remote server stores the remaining operation instructions in the cache space. 一種遠端周邊設備的控制方法,其特徵在於虛擬機器與周邊設備的中斷時的控制處理,該控制方法包括以下步驟:於一遠端服務器中佈署多台虛擬機器,該虛擬機器運行一應用程序時產生至少一虛擬通訊埠與一緩存空間,該應用程序向該虛擬通訊埠發送一操作指令;若一客戶端與該虛擬機器未連線時,該虛擬機器將該操作指令暫存於一緩存空間中;以及若該客戶端與該虛擬機器連線時,該虛擬機器將該些虛擬通訊埠與該客戶端的多個目標通訊埠進行映射處理,該虛擬機器透過該虛擬通訊 埠將該操作指令傳送至該目標通訊埠。 A method for controlling a remote peripheral device, characterized by control processing when a virtual machine and a peripheral device are interrupted, the control method comprising the steps of: deploying a plurality of virtual machines in a remote server, the virtual machine running an application The program generates at least one virtual communication port and a cache space, and the application sends an operation instruction to the virtual communication port; if a client is not connected to the virtual machine, the virtual machine temporarily stores the operation command in a In the cache space; and if the client is connected to the virtual machine, the virtual machine maps the virtual communication port to the target communication port of the client, and the virtual machine transmits the virtual communication 传送 Transfer the operation command to the target communication port. 如請求項8述遠端周邊設備的控制方法,其中該客戶端的連線的步驟中更包括:若該客戶端首次連線至該遠端服務器,該遠端服務器根據不同的該客戶端的連線順序,該遠端服務器從未配置的該些虛擬機器選出任一;以及將所選擇的該虛擬機器指派給欲連接的該客戶端。 The method for controlling a remote peripheral device according to claim 8, wherein the step of connecting the client further comprises: if the client is connected to the remote server for the first time, the remote server is connected according to different clients. In the order, the remote server selects any of the virtual machines that are not configured; and assigns the selected virtual machine to the client to be connected. 如請求項8所述遠端周邊設備的控制方法,其中該客戶端的連線的步驟中更包括:若該客戶端首次連線至該遠端服務器,該遠端服務器從尚未配置的該些虛擬機器中選擇該些虛擬通訊埠的數量大於或等於該些目標通訊埠的該虛擬機器;以及將所選擇的該虛擬機器指派給欲連接的該客戶端。 The method for controlling a remote peripheral device according to claim 8, wherein the step of connecting the client further comprises: if the client connects to the remote server for the first time, the remote server is configured from the virtual The number of the virtual communication ports selected in the machine is greater than or equal to the virtual machine of the target communication ports; and the selected virtual machine is assigned to the client to be connected. 一種遠端服務器,其係包括:一網路傳輸介面,連接至少一客戶端;以及一控制單元,連接於該網路傳輸介面,該控制單元運行至少一虛擬機器,該些虛擬機器均具有多個虛擬通訊埠與一緩存空間,該虛擬機器將一操作指令發送至該虛擬通訊埠;其中,該客戶端連線至該遠端服務器,該控制單元選擇任一該虛擬機器,並將該虛擬機器連接於該客戶端,當該客戶端連接於該遠端服務器時,該虛擬機器透過該虛擬通訊埠將該操作指令映射至該客戶端並將該操作指令傳送至該客戶端的一目標通訊埠,當該客戶端中斷與該虛擬機器的連線時,該虛擬機器將該操作指令儲存於該緩存空間。 A remote server includes: a network transmission interface connecting at least one client; and a control unit connected to the network transmission interface, the control unit running at least one virtual machine, the virtual machines having multiple a virtual communication port and a cache space, the virtual machine sends an operation command to the virtual communication port; wherein the client is connected to the remote server, the control unit selects any of the virtual machines, and the virtual machine The machine is connected to the client, and when the client is connected to the remote server, the virtual machine maps the operation instruction to the client through the virtual communication, and transmits the operation instruction to a target communication of the client. When the client disconnects the virtual machine, the virtual machine stores the operation instruction in the cache space. 一種遠端周邊的控制系統,其特徵在於遠端服務器與客戶端所連接的周邊設備進行映射處理,該遠端周邊的控制系統包括:至少一客戶端,每一該客戶端具有多個目標通訊埠,每一該目標通訊埠耦接一周邊設備;以及一遠端服務器,網路連接於該些客戶端,該客戶端與該遠端服務器連線時,該遠端服務器根據該客戶端的一確認資訊產生一緩存空間與至少一虛擬通訊埠,該遠端服務器將一操作指令透過該虛擬通訊埠映射至 所對應的該目標通訊埠與該周邊設備。 A remote peripheral control system is characterized in that the remote server performs mapping processing with a peripheral device connected to the client, and the remote peripheral control system includes: at least one client, each of the clients having multiple target communications每一, each of the target communication ports is coupled to a peripheral device; and a remote server is connected to the client, and when the client is connected to the remote server, the remote server is configured according to the client The confirmation information generates a cache space and at least one virtual communication port, and the remote server maps an operation command to the virtual communication port to The corresponding target communication port is connected to the peripheral device. 如請求項12所述的遠端周邊的控制系統,其中該客戶端與該遠端服務器連接中斷時,該遠端服務器將發送至該客戶端的該操作指令儲存於該緩存空間,直至該客戶端連接於該遠端服務器時,該遠端服務器將該緩存空間中的操作指令傳送至該客戶端。 The remote peripheral control system of claim 12, wherein when the connection between the client and the remote server is interrupted, the remote server stores the operation instruction sent to the client in the cache space until the client When connected to the remote server, the remote server transmits an operation instruction in the cache space to the client.
TW102114492A 2013-04-24 2013-04-24 The controlling system and the method of the remote device and the server TWI497953B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW102114492A TWI497953B (en) 2013-04-24 2013-04-24 The controlling system and the method of the remote device and the server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW102114492A TWI497953B (en) 2013-04-24 2013-04-24 The controlling system and the method of the remote device and the server

Publications (2)

Publication Number Publication Date
TW201442464A true TW201442464A (en) 2014-11-01
TWI497953B TWI497953B (en) 2015-08-21

Family

ID=52423075

Family Applications (1)

Application Number Title Priority Date Filing Date
TW102114492A TWI497953B (en) 2013-04-24 2013-04-24 The controlling system and the method of the remote device and the server

Country Status (1)

Country Link
TW (1) TWI497953B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI571814B (en) * 2016-03-04 2017-02-21 絡達科技股份有限公司 Method for emulating card reader interface and control device using the same
CN110753075A (en) * 2018-07-24 2020-02-04 昆山尚尼司电子科技有限公司 Method and system for processing abstract and simulation behaviors of remote equipment
CN111443982A (en) * 2019-01-16 2020-07-24 瑞昱半导体股份有限公司 Communication method of virtual machine, electronic device and non-transitory computer readable recording medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050235045A1 (en) * 2004-03-05 2005-10-20 International Business Machines Corporation Portable personal computing environment server
US7975017B1 (en) * 2008-02-27 2011-07-05 Parallels Holdings, Ltd. Method and system for remote device access in virtual environment
US9753712B2 (en) * 2008-03-20 2017-09-05 Microsoft Technology Licensing, Llc Application management within deployable object hierarchy
TWI421689B (en) * 2009-07-09 2014-01-01 Aten Int Co Ltd System and method for remote management
US20120127512A1 (en) * 2010-11-19 2012-05-24 Microsoft Corporation Branch office direct printing
EP2732397B1 (en) * 2011-07-12 2020-02-26 Hewlett-Packard Development Company, L.P. Computing device including a port and a guest domain

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI571814B (en) * 2016-03-04 2017-02-21 絡達科技股份有限公司 Method for emulating card reader interface and control device using the same
CN110753075A (en) * 2018-07-24 2020-02-04 昆山尚尼司电子科技有限公司 Method and system for processing abstract and simulation behaviors of remote equipment
CN110753075B (en) * 2018-07-24 2022-06-17 昆山尚尼司电子科技有限公司 Method and system for processing abstract and simulation behaviors of remote equipment
CN111443982A (en) * 2019-01-16 2020-07-24 瑞昱半导体股份有限公司 Communication method of virtual machine, electronic device and non-transitory computer readable recording medium
CN111443982B (en) * 2019-01-16 2023-02-24 瑞昱半导体股份有限公司 Communication method of virtual machine, electronic device and non-transitory computer readable recording medium

Also Published As

Publication number Publication date
TWI497953B (en) 2015-08-21

Similar Documents

Publication Publication Date Title
CN103412519B (en) The control system of distal circumference, method and far-end server thereof
US7627696B2 (en) Electronic device, method for controlling the same, information processing apparatus, and computer program
US8001229B2 (en) Operation management system, management apparatus, management method and management program
US8103721B2 (en) Computing system and method of changing I/O configuration thereof
US20080215728A1 (en) Computer Management System and Computer Management Method
US8068602B1 (en) Systems and methods for recording using virtual machines
US7613861B2 (en) System and method of obtaining error data within an information handling system
US20100192214A1 (en) Information processing apparatus, information processing method, and recording medium including computer program
CN104636076A (en) Distributed block device driving method and system for cloud storage
JP2002351693A (en) Remote computer testing
CN101373448A (en) Computer system with remote management
US20120017211A1 (en) Virtual computer system, information processing device, storage medium storing computer program, and connection control method
TWI497953B (en) The controlling system and the method of the remote device and the server
US11687470B2 (en) Expander I/O module discovery and management system
US11100037B2 (en) Extended storage device based on PCIe bus
US7124235B2 (en) USB apparatus with switchable host/hub functions and control method thereof
US9946554B2 (en) System, method, and apparatus for configuring a streamed operating system with associated peripheral information
US11093175B1 (en) Raid data storage device direct communication system
KR102137891B1 (en) Server managing Method, Server, and Recording medium using User Specialized Operating Mechanism on BMC environment
JP4180291B2 (en) Storage device system control method, storage device, management device, and program
US20090144466A1 (en) Storage apparatus, storage system and path information setting method
US10339462B2 (en) System and method for executing a high bandwidth network activity as a background activity in a virtual desktop environment
US8799996B2 (en) Logical unit number management device, logical unit number management method, and program therefor
TWM486082U (en) Peripheral device management system, peripheral device operating system, and sharing system thereof
WO2024051231A1 (en) Processor and processor error detection method