Overview
This VI shows how to use the producer/consumer architecture to queue up keyboard inputs in the producer loop and perform actions based on the input in the consumer loop.
Description
Use this template to build a producer/consumer design pattern with events to produce queue items. Use this design pattern instead of the User Interface Event Handler pattern for user interfaces when you want to execute code asynchronously in response to an event without slowing the user interface responsiveness.
Requirements
- LabVIEW 2012 (or compatible)
Steps to Implement or Execute Code
- Run the VI, press the "F" key will toggle the indicator and wait for 1 second.
- If you press the "F" key faster than once per second, the presses are queued up to demonstrate that no input is lost.
Additional Information or References
VI Snippet
**This document has been updated to meet the current required format for the NI Code Exchange.**