InBCD方法

描述
傳回8個輸入的輸入狀態(使用BCD格式)。(二進位十進碼)

語法
Function InBCD (PortNumber As Integer) As Integer
Function InBCD (Label As String) As Integer

參數

  • PortNumber
    代表輸入埠的整數
  • Label
    代表輸入位元組標籤的字串運算式。

傳回值
介於0至9的整數,代表輸入埠的狀態。
另請參閱
In方法, Out方法, OpBCD方法, Sw方法

InBCD範例
VB 例:

Dim port1Value As Integer  
port1Value = m_spel.InBCD(1)  

C# 例:

int port1Value;  
port1Value = m_spel.InBCD(1);