CN115993995A - Single board computer starting method, single board computer and storage medium - Google Patents

Single board computer starting method, single board computer and storage medium Download PDF

Info

Publication number
CN115993995A
CN115993995A CN202111223200.XA CN202111223200A CN115993995A CN 115993995 A CN115993995 A CN 115993995A CN 202111223200 A CN202111223200 A CN 202111223200A CN 115993995 A CN115993995 A CN 115993995A
Authority
CN
China
Prior art keywords
file
single board
driving
board computer
version
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.)
Pending
Application number
CN202111223200.XA
Other languages
Chinese (zh)
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.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Priority to CN202111223200.XA priority Critical patent/CN115993995A/en
Publication of CN115993995A publication Critical patent/CN115993995A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention relates to the field of equipment installation, in particular to a single board machine starting method, a single board machine and a storage medium, wherein the single board machine starting method comprises the following steps: when a starting instruction is detected, a first driving file stored in a local disk of the single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer; comparing the version numbers of the first driving file and the second driving file, and determining the first driving file/the second driving file with higher version numbers as a target driving file; and starting the single board computer according to the target driving file. According to the technical scheme, the first driving file in the local disk is compared with the second driving file in the driving version package, the single board computer is started by using the driving file with the higher version number, and the single board computer is started by using the first driving file with the base station site under the condition that the version upgrading of the second driving file is not supported, so that the compatibility of the single board computer is improved.

Description

Single board computer starting method, single board computer and storage medium
Technical Field
The present invention relates to the field of equipment installation, and in particular, to a single board computer starting method, a single board computer, and a storage medium.
Background
When a single board computer is installed on each base station site, the single board computer needs to be started according to a driving file in the base station site. However, in practical applications, the single board machine needs to be replaced before being sent out to each base station site due to supply chain, business, and other reasons. For example, the clock phase-locked loop, the power chip, the switching chip and other devices in the single board computer are replaced. When the single board computer with the replaced device is installed on a base station site, if the driving file in the base station site is not updated in time, the single board computer can not be started normally by using the old driving file after the device is replaced, and the compatibility of the single board computer is reduced.
In the prior art, a drive file in a base station site generally needs to be updated in a mode of releasing a new version; however, the following problems exist with the approach of releasing the new version: (1) Most base station sites do not allow version upgrades to drive files; (2) It cannot be guaranteed that all base station sites complete version upgrades of the drive file. Therefore, the mode of releasing the new version can not completely solve the compatibility problem of the single board computer.
Therefore, how to improve the compatibility of the single board computer is a problem to be solved.
Disclosure of Invention
The invention provides a single-board machine starting method, a single-board machine and a storage medium.
In a first aspect, the present invention provides a method for starting a single board machine, the method comprising: when a starting instruction is detected, a first driving file stored in a local disk of a single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer; comparing the version numbers of the first driving file and the second driving file, and determining the first driving file/the second driving file with higher version numbers as a target driving file; and starting the single board computer according to the target driving file.
In a second aspect, the present invention also provides a single board computer including a processor and a memory; the memory is used for storing programs; and the processor is used for calling the program in the memory so as to realize the starting method of the single board computer.
In a third aspect, the present invention also provides a storage medium for readable storage, the storage medium storing one or more programs executable by one or more processors to implement a single board computer start-up method as described above.
The invention discloses a single-board machine starting method, a single-board machine and a storage medium, wherein when a starting instruction is detected, a first driving file stored in a local disk of the single-board machine and a second driving file corresponding to the single-board machine are obtained based on a driving version package of a base station site corresponding to the single-board machine, and then the single-board machine can be started by using a driving file with a higher version number in the first driving file and the second driving file, so that the single-board machine can be ensured to be started normally; by comparing the version numbers of the first driving file and the second driving file, the first driving file/the second driving file with higher version numbers are determined to be the target driving file, and then the single board machine can be started according to the target driving file, so that the single board machine is started by using the first driving file with the base station site under the condition that the base station site does not support version upgrading of the second driving file, and the compatibility of the single board machine is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention as claimed.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a single board machine start provided by an embodiment of the present invention;
fig. 2 is a schematic structural view of a single board machine according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of a single board machine starting method provided by an embodiment of the invention;
fig. 4 is a schematic diagram of generating a first driving file according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The flow diagrams depicted in the figures are merely illustrative and not necessarily all of the elements and operations/steps are included or performed in the order described. For example, some operations/steps may be further divided, combined, or partially combined, so that the order of actual execution may be changed according to actual situations.
It is to be understood that the terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should also be understood that the term "and/or" as used in the present specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
In the following description, suffixes such as "module", "part" or "unit" for representing elements are used only for facilitating the description of the present invention, and have no particular meaning in themselves. Thus, "module," "component," or "unit" may be used in combination.
The embodiment of the invention provides a single board machine starting method, a single board machine and a storage medium. The method for starting the single board machine can be applied to the single board machine, the single board machine is started by using the drive file with the higher version number by comparing the first drive file in the local disk with the second drive file in the drive version package, and the single board machine is started by using the first drive file with the own base station site under the condition that the base station site does not support version upgrading of the second drive file, so that the compatibility of the single board machine is improved.
It should be noted that a single board computer is a device for assembling various parts of a computer on a printed circuit, and may include, but is not limited to, a CPU, a magnetic disk, a network card, a memory, and other devices such as a matched chip; and, the single board computer runs the Linux operating system. Base station sites refer to sites of a communication base station and may include 4G sites, 5G sites, and the like. In the embodiment of the invention, the user can insert different types of single boards on the base station site in a plug and play mode. When the single board computer is inserted into the base station site, the single board computer can be started according to a driving file in the base station site or a driving file carried by the single board computer. In the prior art, the driver is generally installed in a windows system, and the driver can be automatically downloaded from outside or in a networking manner; in the embodiment of the invention, because the single board computer runs a Linux operating system, the Linux operating system does not allow the drive files to be downloaded from outside or in a networking manner at will, and therefore, the drive files in the base station site or the drive files carried by the single board computer can only be started.
Referring to fig. 1, fig. 1 is a flowchart of a single board start provided in an embodiment of the invention. As shown in fig. 1, when the single board computer is started, it is determined whether the local disk of the single board computer stores the first drive file. If the local disk does not store the first drive file, determining a second drive file in the drive version package as a target drive file; if the local disk stores the first driving file, the first driving file is loaded from the local disk, whether the version number of the first driving file is larger than that of a second driving file is judged, and the second driving file is obtained based on a driving version package of a base station site corresponding to the single board computer. If the version number of the first driving file is larger than that of the second driving file, the first driving file is used as a target driving file; and if the version number of the first driving file is not greater than that of the second driving file, taking the second driving file as a target driving file. And running the target drive file.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a single board computer according to an embodiment of the present invention. The single board computer 100 may include a processor 101 and a memory 102, wherein the processor 101 and the memory 102 may be connected by a bus, such as any suitable bus, e.g., an I2C (Inter-integrated Circuit) bus.
The memory 102 may include a non-volatile storage medium and an internal memory, among others. The non-volatile storage medium may store an operating system and a computer program. The computer program comprises program instructions that, when executed, cause the processor 101 to perform any one of the single board computer start-up methods.
Wherein the processor 101 is configured to provide computing and control capabilities to support the operation of the entire single board machine 100.
The processor 101 may be a central processing unit (Central Processing Unit, CPU), which may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (application specific integrated circuit, ASIC), field-programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
In an embodiment, the processor 101 is configured to run a computer program stored in the memory 102 and to implement the following steps when executing the computer program:
when a starting instruction is detected, a first driving file stored in a local disk of a single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer; comparing the version numbers of the first driving file and the second driving file, and determining the first driving file/the second driving file with higher version numbers as a target driving file; and starting the single board computer according to the target driving file.
In one embodiment, the processor 101 is configured to implement:
and if the first driving file is not stored in the local disk, starting the single board computer according to the second driving file.
In one embodiment, the driving version package includes at least one driving file and a single board computer identification number corresponding to each driving file; when the processor 101 obtains the second driving file corresponding to the single board machine based on the driving version package of the base station site corresponding to the single board machine, the processor is configured to implement:
inquiring the driving version package to obtain a driving file corresponding to the single board machine identification number of the single board machine, and determining the inquired driving file as the second driving file.
In one embodiment, the first drive file includes first version header information and the second drive file includes second version header information; when implementing the comparison of the version numbers of the first drive file and the second drive file and determining the first drive file/the second drive file with higher version numbers as the target drive file, the processor 101 is configured to implement:
extracting a first version number in the first version header information and extracting a second version number in the second version header information; if the first version number is greater than the second version number, determining the first drive file as the target drive file; and if the first version number is smaller than or equal to the second version number, determining the second drive file as the target drive file.
In one embodiment, the processor 101 is further configured, before implementing the obtaining the first drive file stored in the local disk of the single-board computer, to implement:
determining a target device installed by the single board computer, and generating the first driving file based on the target device; and burning the first driving file to the local disk.
In one embodiment, when implementing the generation of the first driving file based on the target device, the processor 101 is configured to implement:
determining a target driver corresponding to the device information of the target device according to the corresponding relation between the preset device information and the driver and the device information of the target device; compiling the target driver to obtain a dynamic library file corresponding to the target device, and determining the dynamic library file as the first driver file.
In one embodiment, the processor 101 is further configured to, prior to implementing the starting of the single board computer according to the target drive file, implement:
if the device in the single board computer comprises a field programmable gate array chip, acquiring a first firmware file stored in the local disk and acquiring a second firmware file corresponding to the field programmable gate array chip from the base station site; and comparing the version numbers of the first firmware file and the second firmware file, and determining the first firmware file/the second firmware file with higher version numbers as a target firmware file.
In one embodiment, the processor 101 is configured to, when implementing starting the single board machine according to the target drive file, implement:
and operating the target driving file and the target firmware file to start the single board computer.
In one embodiment, before implementing the obtaining the first firmware file stored in the local disk, the processor 101 is further configured to implement:
and acquiring a first firmware file corresponding to the field programmable gate array chip, and burning the first firmware file to the local disk.
Some embodiments of the present invention are described in detail below with reference to the accompanying drawings. The following embodiments and features of the embodiments may be combined with each other without conflict.
As shown in fig. 3, fig. 3 is a schematic flow chart of a single board machine starting method according to an embodiment of the present invention. The single-board computer starting method is applied to the single-board computer, the single-board computer is started by comparing the first driving file in the local disk with the second driving file in the driving version package and using the driving file with higher version number, so that the single-board computer is started by using the first driving file with the base station site under the condition that the base station site does not support version upgrading of the second driving file, and the compatibility of the single-board computer is improved. The single board computer starting method comprises steps S10 to S30.
And step S10, when a starting instruction is detected, acquiring a first driving file stored in a local disk of the single board computer, and acquiring a second driving file corresponding to the single board computer based on a driving version package of a base station site corresponding to the single board computer.
It should be noted that, in the embodiment of the present invention, the first driver file includes a driver corresponding to a target device currently installed by the single board computer. The target device is a device which needs a driving program to drive in the single board computer; the first driving file is generated by the single board computer according to a driving program corresponding to the target device before the single board computer is sent to the base station site. The second driving file is a driving file pre-stored in a base station site and comprises a driving program corresponding to a target device in the single board computer; for example, a driver corresponding to a target device in a single board machine that does not replace the device may be included.
By way of example, the target device may include, but is not limited to, a CPU, disk, network card, memory, and other companion chip in a single board computer. The local disk refers to a storage device in a single board computer.
In some scenarios, if a target device on a single board machine is replaced, a first drive file is generated according to a driver of the replaced target device. At this time, the first drive file is suitable for the single board computer after the device replacement. The second driving file is generated according to the driving program corresponding to each device in the single board computer without replacing the device, and the second driving file is not suitable for the single board computer after replacing the device. It can be understood that after the single board machine is produced, the second driving file corresponding to the single board machine is issued to the driving version package of the base station site for storage; when the single board computer is sent to the base station site for use, the target device on the single board can be replaced according to actual requirements; and then, generating a first driving file corresponding to the single board computer after device replacement. Therefore, the second drive file is not suitable for the single board computer after the device replacement before the version upgrade is performed.
In the prior art, the single board machine is usually started directly by using a second driving file in the base station site; if the version upgrade of the second driving file is unsuccessful, the single board computer after the device replacement cannot be started normally according to the second driving file, so that the situation of error repair can be generated. In the embodiment of the invention, when the version number of the second driving file is lower than that of the first driving file, the single board machine is started according to the first driving file of the single board machine, so that the compatibility of the single board machine can be improved.
In some embodiments, the single board computer may acquire a first drive file stored in a local disk of the single board computer when detecting a start command sent by the base station site, and acquire a second drive file corresponding to the single board computer based on a drive version package of the base station site corresponding to the single board computer.
It should be noted that, when the single board computer is inserted into the card slot of the base station site, the base station site may power up the single board computer to start the single board computer.
For example, the driver version package may include driver files corresponding to different types of single boards. The single board computer corresponding to the driving file can be determined through the single board computer identification number of the driving file.
In other embodiments, after the single board machine is powered on, a start command is generated, a first drive file stored in a local disk of the single board machine is obtained according to the start command, and a second drive file corresponding to the single board machine is obtained based on a drive version package of a base station site corresponding to the single board machine. It should be noted that, when the single board computer is powered on, the built-in Linux operating system can be loaded and started, and in the process of starting the Linux operating system, the driving file is loaded and operated to drive the target device in the single board computer. It can be understood that the Linux operating system is successfully started, namely the single board computer is successfully started, and the target device in the single board computer can work normally.
When a starting instruction is detected, a first driving file stored in a local disk of the single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer, and then the single board computer can be started by using the driving files with higher version numbers in the first driving file and the second driving file, so that the single board computer can be ensured to be started normally.
In some embodiments, if the first drive file is not stored in the local disk, the single board computer is started according to the second drive file.
It should be noted that, since the first drive file is burned into the local disk of the single-board computer in advance, when the number of single-board computers is large, the case of burning omission is easy to occur, and therefore, the local disk of the single-board computer may possibly occur that the first drive file is not stored.
For example, when the first drive file is not stored in the local disk, the single board computer may be started according to the second drive file. For example, the second drive file is run to complete the start of the single board machine. The specific process of running the second driving file is not limited herein.
In the embodiment of the invention, the single board computer can acquire the second driving file corresponding to the single board computer based on the driving version package of the base station site corresponding to the single board computer. The drive version package comprises at least one drive file and a single board computer identification number corresponding to each drive file. For example, the single board computer identification code may be one or more of a single board computer number, name, identification code, etc. for identifying the uniqueness of the single board computer.
In some embodiments, obtaining the second driving file corresponding to the single board machine based on the driving version package of the base station site corresponding to the single board machine may include: inquiring the driving version package to obtain a driving file corresponding to the single board machine identification number of the single board machine, and determining the inquired driving file as a second driving file.
For example, the driving version package may be queried according to the single board machine identification number of the single board machine, and the driving file matched with the single board machine identification number of the single board machine may be determined as the second driving file.
In some embodiments, before acquiring the first drive file stored in the local disk of the single-board computer, the method may further include: determining a target device installed by a single board computer, and generating a first driving file based on the target device; and burning the first driving file to a local disk.
It should be noted that, in the embodiment of the present invention, before the single board computer is sent out to the base station site, a first driving file corresponding to the single board computer needs to be generated. If the device replacement is performed on the single board computer, the target device comprises the device in the single board computer after the device replacement.
In some embodiments, generating the first drive file based on the target device may include: determining a target driver corresponding to the device information of the target device according to the corresponding relation between the preset device information and the driver and the device information of the target device; compiling the target driver program to obtain a dynamic library file corresponding to the target device, and determining the dynamic library file as a first driver file.
For example, the device information may include information for identifying the device uniqueness, such as a type, name, identification code, etc. corresponding to the device. In the embodiment of the invention, the device information of the device and the driver matched with the device can be stored in a correlated way in advance. Wherein the device-matched driver can drive the device normally. For example, the type of device a is stored in association with the matched driver.
For example, when the first driving file is generated, if the target device includes a device a, a device B, and a device C, the target drivers corresponding to the device a, the device B, and the device C may be determined according to the device information corresponding to the device a, the device B, and the device C, respectively; and compiling all target drivers of the target device to obtain a dynamic library file corresponding to the target device, and determining the dynamic library file as a first driving file. The specific compiling process is not limited herein.
It should be noted that the dynamic library file is a file in a dynamic link library in the Linux system, and the suffix of the dynamic library file is. A dynamic library file is a special object file (object file) that can be loaded in when the program is running. The dynamic library file has the advantages of smaller executable file, convenient modularization of the program and convenient updating; meanwhile, the use efficiency of the effective memory is higher. In the embodiment of the invention, the drive program is compiled into the dynamic library file, so that the storage space is saved, and the reading speed can be improved.
The first drive file may be, for example, a libbsp.so file. The second drive file may be a libbsp.so file. For example, a driver corresponding to a device in the single board computer may be compiled to obtain a dynamic library file, and the obtained dynamic library file is determined to be a second driver file; then, the second driver file is published to the driver version package of the base station site. It should be noted that, when the single board computer does not perform device replacement, the version number of the first driving file is the same as the version number of the second driving file; after the device replacement is carried out by the single board computer, if the version upgrade is not carried out on the second driving file in time, the version number of the first driving file is larger than that of the second driving file.
By determining the target device installed by the single board computer and generating the first driving file based on the target device, the first driving file can be ensured to be suitable for the single board computer after device replacement, and the compatibility of the single board computer is improved.
Referring to fig. 4, fig. 4 is a schematic diagram illustrating generation of a first driving file according to an embodiment of the invention. As shown in fig. 4, after compiling according to the target driver corresponding to the target device, the first driving file may be burned into the local disk after the first driving file is generated. For example, the first driving file is burned to the local disk of the single board computer through burning software or burning equipment. The specific burning method and operation are not limited herein.
By burning the first driving file to the local disk, when the single board computer is started, the first driving file with the first driving file is preferentially adopted for starting, so that the starting efficiency of the single board computer is improved, and the situation that the single board computer cannot be started normally due to the second driving file in the base station site can be avoided.
And step S20, comparing the version numbers of the first drive file and the second drive file, and determining the first drive file/the second drive file with higher version numbers as a target drive file.
For example, the first drive file may include first version header information and the second drive file may include second version header information. It should be noted that, in the embodiment of the present invention, each driving file has a version header; the version header may include information such as cpu_ TYPE, SWID, BOARD _type and ver_no. Wherein, CPU_TYPE represents the TYPE of the main CPU of the single board machine; SWID is a single board computer identification number; BOARD_TYPE indicates the TYPE of the drive file supporting single BOARD machine; ver_no represents the version number of the drive file.
In some embodiments, comparing the version numbers of the first drive file and the second drive file, and determining the first drive file/the second drive file with the higher version number as the target drive file may include: extracting a first version number in the first version header information and extracting a second version number in the second version header information; if the first version number is greater than the second version number, determining the first driving file as a target driving file; and if the first version number is smaller than or equal to the second version number, determining the second drive file as the target drive file. And if the second version number is greater than the first version number, indicating that the second drive file is the drive file after version upgrading.
Illustratively, a first version number in the first version header information is extracted, for example, the obtained first version number is a; and extracting a second version number in the second version header information, for example, the obtained second version number is b. If the first version number a is greater than the second version number b, the first drive file may be determined to be the target drive file; and if the first version number a is smaller than or equal to the second version number b, determining the second drive file as the target drive file. Wherein the first drive file may also be determined to be the target drive file when the first version number a is equal to the second version number b.
By comparing the version numbers of the first driving file and the second driving file, the first driving file/the second driving file with higher version numbers are determined to be the target driving file, and then the single board machine can be started according to the target driving file, so that the single board machine is started by using the first driving file with the base station site under the condition that the base station site does not support version upgrading of the second driving file, and the compatibility of the single board machine is improved.
And step S30, starting the single board computer according to the target driving file.
For example, when the single board computer is started according to the target drive file, the target drive file may be directly run to start the single board computer. For example, the single board computer can load and execute the target drive file when the Linux system is started.
In some embodiments, before starting the single board machine according to the target drive file, the method may further include: if the device in the single board computer comprises a field programmable gate array chip, acquiring a first firmware file stored in a local disk and acquiring a second firmware file corresponding to the field programmable gate array chip from a base station site; and comparing the version numbers of the first firmware file and the second firmware file, and determining the first firmware file/the second firmware file with higher version numbers as a target firmware file.
It should be noted that, a Field programmable gate array (Field-Programmable Gate Array, FPGA) is a program-driven logic device, whose control program is stored in a memory; after the FPGA chip is powered up, the control program is automatically loaded and executed. In the embodiment of the invention, when the FPGA chip in the single board computer runs, the corresponding driving program is needed to support, and the matched firmware file is also used. The firmware file may include information such as control program and logic data required by the FPGA chip during operation.
For example, when a start instruction is detected, determining whether a target device in the single board computer comprises an FPGA chip or not; if the target device in the single board computer comprises an FPGA chip, a first driving file and a first firmware file stored in a local disk of the single board computer can be obtained. The first drive file and the first firmware file may be stored in different locations of the local disk. And then, acquiring a second firmware file corresponding to the FPGA chip from the base station site. The second firmware file corresponding to the identification code of the FPGA chip can be obtained from the base station site according to the identification code of the FPGA chip.
For example, if the version number of the first firmware file is greater than the version number of the second firmware file, determining the first firmware file as the target firmware file; and if the version number of the first firmware file is smaller than or equal to that of the second firmware file, determining the second firmware file as the target firmware file.
In some embodiments, before obtaining the first firmware file of the local disk storage, the method may further include: and acquiring a first firmware file corresponding to the field programmable gate array chip, and burning the first firmware file to a local disk.
When the target device in the single board computer includes an FPGA chip, a first firmware file corresponding to the FPGA chip needs to be obtained in a writing stage, and the first firmware file is written to a local disk. For example, when the first drive file is burned to the local disk, the first firmware file is also burned to the local disk.
By burning the first firmware file corresponding to the obtained field programmable gate array chip to the local disk, the problem that the single board computer cannot be started normally due to the fact that the firmware file of the FPGA chip is missing in the follow-up process can be avoided.
In some embodiments, starting the single board machine according to the target drive file may include: and running the target driving file and the target firmware file to start the single board computer.
For example, when the device in the single board computer includes an FPGA chip, the target drive file and the target firmware file need to be run when the single board computer is started according to the target drive file.
When the device in the single board computer comprises an FPGA chip, the target driving file and the target firmware file are operated to start the single board computer, so that the normal starting of the single board computer can be ensured.
According to the single-board machine starting method, the single-board machine and the storage medium, when the starting instruction is detected, the first driving file stored in the local disk of the single-board machine and the second driving file corresponding to the single-board machine are obtained based on the driving version package of the base station site corresponding to the single-board machine, and then the single-board machine can be started by using the driving file with the higher version number in the first driving file and the second driving file, so that the single-board machine can be ensured to be started normally; by determining the target device installed by the single board computer and generating a first driving file based on the target device, the first driving file can be ensured to be suitable for the single board computer after device replacement, and the compatibility of the single board computer is improved; by burning the first driving file to the local disk, when the single board computer is started, the single board computer can be started by preferentially adopting the first driving file, so that the starting efficiency of the single board computer is improved, and the situation that the single board computer cannot be started normally due to the use of the second driving file in the base station site can be avoided; the version numbers of the first driving file and the second driving file are compared, the first driving file/the second driving file with higher version numbers are determined to be the target driving file, and then the single board machine can be started according to the target driving file, so that the single board machine is started by using the first driving file with the base station site under the condition that the version upgrading of the second driving file is not supported, and the compatibility of the single board machine is improved; by burning the first firmware file corresponding to the obtained field programmable gate array chip to the local disk, the problem that the single board computer cannot be started normally due to the fact that the firmware file of the FPGA chip is missing in the follow-up process can be avoided.
The embodiment of the invention also provides a storage medium which is used for readable storage, the storage medium stores a program, the program comprises program instructions, and the processor executes the program instructions to realize any one of the single board computer starting methods provided by the embodiment of the invention.
For example, the program is loaded by a processor, and the following steps may be performed:
when a starting instruction is detected, a first driving file stored in a local disk of a single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer; comparing the version numbers of the first driving file and the second driving file, and determining the first driving file/the second driving file with higher version numbers as a target driving file; and starting the single board computer according to the target driving file.
The storage medium may be an internal storage unit of the single board machine according to the foregoing embodiment, for example, a hard disk or a memory of the single board machine. The storage medium may also be an external storage device of the single board machine, such as a plug-in hard disk provided on the single board machine, a Smart Media Card (SMC), a secure digital Card (Secure Digital Card, SD Card), a Flash memory Card (Flash Card), or the like.
Those of ordinary skill in the art will appreciate that all or some of the steps of the methods, systems, functional modules/units in the devices disclosed above may be implemented as software, firmware, hardware, and suitable combinations thereof.
In a hardware implementation, the division between the functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed cooperatively by several physical components. Some or all of the physical components may be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on a storable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or transitory medium). The term storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data, as known to those skilled in the art. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital Versatile Disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by a computer. Furthermore, as is well known to those of ordinary skill in the art, communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media.
The preferred embodiments of the present invention have been described above with reference to the accompanying drawings, and thus do not limit the scope of the claims of the present invention. Any modifications, equivalent substitutions and improvements made by those skilled in the art without departing from the scope and spirit of the present invention shall fall within the scope of the appended claims.

Claims (10)

1. A single board computer start-up method applied to a single board computer, the method comprising:
when a starting instruction is detected, a first driving file stored in a local disk of a single board computer is obtained, and a second driving file corresponding to the single board computer is obtained based on a driving version package of a base station site corresponding to the single board computer;
comparing the version numbers of the first driving file and the second driving file, and determining the first driving file/the second driving file with higher version numbers as a target driving file;
and starting the single board computer according to the target driving file.
2. The single board computer start-up method of claim 1, wherein the method further comprises:
and if the first driving file is not stored in the local disk, starting the single board computer according to the second driving file.
3. The method for starting a single board computer according to claim 1, wherein the drive version package comprises at least one drive file and a single board computer identification number corresponding to each drive file; the obtaining, based on the driving version package of the base station site corresponding to the single board machine, the second driving file corresponding to the single board machine includes:
inquiring the driving version package to obtain a driving file corresponding to the single board machine identification number of the single board machine, and determining the inquired driving file as the second driving file.
4. The single board computer start-up method of claim 1, wherein the first drive file includes first version header information and the second drive file includes second version header information; the comparing the version numbers of the first driving file and the second driving file, determining the first driving file/the second driving file with higher version numbers as a target driving file, includes:
extracting a first version number in the first version header information and extracting a second version number in the second version header information;
if the first version number is greater than the second version number, determining the first drive file as the target drive file;
and if the first version number is smaller than or equal to the second version number, determining the second drive file as the target drive file.
5. The method for starting up a single board machine according to claim 1, wherein before the first drive file stored in the local disk of the single board machine is acquired, the method comprises:
determining a current target device of the single board computer, and generating the first driving file based on the target device;
and burning the first driving file to the local disk.
6. The method of starting up a single board machine according to claim 5, wherein said generating said first drive file based on said target device comprises:
determining a target driver corresponding to the device information of the target device according to the corresponding relation between the preset device information and the driver and the device information of the target device;
compiling the target driver to obtain a dynamic library file corresponding to the target device, and determining the dynamic library file as the first driver file.
7. The method of starting a single board machine according to any one of claims 1-6, wherein before starting the single board machine according to the target drive file, the method further comprises:
if the device in the single board computer comprises a field programmable gate array chip, acquiring a first firmware file stored in the local disk and acquiring a second firmware file corresponding to the field programmable gate array chip from the base station site;
comparing the version numbers of the first firmware file and the second firmware file, and determining the first firmware file/the second firmware file with higher version numbers as a target firmware file;
the starting of the single board machine according to the target driving file comprises the following steps:
and operating the target driving file and the target firmware file to start the single board computer.
8. The method for starting up a single board computer according to claim 7, wherein before the obtaining the first firmware file stored in the local disk, further comprises:
and acquiring a first firmware file corresponding to the field programmable gate array chip, and burning the first firmware file to the local disk.
9. A single board computer, which is characterized by comprising a processor and a memory;
the memory is used for storing programs;
the processor is configured to execute the program and implement the single board computer start-up method according to any one of claims 1 to 8 when the program is executed.
10. A storage medium for readable storage, wherein the storage medium stores one or more programs executable by one or more processors to implement the single board computer start-up method of any of claims 1 to 8.
CN202111223200.XA 2021-10-20 2021-10-20 Single board computer starting method, single board computer and storage medium Pending CN115993995A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111223200.XA CN115993995A (en) 2021-10-20 2021-10-20 Single board computer starting method, single board computer and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111223200.XA CN115993995A (en) 2021-10-20 2021-10-20 Single board computer starting method, single board computer and storage medium

Publications (1)

Publication Number Publication Date
CN115993995A true CN115993995A (en) 2023-04-21

Family

ID=85990810

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111223200.XA Pending CN115993995A (en) 2021-10-20 2021-10-20 Single board computer starting method, single board computer and storage medium

Country Status (1)

Country Link
CN (1) CN115993995A (en)

Similar Documents

Publication Publication Date Title
CN102334100A (en) Program update device, program update method, and information processing device
CN102184111B (en) The equipment of operating system online upgrading method and tape operation system
CN102426531A (en) Intelligent terminal and application program updating system and method
CN111240720A (en) Boot program upgrading method and device and storage medium
CN105183525A (en) Upgrading method of system software and electronic equipment for implementing upgrading method
CN110750280B (en) Android platform-based application upgrading method and system and storage medium
CN114860291A (en) Method for guiding and flexibly storing and upgrading application program
CN108170456B (en) Firmware upgrading method and device for electronic equipment
CN115993995A (en) Single board computer starting method, single board computer and storage medium
CN105700900A (en) Method and device for optimizing wireless local area network function
CN110286953A (en) Starting method, apparatus, embedded device and the storage medium of embedded system
KR102094447B1 (en) Apparatus for generating source code of Battery Management System software and method thereof
CN109828752B (en) Project code automatic generation method, device, computer equipment and storage medium
CN104636574A (en) Terminal device upgrade method and terminal device
CN112394965B (en) Battery management system upgrade and operation method, controller, battery management system and storage medium
CN113204359A (en) Online server upgrading method and device
CN112667444A (en) System upgrading method, storage medium and terminal equipment
CN114968277A (en) Method and device for generating master burning program file, computer equipment and medium
CN111880828A (en) Method for upgrading multi-board driver in batch in Secure Boot environment
CN110569068A (en) method and device for loading program by Linux driver
CN113672238B (en) Operation method, device and equipment based on real-time operating system modularized management
CN116661905B (en) Method and system for realizing automatic adaptation of equipment based on dynamic library loading
CN114500532A (en) Application deployment method and system in elastically telescopic cluster service
KR101113342B1 (en) Boot-loader version managing method for mobile communication terminal
CN114647420A (en) File processing method and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication