What method should be used to pass data between two loops? Of course, local variable is OK, but if data is passed between the data acquisition loop and the data storage loop, local variable is not enough. Because saving data to the hard disk is a time-consuming task, and data collection requires high cycle time, it is impossible to simply pass data through local variable between the two.
Between the data acquisition loop and the data storage loop, we can pass data through Queue (queue). The name Queue is very intuitive. Imagine that the data acquisition cycle ranks the collected data in a queue, and the data storage cycle takes one data from the head of the queue for storage each time. What a clever idea. LabVIEW provides us with the VIs required to operate Queue. The main commonly used ones are: Obtain Queue (get or create a queue), Release Queue (release a queue), Enqueue Element (data entry), Dequeue Element (data exit), Get Queue Status (get queue status). There are also several VIs. You can view the relevant instructions when needed.
Notifier is actually a special queue. There will only be one data in this queue. When new data is sent to the queue, the old data will be overwritten. So, what's the use of Notifier? It can be used to perform flow control between cycles. Regarding how to control the process between cycles, I won’t go into it here. There will be an example to show in the next article soon. The main commonly used VIs for operation Notifier provided by LabVIEW are: Obtain Notifier (get or build notifier), Release Notifier (release Notifier), Send Notification (send notification), Cancel Notification, Get Notifier Status (get Notifier status), Wait On Notification (wait for notification). For several other VIs, you can check the relevant instructions when needed.
Between the data acquisition loop and the data storage loop, we can pass data through Queue (queue). The name Queue is very intuitive. Imagine that the data acquisition cycle ranks the collected data in a queue, and the data storage cycle takes one data from the head of the queue for storage each time. What a clever idea. LabVIEW provides us with the VIs required to operate Queue. The main commonly used ones are: Obtain Queue (get or create a queue), Release Queue (release a queue), Enqueue Element (data entry), Dequeue Element (data exit), Get Queue Status (get queue status). There are also several VIs. You can view the relevant instructions when needed.
Notifier is actually a special queue. There will only be one data in this queue. When new data is sent to the queue, the old data will be overwritten. So, what's the use of Notifier? It can be used to perform flow control between cycles. Regarding how to control the process between cycles, I won’t go into it here. There will be an example to show in the next article soon. The main commonly used VIs for operation Notifier provided by LabVIEW are: Obtain Notifier (get or build notifier), Release Notifier (release Notifier), Send Notification (send notification), Cancel Notification, Get Notifier Status (get Notifier status), Wait On Notification (wait for notification). For several other VIs, you can check the relevant instructions when needed.