Hallo Ich habe jetzt mal Soft-Uart testen wollen, doch habe ich nichts angezeigt bekommen. Woran kann es liegen ???
Dazu habe ich zwei Mega 32 Boards verbunden. Board 1 (Hardware Uart) <-> Board 2 (Software Uart) und dann noch Board 2 (Hardware Uart) <-> PC
Die Codes : Board1 :
Board 2:Code:$regfile = "m32def.dat" $crystal = 16000000 $baud = 9600 $hwstack = 32 $swstack = 32 $framesize = 32 Config Portd.7 = Output Wait 1 Sound Portd.7 , 400 , 450 Sound Portd.7 , 400 , 250 Sound Portd.7 , 400 , 450 Wait 2 Do Print "Hallo" Waitms 400 Loop End
Code:$regfile = "m32def.dat" $crystal = 16000000 $baud = 9600 $hwstack = 32 $swstack = 32 $framesize = 32 Open "Comb.0: 9600 , 8 , n , 1" for Input As #1 Open "Comb.1: 9600 , 8 , n , 1" For Output As #2 Config Portd.7 = Output 'Summer Dim K As String * 11 Waitms 50 Sound Portd.7 , 400 , 450 'Summer summt : Alles OK Sound Portd.7 , 400 , 250 Sound Portd.7 , 400 , 450 Wait 50 Do Input #1 , K Print K Loop End







Zitieren

Lesezeichen