File creation method and device for torpedo internal measurement data

By adopting a software design method that does not rely on RTC clock chip hardware in torpedoes, obtaining preset timestamp parameters, determining and comparing data file names, and selecting the latest file as the target internal test file, the problem of relying on hardware for the torpedo internal test data file creation is solved, and high reliability and low-cost data management are achieved.

CN119988323APending Publication Date: 2025-05-13CHINA SHIPBUILDING IND CORP NO 705 RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411919856.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-25
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

The torpedo internal test data file creation method relies on the RTC clock chip hardware, which leads to the inability to create the internal test data folder when the RTC chip battery is overdischarged, which has problems of unreliability and high cost.

Method used

The software design method that does not rely on traditional RTC clock chip hardware is adopted. By obtaining preset timestamp parameters, determining the data file name, comparing the file name, and selecting the latest file as the target internal test file to realize the creation of the torpedo internal test data file.

Benefits of technology

The creation of torpedo internal test data files has been realized, which reduces the development and production costs, avoids the risk of functional failure caused by overdischarge of clock chip batteries, and improves the efficiency of data management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119988323A_ABST
    Figure CN119988323A_ABST
Patent Text Reader

Abstract

The invention provides a torpedo internal measurement data file creation method and device. The method comprises the steps of obtaining a preset timestamp parameter; determining a first data file name corresponding to a preset timestamp parameter according to the preset timestamp parameter; comparing the first data file name with the second data file name; according to the method, the file corresponding to the latest data file name in the first data file name and the second data file name is determined as the target internal test file, traditional RTC clock chip hardware is not depended on, new hardware resources are not added, a brand new software design method is adopted, the torpedo internal test data file creation function is achieved, and the efficiency of creating the torpedo internal test data file is improved. Compared with the prior art, the method has the advantages that the development and production cost of the torpedo is reduced, the risk of function failure caused by possible overdischarge of a built-in battery of the clock chip is thoroughly solved, the online cycle recording function of a digital difference naming test data file is realized, data coverage is avoided, and the offline management efficiency of mass actual aviation test data is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of data processing, and in particular relates to a method and a device for creating a file of torpedo internal measurement data. Background Art

[0002] A torpedo is a highly efficient underwater self-propelled guided weapon used to attack submarines, surface ships and other underwater targets. It has the characteristics of good concealment and strong explosive power, and is one of the navy's main attack weapons.

[0003] In tasks such as torpedo scientific research tests, equipment delivery tests, and actual combat training tests for troops, the external test data of the underwater array in the test waters and the internal test data recorded autonomously by the torpedo are collected, which is the main basis for comprehensive evaluation of the completion effect of the test tasks. The internal test data of the torpedo is usually stored in the form of data files on the data storage chip inside the torpedo. In order to facilitate data management, a method of digital difference naming is adopted based on real-time Beijing time (year, month, day, hour, minute, second).

[0004] The method of naming the internal test data file using Beijing time requires the use of hardware resources such as RTC clock chips. These chips have built-in battery chips. Usually, the battery charging and maintenance can be completed during the one-year regular maintenance of the torpedo. However, for products that are stored in inventory for a long time, the RTC chip battery may be over-discharged and cause functional failure, resulting in the risk of being unable to create an internal test data folder. Therefore, it is urgent to design a low-cost, high-reliability data file creation method that does not rely on clock chip hardware resources to realize torpedo internal test data recording. Therefore, how to provide a file creation method for torpedo internal test data has become a technical problem that urgently needs to be solved in this field. Summary of the invention

[0005] The purpose of the present invention is to provide a method and device for creating a file of torpedo internal measurement data.

[0006] According to a first aspect of the present invention, there is provided a method for creating a file of torpedo internal measurement data, comprising:

[0007] Get the preset timestamp parameters;

[0008] According to the preset timestamp parameter, determining a first data file name corresponding to the preset timestamp parameter;

[0009] Compare the first data file name with the second data file name; the second data file name is the file name of the latest time that has been stored;

[0010] The file corresponding to the latest data file name between the first data file name and the second data file name is determined as the target internal test file.

[0011] Optionally, determining the file corresponding to the latest data file name between the first data file name and the second data file name as the target internal test file includes:

[0012] If the time of the first data file name is newer, use the mkdir(recDir) function to create a first torpedo internal test data file, and use the first torpedo internal test data file as the target internal test file;

[0013] If the time of the second data file name is newer, a sexagesimal processing and carry algorithm of the hours, minutes and seconds is adopted to generate a second torpedo internal test data file, and the second torpedo internal test data file is used as the target internal test file.

[0014] Optionally, the preset timestamp parameter is obtained in the following manner:

[0015] In the torpedo firing preparation, the time stamp parameter online binding information command is received through the CAN bus;

[0016] Determining whether the data segment of the online binding information instruction of the timestamp parameter meets the logical requirements of time and date;

[0017] If the timestamp parameter meets the logical requirement of the time, the timestamp parameter is determined as the preset timestamp parameter.

[0018] Optionally, if the timestamp parameter satisfies the logical requirement of the time, determining the timestamp parameter as the preset timestamp parameter includes:

[0019] Performing validity judgment on the data segment of the online binding information instruction of the timestamp parameter;

[0020] If the logical requirements that the month value is not greater than 12 and the date value is not greater than 31 are met, the timestamp parameter in the timestamp parameter online binding information instruction is determined to be a valid parameter, and the timestamp parameter is determined to be the preset timestamp parameter.

[0021] Optionally, the method further comprises:

[0022] After the torpedo launch internal test function is started, the file of the preset timestamp parameters is opened;

[0023] If error is opened, the default parameters are used.

[0024] Optionally, the method further comprises:

[0025] The number of existing data folders on the data storage device is managed, the oldest data folder is deleted, and the current latest data folder name is screened out, and the current latest data file name is determined as the second data file name.

[0026] Optionally, managing the number of data folders already existing in the data storage device and deleting the oldest data folder includes:

[0027] By traversing the digital data file names, the string sizes of the data file names are compared;

[0028] Identify the smallest string as the oldest file, the largest string as the newest file, delete the oldest data file, and store the newest data file name in a variable.

[0029] According to a second aspect of the present invention, there is provided a device for creating a file of torpedo internal measurement data, comprising:

[0030] An acquisition module, used to obtain preset timestamp parameters;

[0031] A determination module, configured to determine, according to the preset timestamp parameter, a name of a first data file corresponding to the preset timestamp parameter;

[0032] A comparison module, used for comparing the first data file name with the second data file name; the second data file name is the file name of the latest time that has been stored;

[0033] A generation module is used to determine the file corresponding to the latest data file name between the first data file name and the second data file name as a target internal test file.

[0034] Optionally, the preset timestamp parameter is obtained in the following manner:

[0035] In the torpedo firing preparation, the time stamp parameter online binding information command is received through the CAN bus;

[0036] Determining whether the data segment of the online binding information instruction of the timestamp parameter meets the logical requirements of time and date;

[0037] If the timestamp parameter meets the logical requirement of the time, the timestamp parameter is determined as the preset timestamp parameter.

[0038] Optionally, if the timestamp parameter satisfies the logical requirement of the time, determining the timestamp parameter as the preset timestamp parameter includes:

[0039] Performing validity judgment on the data segment of the online binding information instruction of the timestamp parameter;

[0040] If the logical requirements that the month value is not greater than 12 and the date value is not greater than 31 are met, the timestamp parameter in the timestamp parameter online binding information instruction is determined to be a valid parameter, and the timestamp parameter is determined to be the preset timestamp parameter.

[0041] Optionally, the generating module is used to:

[0042] After the torpedo launch internal test function is started, the file of the preset timestamp parameters is opened;

[0043] If error is opened, the default parameters are used.

[0044] Optionally, the generating module is used to:

[0045] The number of existing data folders on the data storage device is managed, the oldest data folder is deleted, and the current latest data folder name is screened out, and the current latest data file name is determined as the second data file name.

[0046] Optionally, the generating module is used to:

[0047] By traversing the digital data file names, the string sizes of the data file names are compared;

[0048] Identify the smallest string as the oldest file, the largest string as the newest file, delete the oldest data file, and store the newest data file name in a variable.

[0049] In a third aspect, the present application shows an electronic device, which includes: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute the method described in any of the above aspects.

[0050] In a fourth aspect, the present application illustrates a non-temporary computer-readable storage medium, which, when instructions in the storage medium are executed by a processor of an electronic device, enables the electronic device to execute a method as described in any of the above aspects.

[0051] In a fifth aspect, the present application illustrates a computer program product. When instructions in the computer program product are executed by a processor of an electronic device, the electronic device is enabled to execute the method described in any of the above aspects.

[0052] The beneficial effects brought by the present invention are as follows:

[0053] It can be seen from the above scheme that the embodiment of the present invention provides a file creation method and device for torpedo internal test data, including: obtaining a preset timestamp parameter; determining a first data file name corresponding to the preset timestamp parameter according to the preset timestamp parameter; comparing the first data file name and the second data file name; the second data file name is the file name of the latest time that has been stored; the file corresponding to the data file name with the latest time between the first data file name and the second data file name is determined as the target internal test file, which does not rely on traditional RTC clock chip hardware and does not add new hardware resources. It adopts a brand-new software design method to realize the torpedo internal test data file creation function, reduce the research and production costs of torpedoes, and completely solve the risk of functional failure caused by over-discharge of the built-in battery of the clock chip, and realize the online loop recording function of the digital difference naming test data file, avoid data overwriting, and improve the offline management efficiency of massive actual flight test data. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] Figure 1 A schematic diagram of a flow chart of a method for creating a file of torpedo internal test data according to an embodiment;

[0055] Figure 2 A process for creating a torpedo internal test data file according to an embodiment;

[0056] Figure 3 Creating an example diagram for a file of torpedo internal test data provided according to an embodiment;

[0057] Figure 4 It is a structural block diagram of a file creation device for torpedo internal measurement data of the present application;

[0058] Figure 5 It is a block diagram of an electronic device of the present application.

[0059] Figure 6 It is a block diagram of a computer-readable storage medium of the present application. DETAILED DESCRIPTION

[0060] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution in the embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is a part of the embodiment of the present invention, not all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0061] The present application discloses a method for creating a file of torpedo internal test data, including a timestamp parameter setting instruction, parameter validity judgment, parameter writing file, parameter file reading, data file management, and data file creation technology;

[0062] Reference Figure 1 , shows a flowchart of the steps of a method for creating a file of torpedo internal test data of the present application, which method can be applied to electronic devices, wherein the method specifically may include the following steps:

[0063] S101, obtaining preset timestamp parameters;

[0064] S102, determining a first data file name corresponding to a preset timestamp parameter according to the preset timestamp parameter;

[0065] S103, comparing the first data file name with the second data file name; the second data file name is the file name of the latest stored time;

[0066] S104: Determine the file corresponding to the latest data file name between the first data file name and the second data file name as the target internal test file.

[0067] When creating a torpedo data file, the latest data file stored on the disk and the data file created by the timestamp file are compared, and a torpedo internal test data folder is created based on the newer data file name.

[0068] For example, when creating a torpedo data file, the corresponding data file name recDir is calculated based on the Beijing time timestamp parameter in Date_TimeRunPara, and the size of recDir and last_dataFile is compared. The larger value is the new file name. If the data file name recDir created by the Beijing time timestamp parameter is newer, the mkdir(recDir) function is used to create a torpedo internal test data folder; if last_dataFile is newer, last_dataFile is cumulatively added by 1, and the sexagesimal system of hours, minutes and seconds is used to handle the carry problem, and the newly generated folder name is assigned to recDir, and then the mkdir(recDir) function is used to create a torpedo internal test data folder.

[0069] Another embodiment of the present application further supplements the method for creating a file for torpedo internal measurement data provided in the above embodiment.

[0070] Optionally, determining the file corresponding to the latest data file name between the first data file name and the second data file name as the target internal test file includes:

[0071] If the time of the first data file name is newer, the mkdir(recDir) function is used to create the first torpedo internal test data file, and the first torpedo internal test data file is used as the target internal test file;

[0072] If the time of the second data file name is newer, a sexagesimal processing and carry algorithm of the hours, minutes and seconds is adopted to generate a second torpedo internal test data file, and the second torpedo internal test data file is used as the target internal test file.

[0073] Optionally, the preset timestamp parameter is obtained in the following manner:

[0074] In the torpedo firing preparation, the time stamp parameter online binding information command is received through the CAN bus;

[0075] Determine whether the data segment of the online binding information instruction of the timestamp parameter meets the logical requirements of the time and date;

[0076] If the timestamp parameter meets the logical requirement of time, the timestamp parameter is determined as the preset timestamp parameter.

[0077] During the preparation for torpedo firing, Beijing time parameters are set and stored in the parameter file. During actual navigation, timestamp parameters are read from the parameter file and participate in the creation process of the internal test data folder.

[0078] Optionally, if the timestamp parameter meets the logical requirement of time, determining the timestamp parameter as a preset timestamp parameter includes:

[0079] Perform validity judgment on the data segment of the online binding information instruction of the timestamp parameter;

[0080] If the logical requirement that the month value is not greater than 12 and the date value is not greater than 31 is met, the timestamp parameter in the timestamp parameter online binding information instruction is determined to be a valid parameter, and the timestamp parameter is determined to be a preset timestamp parameter.

[0081] After the torpedo launch internal test function is started, the validity of the 8-byte DATA data segment received from the combat self-test command is judged, and the timestamp file is written only when the parameters are valid.

[0082] In the preparation before torpedo firing, a portable setting instrument and other equipment are used to send parameter online binding information through the combat self-test command (ID: 0x01FE0100) of the CAN bus. After the torpedo receives the combat self-test command, the validity of its 8-byte DATA data segment is judged. If the logical conditions such as the month value is not greater than 12 and the date value is not greater than 31 are met, the 8-byte DATA data segment is used as the Beijing time timestamp parameter and written into the Beijing time timestamp file Date_Time.bin on the non-volatile memory of the torpedo. Otherwise, the write operation is not performed.

[0083] Optionally, the method further comprises:

[0084] After the torpedo launch internal test function is started, open the file with preset timestamp parameters;

[0085] If error is opened, the default parameters are used.

[0086] After the torpedo launch internal test function is started, when the disk Beijing time timestamp parameter file is opened successfully, the read parameters will be stored in the cache variable, otherwise the parameter cache variable will be assigned a default value.

[0087] After the torpedo launch internal test function is started, the Beijing time timestamp file Date_Time.bin is opened. If the file is opened successfully, the file content is read and stored in the program cache variable Date_TimeRunPara. If the opening fails, the default value is assigned to Date_TimeRunPara. In the quantity management of the data folders that already exist on the data storage, the digital data file names are traversed and the size of the data file name strings is compared, that is, the smallest string is the oldest file, and the largest string is the latest file. The oldest data file is deleted, and the latest data file name is stored in the variable last_dataFile.

[0088] Optionally, the method further comprises:

[0089] The number of existing data folders on the data storage device is managed, the oldest data folder is deleted, and the current latest data folder name is screened out, and the current latest data file name is determined as the second data file name.

[0090] When managing the number of data folders that already exist on the data storage device, the oldest file is deleted and the latest data file is recorded.

[0091] Optionally, the number of data folders already existing on the data storage device is managed, and the oldest data folder is deleted, including:

[0092] By traversing the digital data file names, the string sizes of the data file names are compared;

[0093] Identify the smallest string as the oldest file, the largest string as the newest file, delete the oldest data file, and store the newest data file name in a variable.

[0094] In the quantity management of the data folders that already exist on the data storage device, by traversing the digital data file names and using the method of comparing the data file name string size, the oldest data file is deleted and the latest data file name is stored in the variable last_dataFile.

[0095] In tasks such as torpedo scientific research tests, equipment delivery tests, and troop actual combat training tests, the Beijing time timestamp parameter setting including the date and time is completed before the torpedo is fired, and the valid setting parameters are stored in the non-volatile memory in the form of a file. After the torpedo launch internal test function is started, first open the Beijing time timestamp parameter file ( Figure 2 ), if an error occurs when opening, use the default parameters; secondly, manage the number of data folders that already exist on the data storage device, delete the oldest data folder, and filter out the current latest data folder name; finally, if the Beijing time stamp parameter is newer than the current latest data folder name filtered out, create an internal test data file with the Beijing time stamp parameter, otherwise, create a new data folder by accumulating the count of the latest folder name on the data storage device.

[0096] The present invention does not rely on the traditional RTC clock chip hardware and does not add new hardware resources. It adopts a brand-new software design method to realize the torpedo internal test data file creation function, reduces the development and production costs of the torpedo, and completely solves the risk of the clock chip built-in battery possibly being over-discharged and causing functional failure, and realizes the online loop recording function of the digital difference naming test data file ( Figure 3 ), avoiding data overwriting and improving the offline management efficiency of massive actual flight test data.

[0097] In order to achieve the above object, the present invention adopts the following technical solution:

[0098] In the preparation before torpedo firing, complete the Beijing time timestamp parameter setting including date and time, and store the valid setting parameters in the non-volatile memory in the form of a file. After the torpedo launch internal test function is started, first open the Beijing time timestamp parameter file. If an error occurs during opening, use the default parameters; secondly, manage the number of data folders that already exist on the data storage device, delete the oldest data folder, and filter out the latest data folder name; finally, if the Beijing time timestamp parameter filters out the latest data folder name update, create an internal test data file with the Beijing time timestamp parameter, otherwise, create a new data folder by accumulating the latest folder name on the data storage device.

[0099] The embodiment of the present application utilizes the setting parameter file content stored in the torpedo pre-fire preparation, combined with the data file status stored in the torpedo data storage device, to design a parameterized creation method for the internal test data file, thereby realizing a torpedo internal test data file creation function that does not rely on the RTC clock chip hardware.

[0100] The embodiment of the present application adopts a software design method that does not rely on RTC clock chip hardware, and realizes the torpedo internal test data file creation function, and the beneficial effects include:

[0101] 1) The embodiment of the present application cancels the RTC clock chip and does not add new hardware resources, thereby realizing the creation of torpedo internal test data files, and effectively reducing the development and production costs of torpedoes;

[0102] 2) The embodiment of the present application provides a new method, which completely solves the risk of over-discharge of the built-in battery of the clock chip leading to functional failure, making it possible to implement maintenance-free internal test function circuits of the torpedo during the overhaul cycle or life cycle, thereby greatly improving the reliability and security of the torpedo.

[0103] 3) The embodiment of the present application adopts a method of digitally differentially naming the internal test data files based on Beijing time, which realizes online circular recording of test data files, avoids data overwriting, reduces special operations for data erasure, and can improve the offline management efficiency of massive actual flight test data. It is a brand-new design method and idea.

[0104] The embodiment of the present invention provides a file creation method for torpedo internal test data, including: obtaining a preset timestamp parameter; determining a first data file name corresponding to the preset timestamp parameter according to the preset timestamp parameter; comparing the first data file name and the second data file name; the second data file name is the file name of the latest time that has been stored; and the file corresponding to the data file name with the latest time among the first data file name and the second data file name is determined as the target internal test file. The method does not rely on traditional RTC clock chip hardware and does not add new hardware resources. It adopts a brand-new software design method to realize the torpedo internal test data file creation function, reduce the research and production costs of torpedoes, and completely solve the risk of functional failure caused by over-discharge of the built-in battery of the clock chip, realize the online loop recording function of the digital difference naming test data file, avoid data overwriting, and improve the offline management efficiency of massive actual flight test data.

[0105] It should be noted that each implementable method in this embodiment may be implemented separately, or may be implemented in combination in any combination without conflict, and this application is not limited thereto.

[0106] Another embodiment of the present application provides a file creation device for torpedo internal test data, which is used to execute the file creation method for torpedo internal test data provided in the above embodiment.

[0107] like Figure 4 As shown, it is a schematic diagram of the structure of the file creation device for torpedo internal measurement data provided by the embodiment of the present application. The xx device includes an acquisition module 401, a determination module 402, a comparison module 403 and a generation module 404, wherein:

[0108] The acquisition module 401 is used to acquire preset timestamp parameters;

[0109] The determination module 402 is used to determine the name of the first data file corresponding to the preset timestamp parameter according to the preset timestamp parameter;

[0110] The comparison module 403 is used to compare the first data file name with the second data file name; the second data file name is the file name of the latest time that has been stored;

[0111] The generation module 404 is used to determine the file corresponding to the latest data file name between the first data file name and the second data file name as the target internal test file.

[0112] Regarding the device in this embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0113] Another embodiment of the present application further supplements the description of the file creation device for torpedo internal measurement data provided in the above embodiment.

[0114] Optionally, the preset timestamp parameter is obtained in the following manner:

[0115] In the torpedo firing preparation, the time stamp parameter online binding information command is received through the CAN bus;

[0116] Determine whether the data segment of the online binding information instruction of the timestamp parameter meets the logical requirements of the time and date;

[0117] If the timestamp parameter meets the logical requirement of time, the timestamp parameter is determined as the preset timestamp parameter.

[0118] Optionally, if the timestamp parameter meets the logical requirement of time, determining the timestamp parameter as a preset timestamp parameter includes:

[0119] Perform validity judgment on the data segment of the online binding information instruction of the timestamp parameter;

[0120] If the logical requirement that the month value is not greater than 12 and the date value is not greater than 31 is met, the timestamp parameter in the timestamp parameter online binding information instruction is determined to be a valid parameter, and the timestamp parameter is determined to be a preset timestamp parameter.

[0121] Optionally, generate a module for:

[0122] After the torpedo launch internal test function is started, open the file with preset timestamp parameters;

[0123] If error is opened, the default parameters are used.

[0124] Optionally, generate a module for:

[0125] The number of existing data folders on the data storage device is managed, the oldest data folder is deleted, and the current latest data folder name is screened out, and the current latest data file name is determined as the second data file name.

[0126] Optionally, generate a module for:

[0127] By traversing the digital data file names, the string sizes of the data file names are compared;

[0128] Identify the smallest string as the oldest file, the largest string as the newest file, delete the oldest data file, and store the newest data file name in a variable.

[0129] The embodiment of the present invention provides a file creation device for torpedo internal test data, including: obtaining a preset timestamp parameter; determining a first data file name corresponding to the preset timestamp parameter according to the preset timestamp parameter; comparing the first data file name and the second data file name; the second data file name is the file name of the latest time that has been stored; and the file corresponding to the data file name with the latest time among the first data file name and the second data file name is determined as the target internal test file. The device does not rely on traditional RTC clock chip hardware and does not add new hardware resources. It adopts a brand-new software design method to realize the torpedo internal test data file creation function, reduce the research and production costs of torpedoes, and completely solve the risk of functional failure caused by over-discharge of the built-in battery of the clock chip, realize the online loop recording function of the digital difference naming test data file, avoid data overwriting, and improve the offline management efficiency of massive actual flight test data.

[0130] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0131] Optionally, an embodiment of the present application further provides an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, the various processes of the above-mentioned method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.

[0132] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, each process of the above method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it is not repeated here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0133] Figure 5 800 is a block diagram of an electronic device 800 shown in the present application. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0134] Reference Figure 5 , the electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .

[0135] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0136] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, images, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0137] The power supply component 806 provides power to the various components of the electronic device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 800.

[0138] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0139] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0140] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: home button, volume button, start button, and lock button.

[0141] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0142] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast operation information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0143] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.

[0144] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 804 including instructions, and the instructions can be executed by a processor 820 of an electronic device 800 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0145] Figure 619 is a block diagram of a computer-readable storage medium 1900 shown in the present application. For example, the computer-readable storage medium 1900 may be provided as a server.

[0146] Reference Figure 6 , the computer-readable storage medium 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions, such as an application, that can be executed by the processing component 1922. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.

[0147] The computer readable storage medium 1900 may also include a power supply component 1926 configured to perform power management of the computer readable storage medium 1900, a wired or wireless network interface 1950 configured to connect the computer readable storage medium 1900 to a network, and an input / output (I / O) interface 1958. The computer readable storage medium 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™ or the like.

[0148] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0149] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0150] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

[0151] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in the present application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0152] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0153] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0154] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0155] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0156] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard drives, ROM, RAM, magnetic disks, or optical disks.

[0157] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

[0158] The above are preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as within the scope of protection of the present invention.

Claims

1. A method for creating a file of torpedo internal test data, characterized in that: include: Get the preset timestamp parameters; According to the preset timestamp parameter, determining a first data file name corresponding to the preset timestamp parameter; Compare the first data file name with the second data file name; The second data file name is the file name of the latest stored time; The file corresponding to the latest data file name between the first data file name and the second data file name is determined as the target internal test file.

2. The method for creating a file of torpedo internal measurement data according to claim 1, characterized in that: The step of determining the file corresponding to the latest data file name between the first data file name and the second data file name as the target internal test file includes: If the time of the first data file name is newer, a first torpedo internal test data file is created using a preset function, and the first torpedo internal test data file is used as the target internal test file; If the time of the second data file name is newer, a sexagesimal processing and carry algorithm of the hours, minutes and seconds is adopted to generate a second torpedo internal test data file, and the second torpedo internal test data file is used as the target internal test file.

3. The method for creating a file of torpedo internal measurement data according to claim 1, characterized in that: The preset timestamp parameter is obtained in the following way: In the torpedo firing preparation, the time stamp parameter online binding information command is received through the CAN bus; Determining whether the data segment of the online binding information instruction of the timestamp parameter meets the logical requirements of time and date; If the timestamp parameter meets the logical requirement of the time, the timestamp parameter is determined as the preset timestamp parameter.

4. The method for creating a file of torpedo internal measurement data according to claim 3, characterized in that: If the timestamp parameter satisfies the logical requirement of the time, determining the timestamp parameter as the preset timestamp parameter includes: Performing validity judgment on the data segment of the online binding information instruction of the timestamp parameter; If the logical requirements that the month value is not greater than 12 and the date value is not greater than 31 are met, the timestamp parameter in the timestamp parameter online binding information instruction is determined to be a valid parameter, and the timestamp parameter is determined to be the preset timestamp parameter.

5. The method for creating a file of torpedo internal measurement data according to claim 1, characterized in that: The method further comprises: After the torpedo launch internal test function is started, the file of the preset timestamp parameters is opened; If error is opened, the default parameters are used.

6. The method for creating a file of torpedo internal measurement data according to claim 1, characterized in that: The method further comprises: The number of existing data folders on the data storage device is managed, the oldest data folder is deleted, and the current latest data folder name is screened out, and the current latest data file name is determined as the second data file name.

7. The method for creating a file of torpedo internal measurement data according to claim 6, characterized in that: The method of managing the number of data folders already existing in the data storage device and deleting the oldest data folder includes: By traversing the digital data file names, the string sizes of the data file names are compared; Identify the smallest string as the oldest file, the largest string as the newest file, delete the oldest data file, and store the newest data file name in a variable.

8. A device for creating a file of torpedo internal test data, characterized in that: include: An acquisition module, used to obtain preset timestamp parameters; A determination module, configured to determine, according to the preset timestamp parameter, a name of a first data file corresponding to the preset timestamp parameter; A comparison module, used for comparing the first data file name with the second data file name; The second data file name is the file name of the latest stored time; A generation module is used to determine the file corresponding to the latest data file name between the first data file name and the second data file name as a target internal test file.

9. An electronic device, characterized in that: include: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the method according to any one of claims 1 to 7 when executed by the processor.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.