A method and device for determining a single-board slot number, a single board, and a storage medium
By connecting the main unit and the single board with screw holes and screw posts, and using the high and low level signals of the interface to determine the slot number, the problem of connector pin occupation in the existing technology is solved, and more flexible connector selection is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ZHEJIANG UNIVIEW TECH CO LTD
- Filing Date
- 2023-06-05
- Publication Date
- 2026-05-29
AI Technical Summary
Existing technology requires connector pins to be used when configuring board slot numbers via connectors, which affects connector pin allocation and selection.
The screw posts of the whole machine are connected to the screw holes of the single board through the connector. The first screw hole with the connector is determined, and the high and low level signals of the interface that are electrically connected to each screw hole are determined. The slot number of the single board is determined according to the high and low level signals of the interface.
The configuration of board slot numbers can be completed without occupying connector pins, making connector selection more flexible.
Smart Images

Figure CN119088174B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of communication technology, and in particular to a method, apparatus, board, and storage medium for determining the slot number of a single board. Background Technology
[0002] For certain business needs, at least two identical hard drive expansion boards need to be connected to the motherboard via high-speed connectors and cables. Each hard drive expansion board needs to be configured with a different slot number. The motherboard determines the location of the hardware expansion board based on the slot number transmitted by the hard drive expansion board. The location of the hardware expansion board will affect the management and configuration of the system business.
[0003] In existing technology, N (N is a positive integer and N≥1) pins are reserved on the connectors that interconnect the motherboard and expansion board. A high level on a pin is considered 1, and a low level is considered 0. The motherboard configures these pins with high and low levels, and arranging the N pins in a fixed order can form 2n slot numbers. The expansion board obtains its respective slot number by reading these pin levels. Obviously, the slot number configuration scheme provided by the existing technology requires the use of connector pins, affecting the pin allocation and selection of connectors. Summary of the Invention
[0004] This invention provides a method, apparatus, board, and storage medium for determining the slot number of a single board, which can complete the configuration of the slot number of a single board without occupying connector pins.
[0005] According to one aspect of the present invention, a method for determining the slot number of a single board is provided, applied to an entire machine, wherein the screw posts of the entire machine are respectively connected to the screw holes of at least two single boards via connectors, the method comprising:
[0006] For each of the at least two single boards, a first screw hole for fixing the connector is determined from the screw holes on the current single board; wherein the position of the first screw hole is different for each single board.
[0007] Determine the high and low level signals of the interfaces on the at least two single boards that are electrically connected to each screw hole in a one-to-one correspondence; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board.
[0008] For each board, the slot number of the current board is determined based on the high and low level signals of each interface on the current board.
[0009] According to another aspect of the present invention, a method for determining the slot number of a single board is provided, applied to a single board, the method comprising:
[0010] When the screw posts of the whole machine are connected to the screw holes on the single board through the connector, the position information of the connector on the single board is determined;
[0011] The high and low level signals of at least one interface on the single board are determined based on the location information; wherein, the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence.
[0012] The slot number of the single board is determined based on the high and low level signals of at least one interface.
[0013] According to another aspect of the present invention, a device for determining the slot number of a single board is provided, applied to an entire machine, wherein the screw posts of the entire machine are respectively connected to the screw holes of at least two single boards via connectors, the device comprising:
[0014] The first screw hole determining module is used to determine, for each of the at least two single boards, the first screw hole on which the connector is fixed from the screw holes on the current single board; wherein the position of the first screw hole on each single board is different.
[0015] An interface level signal determination module is used to determine the high and low level signals of the interfaces that are electrically connected to each screw hole on the at least two single boards respectively; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board.
[0016] The single-board slot number determination module is used to determine the slot number of each single board based on the high and low level signals of each interface on the current single board.
[0017] According to another aspect of the present invention, a device for determining the slot number of a single board is provided, applied to a single board, the device comprising:
[0018] The position information determination module is used to determine the position information of the connector on the single board when the screw post of the whole machine is connected to the screw hole on the single board through the connector;
[0019] A level signal determination module is used to determine the high and low level signals of at least one interface on the single board based on the position information; wherein the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence.
[0020] The slot number determination module is used to determine the slot number of the single board based on the high and low level signals of the at least one interface.
[0021] According to another aspect of the present invention, a single board is provided, the single board comprising:
[0022] At least one processor; and
[0023] A memory communicatively connected to the at least one processor; wherein,
[0024] The memory stores a computer program that can be executed by the at least one processor, which enables the at least one processor to perform the single-board slot number determination method according to any embodiment of the present invention.
[0025] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions, the computer instructions being configured to cause a processor to execute and implement the method for determining the single-board slot number as described in any embodiment of the present invention.
[0026] The single-board slot number determination scheme of this invention is applied to the entire machine. The method involves connecting the screw posts of the entire machine to the screw holes of at least two single boards via connectors. The method includes: for each of the at least two single boards, determining a first screw hole from the screw holes on the current single board where the connector is fixed; wherein the position of the first screw hole is different on each single board; determining the high and low level signals of the interfaces on the at least two single boards that are electrically connected to each screw hole; wherein the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, and the second interface is the interface electrically connected to the second screw hole, where the second screw hole is a screw hole other than the first screw hole on the single board; and determining the slot number of the current single board based on the high and low level signals of the interfaces on the current single board. The technical solution provided by this invention allows for the configuration of each single board slot number without occupying connector pins, making connector selection more flexible when connecting the single boards to the entire machine.
[0027] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description
[0028] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0029] Figure 1 This is a flowchart of a method for determining a single-board slot number according to Embodiment 1 of the present invention;
[0030] Figure 2 This is a flowchart of a method for determining a single-board slot number according to Embodiment 2 of the present invention;
[0031] Figure 3a This is a schematic diagram of the design structure of a single-board frame and a complete machine frame provided by an embodiment of the present invention;
[0032] Figure 3b This is a schematic diagram of the single-board slot number configuration after a single board is connected to the whole machine, provided by an embodiment of the present invention;
[0033] Figure 4a This is a schematic diagram of another design structure of single-board frame and overall machine frame provided by an embodiment of the present invention;
[0034] Figure 4b This is another schematic diagram of the single-board slot number configuration after the single board is connected to the whole machine, provided by an embodiment of the present invention;
[0035] Figure 5 This is a schematic diagram of a device for determining the slot number of a single board according to Embodiment 3 of the present invention;
[0036] Figure 6 This is a schematic diagram of a device for determining the slot number of a single board according to Embodiment 4 of the present invention;
[0037] Figure 7 This is a schematic diagram of the structure of a single board for implementing the method for determining the slot number of a single board according to an embodiment of the present invention. Detailed Implementation
[0038] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0039] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0040] Example 1
[0041] Figure 1 This is a flowchart illustrating a method for determining a single-board slot number according to Embodiment 1 of the present invention. This embodiment is applicable to situations involving determining single-board slot numbers. The method can be executed by a device for determining single-board slot numbers, which can be implemented in hardware and / or software. This device can be configured within the entire machine, wherein the screw posts of the entire machine are respectively connected to the screw holes of at least two single boards via connectors. Figure 1 As shown, the method includes:
[0042] S110. For each of the at least two single boards, determine the first screw hole where the connector is fixed from the screw holes on the current single board; wherein the position of the first screw hole is different for each of the screw holes on each single board.
[0043] In this embodiment of the invention, the complete machine is connected to at least two single boards. The screw posts of the complete machine are respectively connected to the screw holes of the at least two single boards via connectors, thereby achieving the connection between the complete machine and the at least two single boards. Each single board has at least one screw hole on its edge, and the complete machine has at least one screw post. The number of screw holes on the edges of each single board and the number of screw posts on the complete machine can be the same or different. This embodiment of the invention does not limit the number of screw holes and screw posts.
[0044] For each of at least two single boards, the first screw hole for fixing the connector is determined from the screw holes on the current single board. It is understood that when the current single board is connected to the complete machine, not every screw hole and screw post on the single board is fixed with a connector when assembled with the screw posts on the complete machine. Therefore, it is necessary to determine the screw hole for fixing the connector from the screw holes on the current single board, and this screw hole is referred to as the first screw hole. It should be noted that the position of the first screw hole on each single board is different. For example, if the complete machine is connected to three single boards, and each single board has three screw holes, and the number of first screw holes for fixing the connector on each single board is two, then the position of the first screw hole on the first single board can be the first and second screw holes; the position of the first screw hole on the second single board can be the first and third screw holes; and the position of the first screw hole on the third single board can be the second and third screw holes. Optionally, the connector can be a screw.
[0045] S120. Determine the high and low level signals of the interfaces on the at least two single boards that are electrically connected to each screw hole in a one-to-one correspondence; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board.
[0046] In this embodiment of the invention, each screw hole on each board is electrically connected to an interface, which can be a CPLD or a general purpose input / output (GPIO) interface of another chip. For each board on at least two boards, the high and low level signals of the interfaces electrically connected to each screw hole on the current board are determined. The high and low level signals of the first interface and the second interface are different; for example, the high level signal of the first interface is high, and the high and low level signal of the second interface is low; or, the high and low level signal of the first interface is low, and the high and low level signal of the second interface is high. The first interface is electrically connected to the first screw hole where a connector is fixed, and the second interface is electrically connected to the second screw hole where no connector is fixed. The second screw hole where no connector is fixed can be understood as any screw hole on the board other than the first screw hole.
[0047] S130. For each board, determine the slot number of the current board based on the high and low level signals of each interface on the current board.
[0048] For example, for each board, according to a pre-set interface sequence, the slot number of the current board is determined based on the high and low level signals of each interface on the current board. Since the positions of the first screw holes are different on each board, the high and low level signals of the interfaces electrically connected to the screw holes on each board are different. For example, the entire machine is connected to three single boards, and each single board has three screw holes. Each single board has two first screw holes for fixing connectors. The first screw hole on the first single board is located at the first and second screw holes. Therefore, the high and low level signals of the interfaces electrically connected to each screw hole on the first single board are: low level, low level, high level. Similarly, the first screw hole on the second single board is located at the first and third screw holes. Therefore, the high and low level signals of the interfaces electrically connected to each screw hole on the second single board are: low level, high level, low level. The first screw hole on the third single board can be located at the second and third screw holes. Therefore, the high and low level signals of the interfaces electrically connected to each screw hole on the third single board are: high level, low level, low level. For example, if a low level signal is represented by 0 and a high level signal by 1, then the slot number of the first single board is 001, the slot number of the second single board is 010, and the slot number of the third single board is 100.
[0049] The method for determining the slot number of a single board according to an embodiment of the present invention is applied to a complete machine. The method involves connecting the screw posts of the complete machine to the screw holes of at least two single boards via connectors. The method includes: for each of the at least two single boards, determining a first screw hole from the screw holes on the current single board where the connector is fixed; wherein the position of the first screw hole is different for each single board; determining the high and low level signals of the interfaces on the at least two single boards that are electrically connected to each screw hole; wherein the high and low level signals of the first interface and the second interface are different, the first interface being the interface electrically connected to the first screw hole, and the second interface being the interface electrically connected to the second screw hole, where the second screw hole is a screw hole other than the first screw hole on the single board; and determining the slot number of the current single board based on the high and low level signals of the interfaces on the current single board. The technical solution provided by this embodiment of the invention allows for the configuration of the slot numbers of each single board without occupying connector pins, making connector selection more flexible when connecting the single boards to the complete machine.
[0050] Example 2
[0051] Figure 2This is a flowchart illustrating a method for determining a single-board slot number according to Embodiment 1 of the present invention. This embodiment is applicable to situations involving determining a single-board slot number. This method can be executed by a device for determining the single-board slot number, which can be implemented in hardware and / or software and can be configured within the single-board. Figure 2 As shown, the method includes:
[0052] S210. When the screw posts of the whole machine are connected to the screw holes on the single board through the connector, the position information of the connector on the single board is determined.
[0053] The single board has at least one screw hole on its frame and at least one screw post on the whole machine. The number of screw holes on the frame of the single board and the number of screw posts on the whole machine can be the same or different. This embodiment of the invention does not limit the number of screw holes and screw posts.
[0054] In this embodiment of the invention, when the single board is connected to the complete machine, that is, when the screw posts of the complete machine are connected to the screw holes on the single board via connectors, the position information of the connectors on the single board is determined. It is understood that when the single board is connected to the complete machine, not every screw hole and screw post is fixed with a connector when assembled with the screw posts on the complete machine. Therefore, it is necessary to determine the position information of the connectors on the single board, that is, to determine the position of the screw holes of the connectors on the single board.
[0055] S220. Determine the high and low level signals of at least one interface on the single board according to the location information; wherein, the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence.
[0056] The board has at least one interface, which can be a general purpose input / output (GPIO) interface of a CPLD or other chip. The GPIO can be pulled high by a resistor. Each screw hole on the board is electrically connected to at least one interface. It is understood that the number of screw holes on the board is the same as the number of interfaces.
[0057] In this embodiment of the invention, the high and low level signals of each interface on the single board that is electrically connected to a screw hole are determined based on the position information of the connector on the single board. That is, the high and low level signals of each interface electrically connected to a screw hole on the single board are determined based on the position of the screw hole where the connector is located. For example, the high and low level signals of the interface corresponding to the screw hole at the location of the connector on the single board are different from the high and low level signals of the interfaces corresponding to other screw holes. These other screw holes are all screw holes on the single board except for the screw hole at the location of the connector.
[0058] Optionally, determining the high / low level signal of at least one interface on the single board based on the location information includes: determining a first screw hole on the single board from among the screw holes on the single board where the connector is fixed, based on the location information; determining that the high / low level signal of the interface electrically connected to the first screw hole is low, and the high level signal of the interface electrically connected to the second screw hole is high; wherein, the second screw hole is a screw hole on the single board other than the first screw hole. For example, based on the screw hole position of the connector on the single board, the screw hole on which the connector is fixed is determined from all the screw holes on the single board, and the screw hole on which the connector is fixed is designated as the first screw hole. It can be understood that the screw hole corresponding to the screw hole position of the connector on the single board is designated as the first screw hole. The high / low level signal of the interface on the single board electrically connected to the first screw hole is set to low (which can be represented by 0), and the high level signal of the interface electrically connected to the second screw hole is set to high (which can be represented by 1); wherein, the second screw hole is a screw hole on the single board other than the first screw hole.
[0059] Optionally, the single board is provided with N screw holes, and the single board slot of the whole machine is provided with M screw posts; wherein, when the single board is connected to the whole machine, M third screw holes among the N screw holes are assembled with the M screw posts; M≤N; according to the position information, the first screw hole for fixing the connector is determined from the screw holes on the single board, including: when P target screw holes among the M third screw holes are respectively connected to P target screw posts among the M screw posts one by one through the connector, the P target screw holes are determined as the first screw holes for fixing the connector.
[0060] In this embodiment of the invention, GPIO is used as an example for explanation. The board frame has N screw holes, each corresponding to a GPIO on the board. Therefore, the board also has N GPIOs. The initial level of each GPIO on the board can be pulled high by a resistor. Optionally, 2 N The number of boards that can be installed on the entire machine is greater than or equal to the maximum number of boards that can be installed on the entire machine. Based on business requirements, multiple identical boards need to be connected to the entire machine. Therefore, the maximum number of boards that can be connected to the entire machine can be determined based on the pre-set configuration information. Based on the maximum number of boards that can be installed on the entire machine, the number N of screw holes to be set on the edge of the board is determined, where 2 NThe maximum number of boards that can be installed in the entire machine is greater than or equal to the maximum number of boards that can be installed. For example, if the maximum number of boards that can be installed in the entire machine is 3, then N can be 2 or 3. If the maximum number of boards that can be installed in the entire machine is m, then the entire machine has m board slots. Each board slot in the entire machine has M screw posts, where M ≤ N, and the positions of the M screw posts in each board slot are different. When a board is connected to the entire machine, the M third screw holes out of the N screw holes can be assembled with the M screw posts; where the third screw holes are the screw holes corresponding to the positions of the M screw posts.
[0061] In this embodiment of the invention, when the single board is connected to the complete machine, the M third screw holes on the single board are assembled one-to-one with the M screw posts on the frame of the complete machine. If P target screw holes among the M first screw holes are connected one-to-one with the P target screw posts among the M screw posts through screws, the P target screw holes can be connected to the P target screw posts one-to-one through the screws, thereby making the GPIO electrically connected to the P target screw holes shorted to GND, so that the high and low level signals of the GPIO electrically connected to the P target screw holes on the single board are low (can be represented by 0), while the high and low level signals of the GPIO electrically connected to the other NP screw holes (i.e., the third target screw holes) on the single board are high (can be represented by 1). Among them, the third target screw holes include two types of screw holes: one type is screw holes that are assembled with the screw posts on the frame of the complete machine but without screws, and the other type is screw holes that are not assembled with the screw posts on the frame of the complete machine.
[0062] S230. Determine the slot number of the single board based on the high and low level signals of the at least one interface.
[0063] In this embodiment of the invention, the slot number of a single board is determined according to a pre-set interface order and based on the high and low level signals of each interface on the board. Optionally, determining the slot number of the single board based on the high and low level signals of at least one interface includes: obtaining a pre-set interface order; wherein the interface order is the order used to generate the single board slot number; and determining the slot number of the single board based on the high and low level signals of at least one interface according to the interface order. For example, the user can adjust the pre-set interface order as needed, wherein different pre-set interface orders result in different slot numbers of the single board generated based on the high and low level signals of at least one interface. There can be one or more single boards. When there are multiple single boards, each single board can determine its own slot number according to the single board slot number determination scheme provided in S210-S230.
[0064] For example, when a maximum of 3 identical boards can be installed on a single machine, N can be any integer greater than or equal to 2. Two schemes are described below:
[0065] Option 1 Figure 3a This is a schematic diagram of the design structure of a single-board frame and a complete machine frame provided in an embodiment of the present invention. Figure 3b This is a schematic diagram illustrating the configuration of the single-board slot number after the single-board is connected to the entire machine, as provided in an embodiment of the present invention. Figure 3a As shown, N=2 and M=2, meaning that the edge of the single board has two screw holes that are electrically connected to the GPIOs one-to-one, and the entire chassis has two screw posts that correspond to the screw holes on the single board. Figure 3b As shown, when the single board is connected to the complete machine, the two screw posts on the machine frame and the two screw holes on the single board frame are assembled together. Users can screw screws onto the screw posts as needed. The GPIO output level signal connected to the screw hole with the screw is low (0), and the GPIO output level signal connected to the screw hole without the screw is high (1). Therefore, the single board slot number can be any one of four: 00, 01, 10, and 11. This scheme can use N screw holes to configure 2 N With a slot number, when the number of boards is large, this solution can configure slot numbers for boards with fewer screw holes and GPIOs.
[0066] Option 2 Figure 4a This is a schematic diagram of another design structure for the single-board frame and the overall machine frame provided in an embodiment of the present invention. Figure 4b This is a schematic diagram illustrating the configuration of the single-board slot number after the single-board is connected to the entire machine, as provided in an embodiment of the present invention. Figure 4a As shown, N=3 and M=1, meaning that the board's edge has three screw holes that are electrically connected to each GPIO, and the chassis has one screw post that corresponds to the screw holes on the board. Figure 4b As shown, when the single board is connected to the complete machine, the three screw posts on the machine frame are assembled with one screw hole on the single board frame. The user can screw screws onto the screw posts as needed. The output level signal of the GPIO electrically connected to the screw hole with the screw is low (0), and the output level signal of the GPIO electrically connected to the screw hole without the screw is high (1). When the entire frame and the single board are connected to the grounding screw hole of the single board via the screw posts and screws, and the single board is installed in the slot and screwed in, the slot number changes from 111, 111, 111 to 011, 101, 110. This solution requires only one screw per single board, necessitating more GPIOs and screw holes, but effectively avoids incorrect screw insertion during machine assembly.
[0067] For example, when a maximum of four identical boards can be installed on a single machine, N≥2, and so on. This method is very flexible, allowing for the selection of the number of screw holes pre-drilled on the board frame based on product requirements and future plans. When the board needs to be reused on other machines, only the machine frame needs to be adapted.
[0068] The method for determining the slot number of a single board according to embodiments of the present invention is applied to a single board. The method includes: when the screw posts of the whole machine are connected to the screw holes on the single board through a connector, determining the position information of the connector on the single board; determining the high and low level signals of at least one interface on the single board according to the position information; wherein the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence; and determining the slot number of the single board based on the high and low level signals of the at least one interface. Through the technical solution provided by the embodiments of the present invention, the configuration of the single board slot number can be completed without occupying connector pins, making connector selection more flexible when connecting the single board to the whole machine.
[0069] In some embodiments, after determining the slot number of the single board, the method further includes: obtaining a pre-defined mapping relationship between slot numbers and single board slots; and determining the target single board slot in the entire machine based on the slot number of the single board and the mapping relationship. Specifically, obtaining the mapping relationship between slot numbers and single board slots, wherein the slot number and single board slot have a one-to-one correspondence. Based on the determined slot number of the single board and the mapping relationship between slot numbers and single board slots, the target single board slot in the entire machine is determined.
[0070] In some embodiments, after determining the slot number of the single board, the method further includes: sending the slot number to the complete machine, wherein the slot number is used to instruct the complete machine to perform service configuration on the single board. Specifically, the single board sends its determined slot number to the complete machine, enabling the complete machine to perform service configuration on the complete machine based on the slot number of the single board. Different slot numbers indicate different positions of the single board within the complete machine, resulting in different service management configurations for the single board.
[0071] Example 3
[0072] Figure 5 This is a schematic diagram of a device for determining the slot number of a single-board unit according to Embodiment 3 of the present invention. Figure 5 As shown, this device is applied to the entire machine, wherein the screw posts of the entire machine are respectively connected to the screw holes of at least two single boards via connectors. The device includes:
[0073] The first screw hole determination module 510 is used to determine, for each of the at least two single boards, a first screw hole for fixing the connector from the screw holes on the current single board; wherein the position of the first screw hole is different for each single board.
[0074] The interface level signal determination module 520 is used to determine the high and low level signals of the interfaces that are electrically connected to each screw hole on the at least two single boards respectively; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board.
[0075] The single-board slot number determination module 530 is used to determine the slot number of each single board based on the high and low level signals of each interface on the current single board.
[0076] The single-board slot number determination device provided in the embodiments of the present invention can execute the single-board slot number determination method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0077] Example 4
[0078] Figure 6 This is a schematic diagram of a device for determining the slot number of a single-board unit according to Embodiment 4 of the present invention. Figure 6 As shown, this device is applied to a single board and includes:
[0079] The position information determination module 610 is used to determine the position information of the connector on the single board when the screw post of the whole machine is connected to the screw hole on the single board through the connector.
[0080] The level signal determination module 620 is used to determine the high and low level signals of at least one interface on the single board based on the position information.
[0081] The slot number determination module 630 is used to determine the slot number of the single board based on the high and low level signals of the at least one interface.
[0082] Optionally, the level signal determination module includes:
[0083] The first screw hole determining unit is used to determine the first screw hole on which the connector is fixed from the screw holes on the single board according to the position information.
[0084] The level signal determination unit is used to determine that the high and low level signals of the interface electrically connected to the first screw hole are low level, and the high level signal of the interface electrically connected to the second screw hole is high level; wherein, the second screw hole is a screw hole on the single board other than the first screw hole.
[0085] Optionally, the single board is provided with N screw holes, and the single board slot of the whole machine is provided with M screw posts; wherein, when the single board is connected to the whole machine, the M third screw holes of the N screw holes are assembled together with the M screw posts; M≤N;
[0086] The first screw hole determining unit is used for:
[0087] When P target screw holes among the M third screw holes are respectively connected to P target screw posts among the M screw posts through connectors, the P target screw holes are determined as the first screw holes with the connectors fixed on them.
[0088] Optionally, the device further includes:
[0089] The mapping relationship determination module is used to obtain a pre-set mapping relationship between the slot number and the slot of the single board after determining the slot number of the single board;
[0090] The target board slot determination module is used to determine the target board slot in the whole machine based on the slot number of the board and the mapping relationship.
[0091] Optionally, the level signal determination module is used for:
[0092] Obtain a pre-defined interface order; wherein the interface order is the order used to generate the board slot number;
[0093] According to the interface sequence, the slot number of the single board is determined based on the high and low level signals of at least one interface.
[0094] The single-board slot number determination device provided in the embodiments of the present invention can execute the single-board slot number determination method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0095] Example 5
[0096] Figure 7A schematic diagram of a single-board 10, which can be used to implement embodiments of the present invention, is shown. The single-board is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The single-board can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.
[0097] like Figure 7 As shown, the single-board 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 and a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 can also store various programs and data required for the operation of the single-board 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0098] Multiple components in board 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of monitors, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows board 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0099] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as the method for determining the board slot number.
[0100] In some embodiments, the method for determining the board slot number may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on board 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the method for determining the board slot number described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the method for determining the board slot number by any other suitable means (e.g., by means of firmware).
[0101] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0102] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0103] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.
[0104] To provide user interaction, the systems and technologies described herein can be implemented on a single board having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the board. Other types of devices can also be used to provide user interaction; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or haptic feedback); and input from the user can be received in any form (including sound input, voice input, or haptic input).
[0105] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
[0106] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.
[0107] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.
[0108] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A method for determining the slot number of a single-board unit, characterized in that, Applied to a complete machine, wherein the screw posts of the complete machine are respectively connected to the screw holes of at least two single boards via connectors, the method comprising: For each of the at least two single boards, a first screw hole for fixing the connector is determined from the screw holes on the current single board; wherein the position of the first screw hole is different for each single board. Determine the high and low level signals of the interfaces on the at least two single boards that are electrically connected to each screw hole in a one-to-one correspondence; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board. For each board, the slot number of the current board is determined based on the high and low level signals of each interface on the current board.
2. A method for determining the slot number of a single-board unit, characterized in that, Applied to a single board, the method includes: When the screw posts of the whole machine are connected to the screw holes on the single board through the connector, the position information of the connector on the single board is determined; wherein, the position of the screw hole connecting the connector to each single board is different; The high and low level signals of at least one interface on the single board are determined based on the location information; wherein, the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence. The slot number of the single board is determined based on the high and low level signals of at least one interface.
3. The method according to claim 2, characterized in that, Determining the high / low level signal of at least one interface on the single board based on the location information includes: Based on the location information, the first screw hole where the connector is fixed is determined from the screw holes on the single board; The high-level signal of the interface electrically connected to the first screw hole is determined to be low, and the high-level signal of the interface electrically connected to the second screw hole is determined to be high; wherein, the second screw hole is a screw hole on the single board other than the first screw hole.
4. The method according to claim 3, characterized in that, The single board has N screw holes, and the single board slot of the whole machine has M screw posts; wherein, when the single board is connected to the whole machine, the M third screw holes of the N screw holes are assembled with the M screw posts; M≤N; Based on the location information, the first screw hole for fixing the connector is determined from the screw holes on the single board, including: When P target screw holes among the M third screw holes are respectively connected to P target screw posts among the M screw posts through connectors, the P target screw holes are determined as the first screw holes with the connectors fixed thereon; wherein, P is less than M.
5. The method according to claim 2, characterized in that, After determining the slot number of the single board, the process also includes: Obtain the pre-defined mapping relationship between slot number and single board slot; Based on the slot number of the single board and the mapping relationship, the target single board slot in the whole machine is determined.
6. The method according to claim 2, characterized in that, Determining the slot number of the single board based on the high and low level signals of at least one interface includes: Obtain a pre-defined interface order; wherein the interface order is the order used to generate the board slot number; According to the interface sequence, the slot number of the single board is determined based on the high and low level signals of at least one interface.
7. A device for determining the slot number of a single-board unit, characterized in that, Applied to a complete machine, wherein the screw posts of the complete machine are respectively connected to the screw holes of at least two single boards via connectors, the device includes: The first screw hole determination module is used to determine, for each of the at least two single boards, the first screw hole on which the connector is fixed from the screw holes on the current single board; wherein the position of the first screw hole on each single board is different. An interface level signal determination module is used to determine the high and low level signals of the interfaces that are electrically connected to each screw hole on the at least two single boards respectively; wherein, the high and low level signals of the first interface and the second interface are different, the first interface is the interface electrically connected to the first screw hole, and the second interface is the interface electrically connected to the second screw hole, and the second screw hole is the screw hole other than the first screw hole among the screw holes on the single board. The single-board slot number determination module is used to determine the slot number of each single board based on the high and low level signals of each interface on the current single board.
8. A device for determining the slot number of a single-board unit, characterized in that, Applied to a single board, the device includes: The position information determination module is used to determine the position information of the connector on the single board when the screw posts of the whole machine are connected to the screw holes on the single board through the connector; wherein the position of the connector connected to the screw holes of each single board is different; A level signal determination module is used to determine the high and low level signals of at least one interface on the single board based on the position information; wherein the screw holes on the single board are electrically connected to the at least one interface in a one-to-one correspondence. The slot number determination module is used to determine the slot number of the single board based on the high and low level signals of the at least one interface.
9. A single-board unit, characterized in that, The single board includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the method for determining the single-board slot number according to any one of claims 2-6.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the method for determining the slot number of a single board as described in any one of claims 1 to 2-6.