The automatic beverage machine system designed using the virtual instrument technology LabVIEW can be used to simulate the real automatic beverage machine system to work. Using virtual instrument technology, engineers can use the graphical development software Lahview to conveniently and efficiently create a completely customized solution to meet the flexible and changing demand trends.
The automatic beverage machine system designed in this paper is completed by making full use of the unique and powerful state machine technology of the virtual instrument labview technology, eliminating the cumbersome traditional programming language and making it very convenient to update and maintain.
1 Overall design plan
1.1 Implemented Functions
The main functions are: automatic beverage machine, which realizes: one is to put money in, two is to deliver goods, and three is to give change.
1.2 Design Idea
Figure 1 intuitively shows the situation when coins of different amounts are inserted into the Coke machine, as well as the various states of each processing step and the conversion relationship between them. According to the different denominations of the coins inserted, the total amount is calculated, and various operations are responded to to complete a purchase.
2. Program Design
The biggest feature of Labview programming is the graphical programming language, plus a very rich function library, which makes program design very simple and intuitive. The program design of the automatic beverage machine system is to make full use of some of the rich function libraries in Labview.
Special functions realize corresponding functions, and the state machine technology in LabVIEW is used to realize the overall programming ideas.
2.1 State Machine Mode Diagram
Figure 2 is a classic diagram of the state machine in Labview
2.2 Overall program flowchart design
Figure 3 uses the classic structure of the state machine in Labview. The outermost layer is the while loop, and the inner layer is the conditional structure, which is just a multi-branch conditional structure. The third part is the shift register, which transfers the instruction to the next loop state judgment. In addition, in the state shown in Figure 3, the initial state, the execution steps of each state, and the code for switching to the next state, etc. are provided.
2.3 Design of the automatic beverage machine interface
The state shown in FIG. 4 is an interface of the front panel of the automatic beverage machine in operation.
2.4 Key Technologies
The automatic beverage machine system is designed using virtual instrument technology labview, which has its own unique technical features.
2.4.1 Use of state machine
The classic state machine mode combines the while loop, conditional structure and shift register, making the originally complex programming of the workflow diagram in Figure 1 clear and simple. The conditional structure is a multi-branch conditional mechanism, and the shift register uses two shift registers, one for executing the state instruction to transfer to the next state, and the other for accumulating the amount of coins to determine the working state.
2.4.2 Convert array
Although the conditional structure can solve the problem of multi-state selection, it is not very intuitive in structure and not convenient to manage. You can put all the states to be selected into an array, and directly index the next state from the array to the shift register by judging the subVI output of different index values. See Figure 5.
In addition, the automatic beverage machine system also uses a lot of other functions, making the programming very concise.
2.5 Operation Results Analysis
Analysis of running results: The three functions of the automatic beverage machine system - coin insertion, delivery and change - are realized, which meets the design expectations. In addition, although the system only provides one beverage, if you want to provide more beverages with different prices, you only need to add a subVI to select different beverages.
3 Conclusion
The state machine technology in the virtual instrument technology labview is used to design the automatic beverage machine system. The idea is clear, and programming, debugging and adding functions are very simple. It is very suitable for college students' practical innovation projects and graduation design projects, and provides a reference for related enterprises to design and produce self-service equipment.
Another major benefit of using state machine technology in the vending machine designed in this article is that compared with other technologies, state machine technology is more convenient and concise in maintaining automatic updates or adding functions.
This article is just a classic application of typical state machine technology. In fact, the state machine technology in LabVIEW is widely used. Automatic ticket vending machines, ATMs, etc. can all be designed using state machine technology.
Therefore, the development of this system has certain practical significance and theoretical value whether for learning, instrument development, or practical application.
Previous article:Design and implementation of IGBT module test system based on LabVIEW
Next article:Automated testing of vehicle daytime running lights based on LabVIEW
- Popular Resources
- Popular amplifiers
- Keysight Technologies Helps Samsung Electronics Successfully Validate FiRa® 2.0 Safe Distance Measurement Test Case
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- Seizing the Opportunities in the Chinese Application Market: NI's Challenges and Answers
- Tektronix Launches Breakthrough Power Measurement Tools to Accelerate Innovation as Global Electrification Accelerates
- Not all oscilloscopes are created equal: Why ADCs and low noise floor matter
- Enable TekHSI high-speed interface function to accelerate the remote transmission of waveform data
- How to measure the quality of soft start thyristor
- How to use a multimeter to judge whether a soft starter is good or bad
- What are the advantages and disadvantages of non-contact temperature sensors?
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Keysight Technologies Helps Samsung Electronics Successfully Validate FiRa® 2.0 Safe Distance Measurement Test Case
- Innovation is not limited to Meizhi, Welling will appear at the 2024 China Home Appliance Technology Conference
- Innovation is not limited to Meizhi, Welling will appear at the 2024 China Home Appliance Technology Conference
- Huawei's Strategic Department Director Gai Gang: The cumulative installed base of open source Euler operating system exceeds 10 million sets
- Download from the Internet--ARM Getting Started Notes
- Learn ARM development(22)
- Learn ARM development(21)
- Learn ARM development(20)
- Learn ARM development(19)
- Learn ARM development(14)
- After the stm32 timer is set to input capture, can the level of TI1 be changed by software?
- DSP library expands TI's embedded vision engine for driver assistance systems
- STM32 Cube study notes (16 articles)
- 3D Printer Controller Project Report
- STM32 HAL library UART interrupt reception issue
- 3 RTC configuration and timed wake-up
- Altium Designer 18 official tutorial Chinese and English version
- Selection requirements for electromagnet freewheeling diodes
- PSpice simulation integral circuit output problem
- EEWORLD University Hall----TIDA-01040 High Current Battery Test Equipment Reference Solution