如何使用compactRIO數位輸入模組,將數位訊號轉為數值?

< http-equiv=“content-” content=“text/; charset=utf-8”>< name=“progid” content=“word.”>< name=“generator” content=“microsoft word 12”>< name=“originator” content=“microsoft word 12”><!–[if !mso]>

v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);}

<![endif]–><!–[if gte mso 9]><>
<w:word>
<w:view>Normal</w:view>
<w:zoom>0</w:zoom>
<w:trackmoves>false</w:trackmoves>
<w:trackatting/>
<w:punctuationkerning/>
<w:displayhorizontaldrawinggridevery>0</w:displayhorizontaldrawinggridevery>
<w:displayverticaldrawinggridevery>2</w:displayverticaldrawinggridevery>
<w:validateagainstschemas/>
<w:saveifinvalid>false</w:saveifinvalid>
<w:ignoremixedcontent>false</w:ignoremixedcontent>
<w:alwaysshowplaceholdertext>false</w:alwaysshowplaceholdertext>
<w:donotpromoteqf/>
<w:lidthemeother>EN-US</w:lidthemeother>
<w:lidthemeasian>ZH-TW</w:lidthemeasian>
<w:lidthemecomplex>X-NONE</w:lidthemecomplex>
<w:compatibility>
<w:spaceforul/>
<w:balancesinglebytedoublebytewidth/>
<w:donotleavebackslashalone/>
<w:ultrailspace/>
<w:donotexpandshiftreturn/>
<w:adjustlineheightintable/>
<w:breakwrappedtables/>
<w:snaptogridincell/>
<w:wraptextwithpunct/>
<w:useasianbreakrules/>
<w:dontgrowautofit/>
<w:splitpgbreakandark/>
<w:dontvertaligncellwithsp/>
<w:dontbreakconstrainedforcedtables/>
<w:dontvertalignintxbx/>
<w:word11kerningpairs/>
<w:cachedcolbalance/>
<w:usefelayout/>
</w:compatibility>
<w:browserlevel>MicrosoftInternetExplorer4</w:browserlevel>
<m:mathpr>
<m:mathfont m:val=“cambria math”/>
<m:brkbin m:val=“before”/>
<m:brkbinsub m:val=“–”/>
<m:smallfrac m:val=“off”/>
<m:dispdef/>
<m:lmargin m:val=“0”/>
<m:rmargin m:val=“0”/>
<m:defjc m:val=“centergroup”/>
<m:wrapindent m:val=“1440”/>
<m:intlim m:val=“subsup”/>
<m:narylim m:val=“undovr”/>
</m:mathpr></w:word>
</><![endif]–>

<!–[if gte mso 10]>

/* Style Definitions */ table.MsoNormalTable {mso-style-name:表格內文; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; mso-bidi-font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-font-kerning:1.0pt;}

<![endif]–>

各位labview大大先進您們好;
  
小弟最近也加入labview新手一員,開始摸索cRIO模組,想利用NI-9474數位輸出模組送出數值(如十進制12數值),再由數位數入NI-9411模組接收數位訊號,將數位訊號解讀還原為十進至12數值,小弟將數位輸出部分(9474模組)利用一條CLOCK(9474 DO0 channel)當作trigger 訊號和一條DATA(9474 DO1  channel)方式撰寫,


但數位輸入部分(9411模組)不知該如何下手,才能將數位訊號轉換還原成數值呢?所以在此有請Labviewe高手先進們多多指教指點,教教小弟.

可以使用boolean>>array to num或boolean to 0,1

 

非常感謝<span =“bold”>ancle您的回答
但我碰到的問題在於數位輸入模組(NI-9411)該如何去抓trigger訊號與資料訊號後顯示數值.

你可以使用以下vi判斷是rising或falling edge或二者都是時來擷取DI的信號,至於擷取DI訊號的範例,利用find examples...搜尋digital就有範例可參考

PS.上述vi是指使用在RT端,擷取DI的範例指的是在FPGA端

ancle39820.373287037

<span =“bold”>ancle您好;
    感謝您的答覆與建議,依照提示方向進行撰寫!謝謝您.

不知你的問題解決沒

最近也在玩這塊

分享一些寫法

FPGA內的正緣與負緣判斷