[go: up one dir, main page]

CN111190367B - Cabinet slot control method and device - Google Patents

Cabinet slot control method and device Download PDF

Info

Publication number
CN111190367B
CN111190367B CN201911419897.0A CN201911419897A CN111190367B CN 111190367 B CN111190367 B CN 111190367B CN 201911419897 A CN201911419897 A CN 201911419897A CN 111190367 B CN111190367 B CN 111190367B
Authority
CN
China
Prior art keywords
interrupt event
level signal
cabinet
main control
control module
Prior art date
Legal status (The legal status 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 status listed.)
Expired - Fee Related
Application number
CN201911419897.0A
Other languages
Chinese (zh)
Other versions
CN111190367A (en
Inventor
周浑华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Longxin Lianjing Technology Beijing Co ltd
Original Assignee
Longxin Lianjing Technology Beijing 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 Longxin Lianjing Technology Beijing Co ltd filed Critical Longxin Lianjing Technology Beijing Co ltd
Priority to CN201911419897.0A priority Critical patent/CN111190367B/en
Publication of CN111190367A publication Critical patent/CN111190367A/en
Application granted granted Critical
Publication of CN111190367B publication Critical patent/CN111190367B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers
    • G05B19/042Programme control other than numerical control, i.e. in sequence controllers or logic controllers using digital processors
    • G05B19/0423Input/output

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Slot Machines And Peripheral Devices (AREA)

Abstract

本发明公开了一种柜机槽位的控制方法及装置。其中,该方法包括:当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块;当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位;向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定。本发明解决了相关技术中通过柜机对外围设备进行管理的方式比较复杂的技术问题。

Figure 201911419897

The invention discloses a method and a device for controlling the slot position of a cabinet. The method includes: when an interrupt event is detected, generating a level signal of an analog switch corresponding to the interrupt event in response to the interrupt event, and sending the level signal to the main control module; when the main control module receives the level signal When the control main control module queries the predetermined number of slots corresponding to the analog switch based on the level signal, and determines the target slot in the predetermined number of slots corresponding to the interrupt event according to the query result; sends control information to the target slot, Eject the target device or lock the target device with the action of the target slot in the control cabinet. The invention solves the technical problem that the management of the peripheral equipment through the cabinet is relatively complicated in the related art.

Figure 201911419897

Description

柜机槽位的控制方法及装置Cabinet slot control method and device

技术领域technical field

本发明涉及柜机控制技术领域,具体而言,涉及一种柜机槽位的控制方法及装置。The present invention relates to the technical field of cabinet control, and in particular, to a method and device for controlling slot positions of a cabinet.

背景技术Background technique

目前,包含但不限于共享设备中,一个主控往往需要同时管理大量的外围设备(比如槽位)。并且,在通过一个主控同时管理大量的外围设备的时候,通常会使用诸如RS485,RS233,CAN总线等通讯方式来做实时有效的管理,但这些方式往往存在硬件线路复杂,软件架构复杂,成本比较高等缺点。Currently, including but not limited to shared devices, a master often needs to manage a large number of peripheral devices (such as slots) at the same time. Moreover, when managing a large number of peripheral devices at the same time through a master, communication methods such as RS485, RS233, CAN bus and other communication methods are usually used for real-time and effective management, but these methods often have complex hardware circuits, complex software architecture, and cost. Relatively high disadvantage.

针对上述相关技术中通过柜机对外围设备进行管理的方式比较复杂的问题,目前尚未提出有效的解决方案。Aiming at the problem that the management of peripheral devices through the cabinet is relatively complicated in the above-mentioned related art, no effective solution has been proposed yet.

发明内容SUMMARY OF THE INVENTION

本发明实施例提供了一种柜机槽位的控制方法及装置,以至少解决相关技术中通过柜机对外围设备进行管理的方式比较复杂的技术问题。Embodiments of the present invention provide a method and a device for controlling slot positions of a cabinet, so as to at least solve the technical problem in the related art that the management of peripheral devices through a cabinet is relatively complex.

根据本发明实施例的一个方面,提供了一种柜机槽位的控制方法,包括:当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块;当所述主控模块接收到所述电平信号时,控制所述主控模块基于所述电平信号对所述模拟开关对应的预定数量的槽位进行查询,根据查询结果确定所述中断事件对应的所述预定数量的槽位中的目标槽位;向所述目标槽位发送控制信息,以控制所述柜机中的目标槽位动作弹出目标设备或将目标设备锁定。According to an aspect of the embodiments of the present invention, a method for controlling a slot of a cabinet is provided, including: when an interrupt event is detected, generating a level signal of an analog switch corresponding to the interrupt event in response to the interrupt event , and send the level signal to the main control module; when the main control module receives the level signal, control the main control module to set a predetermined number of analog switches corresponding to the analog switch based on the level signal query the slot, and determine the target slot in the predetermined number of slots corresponding to the interrupt event according to the query result; send control information to the target slot to control the target slot in the cabinet Action Ejects the target device or locks the target device.

可选地,在当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,该柜机槽位的控制方法还包括:确定柜机的模拟开关的数量,其中,所述柜机用于存放所述目标设备以及其他与所述目标设备相同的设备;确定所述柜机的主控模块控制的多个槽位;根据所述柜机的模拟开关的数量对所述主控模块控制的多个槽位进行分组,使得每一个所述模拟开关控制预定数量的槽位。Optionally, when an interruption event is detected, the level signal of the analog switch corresponding to the interruption event is generated in response to the interruption event, and before the level signal is sent to the main control module, the cabinet The method for controlling slot positions further includes: determining the number of analog switches of a cabinet, wherein the cabinet is used to store the target device and other devices identical to the target device; determining a main control module of the cabinet The multiple slots controlled by the main control module are grouped according to the number of analog switches of the cabinet, so that each of the analog switches controls a predetermined number of slots.

可选地,在控制所述目标槽位动作弹出所述目标设备时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述柜机槽位的控制方法包括:根据所述中断信号对所述柜机中的存储的多个设备进行检测,得到所述多个设备中每一个设备的当前状态;根据所述多个设备中每一个设备的当前状态确定所述目标设备;根据所述目标设备的标识信息触发所述中断事件。Optionally, when controlling the target slot action to pop up the target device, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the Before the level signal is sent to the main control module, the method for controlling the slot position of the cabinet includes: detecting a plurality of devices stored in the cabinet according to the interrupt signal, and obtaining each of the plurality of devices. The current state of a device; the target device is determined according to the current state of each device in the plurality of devices; the interrupt event is triggered according to the identification information of the target device.

可选地,所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述柜机槽位的控制方法还包括:控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。Optionally, the interrupt event carries the identification information of the target slot, when the interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the Before the level signal is sent to the main control module, the method for controlling the slot position of the cabinet further includes: controlling the main control module of the cabinet to determine the analog switch corresponding to the interrupt event according to the identification information carried in the interrupt event .

可选地,在控制所述目标槽位动作将所述目标设备锁定时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述柜机槽位的控制方法包括:根据所述中断信号对所述柜机中的多个槽位进行检测,得到所述多个槽位中每一个槽位的槽位状态进行检测;根据所述多个槽位中每一个槽位的槽位状态确定所述目标槽位;根据所述目标槽位的标识信息触发所述中断事件。Optionally, when controlling the target slot action to lock the target device, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the Before the level signal is sent to the main control module, the control method of the cabinet slot includes: detecting a plurality of slots in the cabinet according to the interrupt signal, and obtaining the number of slots in the plurality of slots. The slot status of each slot is detected; the target slot is determined according to the slot status of each of the multiple slots; the interrupt event is triggered according to the identification information of the target slot.

可选地,所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述柜机槽位的控制方法还包括:控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。Optionally, the interrupt event carries the identification information of the target slot, when the interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the Before the level signal is sent to the main control module, the method for controlling the slot position of the cabinet further includes: controlling the main control module of the cabinet to determine the analog switch corresponding to the interrupt event according to the identification information carried in the interrupt event .

根据本发明实施例的另外一个方面,还提供了一种柜机槽位的控制装置,包括:发送单元,用于当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块;第一确定单元,用于当所述主控模块接收到所述电平信号时,控制所述主控模块基于所述电平信号对所述模拟开关对应的预定数量的槽位进行查询,根据查询结果确定所述中断事件对应的所述预定数量的槽位中的目标槽位;控制单元,用于向所述目标槽位发送控制信息,以控制所述柜机中的目标槽位动作弹出目标设备或将目标设备锁定。According to another aspect of the embodiments of the present invention, a device for controlling a slot of a cabinet is also provided, including: a sending unit, configured to, when an interrupt event is detected, generate a corresponding part of the interrupt event in response to the interrupt event The level signal of the analog switch, and send the level signal to the main control module; the first determination unit is used to control the main control module to base on the level signal when the main control module receives the level signal The level signal queries a predetermined number of slots corresponding to the analog switch, and determines a target slot in the predetermined number of slots corresponding to the interrupt event according to the query result; The target slot sends control information to control the target slot in the cabinet to eject the target device or lock the target device.

可选地,该柜机槽位的控制装置还包括:第二确定单元,用于在当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,确定柜机的模拟开关的数量,其中,所述柜机用于存放所述目标设备以及其他与所述目标设备相同的设备;第三确定单元,用于确定所述柜机的主控模块控制的多个槽位;分组单元,用于根据所述柜机的模拟开关的数量对所述主控模块控制的多个槽位进行分组,使得每一个所述模拟开关控制预定数量的槽位。Optionally, the control device for the cabinet slot position further includes: a second determination unit, configured to, when an interrupt event is detected, generate a level signal of an analog switch corresponding to the interrupt event in response to the interrupt event , and before sending the level signal to the main control module, determine the number of analog switches in the cabinet, where the cabinet is used to store the target device and other devices that are the same as the target device; third a determining unit for determining multiple slots controlled by the main control module of the cabinet; a grouping unit for grouping multiple slots controlled by the main control module according to the number of analog switches of the cabinet , so that each of the analog switches controls a predetermined number of slots.

可选地,所述柜机槽位的控制装置包括:第一检测单元,用于在控制所述目标槽位动作弹出所述目标设备时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,根据所述中断信号对所述柜机中的存储的多个设备进行检测,得到所述多个设备中每一个设备的当前状态;第四确定单元,用于根据所述多个设备中每一个设备的当前状态确定所述目标设备;第一触发单元,用于根据所述目标设备的标识信息触发所述中断事件。Optionally, the control device for the cabinet slot includes: a first detection unit, configured to respond to the interrupt event when an interrupt event is detected when the target slot is controlled to act to eject the target device Generate a level signal of the analog switch corresponding to the interrupt event, and before sending the level signal to the main control module, detect a plurality of devices stored in the cabinet according to the interrupt signal, and obtain the current state of each device in the plurality of devices; the fourth determination unit is used for determining the target device according to the current state of each device in the plurality of devices; the first trigger unit is used for determining the target device according to the current state of each device in the plurality of devices The identification information of the device triggers the interrupt event.

可选地,所述柜机槽位的控制装置还包括:第五确定单元,用于所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。Optionally, the control device for the cabinet slot position further includes: a fifth determination unit, used for the interruption event to carry the identification information of the target slot position, when an interruption event is detected, in response to the interruption event. The level signal of the analog switch corresponding to the interruption event is generated, and before the level signal is sent to the main control module, the main control module that controls the cabinet determines the level signal according to the identification information carried in the interruption event. The analog switch corresponding to the interrupt event described above.

可选地,所述柜机槽位的控制装置包括:第二检测单元,用于在控制所述目标槽位动作将所述目标设备锁定时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,根据所述中断信号对所述柜机中的多个槽位进行检测,得到所述多个槽位中每一个槽位的槽位状态进行检测;第六确定单元,用于根据所述多个槽位中每一个槽位的槽位状态确定所述目标槽位;第二触发单元,用于根据所述目标槽位的标识信息触发所述中断事件。Optionally, the control device for the cabinet slot includes: a second detection unit, configured to respond to the interrupt when an interrupt event is detected when the target slot is controlled to lock the target device. The event generates the level signal of the analog switch corresponding to the interrupt event, and before sending the level signal to the main control module, detects multiple slots in the cabinet according to the interrupt signal, and obtains The slot status of each slot in the plurality of slots is detected; the sixth determination unit is used to determine the target slot according to the slot status of each slot in the plurality of slots; the second a triggering unit, configured to trigger the interrupt event according to the identification information of the target slot.

可选地,所述柜机槽位的控制装置还包括:第七确定单元,用于所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。Optionally, the control device for the cabinet slot position further includes: a seventh determination unit, used for the interruption event to carry the identification information of the target slot position, when an interruption event is detected, in response to the interruption event. The level signal of the analog switch corresponding to the interruption event is generated, and before the level signal is sent to the main control module, the main control module that controls the cabinet determines the level signal according to the identification information carried in the interruption event. The analog switch corresponding to the interrupt event described above.

在本发明实施例中,采用当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块;当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位;向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定,通过本发明实施例的柜机槽位的控制方法,实现了对柜机中的多个槽位进行分组以基于每个分组确定需要动作的目标槽位的目的,提高了对柜机的控制效率的技术效果,进而解决了相关技术中通过柜机对外围设备进行管理的方式比较复杂的技术问题。In the embodiment of the present invention, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is sent to the main control module; when the main control module receives the power When the signal is leveled, the control main control module queries the predetermined number of slots corresponding to the analog switch based on the level signal, and determines the target slot in the predetermined number of slots corresponding to the interrupt event according to the query result; sends the control to the target slot information to control the target slot in the cabinet to eject the target device or lock the target device. The method for controlling the slot of the cabinet according to the embodiment of the present invention realizes the grouping of multiple slots in the cabinet to be based on The purpose of determining the target slot to be acted on by each group improves the technical effect of the control efficiency of the cabinet, and further solves the technical problem that the management of peripheral devices through the cabinet is complicated in the related art.

附图说明Description of drawings

此处所说明的附图用来提供对本发明的进一步理解,构成本申请的一部分,本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。在附图中:The accompanying drawings described herein are used to provide a further understanding of the present invention and constitute a part of the present application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the attached image:

图1是根据本发明实施例的柜机槽位的控制方法的流程图;1 is a flowchart of a method for controlling a cabinet slot position according to an embodiment of the present invention;

图2是根据本发明实施例的柜机槽位的控制装置的示意图。FIG. 2 is a schematic diagram of a control device for a cabinet slot according to an embodiment of the present invention.

具体实施方式Detailed ways

为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分的实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本发明保护的范围。In order to make those skilled in the art better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only Embodiments are part of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本发明的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。It should be noted that the terms "first", "second" and the like in the description and claims of the present invention and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific sequence or sequence. It is to be understood that the data so used may be interchanged under appropriate circumstances such that the embodiments of the invention described herein can be practiced in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having", and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those expressly listed Rather, those steps or units may include other steps or units not expressly listed or inherent to these processes, methods, products or devices.

实施例1Example 1

根据本发明实施例,提供了一种柜机槽位的控制方法的方法实施例,需要说明的是,在附图的流程图示出的步骤可以在诸如一组计算机可执行指令的计算机系统中执行,并且,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。According to an embodiment of the present invention, a method embodiment of a method for controlling a slot of a cabinet is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings may be implemented in a computer system such as a set of computer-executable instructions. and, although a logical order is shown in the flowcharts, in some cases the steps shown or described may be performed in an order different from that herein.

图1是根据本发明实施例的柜机槽位的控制方法的流程图,如图1所示,该柜机槽位的控制方法包括如下步骤:FIG. 1 is a flowchart of a method for controlling a cabinet slot according to an embodiment of the present invention. As shown in FIG. 1 , the method for controlling a cabinet slot includes the following steps:

步骤S102,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块。Step S102, when an interrupt event is detected, a level signal of an analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is sent to the main control module.

步骤S104,当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位。Step S104, when the main control module receives the level signal, controls the main control module to query the predetermined number of slots corresponding to the analog switch based on the level signal, and determines the predetermined number of slots corresponding to the interrupt event according to the query result. target slot.

其中,这里的预定数量的槽位是主控模块控制的所有槽位的一部分。Wherein, the predetermined number of slots here is a part of all the slots controlled by the main control module.

步骤S106,向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定。Step S106, sending control information to the target slot to control the target slot in the cabinet to eject the target device or lock the target device.

由上可知,在本发明实施例中,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块;当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位;向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定,实现了对柜机中的多个槽位进行分组以基于每个分组确定需要动作的目标槽位的目的。It can be seen from the above that in this embodiment of the present invention, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is sent to the main control module; when the main control module When receiving the level signal, the control main control module queries the predetermined number of slots corresponding to the analog switch based on the level signal, and determines the target slot in the predetermined number of slots corresponding to the interrupt event according to the query result; Send control information to control the target slot in the cabinet to eject the target device or lock the target device, which realizes the grouping of multiple slots in the cabinet to determine the target slot that needs action based on each grouping. Purpose.

容易注意到,由于在本发明实施例中,当检测到中断事件时,响应于该中断事件生成与中断事件对应的模拟开关的电平信号,并将该电平信号发送至主控模块,从而主控模块根据电平信号对该模拟开关控制的预定数量的槽位进行查询,以得到目标槽位,有效避免了对柜机的所有槽位进行查询,需要较长的时间的弊端,实现了对柜机中的多个槽位进行分组以基于每个分组确定需要动作的目标槽位的目的,提高了对柜机的控制效率的技术效果。It is easy to notice that in this embodiment of the present invention, when an interrupt event is detected, a level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is sent to the main control module, thereby The main control module queries the predetermined number of slots controlled by the analog switch according to the level signal to obtain the target slot, which effectively avoids the drawback of querying all the slots in the cabinet, which takes a long time, and realizes the The purpose of grouping a plurality of slots in the cabinet to determine a target slot requiring action based on each grouping increases the technical effect of improving the control efficiency of the cabinet.

因此,通过本发明实施例的柜机槽位的控制方法,解决了相关技术中通过柜机对外围设备进行管理的方式比较复杂的技术问题。Therefore, the method for controlling the slot position of the cabinet according to the embodiment of the present invention solves the technical problem that the management of the peripheral devices through the cabinet is relatively complicated in the related art.

在一种可选的实施例中,在当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,该柜机槽位的控制方法还包括:确定柜机的模拟开关的数量,其中,柜机用于存放目标设备以及其他与目标设备相同的设备;确定柜机的主控模块控制的多个槽位;根据柜机的模拟开关的数量对主控模块控制的多个槽位进行分组,使得每一个模拟开关控制预定数量的槽位。In an optional embodiment, when an interrupt event is detected, a level signal of an analog switch corresponding to the interrupt event is generated in response to the interrupt event, and before the level signal is sent to the main control module, the cabinet The method for controlling the slots also includes: determining the number of analog switches of the cabinet, wherein the cabinet is used to store the target device and other devices that are the same as the target device; determining a plurality of slots controlled by the main control module of the cabinet; The number of analog switches of the cabinet is used to group multiple slots controlled by the main control module, so that each analog switch controls a predetermined number of slots.

例如,这里的柜机可以为对移动充电设备进行管理的柜机,该柜机的主控模块MCU可以控制72个共享槽位,相关技术中,一般是通过主控模块对72个共享槽位进行逐个轮回,会耗费较长的时间并且容易出现错误。在本发明实施例中,则对这72个共享槽位进行分组,具体地,设置18个模拟开关,这样每一个模拟开关可以带4个共享槽位,从而当检测到触发事件时,可以先确定一个模拟开关,再对模拟开关中的共享槽位进行查询,从而得到目标槽位。For example, the cabinet here can be a cabinet that manages mobile charging equipment. The main control module MCU of the cabinet can control 72 shared slots. In related technologies, the main control module is generally used to control the 72 shared slots. It takes a long time and is prone to errors. In this embodiment of the present invention, the 72 shared slots are grouped, and specifically, 18 analog switches are set, so that each analog switch can have 4 shared slots, so that when a trigger event is detected, the Determine an analog switch, and then query the shared slot in the analog switch to obtain the target slot.

由于在本发明实施例中,由于对主控模块控制的所有槽位进行了分组,并且每个分组对应一个模拟开关,因此,当检测到中断事件后,会触发一个模拟开关,在这样情况下,只需要对该模拟开关下的槽位进行查询,得到目标槽位,从而降低了目标槽位的查询时间,从而也提高了信号的响应速度。In this embodiment of the present invention, since all the slots controlled by the main control module are grouped, and each group corresponds to an analog switch, an analog switch will be triggered when an interrupt event is detected. In this case , it is only necessary to query the slot under the analog switch to obtain the target slot, thereby reducing the query time of the target slot, thereby also improving the response speed of the signal.

在一种可选的实施例中,在控制目标槽位动作弹出目标设备时,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,柜机槽位的控制方法包括:根据中断信号对柜机中的存储的多个设备进行检测,得到多个设备中每一个设备的当前状态;根据多个设备中每一个设备的当前状态确定目标设备;根据目标设备的标识信息触发中断事件。In an optional embodiment, when the control target slot action pops up the target device, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal Before sending to the main control module, the method for controlling the slot position of the cabinet includes: detecting a plurality of devices stored in the cabinet according to the interrupt signal, and obtaining the current state of each device in the plurality of devices; The current state of a device determines the target device; the interrupt event is triggered according to the identification information of the target device.

例如,当接收到移动充电设备的租借信息时,可以对柜机中的多个设备进行检测,得到多个设备中每一个设备的当前状态,例如,剩余电量,是否故障等;根据多个设备中每一个设备的当前状态确定目标设备,进而根据目标设备的标识信息触发中断事件。For example, when the rental information of the mobile charging device is received, multiple devices in the cabinet can be detected to obtain the current status of each device in the multiple devices, such as the remaining power, whether it is faulty, etc.; according to the multiple devices The current state of each device in the device determines the target device, and then triggers an interrupt event according to the identification information of the target device.

在一种可选的实施例中,中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,柜机槽位的控制方法还可以包括:控制柜机的主控模块根据中断事件中携带的标识信息确定中断事件对应的模拟开关。In an optional embodiment, the interrupt event carries the identification information of the target slot, when the interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is Before the signal is sent to the main control module, the method for controlling the slot position of the cabinet may further include: the main control module controlling the cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event.

在一种可选的实施例中,在控制目标槽位动作将目标设备锁定时,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,柜机槽位的控制方法可以包括:根据中断信号对柜机中的多个槽位进行检测,得到多个槽位中每一个槽位的槽位状态进行检测;根据多个槽位中每一个槽位的槽位状态确定目标槽位;根据目标槽位的标识信息触发中断事件。在该实施例中,在用户将目标设备归还时,会根据中断信号对柜机中的多个槽位进行检测,得到多个槽位中每一个槽位的槽位状态,确定槽位为空的槽位为目标槽位,从而可以触发目标槽位动作已经放置于其中的目标设备锁定。In an optional embodiment, when the target slot action is controlled to lock the target device, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is Before the signal is sent to the main control module, the method for controlling the slots of the cabinet may include: detecting multiple slots in the cabinet according to the interrupt signal, and obtaining the slot status of each of the multiple slots for detection; The target slot is determined according to the slot status of each of the multiple slots; the interrupt event is triggered according to the identification information of the target slot. In this embodiment, when the user returns the target device, the multiple slots in the cabinet will be detected according to the interrupt signal, the slot status of each slot in the multiple slots is obtained, and it is determined that the slot is empty The slot of is the target slot, which can trigger the target slot action to lock the target device in which it has been placed.

需要说明的是,当将目标设备锁定于目标槽位后,会将目标槽位的标识信息与目标设备的标识信息关联起来,以便后续基于目标设备的标识信息生成触发事件时,可以基于该触发事件中携带的目标设备的标识信息确定目标槽位。It should be noted that when the target device is locked in the target slot, the identification information of the target slot will be associated with the identification information of the target device, so that when a trigger event is subsequently generated based on the identification information of the target device, it can be based on the trigger. The identification information of the target device carried in the event determines the target slot.

例如,当检测到中断事件后,主控模块会根据中断事件中携带的槽位标识信息,找到控制该标识信息对应的槽位的模拟开关,然后对该模拟开关下的几个槽位进行查询即可得到目标槽位。即,在本发明实施例中,槽位的标识信息也与控制其的模拟开关关联,只需要知道槽位的标识信息,就可以确定控制其的模拟开关。For example, when an interrupt event is detected, the main control module will, according to the slot identification information carried in the interrupt event, find the analog switch that controls the slot corresponding to the identification information, and then query several slots under the analog switch. to get the target slot. That is, in the embodiment of the present invention, the identification information of the slot is also associated with the analog switch that controls the slot, and the analog switch that controls the slot can be determined only by knowing the identification information of the slot.

在一种可选的实施例中,中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,柜机槽位的控制方法还包括:控制柜机的主控模块根据中断事件中携带的标识信息确定中断事件对应的模拟开关。In an optional embodiment, the interrupt event carries the identification information of the target slot, when the interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is Before the signal is sent to the main control module, the method for controlling the slot position of the cabinet further includes: the main control module controlling the cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event.

通过本发明实施例提供的柜机槽位的控制方法,通过设置模拟开关的数量将主控模块控制的多个槽位(即,共享槽位)进行分组,使得每一个模拟开关分别控制预定数量的槽位,这预定数量的槽位同一产生一个中断事件,每一个中断事件对应一路模拟开关,当收到某组槽位产生的中断事件,然后,查询预定数量的槽位是哪一个槽位有触发的中断事件,便可完成对该中断事件对应的槽位进行控制以达到对该槽位对应的设备进行控制,提供了对柜机进行控制的效率的技术效果。With the method for controlling cabinet slots provided by the embodiments of the present invention, multiple slots (ie, shared slots) controlled by the main control module are grouped by setting the number of analog switches, so that each analog switch controls a predetermined number of respectively. The predetermined number of slots will generate an interrupt event at the same time, and each interrupt event corresponds to one analog switch. When an interrupt event generated by a certain group of slots is received, then query which slot the predetermined number of slots is. When there is a triggered interrupt event, the slot corresponding to the interrupt event can be controlled to achieve the control of the device corresponding to the slot, and the technical effect of the efficiency of controlling the cabinet is provided.

实施例2Example 2

根据本发明实施例的另外一个方面,还提供了一种柜机槽位的控制装置,图2是根据本发明实施例的柜机槽位的控制装置的示意图,如图2所示,该柜机槽位的控制装置包括:发送单元21,第一确定单元23以及控制单元25。下面对该柜机槽位的控制装置进行详细说明。According to another aspect of the embodiment of the present invention, a control device for a cabinet slot is also provided. FIG. 2 is a schematic diagram of a control device for a cabinet slot according to an embodiment of the present invention. As shown in FIG. 2 , the cabinet The control device of the machine slot includes: a sending unit 21 , a first determining unit 23 and a control unit 25 . The control device of the cabinet slot is described in detail below.

发送单元21,用于当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块。The sending unit 21 is configured to, when an interrupt event is detected, generate a level signal of the analog switch corresponding to the interrupt event in response to the interrupt event, and send the level signal to the main control module.

第一确定单元23,用于当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位。The first determination unit 23 is used to control the main control module to query the predetermined number of slots corresponding to the analog switch based on the level signal when the main control module receives the level signal, and determine the predetermined number of slots corresponding to the interrupt event according to the query result the target slot in the slot of .

控制单元25,用于向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定。The control unit 25 is configured to send control information to the target slot, so as to control the target slot in the cabinet to eject the target device or lock the target device.

此处需要说明的是,上述发送单元21,第一确定单元23以及控制单元25对应于实施例1中的步骤S102至S106,上述单元与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例1所公开的内容。需要说明的是,上述单元作为装置的一部分可以在诸如一组计算机可执行指令的计算机系统中执行。It should be noted here that the above-mentioned sending unit 21, the first determining unit 23 and the control unit 25 correspond to steps S102 to S106 in Embodiment 1, and the examples and application scenarios implemented by the above-mentioned units and the corresponding steps are the same, but not the same. It is limited to the content disclosed in the above-mentioned Embodiment 1. It should be noted that the above-mentioned units may be executed in a computer system such as a set of computer-executable instructions as part of an apparatus.

由上可知,在本申请上述实施例中,发送单元,用于当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块;第一确定单元,用于当主控模块接收到电平信号时,控制主控模块基于电平信号对模拟开关对应的预定数量的槽位进行查询,根据查询结果确定中断事件对应的预定数量的槽位中的目标槽位;控制单元,用于向目标槽位发送控制信息,以控制柜机中的目标槽位动作弹出目标设备或将目标设备锁定。通过本发明实施例的柜机槽位的控制装置,实现了对柜机中的多个槽位进行分组以基于每个分组确定需要动作的目标槽位的目的,提高了对柜机的控制效率的技术效果,进而解决了相关技术中通过柜机对外围设备进行管理的方式比较复杂的技术问题。It can be seen from the above that in the above-mentioned embodiments of the present application, the sending unit is configured to, when an interrupt event is detected, generate a level signal of the analog switch corresponding to the interrupt event in response to the interrupt event, and send the level signal to the master controller. module; a first determination unit, used to control the main control module to query a predetermined number of slots corresponding to the analog switch based on the level signal when the main control module receives the level signal, and determine the predetermined number of slots corresponding to the interrupt event according to the query result The target slot in the number of slots; the control unit is used to send control information to the target slot to control the action of the target slot in the cabinet to eject the target device or lock the target device. By means of the device for controlling the slots of the cabinet in the embodiment of the present invention, the purpose of grouping multiple slots in the cabinet to determine the target slot requiring action based on each grouping is realized, and the control efficiency of the cabinet is improved. The technical effect of the invention is further solved, and the technical problem of the related art of managing the peripheral equipment through the cabinet is relatively complicated.

在一种可选的实施例中,该柜机槽位的控制装置还包括:第二确定单元,用于在当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,确定柜机的模拟开关的数量,其中,柜机用于存放目标设备以及其他与目标设备相同的设备;第三确定单元,用于确定柜机的主控模块控制的多个槽位;分组单元,用于根据柜机的模拟开关的数量对主控模块控制的多个槽位进行分组,使得每一个模拟开关控制预定数量的槽位。In an optional embodiment, the apparatus for controlling the slot position of the cabinet further includes: a second determining unit, configured to, when an interruption event is detected, generate the power of the analog switch corresponding to the interruption event in response to the interruption event level signal, and before sending the level signal to the main control module, determine the number of analog switches in the cabinet, where the cabinet is used to store the target device and other devices that are the same as the target device; the third determination unit is used to determine Multiple slots controlled by the main control module of the cabinet; grouping unit, used to group multiple slots controlled by the main control module according to the number of analog switches of the cabinet, so that each analog switch controls a predetermined number of slots .

在一种可选的实施例中,柜机槽位的控制装置包括:第一检测单元,用于在控制目标槽位动作弹出目标设备时,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,根据中断信号对柜机中的存储的多个设备进行检测,得到多个设备中每一个设备的当前状态;第四确定单元,用于根据多个设备中每一个设备的当前状态确定目标设备;第一触发单元,用于根据目标设备的标识信息触发中断事件。In an optional embodiment, the apparatus for controlling a cabinet slot includes: a first detection unit, configured to, when controlling the target slot to eject the target device, when an interrupt event is detected, generate a Interrupt the level signal of the analog switch corresponding to the event, and before sending the level signal to the main control module, detect multiple devices stored in the cabinet according to the interrupt signal, and obtain the current state of each device in the multiple devices ; a fourth determining unit for determining a target device according to the current state of each of the multiple devices; a first triggering unit for triggering an interrupt event according to the identification information of the target device.

在一种可选的实施例中,柜机槽位的控制装置还包括:第五确定单元,用于中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,控制柜机的主控模块根据中断事件中携带的标识信息确定中断事件对应的模拟开关。In an optional embodiment, the control device for the cabinet slot further includes: a fifth determination unit, configured to carry the identification information of the target slot in the interrupt event, and respond to the interrupt event when the interrupt event is detected. Before generating the level signal of the analog switch corresponding to the interruption event and sending the level signal to the main control module, the main control module of the control cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event.

在一种可选的实施例中,柜机槽位的控制装置包括:第二检测单元,用于在控制目标槽位动作将目标设备锁定时,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,根据中断信号对柜机中的多个槽位进行检测,得到多个槽位中每一个槽位的槽位状态进行检测;第六确定单元,用于根据多个槽位中每一个槽位的槽位状态确定目标槽位;第二触发单元,用于根据目标槽位的标识信息触发中断事件。In an optional embodiment, the apparatus for controlling a cabinet slot includes: a second detection unit, configured to generate an interrupt event in response to an interrupt event when an interrupt event is detected when the target slot is controlled to lock the target device. The level signal of the analog switch corresponding to the interrupt event, and before the level signal is sent to the main control module, the multiple slots in the cabinet are detected according to the interrupt signal, and the level of each slot in the multiple slots is obtained. The slot state is detected; the sixth determination unit is used to determine the target slot according to the slot state of each of the multiple slots; the second trigger unit is used to trigger the interrupt event according to the identification information of the target slot.

在一种可选的实施例中,柜机槽位的控制装置还包括:第七确定单元,用于中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于中断事件生成与中断事件对应的模拟开关的电平信号,并将电平信号发送至主控模块之前,控制柜机的主控模块根据中断事件中携带的标识信息确定中断事件对应的模拟开关。In an optional embodiment, the apparatus for controlling the slot of the cabinet further includes: a seventh determination unit, configured to carry the identification information of the target slot in the interrupt event, and respond to the interrupt event when the interrupt event is detected Before generating the level signal of the analog switch corresponding to the interruption event and sending the level signal to the main control module, the main control module of the control cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event.

上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。The above-mentioned serial numbers of the embodiments of the present invention are only for description, and do not represent the advantages or disadvantages of the embodiments.

在本发明的上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the above-mentioned embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.

在本申请所提供的几个实施例中,应该理解到,所揭露的技术内容,可通过其它的方式实现。其中,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,可以为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,单元或模块的间接耦合或通信连接,可以是电性或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are only illustrative, for example, the division of the units may be a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components may be combined or Integration into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of units or modules, and may be in electrical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components shown as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium , including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes .

以上所述仅是本发明的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。The above are only the preferred embodiments of the present invention. It should be pointed out that for those skilled in the art, without departing from the principles of the present invention, several improvements and modifications can be made. It should be regarded as the protection scope of the present invention.

Claims (8)

1.一种柜机槽位的控制方法,其特征在于,包括:1. a control method of a cabinet slot position, is characterized in that, comprises: 当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块;When an interrupt event is detected, a level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and the level signal is sent to the main control module; 当所述主控模块接收到所述电平信号时,控制所述主控模块基于所述电平信号对所述模拟开关对应的预定数量的槽位进行查询,根据查询结果确定所述中断事件对应的所述预定数量的槽位中的目标槽位,其中,所述目标槽位为柜机中的槽位;When the main control module receives the level signal, it controls the main control module to query a predetermined number of slots corresponding to the analog switch based on the level signal, and determines the interrupt event according to the query result the corresponding target slot in the predetermined number of slots, wherein the target slot is a slot in the cabinet; 向所述目标槽位发送控制信息,以控制所述柜机中的目标槽位动作弹出目标设备或将目标设备锁定;Send control information to the target slot to control the target slot in the cabinet to eject the target device or lock the target device; 其中,在当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,还包括:Wherein, when an interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and before the level signal is sent to the main control module, the method further includes: 确定柜机的模拟开关的数量,其中,所述柜机用于存放所述目标设备以及其他与所述目标设备相同的设备;determining the number of analog switches in a cabinet, wherein the cabinet is used to store the target device and other devices identical to the target device; 确定所述柜机的主控模块控制的多个槽位;Determine multiple slots controlled by the main control module of the cabinet; 根据所述柜机的模拟开关的数量对所述主控模块控制的多个槽位进行分组,使得每一个所述模拟开关控制预定数量的槽位。The multiple slots controlled by the main control module are grouped according to the number of analog switches of the cabinet, so that each of the analog switches controls a predetermined number of slots. 2.根据权利要求1所述的方法,其特征在于,在控制所述目标槽位动作弹出所述目标设备时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述方法包括:2. The method according to claim 1, wherein, when controlling the target slot action to pop up the target device, when an interrupt event is detected, a generation corresponding to the interrupt event is generated in response to the interrupt event The level signal of the analog switch, and before sending the level signal to the main control module, the method includes: 根据所述中断事件对所述柜机中的存储的多个设备进行检测,得到所述多个设备中每一个设备的当前状态;Detecting a plurality of devices stored in the cabinet according to the interruption event, to obtain the current state of each device in the plurality of devices; 根据所述多个设备中每一个设备的当前状态确定所述目标设备;determining the target device according to the current state of each of the plurality of devices; 根据所述目标设备的标识信息触发所述中断事件。The interrupt event is triggered according to the identification information of the target device. 3.根据权利要求2所述的方法,其特征在于,所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述方法还包括:3. method according to claim 2, is characterized in that, carries the identification information of target slot position in described interrupt event, when detecting interrupt event, in response to described interrupt event generation and described interrupt event corresponding Simulate the level signal of the switch, and before sending the level signal to the main control module, the method further includes: 控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。The main control module that controls the cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event. 4.根据权利要求1所述的方法,其特征在于,在控制所述目标槽位动作将所述目标设备锁定时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述方法包括:4. The method according to claim 1, characterized in that, when controlling the target slot action to lock the target device, when an interrupt event is detected, generating and the interrupt event in response to the interrupt event The level signal of the corresponding analog switch, and before sending the level signal to the main control module, the method includes: 根据所述中断事件对所述柜机中的多个槽位进行检测,得到所述多个槽位中每一个槽位的槽位状态进行检测;Detecting a plurality of slots in the cabinet according to the interruption event to obtain a slot status of each of the plurality of slots for detection; 根据所述多个槽位中每一个槽位的槽位状态确定所述目标槽位;Determine the target slot according to the slot state of each slot in the plurality of slots; 根据所述目标槽位的标识信息触发所述中断事件。The interrupt event is triggered according to the identification information of the target slot. 5.根据权利要求4所述的方法,其特征在于,所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,所述方法还包括:5. method according to claim 4, is characterized in that, carrying the identification information of target slot in described interrupt event, when detecting interrupt event, in response to described interrupt event generation and described interrupt event corresponding Simulate the level signal of the switch, and before sending the level signal to the main control module, the method further includes: 控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。The main control module that controls the cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event. 6.一种柜机槽位的控制装置,其特征在于,包括:6. A control device for a cabinet slot, comprising: 发送单元,用于当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块;a sending unit, configured to, when an interrupt event is detected, generate a level signal of an analog switch corresponding to the interrupt event in response to the interrupt event, and send the level signal to the main control module; 第一确定单元,用于当所述主控模块接收到所述电平信号时,控制所述主控模块基于所述电平信号对所述模拟开关对应的预定数量的槽位进行查询,根据查询结果确定所述中断事件对应的所述预定数量的槽位中的目标槽位;The first determining unit is configured to, when the main control module receives the level signal, control the main control module to query the predetermined number of slots corresponding to the analog switch based on the level signal, and according to the The query result determines the target slot in the predetermined number of slots corresponding to the interrupt event; 控制单元,用于向所述目标槽位发送控制信息,以控制所述柜机中的目标槽位动作弹出目标设备或将目标设备锁定;a control unit, configured to send control information to the target slot to control the target slot in the cabinet to eject the target device or lock the target device; 其中,还包括:Among them, it also includes: 第二确定单元,用于在当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,确定柜机的模拟开关的数量,其中,所述柜机用于存放所述目标设备以及其他与所述目标设备相同的设备;The second determining unit is configured to, when an interrupt event is detected, generate a level signal of the analog switch corresponding to the interrupt event in response to the interrupt event, and before sending the level signal to the main control module, determining the number of analog switches in a cabinet, wherein the cabinet is used to store the target device and other devices identical to the target device; 第三确定单元,用于确定所述柜机的主控模块控制的多个槽位;a third determining unit, configured to determine a plurality of slots controlled by the main control module of the cabinet; 分组单元,用于根据所述柜机的模拟开关的数量对所述主控模块控制的多个槽位进行分组,使得每一个所述模拟开关控制预定数量的槽位。A grouping unit, configured to group a plurality of slots controlled by the main control module according to the number of analog switches of the cabinet, so that each of the analog switches controls a predetermined number of slots. 7.根据权利要求6所述的装置,其特征在于,所述装置包括:7. The apparatus of claim 6, wherein the apparatus comprises: 第一检测单元,用于在控制所述目标槽位动作弹出所述目标设备时,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,根据所述中断事件对所述柜机中的存储的多个设备进行检测,得到所述多个设备中每一个设备的当前状态;The first detection unit is configured to, when controlling the target slot action to pop up the target device, when an interrupt event is detected, generate a level signal of an analog switch corresponding to the interrupt event in response to the interrupt event, Before sending the level signal to the main control module, detect the multiple devices stored in the cabinet according to the interrupt event, and obtain the current state of each device in the multiple devices; 第四确定单元,用于根据所述多个设备中每一个设备的当前状态确定所述目标设备;a fourth determining unit, configured to determine the target device according to the current state of each device in the plurality of devices; 第一触发单元,用于根据所述目标设备的标识信息触发所述中断事件。A first triggering unit, configured to trigger the interrupt event according to the identification information of the target device. 8.根据权利要求7所述的装置,其特征在于,所述装置还包括:8. The apparatus according to claim 7, wherein the apparatus further comprises: 第五确定单元,用于所述中断事件中携带有目标槽位的标识信息,当检测到中断事件时,响应于所述中断事件生成与所述中断事件对应的模拟开关的电平信号,并将所述电平信号发送至主控模块之前,控制所述柜机的主控模块根据所述中断事件中携带的标识信息确定所述中断事件对应的模拟开关。The fifth determination unit is used to carry the identification information of the target slot in the interrupt event, when the interrupt event is detected, the level signal of the analog switch corresponding to the interrupt event is generated in response to the interrupt event, and Before sending the level signal to the main control module, the main control module controlling the cabinet determines the analog switch corresponding to the interruption event according to the identification information carried in the interruption event.
CN201911419897.0A 2019-12-31 2019-12-31 Cabinet slot control method and device Expired - Fee Related CN111190367B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911419897.0A CN111190367B (en) 2019-12-31 2019-12-31 Cabinet slot control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911419897.0A CN111190367B (en) 2019-12-31 2019-12-31 Cabinet slot control method and device

Publications (2)

Publication Number Publication Date
CN111190367A CN111190367A (en) 2020-05-22
CN111190367B true CN111190367B (en) 2020-12-08

Family

ID=70709811

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911419897.0A Expired - Fee Related CN111190367B (en) 2019-12-31 2019-12-31 Cabinet slot control method and device

Country Status (1)

Country Link
CN (1) CN111190367B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113641555B (en) * 2021-08-17 2023-11-24 中国联合网络通信集团有限公司 Faulty equipment locating method, device, equipment and readable storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1299213C (en) * 2002-09-19 2007-02-07 华为技术有限公司 Method for making centralized control processing by utilizing CPU on system board
CN100471128C (en) * 2005-12-30 2009-03-18 华为技术有限公司 Method and device for realizing equipment state polling
CN201397503Y (en) * 2008-11-21 2010-02-03 冶金自动化研究设计院 Interrupt expander circuit
KR101958902B1 (en) * 2011-09-30 2019-07-03 삼성전자주식회사 Method for group controlling of electronic devices and electronic device management system therefor
CN102662889B (en) * 2012-04-24 2016-12-14 华为技术有限公司 Interruption processing method, interrupt control unit and processor
WO2018133242A1 (en) * 2017-01-19 2018-07-26 华为技术有限公司 Terminal, debugging system, and debugging method

Also Published As

Publication number Publication date
CN111190367A (en) 2020-05-22

Similar Documents

Publication Publication Date Title
US20160239540A1 (en) Data Query Method and Apparatus, Server, and System
CN104516851B (en) A kind of system and method for RS485 slave units address distribution
US20120167087A1 (en) Apparatus and method for driving virtual machine, and method for deduplication of virtual machine image
WO2014101044A1 (en) Partition balancing method, device and server in distributed storage system
JP2016508638A5 (en)
CN106888100B (en) Ethernet power supply switch and power supply method thereof
CN111190367B (en) Cabinet slot control method and device
CN105824775A (en) Electronic equipment and information processing method
WO2016183918A1 (en) Method and device for processing storage space
CN114049123A (en) Block chain consensus method and device, computer equipment and storage medium
CN108540582B (en) Terminal identification processing method, server and terminal
CN104794079A (en) Bus arbitration method, device and system
CN111541762A (en) Data processing method, management server, device and storage medium
EP3896571A1 (en) Data backup method, apparatus and system
CN108345562B (en) Multi-path server and signal processing method thereof
CN107704734A (en) A kind of recognition methods of user account and its equipment
CN116775382B (en) Main and standby server switching method and system based on ZooKeeper distributed coordination service
CN108449225A (en) The system and method for determining and repairing network connectivity problem
EP1183623B1 (en) Data storage and retrieval
CN105183373B (en) A kind of data processing method and the network equipment
CN107818522B (en) User power condition query method and terminal equipment
CN112382016B (en) Container processing method and device, storage medium and electronic equipment
JPH1153201A (en) Method and device for processing plural interruptions
EP3671402A1 (en) Data recovery method and apparatus
CN100364280C (en) Method for sending safety strategy

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20201208