so: (es geht sogar schon getestet)Ne Manchesterkodierung wäre sicher was feines, aber wie erzeugen?
jaja ich fühl mich schon mies wegen dem benutzten String aber liefert mir ne bessere Möglichkeit ich hatte nu kein bock mehrCode:$regfile = "m8def.dat" $crystal = 7372800 Declare Function M2b(byval Minput As Word) As Byte Declare Function B2m(byval Binput As Byte) As Word Dim W As Byte Dim W2 As Word Dim I As Byte Dim I2 As Byte Dim S As String * 16 W = M2b(&B0110011001100110) W2 = B2m(&B01010101) Function M2b(byval Minput As Word) As Byte For I = 0 To 15 Step 2 I2 = I / 2 Select Case Minput.i Case 1 : M2b.i2 = 0 Case 0 : M2b.i2 = 1 End Select Next End Function Function B2m(byval Binput As Byte ) As Word For I = 7 To 0 Step -1 Select Case Binput.i Case 0 : S = S + "01" Case 1 : S = S + "10" End Select Next B2m = Binval(s) End Function End![]()
Martin







Zitieren

Lesezeichen