
Originally Posted by
Philtkp
Private Sub Check1_Click(index As Integer)
'
' Convert PORTB check box to decimal value before sending it
' to USB bus. Result is store in BufferOut(1)
'
Dim LoopCheck, PORTB As Byte
PORTB = 0
For LoopCheck = 0 to 15 ' 0 To 7
PORTB = PORTB + (Check1(LoopCheck).Value * (2 ^ LoopCheck))
Next
BufferOut(1) = PORTB
WriteSomeData
End Sub
Bookmarks