CN114237344B - Arbitrary waveform generator process changing method, equipment and medium - Google Patents
Arbitrary waveform generator process changing method, equipment and medium Download PDFInfo
- Publication number
- CN114237344B CN114237344B CN202111542848.3A CN202111542848A CN114237344B CN 114237344 B CN114237344 B CN 114237344B CN 202111542848 A CN202111542848 A CN 202111542848A CN 114237344 B CN114237344 B CN 114237344B
- Authority
- CN
- China
- Prior art keywords
- waveform generator
- arbitrary waveform
- state
- information file
- file
- 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.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 253
- 230000008569 process Effects 0.000 title claims abstract description 212
- 238000012545 processing Methods 0.000 claims description 24
- 230000006870 function Effects 0.000 claims description 13
- 238000012986 modification Methods 0.000 claims description 7
- 230000004048 modification Effects 0.000 claims description 7
- 238000004140 cleaning Methods 0.000 claims description 6
- 238000012423 maintenance Methods 0.000 claims description 3
- 238000005259 measurement Methods 0.000 description 8
- FFBHFFJDDLITSX-UHFFFAOYSA-N benzyl N-[2-hydroxy-4-(3-oxomorpholin-4-yl)phenyl]carbamate Chemical compound OC1=C(NC(=O)OCC2=CC=CC=C2)C=CC(=C1)N1CCOCC1=O FFBHFFJDDLITSX-UHFFFAOYSA-N 0.000 description 7
- 238000010586 diagram Methods 0.000 description 4
- 238000004088 simulation Methods 0.000 description 3
- 238000011160 research Methods 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 238000002715 modification method Methods 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000012800 visualization Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/02—Digital function generators
- G06F1/03—Digital function generators working, at least partly, by table look-up
- G06F1/0321—Waveform generators, i.e. devices for generating periodical functions of time, e.g. direct digital synthesizers
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Testing And Monitoring For Control Systems (AREA)
Abstract
The embodiment of the application discloses a method, equipment and medium for changing an arbitrary waveform generator process. Under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator; when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator; the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated; and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator. By the method, the accuracy of the output waveform of the arbitrary waveform generator is improved.
Description
Technical Field
The present disclosure relates to the field of instrumentation technologies, and in particular, to a method, an apparatus, and a medium for modifying a process of an arbitrary waveform generator.
Background
The arbitrary waveform generator is the best instrument for simulation experiments, is one of the signal sources, and has all the characteristics of the signal sources.
In the leading-edge scientific research field, a large number of arbitrary waveform generators are often required to work cooperatively. When the number of arbitrary waveform generators increases, a situation occurs in which different programs access the same arbitrary waveform generator. If the same arbitrary waveform generator is configured differently in a plurality of different programs, the arbitrary waveform generator is likely to be confused when loading waveforms, so that it is difficult to output accurate waveforms.
Disclosure of Invention
The embodiment of the application provides a method, equipment and medium for changing the progress of an arbitrary waveform generator, which are used for solving the following technical problems: the same arbitrary waveform generator is respectively configured with different waveforms in a plurality of different programs, so that the arbitrary waveform generator is easy to be confused when loading waveforms, and accurate waveforms are difficult to output.
The embodiment of the application adopts the following technical scheme:
the embodiment of the application provides an arbitrary waveform generator process changing method. Under the condition that the arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator; when the first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator; the method comprises the steps of performing cleaning processing on waveform configuration of an arbitrary waveform generator through a first process, and changing the state of the arbitrary waveform generator into a state to be updated; and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
According to the method and the device for processing the waveform configuration of the random waveform generator, the first process information is obtained, the created information file is sent to the first process, and the waveform configuration of the random waveform generator can be cleared through the first process, so that the second process information is rewritten into the state file. The arbitrary waveform generator receives the waveform configuration corresponding to one process at a time and outputs the waveform corresponding to the process, so that the problem that the waveform configuration is carried out on the same arbitrary waveform generator by a plurality of processes at the same time, and the waveform disorder of the arbitrary waveform generator is caused, and the accuracy of the output waveform is ensured.
In one implementation manner of the present application, creating an information file and sending the information file to a first process, specifically includes: creating an information file corresponding to the arbitrary waveform generator; writing the box number and the slot number corresponding to the arbitrary waveform generator into an information file; and sending a preset specified signal to the first process so that the first process obtains the information file according to the preset specified signal.
In one implementation manner of the present application, the first process obtains an information file according to a preset specified signal, and specifically includes: calling a preset signal processing function through a first process; and acquiring the machine box number and the slot number of the arbitrary waveform generator recorded in the information file through a signal processing function.
In one implementation manner of the present application, before the first process information is acquired in the state file corresponding to the arbitrary waveform generator, the method further includes: opening a state lock file corresponding to the arbitrary waveform generator; locking the state lock file corresponding to the arbitrary waveform generator; the locked file only allows the current user to modify the file.
According to the method and the device for carrying out the shackle processing on the file, only one process can modify the file at a time, and therefore the risk that a plurality of processes carry out waveform configuration on the same arbitrary waveform generator at the same time is reduced. The phenomenon of waveform disorder of the arbitrary waveform generator is reduced.
In one implementation of the present application, before changing the state of the arbitrary waveform generator to the updated state, the method further includes: acquiring the state of an arbitrary waveform generator; under the condition that the arbitrary waveform generator is in an updated state, unlocking the state lock file corresponding to the arbitrary waveform generator; closing the state lock file corresponding to the arbitrary waveform generator, and loading the waveform corresponding to the second process to the arbitrary waveform generator.
In one implementation of the present application, before sending the information file to the first process, the method further includes: acquiring an established information file corresponding to an arbitrary waveform generator; carrying out clearing treatment on the information in the created information file; and writing the case number and the slot number corresponding to the random waveform generator currently into an information file.
In one implementation manner of the present application, after the first process information is obtained in the state file corresponding to the arbitrary waveform generator, the method further includes: and when the first process is in the exited state, the second process is used for clearing the waveform configuration of the arbitrary waveform generator.
In one implementation of the present application, after the cleaning processing is performed on the waveform configuration of the arbitrary waveform generator by the second process, the method further includes: carrying out clearing treatment on the state file corresponding to the arbitrary waveform generator through a second process; re-writing second process information in the state file, and changing the state of the arbitrary waveform generator into an updated state; wherein the updated state is that the arbitrary waveform generator is in a maintenance state in the second process.
The embodiment of the application provides an arbitrary waveform generator process changing device, which comprises the following components: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executable by the at least one processor to enable the at least one processor to: under the condition that the arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator; when the first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator; the method comprises the steps of performing cleaning processing on waveform configuration of an arbitrary waveform generator through a first process, and changing the state of the arbitrary waveform generator into a state to be updated; and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
The embodiment of the application provides a nonvolatile computer storage medium, which stores computer executable instructions, wherein the computer executable instructions are configured to: under the condition that the arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator; when the first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator; the method comprises the steps of performing cleaning processing on waveform configuration of an arbitrary waveform generator through a first process, and changing the state of the arbitrary waveform generator into a state to be updated; and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
The above-mentioned at least one technical scheme that this application embodiment adopted can reach following beneficial effect: according to the method and the device for processing the waveform configuration of the random waveform generator, the first process information is obtained, the created information file is sent to the first process, and the waveform configuration of the random waveform generator can be cleared through the first process, so that the second process information is rewritten into the state file. The arbitrary waveform generator receives the waveform configuration corresponding to one process at a time and outputs the waveform corresponding to the process, so that the problem that the waveform configuration is carried out on the same arbitrary waveform generator by a plurality of processes at the same time, and the waveform disorder of the arbitrary waveform generator is caused, and the accuracy of the output waveform is ensured.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments described in the present application, and that other drawings may be obtained according to these drawings without inventive effort to a person skilled in the art. In the drawings:
FIG. 1 is a flowchart of a method for modifying an arbitrary waveform generator process according to an embodiment of the present application;
FIG. 2 is a block diagram of a process modification flow of an arbitrary waveform generator according to an embodiment of the present application;
fig. 3 is a schematic structural diagram of an arbitrary waveform generator process modification apparatus according to an embodiment of the present application.
Detailed Description
The embodiment of the application provides a method, equipment and medium for changing an arbitrary waveform generator process.
In order to better understand the technical solutions in the present application, the following description will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments herein without making any inventive effort, shall fall within the scope of the present application.
The arbitrary waveform generator is the best instrument for simulation experiments, is one of the signal sources, and has all the characteristics of the signal sources.
In the leading-edge scientific research field, a large number of arbitrary waveform generators are often required to work cooperatively. When the number of arbitrary waveform generators increases, a situation occurs in which different programs access the same arbitrary waveform generator. If the same arbitrary waveform generator is configured differently in a plurality of different programs, the arbitrary waveform generator is likely to be confused when loading waveforms, so that it is difficult to output accurate waveforms.
In order to solve the above problems, embodiments of the present application provide a method, an apparatus, and a medium for modifying an arbitrary waveform generator process. And by acquiring the first process information and sending the created information file to the first process, the waveform configuration of the arbitrary waveform generator can be cleared through the first process, so that the second process information is rewritten into the state file. The arbitrary waveform generator receives the waveform configuration corresponding to one process at a time and outputs the waveform corresponding to the process, so that the problem that the waveform configuration is carried out on the same arbitrary waveform generator by a plurality of processes at the same time, and the waveform disorder of the arbitrary waveform generator is caused, and the accuracy of the output waveform is ensured.
The following describes in detail the technical solution proposed in the embodiments of the present application through the accompanying drawings.
Fig. 1 is a flowchart of a method for modifying an arbitrary waveform generator process according to an embodiment of the present application. As shown in fig. 1, the arbitrary waveform generator process modification method includes the steps of:
s101, the process changing device of the arbitrary waveform generator acquires first process information from a state file corresponding to the arbitrary waveform generator when the arbitrary waveform generator is in an un-updated state.
In one embodiment of the present application, a state lock file corresponding to an arbitrary waveform generator is opened. And locking the state lock file corresponding to the arbitrary waveform generator. The locked file only allows the current user to modify the file.
Specifically, in order to prevent multiple users from modifying the arbitrary waveform generator at the same time, the state lock file of the current arbitrary waveform generator needs to be subjected to locking processing, so that only the current user is ensured to modify the state lock file.
In one embodiment of the present application, the arbitrary waveform generator process alters the device to see if the arbitrary waveform generator is in an un-updated state.
Specifically, if the arbitrary waveform generator is in an updated state, unlocking the state lock file corresponding to the arbitrary waveform generator. Closing the state lock file corresponding to the arbitrary waveform generator, and loading the waveform corresponding to the second process to the arbitrary waveform generator.
Specifically, if the arbitrary waveform generator is in an un-updated state, the first process ID in the arbitrary waveform generator state file identified by the machine box number and the slot number is read, and the read state of the first process is obtained. The read state of the first process may include a running state and an exited state.
S102, when the first process is in an operation state, the arbitrary waveform generator process changing device creates an information file and sends the information file to the first process.
In one embodiment of the present application, an information file corresponding to an arbitrary waveform generator is created. And writing the box number and the slot number corresponding to the arbitrary waveform generator into an information file. And sending a preset specified signal to the first process so that the first process obtains the information file according to the preset specified signal.
Specifically, when the first process is in an operational state, then an arbitrary waveform generator information file is created. Writing the box number and the slot number of the current arbitrary waveform generator into the information file of the arbitrary waveform generator, and sending a designated signal to the process indicated by the read first process ID. The first process is notified to acquire the information file by the designation signal. The first designated signal is a preset signal, and the first process can make corresponding operation under the condition of receiving the signal.
In one embodiment of the present application, an information file corresponding to an arbitrary waveform generator that has been created is obtained. And carrying out clearing processing on the information in the created information file. And writing the case number and the slot number corresponding to the random waveform generator currently into an information file.
Specifically, when the first process is in an operation state, if an arbitrary waveform generator information file exists, the content in the information file needs to be emptied. And then inputting the case number and the slot number corresponding to the current arbitrary waveform generator into the information file. And sending a specified signal to the process indicated by the read first process ID. The first process is notified to acquire the information file by the designation signal.
In one embodiment of the present application, the preset signal processing function is invoked by a first process. And acquiring the machine box number and the slot number of the arbitrary waveform generator recorded in the information file through a signal processing function.
Specifically, after receiving the specified signal, the first process calls a signal processing function and reads the box number and the slot number of the arbitrary waveform generator in the information file of the arbitrary waveform generator. And acquiring configuration content corresponding to the arbitrary waveform generator, and carrying out corresponding processing on the configuration content.
S103, through a first process, the waveform configuration of the arbitrary waveform generator is cleared, and the state of the arbitrary waveform generator is changed into a state to be updated.
In one embodiment of the present application, after receiving the specified signal, the first process invokes the signal processing function, reads the box number and the slot number of the arbitrary waveform generator in the information file of the arbitrary waveform generator, clears the waveform configuration of the arbitrary waveform generator, and sets the arbitrary waveform generator to be in a state to be updated.
It should be noted that the state of the arbitrary waveform generator to be updated refers to a state maintained by the arbitrary waveform generator in the first process receiving the specified signal.
S104, rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
In one embodiment of the present application, after setting the arbitrary waveform generator to be in a state to be updated, the second process, that is, the current process, clears the state file of the arbitrary waveform generator, writes the process ID of the current process, and sets the arbitrary waveform generator to be in an updated state.
The updated state of the arbitrary waveform generator refers to a state that the arbitrary waveform generator maintains in the current process.
Further, unlock the arbitrary waveform generator state lock file. Closing the arbitrary waveform generator state lock file. The current process loads a new waveform into the arbitrary waveform generator.
According to the method and the device for processing the waveform configuration of the random waveform generator, the first process information is obtained, the created information file is sent to the first process, and the waveform configuration of the random waveform generator can be cleared through the first process, so that the second process information is rewritten into the state file. The arbitrary waveform generator receives the waveform configuration corresponding to one process at a time and outputs the waveform corresponding to the process, so that the problem that a plurality of processes simultaneously carry out waveform configuration on the same arbitrary waveform generator is solved, and the accuracy of the output waveform is ensured.
In another embodiment of the present application, a state lock file corresponding to the arbitrary waveform generator is opened, and a locking process is performed on the state lock file corresponding to the arbitrary waveform generator. See if any waveform generator is in an un-updated state.
Specifically, if the arbitrary waveform generator is in an un-updated state, the first process ID in the arbitrary waveform generator state file identified by the machine box number and the slot number is read, and the read state of the first process is obtained.
Further, when the first process is in the exited state, the waveform configuration of the arbitrary waveform generator is cleared by the second process, i.e., the current process.
Further, through a second process, the state file corresponding to the arbitrary waveform generator is cleared. And rewriting second process information in the state file, and changing the state of the arbitrary waveform generator into an updated state. Wherein the updated state is that the arbitrary waveform generator is in a maintenance state in the second process. Unlocking the arbitrary waveform generator state lock file, and closing the arbitrary waveform generator state lock file. The current process loads a new waveform into the arbitrary waveform generator.
In one embodiment of the present application, the measurement and control system is composed of a measurement and control computer, a PXIe chassis, and an arbitrary waveform generator. The measurement and control computer runs a Python measurement and control program through a Jupyter Notebook, and accesses the arbitrary waveform generator through a Python interface, a C library function and a driver. The Jupyter Notebook is a Web application program, which is convenient for creating and sharing program documents, and supports real-time codes, mathematical equations, visualization and markdown. The application comprises the following steps: data cleaning and conversion, numerical simulation, statistical modeling, machine learning, and the like.
Further, two identical Python measurement and control programs are opened through a Jupyter Notebook, but the file names of the Python measurement and control programs are different, and the two processes are corresponding. The Python measurement and control program of the creation process 1 accesses an arbitrary waveform generator specified by the machine box number and the slot number, the Python measurement and control program of the creation process 2 accesses the same arbitrary waveform generator specified by the machine box number and the slot number, and both processes are provided with signal processing functions aiming at user-defined signals SIGUSR1 when the equipment is opened. At this time, the process 2 sends a signal to the process 1, the process 1 calls a signal processing function after receiving the signal, clears the waveform configuration of the process 1 to the arbitrary waveform generator, and loads a new waveform to the arbitrary waveform generator.
Fig. 2 is a process modification flow block diagram of an arbitrary waveform generator according to an embodiment of the present application. As shown in fig. 2, process 1 and process 2 open the arbitrary waveform generator state lock file and lock the arbitrary waveform generator state lock file. And determining whether the state of the arbitrary waveform generator is updated, if so, reading the process ID in the state file of the arbitrary waveform generator identified by the machine box number and the slot number, and determining whether the read process is still running. If the process ID is still in progress, an arbitrary waveform generator information file is created or emptied, a box number and a slot number of the arbitrary waveform generator are written into the arbitrary waveform generator information file, and a specified signal is sent to the process indicated by the read process ID.
When the equipment is opened, a signal processing function aiming at a user-defined signal SIGUSR1 is set by both processes, a signal is sent to the process 1 by the process 2, the signal processing function is called after the process 1 receives the signal, the box number and the slot number of the arbitrary waveform generator in the information file of the arbitrary waveform generator are read, the waveform configuration of the arbitrary waveform generator is cleared, and the arbitrary waveform generator is set to be in a state to be updated.
The current process 2 clears the status file of the arbitrary waveform generator, writes the process ID of the current process 2, sets the arbitrary waveform generator to be in an updated state, and unlocks the status lock file of the arbitrary waveform generator. Closing the arbitrary waveform generator state lock file and the current process 2 loads a new waveform into the arbitrary waveform generator.
Further, if the state of the arbitrary waveform generator is not updated, the state lock file of the arbitrary waveform generator is directly unlocked. Closing the status lock file of the arbitrary waveform generator, and loading a new waveform to the arbitrary waveform generator by the current process.
Further, if the process indicated by the read process ID has been exited, the current process 2 clears the waveform configuration of the arbitrary waveform generator, clears the state file of the arbitrary waveform generator through the current process, writes the process ID of the current process 2, and sets the arbitrary waveform generator to be in an updated state. Then, unlock the arbitrary waveform generator state lock file, close the arbitrary waveform generator state lock file, the current process 2 loads a new waveform to the arbitrary waveform generator.
Fig. 3 is a schematic structural diagram of an arbitrary waveform generator process modification apparatus according to an embodiment of the present application. As shown in fig. 3, the arbitrary waveform generator process changing apparatus includes,
at least one processor; the method comprises the steps of,
a memory communicatively coupled to the at least one processor; wherein,,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator;
when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator;
the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated;
and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
Embodiments of the present application also provide a non-volatile computer storage medium storing computer-executable instructions configured to:
under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator;
when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator;
the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated;
and rewriting second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator.
All embodiments in the application are described in a progressive manner, and identical and similar parts of all embodiments are mutually referred, so that each embodiment mainly describes differences from other embodiments. In particular, for apparatus, devices, non-volatile computer storage medium embodiments, the description is relatively simple, as it is substantially similar to method embodiments, with reference to the section of the method embodiments being relevant.
The foregoing describes specific embodiments of the present application. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
The foregoing is merely exemplary of the present application and is not intended to limit the present application. Various modifications and variations of the embodiments of the present application will be apparent to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the embodiments of the present application should be included in the scope of the claims of the present application.
Claims (8)
1. A method for modifying a process of an arbitrary waveform generator, the method comprising:
under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator;
when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator;
the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated;
re-writing second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator;
before the information file is sent to the first process, the method further comprises:
acquiring an established information file corresponding to the arbitrary waveform generator;
carrying out clearing treatment on the information in the created information file;
writing the case number and the slot number currently corresponding to the arbitrary waveform generator into the information file;
the creating an information file and sending the information file to the first process specifically includes:
creating an information file corresponding to the arbitrary waveform generator;
writing the machine box number and the slot number corresponding to the arbitrary waveform generator into the information file;
and sending a preset specified signal to the first process so that the first process obtains the information file according to the preset specified signal.
2. The method for modifying an arbitrary waveform generator process according to claim 1, wherein the first process obtains the information file according to the preset specification signal, specifically comprising:
calling a preset signal processing function through the first process;
and acquiring the machine box number and the slot number of the arbitrary waveform generator recorded in the information file through the signal processing function.
3. The method for modifying a process of an arbitrary waveform generator according to claim 1, wherein before the first process information is acquired in the state file corresponding to the arbitrary waveform generator, the method further comprises:
opening a state lock file corresponding to the arbitrary waveform generator;
locking the state lock file corresponding to the arbitrary waveform generator; the locked file only allows the current user to modify the file.
4. The method of claim 1, wherein prior to said changing the state of said arbitrary waveform generator to an updated state, said method further comprises:
acquiring the state of the arbitrary waveform generator;
under the condition that the arbitrary waveform generator is in an updated state, unlocking the state lock file corresponding to the arbitrary waveform generator;
closing the state lock file corresponding to the arbitrary waveform generator, and loading the waveform corresponding to the second process to the arbitrary waveform generator.
5. The method for modifying a process of an arbitrary waveform generator according to claim 1, wherein after the first process information is obtained from the state file corresponding to the arbitrary waveform generator, the method further comprises:
and when the first process is in the exited state, the second process is used for clearing the waveform configuration of the arbitrary waveform generator.
6. The method according to claim 5, wherein after the cleaning of the waveform configuration of the arbitrary waveform generator by the second process, the method further comprises:
carrying out emptying treatment on the state file corresponding to the arbitrary waveform generator through the second process;
re-writing second process information in the state file, and changing the state of the arbitrary waveform generator into an updated state; wherein the updated state is a maintenance state of the arbitrary waveform generator in the second process.
7. An arbitrary waveform generator process modification apparatus comprising:
at least one processor; the method comprises the steps of,
a memory communicatively coupled to the at least one processor; wherein,,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator;
when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator;
the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated;
re-writing second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator;
before the information file is sent to the first process, the method further comprises:
acquiring an established information file corresponding to the arbitrary waveform generator;
carrying out clearing treatment on the information in the created information file;
writing the case number and the slot number currently corresponding to the arbitrary waveform generator into the information file;
the creating an information file and sending the information file to the first process specifically includes:
creating an information file corresponding to the arbitrary waveform generator;
writing the machine box number and the slot number corresponding to the arbitrary waveform generator into the information file;
and sending a preset specified signal to the first process so that the first process obtains the information file according to the preset specified signal.
8. A non-transitory computer storage medium storing computer executable instructions executable by a processor to implement:
under the condition that an arbitrary waveform generator is in an un-updated state, acquiring first process information from a state file corresponding to the arbitrary waveform generator;
when a first process is in an operation state, creating an information file and sending the information file to the first process; the information file at least comprises a case number and a slot number corresponding to the arbitrary waveform generator;
the waveform configuration of the arbitrary waveform generator is cleared through the first process, and the state of the arbitrary waveform generator is changed into a state to be updated;
re-writing second process information in the state file, changing the state of the arbitrary waveform generator into an updated state, and loading waveforms corresponding to the second process to the arbitrary waveform generator;
before the information file is sent to the first process, the method further comprises:
acquiring an established information file corresponding to the arbitrary waveform generator;
carrying out clearing treatment on the information in the created information file;
writing the case number and the slot number currently corresponding to the arbitrary waveform generator into the information file;
the creating an information file and sending the information file to the first process specifically includes:
creating an information file corresponding to the arbitrary waveform generator;
writing the machine box number and the slot number corresponding to the arbitrary waveform generator into the information file;
and sending a preset specified signal to the first process so that the first process obtains the information file according to the preset specified signal.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111542848.3A CN114237344B (en) | 2021-12-16 | 2021-12-16 | Arbitrary waveform generator process changing method, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111542848.3A CN114237344B (en) | 2021-12-16 | 2021-12-16 | Arbitrary waveform generator process changing method, equipment and medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114237344A CN114237344A (en) | 2022-03-25 |
CN114237344B true CN114237344B (en) | 2023-05-19 |
Family
ID=80757103
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111542848.3A Active CN114237344B (en) | 2021-12-16 | 2021-12-16 | Arbitrary waveform generator process changing method, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114237344B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2018079272A (en) * | 2016-11-18 | 2018-05-24 | 株式会社テクノリード | Waveform generator |
CN113419597A (en) * | 2021-07-12 | 2021-09-21 | 山东浪潮科学研究院有限公司 | Working method, equipment and medium of arbitrary waveform generator |
CN113468086A (en) * | 2021-06-23 | 2021-10-01 | 山东浪潮科学研究院有限公司 | PXIe case expansion method, equipment and medium |
-
2021
- 2021-12-16 CN CN202111542848.3A patent/CN114237344B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2018079272A (en) * | 2016-11-18 | 2018-05-24 | 株式会社テクノリード | Waveform generator |
CN113468086A (en) * | 2021-06-23 | 2021-10-01 | 山东浪潮科学研究院有限公司 | PXIe case expansion method, equipment and medium |
CN113419597A (en) * | 2021-07-12 | 2021-09-21 | 山东浪潮科学研究院有限公司 | Working method, equipment and medium of arbitrary waveform generator |
Non-Patent Citations (1)
Title |
---|
基于PXIe接口的任意波形发生器访问方法研究;李清石;《信息技术与信息化》;全文 * |
Also Published As
Publication number | Publication date |
---|---|
CN114237344A (en) | 2022-03-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CA2002325C (en) | Method for observing the progress in time of an object program | |
Herbold | Crosspare: a tool for benchmarking cross-project defect predictions | |
De La Banda et al. | The future of optimization technology | |
Bánáti et al. | Four level provenance support to achieve portable reproducibility of scientific workflows | |
CN114237344B (en) | Arbitrary waveform generator process changing method, equipment and medium | |
Pasquini et al. | Modeling safety-critical systems with Z and Petri nets | |
WO2019047510A1 (en) | Ios platform dylib file hiding method, storage medium, electronic apparatus and system | |
CN107885489B (en) | Method and system for rapidly detecting real-name registration data indexes | |
Hao et al. | Testing fine-grained parallelism for the admm on a factor-graph | |
WO2021137901A1 (en) | Explainable process prediction | |
EP4185982A1 (en) | Design aware adaptive mixed-signal simulation | |
Beauquier et al. | Application of formal language theory to problems of security and synchronization | |
CN111241571A (en) | Data sharing method, model and storage medium | |
US10140436B1 (en) | Program obfuscation by reorganizing execution paths | |
Huang et al. | Self-adaptive containers: Building resource-efficient applications with low programmer overhead | |
Howar et al. | The teachers’ crowd: the impact of distributed oracles on active automata learning | |
Jin et al. | Reasoning about block-based cloud storage systems via separation logic | |
Djelassi | Discretization-based algorithms for the global solution of hierarchical programs | |
CN104572655A (en) | Data processing method, device and system | |
Stramaglia et al. | Formal verification of an industrial UML-like model using mCRL2 | |
WO2012088589A1 (en) | System and method for assigning executable functions to available processors in a multiprocessing environment | |
Drozdowski et al. | Isoefficiency maps for divisible computations in hierarchical memory systems | |
Kersting et al. | Se4ml-software engineering for ai-ml-based systems (dagstuhl seminar 20091) | |
Pieume et al. | A method for solving bilevel linear programming problems | |
Wu et al. | An empirical study on C++ concurrency constructs |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |