NI產品與技術 討論區

取消
顯示結果 
搜尋替代 
您的意思是: 

請用如何用labview寫出類似提款機的程式

我想做個充電站的人機介面 就是類似提款機的那樣  可以輸入帳號 密碼 然後充電的選擇 之類的...

0 積分
1 條訊息(共 3 條)
6,454 檢視

Hi,

 

That would be interesting one 🙂 And, perhaps, you might want to start it with...

 

 

  1. System program flow-chart (including GUI/HMI, data-flow etc)
  2. Design GUI/ HMI (Front Panels) according to your flow-chart
  3. LabVIEW Coding
 
1. Since you already know what you want i.e. ATM-like GUI/HMI, you may design each of the intended GUI/HMI and having its Input and Output (based on the data-flow) connectors ready.
 
2. With proper data-flow design, each of the intended GUI/HMI may be coded separately (as sub-VI {sub-Front Panel}), and finally called through a main (caller) VI.
 
3. LabVIEW coding portion will very much depending on your experience in LabVIEW programming. Try look for LabVIEW shipped examples, examples in the forums, or even fro external sites.
 
Happy coding! 😉 

 

Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010, 2014
依恩与LabVIEW
LVVILIB.blogspot.com
0 積分
2 條訊息(共 3 條)
6,430 檢視

軟軟您好,

 

不知道您之前曾經寫過LabVIEW程式嗎?

如果沒有的話,建議您可以參加NI舉辦的實機操作課程,並配合坊間的一些相關書籍,來對LabVIEW有初步的認識與瞭解。

如果您寫過LabVIEW的程式,ian所講的方式非常適合,建議您可以依照下列的步驟進行:

 

1. 設計基本的人機介面

2. 將您所要的所有動作/功能以流程圖畫出來

3. 將每個部分的功能寫成一個subVI (即子程式)

4. 在主程式中加入各subVI,完成程式框架

5. 測試與debug

 

可以的話,使用狀態機(state machine)的方式來撰寫,會使程式架構更漂亮、容易維護。

 

多參考LabVIEW中的範例、以及NI網頁上的範例,對提升程式能力會很有幫助,同時也許能只到現成的程式,做些修改即可套用。

 

 

 

Rebecca

NITW Application Engineer 

 

 

3 條訊息(共 3 條)
6,422 檢視